]> git.lyx.org Git - features.git/commitdiff
* Delegates.h: clarify some comments.
authorAbdelrazak Younes <younes@lyx.org>
Fri, 2 May 2008 21:38:23 +0000 (21:38 +0000)
committerAbdelrazak Younes <younes@lyx.org>
Fri, 2 May 2008 21:38:23 +0000 (21:38 +0000)
* Dialog: get rid of updateData()

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24589 a592a061-630c-0410-9148-cb99ea01b6c8

src/frontends/Delegates.h
src/frontends/qt4/Dialog.cpp
src/frontends/qt4/Dialog.h
src/frontends/qt4/GuiView.cpp
src/frontends/qt4/GuiView.h

index 96c134bf56b706bf2f9fc152ea3e39f397ae8de8..c1ef6556a40c455bdb0e829ddf359d145b260189 100644 (file)
@@ -45,9 +45,9 @@ public:
        virtual void showDialog(std::string const & name,
                std::string const & data, Inset * inset = 0) = 0;
 
-       /// This function is called when some dialogs needs to be updated.
+       /// This function is called when some dialogs needs to be reset.
        /** \param name == "citation", "bibtex" etc; an identifier used
-           to update the contents of a particular dialog with \param data.
+           to reset the contents of a particular dialog with \param data.
            See the comments to 'show', above.
        */
        virtual void updateDialog(std::string const & name,
index fc741985d8c73a1fcffabfc94150d0e23e9931ab..d4bd227e127b849575555ec0bb4294781d2ddafc 100644 (file)
@@ -163,21 +163,6 @@ void Dialog::apply()
 }
 
 
-void Dialog::updateData(string const & data)
-{
-       if (!initialiseParams(data)) {
-               LYXERR0("Dialog \"" << fromqstr(name())
-                      << "\" could not be initialized");
-               return;
-       }
-
-       if (lyxview_->buffer())
-               updateView();
-       else
-               enableView(false);
-}
-
-
 void Dialog::showView()
 {
        // Make sure the dialog controls are correctly enabled/disabled with
index 1bd75673c54af9c076edf8a516b393216793c48f..9c7b3b6c56cad85a3c4e778cc8269222595cd8cc 100644 (file)
@@ -87,7 +87,6 @@ public:
        /// \param data is a string encoding of the data to be displayed.
        /// It is passed to the Controller to be translated into a useable form.
        virtual void showData(std::string const & data);
-       virtual void updateData(std::string const & data);
        //@}
 
        /** Check whether we may apply our data.
index 46b0a83f9d75f6ba8906773bcd9a38ee23938fc2..f4cdda665f24401aa7cd0341a5ac1b81f0bfc2cf 100644 (file)
@@ -941,7 +941,7 @@ void GuiView::updateDialog(string const & name, string const & data)
 
        Dialog * const dialog = it->second.get();
        if (dialog->isVisibleView())
-               dialog->updateData(data);
+               dialog->initialiseParams(data);
 }
 
 
index d3e041f3d57c835059483ee0710cd2efb93d17ca..7400c27e0cd637cc08af65b952157fbcaed10136 100644 (file)
@@ -229,7 +229,7 @@ public:
                std::string const & data, Inset * inset = 0);
 
        /** \param name == "citation", "bibtex" etc; an identifier used
-           to update the contents of a particular dialog with \param data.
+           to reset the contents of a particular dialog with \param data.
            See the comments to 'show', above.
        */
        void updateDialog(std::string const & name, std::string const & data);