X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=src%2FXGUI%2FXGUI_MainWindow.h;h=010f9e309530b3cb12289015b259a85908bfdcee;hb=fd958c0c05de3b2661006daeb7580c3734c9709d;hp=a4b05f3d915aa34d0d7b7cc4446fb08053d40a9d;hpb=e1f8fb3cfc1ee565db16fbbd9fe6f65121c4577c;p=modules%2Fshaper.git diff --git a/src/XGUI/XGUI_MainWindow.h b/src/XGUI/XGUI_MainWindow.h index a4b05f3d9..010f9e309 100644 --- a/src/XGUI/XGUI_MainWindow.h +++ b/src/XGUI/XGUI_MainWindow.h @@ -1,14 +1,24 @@ #ifndef XGUI_MAINWINDOW_H #define XGUI_MAINWINDOW_H +#include "XGUI.h" #include class XGUI_MainMenu; class XGUI_Viewer; -class QTreeWidget; +class XGUI_ActionsMgr; +class XGUI_ViewWindow; class QMdiArea; +class QMdiSubWindow; +class PyConsole_EnhConsole; +class QCloseEvent; -class XGUI_MainWindow: public QMainWindow +/**\class XGUI_MainWindow + * \ingroup GUI + * \brief Main window of the application (Desktop). + * It contains: Object Browser, 3d Viewer, Python console, property panel, main menu + */ +class XGUI_EXPORT XGUI_MainWindow: public QMainWindow { Q_OBJECT @@ -16,36 +26,45 @@ public: XGUI_MainWindow(QWidget* parent = 0); virtual ~XGUI_MainWindow(); + //! Returns main menu object XGUI_MainMenu* menuObject() const { return myMenuBar; } - QTreeWidget* objectBrowser() const - { - return myObjectBrowser; - } - void showObjectBrowser(); - void hideObjectBrowser(); - + //! Returns MDI area QMdiArea* mdiArea() const; + //! Returns 3d viewer XGUI_Viewer* viewer() const { return myViewer; } -private: - //!! For test purposes only - //QWidget* getSubWindow(); +public slots: + void showPythonConsole(); + void hidePythonConsole(); - void fillObjectBrowser(); - void addPropertyPanel(); + void createSubWindow(); + +private slots: + void cascadeWindows(); + void onViewCreated(XGUI_ViewWindow* theWindow); + void onDeleteView(XGUI_ViewWindow* theWindow); + void activateView(); + void onViewActivated(QMdiSubWindow* theSubWnd); - XGUI_MainMenu* myMenuBar; - QTreeWidget* myObjectBrowser; +signals: + void exitKeySequence(); +protected: + void closeEvent(QCloseEvent* event); + +private: + XGUI_MainMenu* myMenuBar; XGUI_Viewer* myViewer; + + PyConsole_EnhConsole* myPythonConsole; }; #endif