]> SALOME platform Git repositories - modules/yacs.git/blob - src/genericgui/ItemMimeData.hxx
Salome HOME
mergefrom branch BR_V511_PR tag mergeto_trunk_03feb09
[modules/yacs.git] / src / genericgui / ItemMimeData.hxx
1 //  Copyright (C) 2006-2008  CEA/DEN, EDF R&D
2 //
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.
7 //
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.
12 //
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
16 //
17 //  See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18 //
19 #ifndef _ITEMMIMEDATA_HXX_
20 #define _ITEMMIMEDATA_HXX_
21
22 #include <QMimeData>
23 #include <string>
24
25 namespace YACS
26 {
27   namespace ENGINE
28   {
29     class Catalog;
30   }
31
32   namespace HMI
33   {
34     class Subject;
35
36     /*!
37      * ItemMimeData is used for Drag and Drop of Scene Items.
38      */
39     class ItemMimeData: public QMimeData
40     {
41     public:
42       ItemMimeData();
43       virtual ~ItemMimeData();
44       virtual void setSubject(Subject *sub);
45       virtual void setCatalog(YACS::ENGINE::Catalog *cata);
46       virtual void setCataName(std::string cataName);
47       virtual void setCompo(std::string compo);
48       virtual void setType(std::string aType);
49       virtual void setCase(int aCase);
50       virtual Subject* getSubject() const;
51       virtual YACS::ENGINE::Catalog* getCatalog() const;
52       virtual std::string getCataName() const;
53       virtual std::string getCompo() const;
54       virtual std::string getType() const;
55       virtual int getCase() const;
56     protected:
57       Subject *_sub;
58       YACS::ENGINE::Catalog *_catalog;
59       std::string _cataName;
60       std::string _compoName;
61       std::string _typeName;
62       int _swCase;
63     };
64     
65   }
66 }
67
68 #endif