Salome HOME
5f853a485a0c44c6b56d800f291460c8faef06ce
[modules/kernel.git] / src / SALOMEGUI / SALOMEGUI.cxx
1 //  SALOME SALOMEGUI : implementation of desktop and GUI kernel
2 //
3 //  Copyright (C) 2003  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 //  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 
5 // 
6 //  This library is free software; you can redistribute it and/or 
7 //  modify it under the terms of the GNU Lesser General Public 
8 //  License as published by the Free Software Foundation; either 
9 //  version 2.1 of the License. 
10 // 
11 //  This library is distributed in the hope that it will be useful, 
12 //  but WITHOUT ANY WARRANTY; without even the implied warranty of 
13 //  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU 
14 //  Lesser General Public License for more details. 
15 // 
16 //  You should have received a copy of the GNU Lesser General Public 
17 //  License along with this library; if not, write to the Free Software 
18 //  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA 
19 // 
20 //  See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org 
21 //
22 //
23 //
24 //  File   : SALOMEGUI.cxx
25 //  Author : Sergey ANIKIN
26 //  Module : SALOME
27 //  $Header$
28
29 #include "SALOMEGUI.h"
30 #include "QAD_Desktop.h"
31
32
33 //=============================================================================
34 /*!
35  *
36  */
37 //=============================================================================
38 SALOMEGUI::SALOMEGUI( const QString& name, QObject* parent )
39 : QObject( parent ),
40   myName( name )
41 {
42 }
43
44 //=============================================================================
45 /*!
46  *
47  */
48 //=============================================================================
49 SALOMEGUI::~SALOMEGUI()
50 {
51 }
52
53 //=============================================================================
54 /*!
55  *
56  */
57 //=============================================================================
58 bool SALOMEGUI::OnGUIEvent(int theCommandID, QAD_Desktop* parent)
59 {
60   return true;
61 }
62
63 //=============================================================================
64 /*!
65  *
66  */
67 //=============================================================================
68 bool SALOMEGUI::OnKeyPress(QKeyEvent* pe, QAD_Desktop* parent, QAD_StudyFrame* studyFrame)
69 {
70   return true;
71 }
72
73 //=============================================================================
74 /*!
75  *
76  */
77 //=============================================================================
78 bool SALOMEGUI::OnMousePress(QMouseEvent* pe, QAD_Desktop* parent, QAD_StudyFrame* studyFrame)
79 {
80   return true;
81 }
82
83 //=============================================================================
84 /*!
85  *
86  */
87 //=============================================================================
88 bool SALOMEGUI::OnMouseMove(QMouseEvent* pe, QAD_Desktop* parent, QAD_StudyFrame* studyFrame)
89 {
90   return true;
91 }
92
93 //=============================================================================
94 /*!
95  *
96  */
97 //=============================================================================
98 bool SALOMEGUI::SetSettings( QAD_Desktop* parent )
99 {
100   return true;
101 }
102
103 //=============================================================================
104 /*!
105  *
106  */
107 //=============================================================================
108 bool SALOMEGUI::SetSettings( QAD_Desktop* parent, char* compName )
109 {
110   return SetSettings( parent);
111 }
112
113 //=============================================================================
114 /*!
115  *
116  */
117 //=============================================================================
118 bool SALOMEGUI::CustomPopup( QAD_Desktop* parent, QPopupMenu* popup, const QString & theContext,
119                                    const QString & theParent, const QString & theObject )
120 {
121   return true;
122 }
123
124 //=============================================================================
125 /*!
126  *
127  */
128 //=============================================================================
129 void SALOMEGUI::DefinePopup( QString & theContext, QString & theParent, QString & theObject )
130 {
131 }
132
133 //=============================================================================
134 /*!
135  *
136  */
137 //=============================================================================
138 bool SALOMEGUI::ActiveStudyChanged( QAD_Desktop* parent )
139 {
140   //static QAD_Study* aPrevStudy = NULL;
141   //QAD_Study* aStudy = parent->getActiveStudy();
142   //if(!aPrevStudy)
143   //  aPrevStudy = aStudy;
144   //if(aStudy != aPrevStudy){
145   //  emit SignalCloseAllDialogs();
146   //  aPrevStudy = aStudy;
147   //}
148   emit SignalCloseAllDialogs();
149   return true;
150 }
151
152 //=============================================================================
153 /*!
154  *
155  */
156 //=============================================================================
157 void SALOMEGUI::BuildPresentation( const Handle(SALOME_InteractiveObject)& theIO )
158 {
159 }
160
161 //=============================================================================
162 /*!
163  *
164  */
165 //=============================================================================
166 void SALOMEGUI::SupportedViewType(int* buffer, int bufferSize)
167 {
168 }
169
170 //=============================================================================
171 /*!
172  *
173  */
174 //=============================================================================
175 void SALOMEGUI::Deactivate()
176 {
177   emit SignalCloseAllDialogs();
178 }
179