delete unneeded Menubar virtual interface.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19751 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Abdelrazak Younes 2007-08-23 12:54:35 +00:00
parent 77d4d1256d
commit 8381d36098
8 changed files with 1 additions and 64 deletions

View File

@ -84,9 +84,7 @@
#include "frontends/Gui.h" #include "frontends/Gui.h"
#include "frontends/KeySymbol.h" #include "frontends/KeySymbol.h"
#include "frontends/LyXView.h" #include "frontends/LyXView.h"
#include "frontends/Menubar.h"
#include "frontends/Selection.h" #include "frontends/Selection.h"
#include "frontends/Toolbars.h"
#include "frontends/WorkArea.h" #include "frontends/WorkArea.h"
#include "support/environment.h" #include "support/environment.h"

View File

@ -15,7 +15,6 @@
#include "Dialogs.h" #include "Dialogs.h"
#include "Toolbars.h" #include "Toolbars.h"
#include "Menubar.h"
#include "WorkArea.h" #include "WorkArea.h"
#include "Gui.h" #include "Gui.h"

View File

@ -28,7 +28,6 @@ liblyxfrontends_la_SOURCES = \
KeySymbol.h \ KeySymbol.h \
LyXView.cpp \ LyXView.cpp \
LyXView.h \ LyXView.h \
Menubar.h \
Painter.cpp \ Painter.cpp \
Painter.h \ Painter.h \
Toolbars.cpp \ Toolbars.cpp \

View File

@ -1,39 +0,0 @@
// -*- C++ -*-
/**
* \file Menubar.h
* This file is part of LyX, the document processor.
* Licence details can be found in the file COPYING.
*
* \author Lars Gullik Bjønnes
* \author Jean-Marc Lasgouttes
*
* Full author contact details are available in file CREDITS.
*/
#ifndef MENUBAR_H
#define MENUBAR_H
#include "support/docstring.h"
namespace lyx {
namespace frontend {
/**
* The LyX GUI independent menubar class
* The GUI interface is implemented in the frontends
*/
class Menubar {
public:
///
virtual ~Menubar() {}
/// Opens a top-level submenu given its name
virtual void openByName(docstring const &) = 0;
/// update the state of the menuitems
virtual void update() = 0;
};
} // namespace frontend
} // namespace lyx
#endif // MENUBAR_H

View File

@ -309,8 +309,6 @@ QMenu* GuiView::createPopupMenu()
void GuiView::init() void GuiView::init()
{ {
d.menubar_ = new QLMenubar(this, menubackend); d.menubar_ = new QLMenubar(this, menubackend);
QObject::connect(menuBar(), SIGNAL(triggered(QAction *)),
this, SLOT(updateMenu(QAction *)));
toolbars_->init(); toolbars_->init();
@ -561,12 +559,6 @@ void GuiView::setGeometry(unsigned int width,
} }
void GuiView::updateMenu(QAction * /*action*/)
{
d.menubar_->update();
}
void GuiView::setWindowTitle(docstring const & t, docstring const & it) void GuiView::setWindowTitle(docstring const & t, docstring const & it)
{ {
QString title = windowTitle(); QString title = windowTitle();

View File

@ -92,9 +92,6 @@ public Q_SLOTS:
/// idle timeout /// idle timeout
void update_view_state_qt(); void update_view_state_qt();
/// populate a toplevel menu and all its children on demand
void updateMenu(QAction *);
void currentTabChanged(int index); void currentTabChanged(int index);
void closeCurrentTab(); void closeCurrentTab();

View File

@ -111,9 +111,6 @@ void QLMenubar::openByName(docstring const & name)
} }
void QLMenubar::update()
{ }
GuiView * QLMenubar::view() GuiView * QLMenubar::view()
{ {
return owner_; return owner_;

View File

@ -13,8 +13,6 @@
#ifndef QLMENUBAR_H #ifndef QLMENUBAR_H
#define QLMENUBAR_H #define QLMENUBAR_H
#include "frontends/Menubar.h"
#include "QLPopupMenu.h" #include "QLPopupMenu.h"
#include <map> #include <map>
@ -34,7 +32,7 @@ namespace frontend {
class GuiView; class GuiView;
class LyXView; class LyXView;
class QLMenubar : public QObject, public Menubar { class QLMenubar : public QObject {
Q_OBJECT Q_OBJECT
public: public:
QLMenubar(LyXView *, MenuBackend &); QLMenubar(LyXView *, MenuBackend &);
@ -54,10 +52,6 @@ public:
/// update the state of the menuitems - not needed /// update the state of the menuitems - not needed
void update(); void update();
public Q_SLOTS:
/// populate a toplevel menu and all its children on demand
// void updateMenu();
private: private:
/// Initialize specific MACOS X menubar /// Initialize specific MACOS X menubar
void macxMenuBarInit(); void macxMenuBarInit();