修改设置界面为独立弹窗
This commit is contained in:
@ -6,6 +6,7 @@
|
||||
|
||||
#include "mainwindowlayout.h"
|
||||
#include "ui_MainWindowLayout.h"
|
||||
#include "mysettingsdialog.h"
|
||||
|
||||
MainWindowLayout::MainWindowLayout(QWidget *parent) :
|
||||
QWidget(parent), ui(new Ui::MainWindowLayout) {
|
||||
@ -47,10 +48,15 @@ void MainWindowLayout::resizeEvent(QResizeEvent *event) {
|
||||
|
||||
void MainWindowLayout::clickButton(QString text, QString url) {
|
||||
QString path = QApplication::applicationDirPath();
|
||||
path += "/startcalc.exe";
|
||||
path += "/app/startcalc.exe";
|
||||
if (text== QString::fromLocal8Bit("<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>")) {
|
||||
WinExec(path.toStdString().c_str(), SW_SHOW);
|
||||
}
|
||||
else if (text == QString::fromLocal8Bit("<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>")) {
|
||||
MySettingsDialog *settings = new MySettingsDialog;
|
||||
settings->exec();
|
||||
delete settings;
|
||||
}
|
||||
else{
|
||||
emit clickButton1(text, url);
|
||||
}
|
||||
|
Reference in New Issue
Block a user