mirror of
https://github.com/rizinorg/cutter.git
synced 2024-12-18 19:06:10 +00:00
added a ';' delimiter and responsive dialog box (#1983)
This commit is contained in:
parent
12c1d2c5ab
commit
7fdd8117a9
@ -8,6 +8,8 @@ EditInstructionDialog::EditInstructionDialog(InstructionEditMode editMode, QWidg
|
||||
editMode(editMode)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
ui->lineEdit->setMinimumWidth(400);
|
||||
ui->instructionLabel->setWordWrap(true);
|
||||
setWindowFlags(windowFlags() & (~Qt::WindowContextHelpButtonHint));
|
||||
|
||||
connect(ui->lineEdit, SIGNAL(textEdited(const QString &)), this,
|
||||
@ -46,7 +48,7 @@ void EditInstructionDialog::updatePreview(const QString &input)
|
||||
return;
|
||||
} else if (editMode == EDIT_BYTES) {
|
||||
QByteArray data = CutterCore::hexStringToBytes(input);
|
||||
result = Core()->disassemble(data).simplified();
|
||||
result = Core()->disassemble(data).replace('\n', "; ");
|
||||
} else if (editMode == EDIT_TEXT) {
|
||||
QByteArray data = Core()->assemble(input);
|
||||
result = CutterCore::bytesToHexString(data).trimmed();
|
||||
|
@ -20,6 +20,9 @@
|
||||
<property name="spacing">
|
||||
<number>2</number>
|
||||
</property>
|
||||
<property name="sizeConstraint">
|
||||
<enum>QLayout::SetFixedSize</enum>
|
||||
</property>
|
||||
<property name="leftMargin">
|
||||
<number>2</number>
|
||||
</property>
|
||||
|
Loading…
Reference in New Issue
Block a user