mirror of
https://github.com/rizinorg/cutter.git
synced 2024-12-20 03:46:11 +00:00
Fixed DisassemblyWidget's eventFilter crash (#1111)
* Fixed DisassemblyWidget's eventFilter crash (usage of a non-initialized member before assignment) * Alignment fix, just to trigger appveyor build
This commit is contained in:
parent
3c27c62b2d
commit
1a748903e4
@ -583,8 +583,8 @@ void DisassemblyWidget::moveCursorRelative(bool up, bool page)
|
|||||||
|
|
||||||
bool DisassemblyWidget::eventFilter(QObject *obj, QEvent *event)
|
bool DisassemblyWidget::eventFilter(QObject *obj, QEvent *event)
|
||||||
{
|
{
|
||||||
/*if ((obj == mDisasTextEdit || obj == mDisasTextEdit->viewport())
|
if (event->type() == QEvent::MouseButtonDblClick
|
||||||
&& event->type() == QEvent::MouseButtonDblClick) {
|
&& (obj == mDisasTextEdit || obj == mDisasTextEdit->viewport())) {
|
||||||
QMouseEvent *mouseEvent = static_cast<QMouseEvent *>(event);
|
QMouseEvent *mouseEvent = static_cast<QMouseEvent *>(event);
|
||||||
|
|
||||||
QTextCursor cursor = mDisasTextEdit->cursorForPosition(QPoint(mouseEvent->x(), mouseEvent->y()));
|
QTextCursor cursor = mDisasTextEdit->cursorForPosition(QPoint(mouseEvent->x(), mouseEvent->y()));
|
||||||
@ -595,7 +595,7 @@ bool DisassemblyWidget::eventFilter(QObject *obj, QEvent *event)
|
|||||||
if (jump == RVA_INVALID) {
|
if (jump == RVA_INVALID) {
|
||||||
bool ok;
|
bool ok;
|
||||||
RVA xref = Core()->cmdj("axfj@" + QString::number(
|
RVA xref = Core()->cmdj("axfj@" + QString::number(
|
||||||
offset)).array().first().toObject().value("to").toVariant().toULongLong(&ok);
|
offset)).array().first().toObject().value("to").toVariant().toULongLong(&ok);
|
||||||
if (ok) {
|
if (ok) {
|
||||||
jump = xref;
|
jump = xref;
|
||||||
}
|
}
|
||||||
@ -606,7 +606,7 @@ bool DisassemblyWidget::eventFilter(QObject *obj, QEvent *event)
|
|||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}*/
|
}
|
||||||
return CutterDockWidget::eventFilter(obj, event);
|
return CutterDockWidget::eventFilter(obj, event);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user