]> git.lyx.org Git - lyx.git/commitdiff
GuiView::findOrBuild(): hide the dialog if requested and the dialog already exists.
authorAbdelrazak Younes <younes@lyx.org>
Fri, 3 Oct 2008 13:17:22 +0000 (13:17 +0000)
committerAbdelrazak Younes <younes@lyx.org>
Fri, 3 Oct 2008 13:17:22 +0000 (13:17 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@26695 a592a061-630c-0410-9148-cb99ea01b6c8

src/frontends/qt4/GuiView.cpp

index f1e8e7c666fa02b1ef16c333987a574719a75307..567680d3247a87437ddedaea289512fd79bcd563 100644 (file)
@@ -2248,8 +2248,11 @@ Dialog * GuiView::findOrBuild(string const & name, bool hide_it)
 
        map<string, DialogPtr>::iterator it = d.dialogs_.find(name);
 
-       if (it != d.dialogs_.end())
+       if (it != d.dialogs_.end()) {
+               if (hide_it)
+                       it->second->hideView();
                return it->second.get();
+       }
 
        Dialog * dialog = build(name);
        d.dialogs_[name].reset(dialog);