1 // Copyright (C) 2005 OPEN CASCADE, CEA/DEN, EDF R&D, PRINCIPIA R&D
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License.
8 // This library is distributed in the hope that it will be useful
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 // Lesser General Public License for more details.
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
19 #ifndef LIGHTAPP_OBSELECTOR_H
20 #define LIGHTAPP_OBSELECTOR_H
24 #include <SUIT_Selector.h>
25 #include <SUIT_DataOwner.h>
28 class LightApp_DataObject;
31 \class LightApp_OBSelector
32 Custom selector to get/set selection from object browser
34 class LIGHTAPP_EXPORT LightApp_OBSelector : public SUIT_Selector
39 LightApp_OBSelector( OB_Browser*, SUIT_SelectionMgr* );
40 virtual ~LightApp_OBSelector();
42 OB_Browser* browser() const;
44 /*!Return "ObjectBrowser"*/
45 virtual QString type() const { return "ObjectBrowser"; }
48 unsigned long getModifiedTime() { return myModifiedTime; }
51 void onSelectionChanged();
54 virtual void getSelection( SUIT_DataOwnerPtrList& ) const;
55 virtual void setSelection( const SUIT_DataOwnerPtrList& );
58 void fillEntries( QMap<QString, LightApp_DataObject*>& );
61 OB_Browser* myBrowser;
62 SUIT_DataOwnerPtrList mySelectedList;
64 QMap<QString, LightApp_DataObject*> myEntries;
66 unsigned long myModifiedTime;