From 05732251c115b3538879ca523c461572115c6526 Mon Sep 17 00:00:00 2001 From: Bent Bisballe Nyeng Date: Thu, 23 Aug 2012 13:31:54 +0200 Subject: Block click on buttons while waiting for close. --- client/mainwindow.cc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/client/mainwindow.cc b/client/mainwindow.cc index 121412e..9e62e5d 100644 --- a/client/mainwindow.cc +++ b/client/mainwindow.cc @@ -164,6 +164,8 @@ bool MainWindow::hasOpen(void *me) void MainWindow::closeCommit() { + if(closing) return; + if(hasOpen(NULL)) { MessageBox::warning(this, tr("Close first."), tr("Close open macros first.")); @@ -176,6 +178,8 @@ void MainWindow::closeCommit() void MainWindow::closeNoCommit() { + if(closing) return; + if(hasOpen(NULL)) { MessageBox::warning(this, tr("Close first."), tr("Close open macros first.")); @@ -188,6 +192,8 @@ void MainWindow::closeNoCommit() void MainWindow::closeDiscard() { + if(closing) return; + if(hasOpen(NULL)) { MessageBox::warning(this, tr("Close first."), tr("Close open macros first.")); -- cgit v1.2.3 From 6d586584f530035b46dfedf88c30c719c8cc0dbd Mon Sep 17 00:00:00 2001 From: senator Date: Mon, 27 Aug 2012 08:56:46 +0200 Subject: Ticked version to 2.2.3 --- client/client.pro | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/client.pro b/client/client.pro index 5e16942..ab25177 100644 --- a/client/client.pro +++ b/client/client.pro @@ -16,7 +16,7 @@ debug { DEFINES+=USE_DEBUG } -DEFINES+=VERSION=\\\"2.2.2\\\" +DEFINES+=VERSION=\\\"2.2.3\\\" win32 { QMAKE_LIBDIR += lua/lib -- cgit v1.2.3 From db3b3fed726527600aa37f3310de13439571f04d Mon Sep 17 00:00:00 2001 From: Bent Bisballe Nyeng Date: Fri, 7 Sep 2012 10:28:47 +0200 Subject: Disable all macro entities when commit/nocommit/discard has been pressed, until an answer has been received. --- client/mainwindow.cc | 18 ++++++++++++++++++ client/mainwindow.h | 1 + 2 files changed, 19 insertions(+) diff --git a/client/mainwindow.cc b/client/mainwindow.cc index 756f759..7bf4116 100644 --- a/client/mainwindow.cc +++ b/client/mainwindow.cc @@ -161,6 +161,14 @@ bool MainWindow::hasOpen(void *me) return false; } +void MainWindow::enableEntities(bool enable) +{ + Entities::iterator i = entities.begin(); + while(i != entities.end()) { + i.value()->widget()->setEnabled(enable); + i++; + } +} void MainWindow::closeCommit() { @@ -171,6 +179,9 @@ void MainWindow::closeCommit() tr("Close open macros first.")); return; } + + enableEntities(false); + netcom.commit(); // isStored = true; closing = true; @@ -185,6 +196,9 @@ void MainWindow::closeNoCommit() tr("Close open macros first.")); return; } + + enableEntities(false); + netcom.nocommit(); // isStored = true; closing = true; @@ -209,6 +223,8 @@ void MainWindow::closeDiscard() MessageBox::Yes | MessageBox::No); if(res == MessageBox::Yes) { + enableEntities(false); + netcom.discard(); // isStored = true; closing = true; @@ -394,6 +410,8 @@ void MainWindow::setTemplate(QString name) void MainWindow::handle(QDomDocument &doc) { + enableEntities(true); + DEBUG(mainwindow, "Handle %s\n", doc.toString().toStdString().c_str()); diff --git a/client/mainwindow.h b/client/mainwindow.h index ad96154..70519b3 100644 --- a/client/mainwindow.h +++ b/client/mainwindow.h @@ -65,6 +65,7 @@ public slots: void setTemplate(QString name); private: + void enableEntities(bool enable); void updateTemplates(QDomNodeList &nodes); void updateMacros(QDomNodeList &nodes); void updateTemplateHeaders(QDomNode &templatenode); -- cgit v1.2.3 From 39777a9f5ea2b0761028f6db6dbc071ea2ad7c60 Mon Sep 17 00:00:00 2001 From: Bent Bisballe Nyeng Date: Fri, 7 Sep 2012 10:29:36 +0200 Subject: Bump version to 2.2.4 --- client/client.pro | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/client.pro b/client/client.pro index ab25177..e9b2c29 100644 --- a/client/client.pro +++ b/client/client.pro @@ -16,7 +16,7 @@ debug { DEFINES+=USE_DEBUG } -DEFINES+=VERSION=\\\"2.2.3\\\" +DEFINES+=VERSION=\\\"2.2.4\\\" win32 { QMAKE_LIBDIR += lua/lib -- cgit v1.2.3