All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
OutsideArea.h
Go to the documentation of this file.
1 /* Copyright (C) 2008 National Institute For Space Research (INPE) - Brazil.
2 
3  This file is part of the TerraLib - a Framework for building GIS enabled applications.
4 
5  TerraLib is free software: you can redistribute it and/or modify
6  it under the terms of the GNU Lesser General Public License as published by
7  the Free Software Foundation, either version 3 of the License,
8  or (at your option) any later version.
9 
10  TerraLib is distributed in the hope that it will be useful,
11  but WITHOUT ANY WARRANTY; without even the implied warranty of
12  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  GNU Lesser General Public License for more details.
14 
15  You should have received a copy of the GNU Lesser General Public License
16  along with TerraLib. See COPYING. If not, write to
17  TerraLib Team at <terralib-team@terralib.org>.
18  */
19 
20 /*!
21  \file OutsideArea.h
22 
23  \brief
24 
25  \ingroup layout
26 */
27 
28 #ifndef __TE_QT_PLUGINS_LAYOUT_INTERNAL_OUTSIDE_AREA_H
29 #define __TE_QT_PLUGINS_LAYOUT_INTERNAL_OUTSIDE_AREA_H
30 
31 // TerraLib
32 #include "../../../layout/qt/core/View.h"
33 #include "../../../layout/qt/outside/ToolbarOutside.h"
34 
35 // STL
36 #include <string>
37 
38 // Qt
39 #include <QObject>
40 
41 class QWidget;
42 class QMenu;
43 class QAction;
44 class QStatusBar;
45 class QGraphicsItem;
46 
47 namespace te
48 {
49  namespace qt
50  {
51  namespace plugins
52  {
53  namespace layout
54  {
55  class PropertiesDock;
56  class ObjectInspectorDock;
57  class EditTemplateDock;
58  class EnumType;
59 
60  class OutsideArea : public QObject
61  {
62  Q_OBJECT //for slots/signals
63 
64  public:
65 
66  OutsideArea(te::layout::View* view, QWidget* dockParent = 0, QMenu* mnuLayout = 0, QStatusBar* status = 0);
67  virtual ~OutsideArea();
68 
72 
73  virtual void openAllDocks();
74  virtual void closeAllDocks();
75 
76  virtual void openMainMenu();
77  virtual void closeMainMenu();
78 
79  public slots:
80 
81  virtual void onMainMenuTriggered(QAction* action);
82  virtual void onSelectionChanged();
83  virtual void onAddItemFinalized();
84  virtual void onShowView();
85  virtual void onHideView();
86  virtual void onCloseView();
87  virtual void onRefreshStatusBar();
88  virtual void onAddChildFinalized(QGraphicsItem* parent, QGraphicsItem* child);
89 
90  signals:
91 
92  void changeMenuContext(bool change);
93 
94  void exit();
95 
96  protected:
97 
98  virtual void init();
99  virtual void createPropertiesDock();
100  virtual void createInspectorDock();
101  virtual void createToolbar();
102  virtual void createMainMenu();
103  virtual void createEditTemplateDock();
104 
105  virtual QAction* createAction(std::string text, std::string objName, std::string icon, std::string tooltip = "");
106 
107  virtual void changeAction(te::layout::EnumType* mode);
108 
109  protected:
110 
111  QWidget* m_dockParent;
115  QMenu* m_parentMenu;
118  QStatusBar* m_statusBar;
119 
120  /* Menu options */
121 
122  std::string m_optionNew;
123  std::string m_optionUpdate;
124  std::string m_optionImportJSON;
125  std::string m_optionExportJSON;
126  std::string m_optionPageConfig;
127  std::string m_optionPrint;
128  std::string m_optionExit;
131  std::string m_optionDockToolbar;
133  };
134  }
135  }
136  }
137 }
138 
139 
140 #endif
virtual void changeAction(te::layout::EnumType *mode)
EditTemplateDock * m_dockEditTemplate
Definition: OutsideArea.h:114
ObjectInspectorDock * getObjectInspectorDock()
virtual void onAddChildFinalized(QGraphicsItem *parent, QGraphicsItem *child)
Class representing the view. This view is child of QGraphicsView, part of Graphics View Framework...
Definition: View.h:89
OutsideArea(te::layout::View *view, QWidget *dockParent=0, QMenu *mnuLayout=0, QStatusBar *status=0)
Definition: OutsideArea.cpp:50
ObjectInspectorDock * m_dockInspector
Definition: OutsideArea.h:113
virtual QAction * createAction(std::string text, std::string objName, std::string icon, std::string tooltip="")
virtual void onMainMenuTriggered(QAction *action)
Class that represents the value of an enumeration. An enumeration is made of "1..n" objects EnumType...
Definition: EnumType.h:48
Standard Toolbar for Layout. Includes Qt components for interaction between the user and the plugin/a...
te::layout::ToolbarOutside * m_toolbar
Definition: OutsideArea.h:117
te::layout::ToolbarOutside * getToolbar()