class MyListView
|
This class provides encoding and decoding for the uml data
that will be use in a drag_n_drop operation or in a copy paste
operation
More... |
|
|
Public Types
- enum Icon_Type { it_Home = 0,
it_Folder_Green,
it_Folder_Green_Open,
it_Folder_Grey,
it_Folder_Grey_Open,
it_Diagram,
it_Class,
it_Actor,
it_UseCase,
it_Public_Method,
it_Private_Method,
it_Protected_Method,
it_Public_Attribute,
it_Private_Attribute,
it_Protected_Attribute
}
Public Methods
- MyListView (QWidget *parent,const char *name)
- ~MyListView ()
- void setDocument (UMLDoc * d)
- void init ()
- void setView (UMLView * v)
- bool serialize (QDataStream *s, bool archive)
- bool ReadChilds ( MyListViewItem* parent, QDataStream *s)
- long getClipSizeOf ()
- void setLoading (bool _state)
- void setWidgetDefaults ()
- bool GetSelectedItems (MyListViewItemList &ItemList)
- long getClipSizeOfItemList (MyListViewItemList* Items)
- bool clipSerializeItemList (MyListViewItemList* Items, QDataStream *s, const bool toClip)
- MyListViewItem* CreateItem (MyListViewItemData& Data, IDChangeLog& IDChanges,
MyListViewItem* parent = 0)
- QPoint TranslatePosition (QPoint Pt)
- int getSelectedCount ()
- QPixmap & getPixmap ( Icon_Type type )
- UMLDoc * getDocument ()
- void addNewItem ( QListViewItem * parent, Uml::ListView_Type type )
- void createUMLObject ( MyListViewItem * item, Uml::UMLObject_Type type )
- void createChildUMLObject ( MyListViewItem * item, Uml::UMLObject_Type type )
- void createDiagram ( MyListViewItem * item, Uml::Diagram_Type type )
- QString getUniqueDiagramName ( Uml::Diagram_Type type )
- QString getUniqueChildUMLObjectName ( UMLConcept * parent, Uml::UMLObject_Type type )
- QString getUniqueUMLObjectName ( Uml::UMLObject_Type type )
- bool isUnique ( MyListViewItem * item, QString name )
- void cancelRename ( QListViewItem * item )
- bool saveToXMI ( QDomDocument & qDoc, QDomElement & qElement )
- bool loadFromXMI ( QDomElement & element )
- bool loadChildrenFromXMI ( MyListViewItem * parent, QDomElement & element )
Public Slots
Signals
Protected Types
Protected Methods
Protected Members
This class provides encoding and decoding for the uml data
that will be use in a drag_n_drop operation or in a copy paste
operation
| enum Icon_Type { it_Home = 0,
it_Folder_Green,
it_Folder_Green_Open,
it_Folder_Grey,
it_Folder_Grey_Open,
it_Diagram,
it_Class,
it_Actor,
it_UseCase,
it_Public_Method,
it_Private_Method,
it_Protected_Method,
it_Public_Attribute,
it_Private_Attribute,
it_Protected_Attribute
}
| Icon_Type |
MyListView (QWidget *parent,const char *name)
| MyListView |
Constructs the tree view.
Parameters:
| parent | The parent to this.
|
| name | The internal name for this class.
|
~MyListView ()
| ~MyListView |
Standard deconstructor.
void setDocument (UMLDoc * d)
| setDocument |
Sets the document his is associated with. This is important as
this is required as to setup the callbacks.
Parameters:
| d | The document to associate with this class.
|
Carries out initalisation of attributes in class.
Set the current view to the given view.
Parameters:
bool serialize (QDataStream *s, bool archive)
| serialize |
Use to save or load this classes information
Parameters:
| s | Pointer to the datastream (file) to save/load from.
|
| archive | If true will save the classes information, else will
load the information.
|
Returns: Returns the status of the operation.
long getClipSizeOf ()
| getClipSizeOf |
void setLoading (bool _state)
| setLoading |
void setWidgetDefaults ()
| setWidgetDefaults |
Returns the amount of bytes needed to serialize Item to the clipboard
Serialize Item to a QDataStream that will be put in the clipboard
Creates a new MyListViewItem from a MyListViewItemData, if
parent is null the ListView Decides who is going to be the
parent
QPoint TranslatePosition (QPoint Pt)
| TranslatePosition |
Transalates a QPoint to the coordinates of the viewport
containing the ListView
int getSelectedCount ()
| getSelectedCount |
Return the amount of items selected.
Returns the correct pixmap for the given type.
UMLDoc * getDocument ()
| getDocument |
Returns the document pointer. Called by the MyListViewItem class.
Adds a new item to the tree of the given type under the given parent.
Method will take care of signalling anyone needed on creation of new item.
e.g. UMLDoc if an UMLObject is created.
Creates a UMLObject out of the given list view item.
Creates a child UMLObject out of the given list view item.
Creates a diagram out of the given list view item.
Returns a unique name for a diagram.
Returns a unique name for a child umlobject.
Returns a unique name for an object.
Returns if the given name is unique for the given items type.
Cancel rename event has occurred for the given item.
bool saveToXMI ( QDomDocument & qDoc, QDomElement & qElement )
| saveToXMI |
bool loadFromXMI ( QDomElement & element )
| loadFromXMI |
bool loadChildrenFromXMI ( MyListViewItem * parent, QDomElement & element )
| loadChildrenFromXMI |
[protected]
[protected]
[protected]
[protected]
[protected]
[protected]
[protected]
[protected]
| bool m_bStartedCut
| m_bStartedCut |
[protected]
| bool m_bIgnoreCancelRename
| m_bIgnoreCancelRename |
[protected]
[protected]
void contentsMouseReleaseEvent (QMouseEvent * me)
| contentsMouseReleaseEvent |
[protected]
void contentsMousePressEvent (QMouseEvent *me)
| contentsMousePressEvent |
[protected]
void contentsMouseDoubleClickEvent (QMouseEvent * me)
| contentsMouseDoubleClickEvent |
[protected]
void focusOutEvent ( QFocusEvent * fe)
| focusOutEvent |
[protected]
[protected]
QDragObject* dragObject ()
| dragObject |
[protected]
void startDrag ()
| startDrag |
[protected]
void tidyChangeItem ()
| tidyChangeItem |
[protected]
bool acceptDrag (QDropEvent* event)
| acceptDrag |
[protected const]
[protected]
[protected]
[protected]
[protected]
[protected]
[protected]
void loadPixmaps ()
| loadPixmaps |
[protected]
Loads the pixmaps to use in the list items.
void slotDiagramCreated (int id)
| slotDiagramCreated |
[slot]
void slotChildObjectCreated (UMLObject * o)
| slotChildObjectCreated |
[slot]
void slotDiagramRenamed (int id)
| slotDiagramRenamed |
[slot]
void slotObjectChanged (UMLObject * o)
| slotObjectChanged |
[slot]
void slotChildObjectChanged (UMLObject * o)
| slotChildObjectChanged |
[slot]
void slotObjectRemoved (UMLObject * o)
| slotObjectRemoved |
[slot]
void slotDiagramRemoved (int id)
| slotDiagramRemoved |
[slot]
void popupMenuSel (int sel)
| popupMenuSel |
[slot]
void slotObjectCreated (UMLObject * o)
| slotObjectCreated |
[slot]
[slot]
[slot]
[slot]
void slotCutSuccessful ()
| slotCutSuccessful |
[slot]
Connects to the signal that UMLApp emits when a
cut operation is successful.
void slotItemRenamed ( QListViewItem * item , int col )
| slotItemRenamed |
[slot]
When a user requests a new item we wait for the signal
to then verify the item. The class only connects to the
rename signal while needed.
void sigResetStatusbarProgress ()
| sigResetStatusbarProgress |
[signal]
Reset the status bar
void sigSetStatusbarProgressSteps (int totalSteps)
| sigSetStatusbarProgressSteps |
[signal]
void sigSetStatusbarProgress (int stepPosition)
| sigSetStatusbarProgress |
[signal]
- Author: Gustavo Madrigal
- Generated: jr on radge on Wed Sep 25 00:11:47 2002, using kdoc 2.0a54.