Now icon.png is copied
This commit is contained in:
parent
915c46ee74
commit
846a5c35bb
|
@ -72,3 +72,10 @@ target_link_libraries(contractNotifier Qt5::Core Qt5::Widgets Boost::serializati
|
|||
if (WIN32)
|
||||
target_link_libraries(contractNotifier Qt5::Core Qt5::Widgets Boost::serialization ${CMAKE_THREAD_LIBS_INIT} CURL::libcurl)
|
||||
endif(WIN32)
|
||||
|
||||
# res files:
|
||||
add_custom_command(
|
||||
TARGET contractNotifier POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy
|
||||
${CMAKE_SOURCE_DIR}/res/icon.png
|
||||
${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/icon.png)
|
||||
|
|
|
@ -24,25 +24,27 @@ MainWindow::MainWindow(QWidget *parent)
|
|||
else{
|
||||
show();
|
||||
activateWindow();}}});
|
||||
|
||||
}
|
||||
|
||||
MainWindow::~MainWindow() {
|
||||
|
||||
}
|
||||
|
||||
void MainWindow::closeEvent(QCloseEvent *event)
|
||||
{
|
||||
if(closing)
|
||||
{
|
||||
void MainWindow::closeEvent(QCloseEvent *event) {
|
||||
if(closing) {
|
||||
event->accept();
|
||||
}
|
||||
else
|
||||
{
|
||||
else {
|
||||
this->hide();
|
||||
event->ignore();
|
||||
}
|
||||
}
|
||||
|
||||
void MainWindow::onCloseBtn_clicked() {
|
||||
void MainWindow::on_closeBtn_clicked() {
|
||||
hide();
|
||||
}
|
||||
|
||||
void MainWindow::on_settingsBtn_clicked() {
|
||||
settingsWin* win = new settingsWin(this);
|
||||
win->show();
|
||||
}
|
||||
|
|
|
@ -8,6 +8,7 @@
|
|||
#include <QMessageBox>
|
||||
#include <QCloseEvent>
|
||||
#include "ui_mainwindow.h"
|
||||
#include "settingsWin.h"
|
||||
|
||||
namespace Ui {
|
||||
class mainWin;
|
||||
|
@ -21,8 +22,8 @@ public:
|
|||
~MainWindow();
|
||||
|
||||
private slots:
|
||||
void onCloseBtn_clicked();
|
||||
//void onSettingsBtn_clicked();
|
||||
void on_closeBtn_clicked();
|
||||
void on_settingsBtn_clicked();
|
||||
//void onDeleteBtn_clicked();
|
||||
//void onInfoBtn_clicked();
|
||||
void closeEvent(QCloseEvent *event) override;
|
||||
|
|
Loading…
Reference in New Issue