From 03c97c2f3c717aebe4e819a818ae60d88db63a31 Mon Sep 17 00:00:00 2001 From: Michael Schmitt Date: Mon, 10 Jul 2006 18:58:44 +0000 Subject: [PATCH] * gtk/lyx_gui.C: * qt3/lyx_gui.C: * qt3/Dialogs.C: * qt4/lyx_gui.C: * qt4/Dialogs.C: remove special handling of preamble dialog (which no longer exists) git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14416 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/frontends/gtk/lyx_gui.C | 4 ---- src/frontends/qt3/Dialogs.C | 25 +++++-------------------- src/frontends/qt3/lyx_gui.C | 4 ---- src/frontends/qt4/Dialogs.C | 25 +++++-------------------- src/frontends/qt4/lyx_gui.C | 4 ---- 5 files changed, 10 insertions(+), 52 deletions(-) diff --git a/src/frontends/gtk/lyx_gui.C b/src/frontends/gtk/lyx_gui.C index d775e8e15f..40d6676156 100644 --- a/src/frontends/gtk/lyx_gui.C +++ b/src/frontends/gtk/lyx_gui.C @@ -187,10 +187,6 @@ FuncStatus lyx_gui::getStatus(FuncRequest const & ev) { FuncStatus flag; switch (ev.action) { - case LFUN_DIALOG_SHOW: - if (ev.argument == "preamble") - flag.unknown(true); - break; case LFUN_TOOLTIPS_TOGGLE: flag.unknown(true); break; diff --git a/src/frontends/qt3/Dialogs.C b/src/frontends/qt3/Dialogs.C index 415f2b0f3f..bd273e23d4 100644 --- a/src/frontends/qt3/Dialogs.C +++ b/src/frontends/qt3/Dialogs.C @@ -105,7 +105,7 @@ char const * const dialognames[] = { "aboutlyx", "bibitem", "bibtex", "box", "branch", "changes", "character", "citation", "document", "errorlist", "ert", "external", "file", "findreplace", "float", "graphics", "include", "index", "label", "log", "view-source", -"mathpanel", "mathdelimiter", "mathmatrix", "note", "paragraph", "preamble", +"mathpanel", "mathdelimiter", "mathmatrix", "note", "paragraph", "prefs", "print", "ref", "sendto", "spellchecker","tabular", "tabularcreate", #ifdef HAVE_LIBAIKSAURUS @@ -177,25 +177,10 @@ Dialogs::DialogPtr Dialogs::build(string const & name) dialog->setController(new ControlCitation(*dialog)); dialog->setView(new QCitation(*dialog)); dialog->bc().bp(new NoRepeatedApplyReadOnlyPolicy); - } else if (name == "document" || name == "preamble") { - - // This nastiness will exist only as long as xforms - // has a separate preamble dialog. - - string const other = (name == "document") ? - "preamble" : "document"; - - std::map::iterator it = - dialogs_.find(other); - - if (it != dialogs_.end()) - dialog = it->second; - else { - dialog->setController(new ControlDocument(*dialog)); - dialog->setView(new QDocument(*dialog)); - dialog->bc().bp(new NoRepeatedApplyReadOnlyPolicy); - } - + } else if (name == "document") { + dialog->setController(new ControlDocument(*dialog)); + dialog->setView(new QDocument(*dialog)); + dialog->bc().bp(new NoRepeatedApplyReadOnlyPolicy); } else if (name == "errorlist") { dialog->setController(new ControlErrorList(*dialog)); dialog->setView(new QErrorList(*dialog)); diff --git a/src/frontends/qt3/lyx_gui.C b/src/frontends/qt3/lyx_gui.C index 64c9b6b0c4..70a2792e50 100644 --- a/src/frontends/qt3/lyx_gui.C +++ b/src/frontends/qt3/lyx_gui.C @@ -303,10 +303,6 @@ FuncStatus getStatus(FuncRequest const & ev) { FuncStatus flag; switch (ev.action) { - case LFUN_DIALOG_SHOW: - if (ev.argument == "preamble") - flag.unknown(true); - break; case LFUN_TOOLTIPS_TOGGLE: flag.unknown(true); break; diff --git a/src/frontends/qt4/Dialogs.C b/src/frontends/qt4/Dialogs.C index 4ae2befb64..5606bc190f 100644 --- a/src/frontends/qt4/Dialogs.C +++ b/src/frontends/qt4/Dialogs.C @@ -101,7 +101,7 @@ char const * const dialognames[] = { "aboutlyx", "bibitem", "bibtex", "box", "branch", "changes", "character", "citation", "document", "errorlist", "ert", "external", "file", "findreplace", "float", "graphics", "include", "index", "label", "log", "view-source", -"mathpanel", "mathdelimiter", "mathmatrix", "note", "paragraph", "preamble", +"mathpanel", "mathdelimiter", "mathmatrix", "note", "paragraph", "prefs", "print", "ref", "sendto", "spellchecker","tabular", "tabularcreate", #ifdef HAVE_LIBAIKSAURUS @@ -174,25 +174,10 @@ Dialogs::DialogPtr Dialogs::build(string const & name) dialog->setController(ci); dialog->setView(new QCitationDialog(*dialog, ci)); dialog->bc().bp(new NoRepeatedApplyReadOnlyPolicy); - } else if (name == "document" || name == "preamble") { - - // This nastiness will exist only as long as xforms - // has a separate preamble dialog. - - string const other = (name == "document") ? - "preamble" : "document"; - - std::map::iterator it = - dialogs_.find(other); - - if (it != dialogs_.end()) - dialog = it->second; - else { - dialog->setController(new ControlDocument(*dialog)); - dialog->setView(new QDocument(*dialog)); - dialog->bc().bp(new NoRepeatedApplyReadOnlyPolicy); - } - + } else if (name == "document") { + dialog->setController(new ControlDocument(*dialog)); + dialog->setView(new QDocument(*dialog)); + dialog->bc().bp(new NoRepeatedApplyReadOnlyPolicy); } else if (name == "errorlist") { dialog->setController(new ControlErrorList(*dialog)); dialog->setView(new QErrorList(*dialog)); diff --git a/src/frontends/qt4/lyx_gui.C b/src/frontends/qt4/lyx_gui.C index 7e572d765d..3051dbe9d6 100644 --- a/src/frontends/qt4/lyx_gui.C +++ b/src/frontends/qt4/lyx_gui.C @@ -275,10 +275,6 @@ FuncStatus getStatus(FuncRequest const & ev) { FuncStatus flag; switch (ev.action) { - case LFUN_DIALOG_SHOW: - if (ev.argument == "preamble") - flag.unknown(true); - break; case LFUN_TOOLTIPS_TOGGLE: flag.unknown(true); break; -- 2.39.2