]> git.lyx.org Git - lyx.git/blobdiff - src/frontends/Dialogs.h
enable Font cache only for MacOSX and inline width() for other platform.
[lyx.git] / src / frontends / Dialogs.h
index 71135cf480febd7ee615e59abb2bb9acf8f19da4..4a9c1451a92b2247b80982bc7ef84441b3c15ed1 100644 (file)
 #ifndef DIALOGS_H
 #define DIALOGS_H
 
+#include <boost/signal.hpp>
 #include <boost/utility.hpp>
-#include <boost/signals/signal0.hpp>
+
+#include <map>
 
 class InsetBase;
 class LyXView;
@@ -27,19 +29,19 @@ class Dialog;
 
 /** Container of all dialogs.
  */
-class Dialogs : boost::noncopyable
-{
+class Dialogs : boost::noncopyable {
 public:
        ///
        Dialogs(LyXView &);
 
-       /** Redraw all visible dialogs because, for example, the GUI colours
-        *  have been re-mapped.
+       /** Check the status of all visible dialogs and disable or reenable
+        *  them as appropriate.
         *
-        *  Note that static boost signals break some compilers, so we return a
-        *  reference to some hidden magic ;-)
+        *  Disabling is needed for example when a dialog is open and the
+        *  cursor moves to a position where the corresponding inset is not
+        *  allowed.
         */
-       static boost::signal0<void> & redrawGUI();
+       void checkStatus();
 
        /// Toggle tooltips on/off in all dialogs.
        static void toggleTooltips();
@@ -116,6 +118,9 @@ private:
 
        ///
        std::map<std::string, DialogPtr> dialogs_;
+
+       /// flag against a race condition due to multiclicks in Qt frontend, see bug #1119
+       bool in_show_;
 };
 
 #endif