source: PSPA/Interface_Web/trunk/pspaWT/sources/userInterface/include/GWt_elementLigneFaisceau.h @ 289

Last change on this file since 289 was 287, checked in by garnier, 11 years ago

ajout de tooltip et nettoyage de code

File size: 2.0 KB
Line 
1#ifndef GWt_elementLigneFaisceau_SEEN
2#define GWt_elementLigneFaisceau_SEEN
3
4#include "GWt_dialog.h"
5#include "abstractElement.h"
6#include "GWt_abstractElement.h"
7#include "GWt_dropZoneLigneFaisceau.h"
8
9#include <Wt/WContainerWidget>
10
11using namespace Wt;
12
13
14class GWt_elementLigneFaisceau : public WContainerWidget
15{
16    public :
17    /**
18     dropZone element
19     a drop zone is the basic element for a widget in the ligne faisceau drop zone area
20     it should be like this :
21     
22     +----------+--------+---------+
23     |   (--->) |  ELEM  | (-----) |
24     +----------+--------+---------+
25     |             NAME            |
26     +----------+--------+---------+
27     ELEM : Element representation, draggable object
28     (----) and (---->) : Droppable zone, contain arrows or line if this element is connected to another
29     NAME : editable element name
30     
31     At first time, the ELEM element is replace by a message.
32     */
33   
34    GWt_elementLigneFaisceau();
35    GWt_elementLigneFaisceau(abstractElement*);
36   
37    ~GWt_elementLigneFaisceau();
38    void addElement(GWt_abstractElement* elem);
39   
40    inline WText* getElementName() {
41        return elementName_;
42    }
43   
44    inline WText* getElementIcon() {
45        return elementName_;
46    }
47   
48    void setElementName(std::string label);
49   
50    inline GWt_dropZoneLigneFaisceau* getDropZoneLeft() {
51        return dropZoneLeft_;
52    }
53
54    inline GWt_dropZoneLigneFaisceau* getDropZoneRight() {
55        return dropZoneRight_;
56    }
57
58private:
59   
60    void onClick(GWt_abstractElement*);
61    void removeDone(GWt_abstractElement*);
62    std::string getElementNumberInBeamLine(nomdElements el);
63    void initialize_ligneFaisceau(abstractElement*);
64    GWt_dialog* messageDropZone_;
65    WText* firstTimeInsertMessage_;
66   
67    GWt_dropZoneLigneFaisceau* dropZoneLeft_;
68    WContainerWidget* dragElementZone_;
69    GWt_dropZoneLigneFaisceau* dropZoneRight_;
70    WText* elementName_;
71   
72    GWt_abstractElement* abstractElement_;
73};
74#endif
Note: See TracBrowser for help on using the repository browser.