From a0892f87e918f2e03ad2406e22ed02c35e645e27 Mon Sep 17 00:00:00 2001 From: Angus Leeming Date: Tue, 17 Jun 2003 13:16:25 +0000 Subject: [PATCH] Get rid of Dialogs::showMathPanel. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@7181 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/ChangeLog | 4 ++++ src/frontends/ChangeLog | 5 +++++ src/frontends/Dialogs.h | 2 -- src/frontends/guiapi.C | 6 ------ src/frontends/guiapi.h | 1 - src/frontends/qt2/ChangeLog | 5 +++++ src/frontends/qt2/Dialogs.C | 4 ++-- src/frontends/qt2/Dialogs2.C | 7 ------- src/frontends/xforms/ChangeLog | 5 +++++ src/frontends/xforms/Dialogs.C | 4 ++-- src/frontends/xforms/Dialogs2.C | 8 -------- src/lyxfunc.C | 2 +- src/mathed/ChangeLog | 4 ++++ src/mathed/formulabase.C | 2 +- 14 files changed, 29 insertions(+), 30 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 486e403a02..db1698728e 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2003-06-17 Angus Leeming + + * lyxfunc.C (dispatch): s/showMathPanel/show("mathpanel")/ + 2003-06-17 Angus Leeming * lfuns.h: diff --git a/src/frontends/ChangeLog b/src/frontends/ChangeLog index ffad45d1ac..fd02f185ac 100644 --- a/src/frontends/ChangeLog +++ b/src/frontends/ChangeLog @@ -1,3 +1,8 @@ +2003-06-17 Angus Leeming + + * Dialogs.h: (showMathPanel): + * guiapi.[Ch] (gui_ShowMathPanel): removed. + 2003-06-06 Alfredo Braunstein * Dialogs.[Ch] (visible): added. diff --git a/src/frontends/Dialogs.h b/src/frontends/Dialogs.h index 60e0fef371..af8f12a090 100644 --- a/src/frontends/Dialogs.h +++ b/src/frontends/Dialogs.h @@ -74,8 +74,6 @@ public: void showDocument(); /// show all forked child processes void showForks(); - /// display the top-level maths panel - void showMathPanel(); /// void showPreamble(); /// diff --git a/src/frontends/guiapi.C b/src/frontends/guiapi.C index 824eca21e3..1265a84b2f 100644 --- a/src/frontends/guiapi.C +++ b/src/frontends/guiapi.C @@ -33,12 +33,6 @@ void gui_ShowForks(Dialogs & d) } -void gui_ShowMathPanel(Dialogs & d) -{ - d.showMathPanel(); -} - - void gui_ShowPreamble(Dialogs & d) { d.showPreamble(); diff --git a/src/frontends/guiapi.h b/src/frontends/guiapi.h index f98d61125d..b34910b472 100644 --- a/src/frontends/guiapi.h +++ b/src/frontends/guiapi.h @@ -23,7 +23,6 @@ void gui_show_dialog(Dialogs *, char const * name, char const * data); void gui_ShowDocument(Dialogs &); void gui_ShowForks(Dialogs &); -void gui_ShowMathPanel(Dialogs &); void gui_ShowPreamble(Dialogs &); void gui_ShowPreferences(Dialogs &); void gui_ShowPrint(Dialogs &); diff --git a/src/frontends/qt2/ChangeLog b/src/frontends/qt2/ChangeLog index 02cf579eee..02efbce62d 100644 --- a/src/frontends/qt2/ChangeLog +++ b/src/frontends/qt2/ChangeLog @@ -1,3 +1,8 @@ +2003-06-17 Angus Leeming + + * Dialogs.C: rename math panel identifier as "mathpanel". + * Dialogs2.C (showMathPanel): removed. + 2003-06-17 Angus Leeming * Dialogs.C: diff --git a/src/frontends/qt2/Dialogs.C b/src/frontends/qt2/Dialogs.C index 41703b023a..e8d5d767f7 100644 --- a/src/frontends/qt2/Dialogs.C +++ b/src/frontends/qt2/Dialogs.C @@ -83,7 +83,7 @@ namespace { char const * const dialognames[] = { "about", "bibitem", "bibtex", "changes", "character", "citation", "error", "errorlist", "ert", "external", "file", "float", "graphics", "include", "index", "label", "log", -"math", "mathdelimiter", "mathmatrix", +"mathpanel", "mathdelimiter", "mathmatrix", "minipage", "paragraph", "ref", "tabular", "tabularcreate", #ifdef HAVE_LIBAIKSAURUS @@ -195,7 +195,7 @@ Dialog * Dialogs::build(string const & name) dialog->setController(new ControlLog(*dialog)); dialog->setView(new QLog(*dialog)); dialog->bc().bp(new OkCancelPolicy); - } else if (name == "math") { + } else if (name == "mathpanel") { dialog->setController(new ControlMath(*dialog)); dialog->setView(new QMath(*dialog)); dialog->bc().bp(new IgnorantPolicy); diff --git a/src/frontends/qt2/Dialogs2.C b/src/frontends/qt2/Dialogs2.C index 807c68a9bf..4edb6a1bf3 100644 --- a/src/frontends/qt2/Dialogs2.C +++ b/src/frontends/qt2/Dialogs2.C @@ -118,13 +118,6 @@ void Dialogs::showForks() {} -void Dialogs::showMathPanel() -{ - static DialogPtr mathdialog(build("math")); - mathdialog->show(string()); -} - - void Dialogs::showPreamble() { pimpl_->document.controller().show(); diff --git a/src/frontends/xforms/ChangeLog b/src/frontends/xforms/ChangeLog index ad7cfbca20..708ea80fd9 100644 --- a/src/frontends/xforms/ChangeLog +++ b/src/frontends/xforms/ChangeLog @@ -1,3 +1,8 @@ +2003-06-17 Angus Leeming + + * Dialogs.C: rename math panel identifier as "mathpanel". + * Dialogs2.C (showMathPanel): removed. + 2003-06-17 Angus Leeming * Dialogs.C: diff --git a/src/frontends/xforms/Dialogs.C b/src/frontends/xforms/Dialogs.C index d21216d041..6eed624908 100644 --- a/src/frontends/xforms/Dialogs.C +++ b/src/frontends/xforms/Dialogs.C @@ -110,7 +110,7 @@ FormMathsBitmap * createFormBitmap(Dialog & parent, string const & title, char const * const dialognames[] = { "about", "bibitem", "bibtex", "changes", "character", "citation", "error", "errorlist" , "ert", "external", "file", -"float", "graphics", "include", "index", "label", "log", "math", +"float", "graphics", "include", "index", "label", "log", "mathpanel", "mathaccents", "matharrows", "mathoperators", "mathrelations", "mathgreek", "mathmisc", "mathdots", "mathbigoperators", "mathamsmisc", "mathamsarrows", "mathamsrelations", "mathamsnegatedrelations", "mathamsoperators", @@ -224,7 +224,7 @@ Dialog * Dialogs::build(string const & name) dialog->setView(new FormLog(*dialog)); dialog->bc().bp(new OkCancelPolicy); - } else if (name == "math") { + } else if (name == "mathpanel") { dialog->setController(new ControlMath(*dialog)); dialog->setView(new FormMathsPanel(*dialog)); dialog->bc().bp(new IgnorantPolicy); diff --git a/src/frontends/xforms/Dialogs2.C b/src/frontends/xforms/Dialogs2.C index 1c9a733b7f..0aeab5f771 100644 --- a/src/frontends/xforms/Dialogs2.C +++ b/src/frontends/xforms/Dialogs2.C @@ -13,7 +13,6 @@ #include #include "Dialogs.h" -#include "Dialog.h" #include "controllers/GUI.h" #include "ButtonController.h" @@ -135,13 +134,6 @@ void Dialogs::showForks() } -void Dialogs::showMathPanel() -{ - static DialogPtr mathdialog(build("math")); - mathdialog->show(string()); -} - - void Dialogs::showPreamble() { pimpl_->preamble.controller().show(); diff --git a/src/lyxfunc.C b/src/lyxfunc.C index c97fa8bc82..75577bce9e 100644 --- a/src/lyxfunc.C +++ b/src/lyxfunc.C @@ -1405,7 +1405,7 @@ void LyXFunc::dispatch(FuncRequest const & ev, bool verbose) break; case LFUN_MATH_PANEL: - owner->getDialogs().showMathPanel(); + owner->getDialogs().show("mathpanel"); break; case LFUN_DIALOG_SHOW: diff --git a/src/mathed/ChangeLog b/src/mathed/ChangeLog index 48b93ec128..8708e5b181 100644 --- a/src/mathed/ChangeLog +++ b/src/mathed/ChangeLog @@ -1,3 +1,7 @@ +2003-06-17 Angus Leeming + + * formulabase.C (lfunMouseRelease): s/showMathPanel/show("mathpanel")/ + 2003-06-13 Jean-Marc Lasgouttes * formulabase.C (mathDispatchCreation): fix call to cutSelection diff --git a/src/mathed/formulabase.C b/src/mathed/formulabase.C index ae0d51d0f4..5884d0679b 100644 --- a/src/mathed/formulabase.C +++ b/src/mathed/formulabase.C @@ -227,7 +227,7 @@ dispatch_result InsetFormulaBase::lfunMouseRelease(FuncRequest const & cmd) if (mathcursor->dispatch(cmd) == UNDISPATCHED) { // launch math panel for right mouse button lyxerr << "lfunMouseRelease: undispatched: " << cmd.button() << endl; - bv->owner()->getDialogs().showMathPanel(); + bv->owner()->getDialogs().show("mathpanel"); } return DISPATCHED; } -- 2.39.2