]> git.lyx.org Git - lyx.git/blobdiff - src/DispatchResult.h
typo
[lyx.git] / src / DispatchResult.h
index 5b209ff8f74923d1f87d81d7d81915c19e04e66d..070ee1bdfc0efa65d84621cc18e5c41ce9dac8ed 100644 (file)
@@ -23,9 +23,11 @@ namespace lyx {
 class DispatchResult {
 public:
        ///
-       DispatchResult() : dispatched_(false), update_(Update::None) {}
+       DispatchResult() : dispatched_(false), error_(false), 
+                          update_(Update::None), need_buf_update_(false) {}
        ///
-       DispatchResult(bool disp, Update::flags f) : dispatched_(disp), update_(f) {}
+       DispatchResult(bool disp, Update::flags f) 
+               : dispatched_(disp), error_(false), update_(f) {}
        ///
        bool dispatched() const { return dispatched_; }
        ///
@@ -42,6 +44,12 @@ public:
        Update::flags update() const { return update_; }
        ///
        void update(Update::flags f) { update_ = f; }
+       /// Does the buffer need updating?
+       bool needBufferUpdate() const { return need_buf_update_; }
+       /// Force the buffer to be updated
+       void forceBufferUpdate() { need_buf_update_ = true; }
+       /// Clear the flag indicating we need an update
+       void clearBufferUpdate() { need_buf_update_ = false; }
 private:
        /// was the event fully dispatched?
        bool dispatched_;
@@ -51,6 +59,8 @@ private:
        Update::flags update_;
        ///
        docstring message_;
+       /// 
+       bool need_buf_update_;
 };