Commit 1926f363 by Carwyn

1. 设置界面代码上传

parent ad13983a
...@@ -3,8 +3,12 @@ ...@@ -3,8 +3,12 @@
#include <fmp_logger_i.h> #include <fmp_logger_i.h>
#include <ctkServiceReference.h> #include <ctkServiceReference.h>
#include <ctkPluginContext.h> #include <ctkPluginContext.h>
#include "ui/window.h"
#include <QDebug> #include <QDebug>
#ifdef Q_OS_WIN
#undef StartService
#endif
/** /**
* @brief The FMPSettings class * @brief The FMPSettings class
...@@ -72,6 +76,10 @@ int FMPSettingsPrivate::Init() ...@@ -72,6 +76,10 @@ int FMPSettingsPrivate::Init()
if (!_sets) { if (!_sets) {
_sets = new QSettings(_ctx->getProperty(FMP_PROPKEY_CFG).toString(), QSettings::IniFormat); _sets = new QSettings(_ctx->getProperty(FMP_PROPKEY_CFG).toString(), QSettings::IniFormat);
} }
else {
FMPSettingsWindow * set_dlg = new FMPSettingsWindow;
set_dlg->show();
}
return FMP_SUCCESS; return FMP_SUCCESS;
} }
......
...@@ -4,16 +4,18 @@ ...@@ -4,16 +4,18 @@
# #
#------------------------------------------------- #-------------------------------------------------
QT -= gui QT += widgets
TEMPLATE = lib TEMPLATE = lib
SOURCES += fmp_settings.cpp \ SOURCES += fmp_settings.cpp \
fmp_settings_plugin.cpp fmp_settings_plugin.cpp \
ui/window.cpp
HEADERS += fmp_settings.h \ HEADERS += fmp_settings.h \
fmp_settings_i.h \ fmp_settings_i.h \
fmp_settings_plugin_p.h \ fmp_settings_plugin_p.h \
fmp_settings_def.h fmp_settings_def.h \
ui/window.h
unix { unix {
target.path = /usr/lib target.path = /usr/lib
...@@ -28,6 +30,7 @@ TARGET = $${TARGET}_$${VER} ...@@ -28,6 +30,7 @@ TARGET = $${TARGET}_$${VER}
#Header path #Header path
INCLUDEPATH += $$PWD/../include/ctk \ INCLUDEPATH += $$PWD/../include/ctk \
+= $$PWD/../include/interface \ += $$PWD/../include/interface \
+= $$PWD/../include/window
#Library path #Library path
LIBS += -L$$PWD/../lib LIBS += -L$$PWD/../lib
...@@ -44,12 +47,18 @@ CONFIG(debug, debug|release) { ...@@ -44,12 +47,18 @@ CONFIG(debug, debug|release) {
# #
RESOURCES += \ RESOURCES += \
res/$${ORIGIN_TARGET}.qrc res/$${ORIGIN_TARGET}.qrc \
res/images.qrc
win32 { win32 {
RC_FILE += res/$${ORIGIN_TARGET}.rc RC_FILE += res/$${ORIGIN_TARGET}.rc
system($$PWD/../fmprc.bat $$PWD/version.h $$ORIGIN_TARGET) system($$PWD/../fmprc.bat $$PWD/version.h $$ORIGIN_TARGET)
LIBS += -luser32
} }
else { else {
system($$PWD/../fmprc.sh $$PWD/version.h $$ORIGIN_TARGET) system($$PWD/../fmprc.sh $$PWD/version.h $$ORIGIN_TARGET)
} }
FORMS += \
ui/window.ui
<RCC>
<qresource prefix="/">
<file>images/arrow_down.png</file>
</qresource>
</RCC>
#include "window.h"
#include "ui_window.h"
FMPSettingsWindow::FMPSettingsWindow(QWidget *parent) :
FMPWindow(parent),
ui(new Ui::FMPSettingsWindow)
{
ui->setupUi(this);
connect(ui->btn_close, SIGNAL(clicked(bool)), SLOT(close()));
}
FMPSettingsWindow::~FMPSettingsWindow()
{
delete ui;
}
#ifndef FMP_SETS_DLG_H
#define FMP_SETS_DLG_H
#include <fmp_window.hpp>
#include <QWidget>
namespace Ui {
class FMPSettingsWindow;
}
class FMPSettingsWindow : public FMPWindow
{
Q_OBJECT
public:
explicit FMPSettingsWindow(QWidget *parent = 0);
~FMPSettingsWindow();
private:
Ui::FMPSettingsWindow *ui;
};
#endif // FMP_SETS_DLG_H
This diff is collapsed. Click to expand it.
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
#define VER_MINOR 1 #define VER_MINOR 1
#define VER_REVISION 0 #define VER_REVISION 0
#define VER_BUILD 5 #define VER_BUILD 6
//! Convert version numbers to string //! Convert version numbers to string
#define _STR(S) #S #define _STR(S) #S
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment