如图所示,如何修改代码让点击时就预览?
#include "CodepageSelectionDialog.h"
#include "ui_CodepageSelectionDialog.h"
#include "Bridge.h"
#include <QTextCodec>
#include "MiscUtil.h"
CodepageSelectionDialog::CodepageSelectionDialog(QWidget* parent) :
QDialog(parent),
ui(new Ui::CodepageSelectionDialog)
{
ui->setupUi(this);
setModal(true);
setWindowFlags(windowFlags() & ~Qt::WindowContextHelpButtonHint | Qt::MSWindowsFixedSizeDialogHint);
setWindowIcon(DIcon("codepage.png"));
for(auto & name : QTextCodec::availableCodecs())
{
auto codec = QTextCodec::codecForName(name);
if(!codec)
continue;
ui->listCodepages->addItem(name);
mCodepages.append(codec->name());
}
duint setting;
if(BridgeSettingGetUint("Misc", "LastCodepage", &setting) && setting < duint(ui->listCodepages->count()))
ui->listCodepages->setCurrentRow(setting);
else
ui->listCodepages->setCurrentRow(0);
}
CodepageSelectionDialog::~CodepageSelectionDialog()
{
BridgeSettingSetUint("Misc", "LastCodepage", ui->listCodepages->currentRow());
delete ui;
}
QByteArray CodepageSelectionDialog::getSelectedCodepage()
{
return mCodepages;
}
楼主发的大部分帖子我都整不太明白 看不懂,楼主能多打几个字么。。。 七度 发表于 2021-11-9 11:43
看不懂,楼主能多打几个字么。。。
没用过x32dbg,看来是不能理解不方便之处的。
页:
[1]