From 72fe3d9fc1931c3ff834b1ed53c23d279293bd50 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20P=C3=B6nitz?= Date: Wed, 19 Sep 2007 21:28:11 +0000 Subject: [PATCH] One more second.. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20362 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/frontends/Dialogs.h | 3 ++- src/frontends/LyXView.cpp | 5 ++++- src/frontends/LyXView.h | 23 ++++++++++------------- src/frontends/pch.h | 15 --------------- src/frontends/qt4/pch.h | 3 +++ 5 files changed, 19 insertions(+), 30 deletions(-) diff --git a/src/frontends/Dialogs.h b/src/frontends/Dialogs.h index 335bd3f31d..ae08680401 100644 --- a/src/frontends/Dialogs.h +++ b/src/frontends/Dialogs.h @@ -114,7 +114,8 @@ private: /// std::map dialogs_; - /// flag against a race condition due to multiclicks in Qt frontend, see bug #1119 + /// flag against a race condition due to multiclicks in Qt frontend, + /// see bug #1119 bool in_show_; /// diff --git a/src/frontends/LyXView.cpp b/src/frontends/LyXView.cpp index f621e3291a..5a41bce238 100644 --- a/src/frontends/LyXView.cpp +++ b/src/frontends/LyXView.cpp @@ -85,6 +85,9 @@ LyXView::~LyXView() { disconnectBuffer(); disconnectBufferView(); + delete dialogs_; + delete toolbars_; + delete autosave_timeout_; } @@ -228,7 +231,7 @@ void LyXView::connectBufferView(BufferView & bv) update_dialog_connection_ = bv.updateDialog.connect( boost::bind(&LyXView::updateDialog, this, _1, _2)); layout_changed_connection_ = bv.layoutChanged.connect( - boost::bind(&Toolbars::setLayout, toolbars_.get(), _1)); + boost::bind(&Toolbars::setLayout, toolbars_, _1)); } diff --git a/src/frontends/LyXView.h b/src/frontends/LyXView.h index bf9aa5778d..0ad2fbfb06 100644 --- a/src/frontends/LyXView.h +++ b/src/frontends/LyXView.h @@ -18,7 +18,6 @@ #include "LyXFunc.h" -#include #include #include #include @@ -57,15 +56,15 @@ class WorkArea; */ class LyXView : public boost::signals::trackable, boost::noncopyable { public: - + /// LyXView(int id); - + /// virtual ~LyXView(); - + /// int id() const { return id_; } - + /// virtual void close() = 0; - + /// virtual void setFocus() = 0; /// @@ -131,9 +130,9 @@ public: virtual void openMenu(docstring const & name) = 0; /// get access to the dialogs - Dialogs & getDialogs() { return *dialogs_.get(); } + Dialogs & getDialogs() { return *dialogs_; } /// - Dialogs const & getDialogs() const { return *dialogs_.get(); } + Dialogs const & getDialogs() const { return *dialogs_; } //@} @@ -193,7 +192,7 @@ protected: void disconnectBuffer(); /// view's toolbar - boost::scoped_ptr toolbars_; + Toolbars * toolbars_; private: /** @@ -207,11 +206,9 @@ private: void autoSave(); /// auto-saving of buffers - boost::scoped_ptr const autosave_timeout_; - /// our function handler - boost::scoped_ptr lyxfunc_; + Timeout * const autosave_timeout_; /// dialogs for this view - boost::scoped_ptr dialogs_; + Dialogs * dialogs_; /// buffer structure changed signal connection boost::signals::connection bufferStructureChangedConnection_; diff --git a/src/frontends/pch.h b/src/frontends/pch.h index 9864bc0176..65ab4bc659 100644 --- a/src/frontends/pch.h +++ b/src/frontends/pch.h @@ -1,20 +1,5 @@ #include -#include -#include -#include -#include -#include -#include - -#ifdef HAVE_SYS_TIME_H -# include -#endif -#ifdef HAVE_UNISTD_H -# include -#endif - -#include #include #include #include diff --git a/src/frontends/qt4/pch.h b/src/frontends/qt4/pch.h index dfa99ac414..f509dc9fe5 100644 --- a/src/frontends/qt4/pch.h +++ b/src/frontends/qt4/pch.h @@ -21,3 +21,6 @@ #include #include #include + +#include +#include