mirror of
https://github.com/rizinorg/cutter.git
synced 2025-01-18 18:38:51 +00:00
added show jump lines in disassembly (#286)
This commit is contained in:
parent
98c6c0a56e
commit
a7ce43784b
@ -507,6 +507,7 @@ void CutterCore::resetDefaultAsmOptions()
|
||||
setConfig("asm.offset", Config()->getAsmOffset());
|
||||
setConfig("asm.describe", Config()->getAsmDescribe());
|
||||
setConfig("asm.stackptr", Config()->getAsmStackPointer());
|
||||
setConfig("asm.lines", Config()->getAsmLines());
|
||||
setConfig("asm.bytes", Config()->getAsmBytes());
|
||||
setConfig("asm.bytespace", Config()->getAsmBytespace());
|
||||
setConfig("asm.lbytes", Config()->getAsmLBytes());
|
||||
@ -525,6 +526,7 @@ void CutterCore::saveDefaultAsmOptions()
|
||||
Config()->setAsmOffset(getConfigb("asm.offset"));
|
||||
Config()->setAsmDescribe(getConfigb("asm.describe"));
|
||||
Config()->setAsmStackPointer(getConfigb("asm.stackptr"));
|
||||
Config()->setAsmLines(getConfigb("asm.lines"));
|
||||
Config()->setAsmBytes(getConfigb("asm.bytes"));
|
||||
Config()->setAsmBytespace(getConfigb("asm.bytespace"));
|
||||
Config()->setAsmLBytes(getConfigb("asm.lbytes"));
|
||||
@ -760,7 +762,6 @@ void CutterCore::getOpcodes()
|
||||
void CutterCore::setSettings()
|
||||
{
|
||||
setConfig("scr.interactive", false);
|
||||
setConfig("asm.lines", false);
|
||||
// Intredazting...
|
||||
//setConfig("asm.linesright", "true");
|
||||
//setConfig("asm.lineswidth", "15");
|
||||
|
@ -40,6 +40,7 @@ void AsmOptionsWidget::updateAsmOptionsFromVars()
|
||||
qhelpers::setCheckedWithoutSignals(ui->offsetCheckBox, Core()->getConfigb("asm.offset"));
|
||||
qhelpers::setCheckedWithoutSignals(ui->describeCheckBox, Core()->getConfigb("asm.describe"));
|
||||
qhelpers::setCheckedWithoutSignals(ui->stackpointerCheckBox, Core()->getConfigb("asm.stackptr"));
|
||||
qhelpers::setCheckedWithoutSignals(ui->linesCheckBox, Core()->getConfigb("asm.lines"));
|
||||
|
||||
bool bytesEnabled = Core()->getConfigb("asm.bytes");
|
||||
qhelpers::setCheckedWithoutSignals(ui->bytesCheckBox, bytesEnabled);
|
||||
@ -134,6 +135,12 @@ void AsmOptionsWidget::on_stackpointerCheckBox_toggled(bool checked)
|
||||
triggerAsmOptionsChanged();
|
||||
}
|
||||
|
||||
void AsmOptionsWidget::on_linesCheckBox_toggled(bool checked)
|
||||
{
|
||||
Core()->setConfig("asm.lines", checked);
|
||||
triggerAsmOptionsChanged();
|
||||
}
|
||||
|
||||
void AsmOptionsWidget::on_bytesCheckBox_toggled(bool checked)
|
||||
{
|
||||
Core()->setConfig("asm.bytes", checked);
|
||||
@ -225,4 +232,4 @@ void AsmOptionsWidget::on_buttonBox_clicked(QAbstractButton *button)
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -39,6 +39,7 @@ private slots:
|
||||
void on_offsetCheckBox_toggled(bool checked);
|
||||
void on_describeCheckBox_toggled(bool checked);
|
||||
void on_stackpointerCheckBox_toggled(bool checked);
|
||||
void on_linesCheckBox_toggled(bool checked);
|
||||
void on_bytesCheckBox_toggled(bool checked);
|
||||
void on_bytespaceCheckBox_toggled(bool checked);
|
||||
void on_lbytesCheckBox_toggled(bool checked);
|
||||
|
@ -6,8 +6,8 @@
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>461</width>
|
||||
<height>463</height>
|
||||
<width>541</width>
|
||||
<height>478</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
@ -49,6 +49,13 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="linesCheckBox">
|
||||
<property name="text">
|
||||
<string>Show jump lines (asm.lines)</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="bytesCheckBox">
|
||||
<property name="text">
|
||||
|
@ -58,6 +58,9 @@ public:
|
||||
bool getAsmStackPointer() const { return s.value("asm.stackptr", false).toBool(); }
|
||||
void setAsmStackPointer(bool v) { s.setValue("asm.stackptr", v); }
|
||||
|
||||
bool getAsmLines() const { return s.value("asm.lines", false).toBool(); }
|
||||
void setAsmLines(bool v) { s.setValue("asm.lines", v); }
|
||||
|
||||
bool getAsmBytes() const { return s.value("asm.bytes", false).toBool(); }
|
||||
void setAsmBytes(bool v) { s.setValue("asm.bytes", v); }
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user