This is an automated email from the git hooks/post-receive script.

x2go pushed a commit to branch bugfix/osx
in repository x2goclient.

commit 0b8c6d61b5d4742e23c7d57bd0626405a56d7b5b
Author: Mihai Moldovan <io...@ionic.de>
Date:   Wed Jun 22 02:45:45 2016 +0200

    src/x2goutils.{cpp,h}: add application modality parameter to 
show_RichText_Generic_MsgBox () and its wrappers.
---
 debian/changelog  |    2 ++
 src/x2goutils.cpp |   19 +++++++++++++------
 src/x2goutils.h   |    6 +++---
 3 files changed, 18 insertions(+), 9 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index afe6db7..4a6990b 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -318,6 +318,8 @@ x2goclient (4.0.5.3-0x2go1) UNRELEASED; urgency=medium
       a system PA binary shall be used.
     - src/pulsemanager.cpp: correctly initialize and set system_pulse_ when
       required.
+    - src/x2goutils.{cpp,h}: add application modality parameter to
+      show_RichText_Generic_MsgBox () and its wrappers.
 
  -- X2Go Release Manager <git-ad...@x2go.org>  Mon, 19 Sep 2016 09:07:07 +0200
 
diff --git a/src/x2goutils.cpp b/src/x2goutils.cpp
index eebd05c..ab109c1 100644
--- a/src/x2goutils.cpp
+++ b/src/x2goutils.cpp
@@ -94,7 +94,7 @@ QString convert_to_rich_text (const QString &text, bool 
force) {
   return (fixup_text);
 }
 
-void show_RichText_Generic_MsgBox (QMessageBox::Icon icon, const QString 
&main_text, const QString &informative_text) {
+void show_RichText_Generic_MsgBox (QMessageBox::Icon icon, const QString 
&main_text, const QString &informative_text, bool app_modal) {
   QString fixup_main_text (convert_to_rich_text (main_text));
   QString fixup_informative_text (convert_to_rich_text (informative_text, 
true));
 
@@ -102,16 +102,23 @@ void show_RichText_Generic_MsgBox (QMessageBox::Icon 
icon, const QString &main_t
 
   msg_box.setTextFormat (Qt::RichText);
   msg_box.setInformativeText (fixup_informative_text);
-  msg_box.setWindowModality (Qt::WindowModal);
+
+  if (app_modal) {
+    msg_box.setWindowModality (Qt::ApplicationModal);
+  }
+  else {
+    msg_box.setWindowModality (Qt::WindowModal);
+  }
+
   msg_box.exec ();
 }
 
-void show_RichText_WarningMsgBox (const QString &main_text, const QString 
&informative_text) {
-  show_RichText_Generic_MsgBox (QMessageBox::Warning, main_text, 
informative_text);
+void show_RichText_WarningMsgBox (const QString &main_text, const QString 
&informative_text bool app_modal) {
+  show_RichText_Generic_MsgBox (QMessageBox::Warning, main_text, 
informative_text, app_modal);
 }
 
-void show_RichText_ErrorMsgBox (const QString &main_text, const QString 
&informative_text) {
-  show_RichText_Generic_MsgBox (QMessageBox::Critical, main_text, 
informative_text);
+void show_RichText_ErrorMsgBox (const QString &main_text, const QString 
&informative_text, bool app_modal) {
+  show_RichText_Generic_MsgBox (QMessageBox::Critical, main_text, 
informative_text, app_modal);
 }
 
 QString git_changelog_extract_commit_sha (const QString &gitlog) {
diff --git a/src/x2goutils.h b/src/x2goutils.h
index 4159d39..dd7613c 100644
--- a/src/x2goutils.h
+++ b/src/x2goutils.h
@@ -33,9 +33,9 @@ QString wrap_legacy_resource_URIs (const QString &res_path);
 
 QString convert_to_rich_text (const QString &text, bool force = false);
 
-void show_RichText_Generic_MsgBox (QMessageBox::Icon icon, const QString 
&main_text, const QString &informative_text);
-void show_RichText_WarningMsgBox (const QString &main_text, const QString 
&informative_text = "");
-void show_RichText_ErrorMsgBox (const QString &main_text, const QString 
&informative_text = "");
+void show_RichText_Generic_MsgBox (QMessageBox::Icon icon, const QString 
&main_text, const QString &informative_text, bool app_modal = false);
+void show_RichText_WarningMsgBox (const QString &main_text, const QString 
&informative_text = "", bool app_modal = false);
+void show_RichText_ErrorMsgBox (const QString &main_text, const QString 
&informative_text = "", bool app_modal = false);
 
 QString git_changelog_extract_commit_sha (const QString &gitlog);
 

--
Alioth's /srv/git/code.x2go.org/x2goclient.git//..//_hooks_/post-receive-email 
on /srv/git/code.x2go.org/x2goclient.git
_______________________________________________
x2go-commits mailing list
x2go-commits@lists.x2go.org
http://lists.x2go.org/listinfo/x2go-commits

Reply via email to