Changeset 64749 in vbox for trunk/src/VBox/Frontends/VirtualBox
- Timestamp:
- Nov 24, 2016 5:25:23 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/widgets/UIApplianceEditorWidget.cpp
r64748 r64749 48 48 /** Describes the interface of Appliance item. 49 49 * Represented as a tree structure with a parent & multiple children. */ 50 class UIApplianceModelItem 50 class UIApplianceModelItem : public QITreeViewItem 51 51 { 52 52 public: … … 68 68 void appendChild(UIApplianceModelItem *pChildItem); 69 69 /** Returns the child specified by the @a iIndex. */ 70 UIApplianceModelItem *childItem(int iIndex) const;70 virtual UIApplianceModelItem *childItem(int iIndex) const /* override */; 71 71 72 72 /** Returns the row of the item in the parent. */ … … 74 74 75 75 /** Returns the number of children. */ 76 int childCount() const;76 virtual int childCount() const /* override */; 77 77 /** Returns the number of columns. */ 78 78 int columnCount() const { return 3; } 79 80 /** Returns the item text. */ 81 virtual QString text() const /* override */; 79 82 80 83 /** Returns the item flags for the given @a iColumn. */ … … 215 218 *********************************************************************************************************************************/ 216 219 217 UIApplianceModelItem::UIApplianceModelItem(int iNumber, ApplianceModelItemType enmType, QITreeView * /* pParent */) 218 : m_iNumber(iNumber) 220 UIApplianceModelItem::UIApplianceModelItem(int iNumber, ApplianceModelItemType enmType, QITreeView *pParent) 221 : QITreeViewItem(pParent) 222 , m_iNumber(iNumber) 219 223 , m_enmType(enmType) 220 224 , m_pParentItem(0) … … 223 227 224 228 UIApplianceModelItem::UIApplianceModelItem(int iNumber, ApplianceModelItemType enmType, UIApplianceModelItem *pParentItem) 225 : m_iNumber(iNumber) 229 : QITreeViewItem(pParentItem) 230 , m_iNumber(iNumber) 226 231 , m_enmType(enmType) 227 232 , m_pParentItem(pParentItem) … … 256 261 { 257 262 return m_childItems.count(); 263 } 264 265 QString UIApplianceModelItem::text() const 266 { 267 return data(ApplianceViewSection_Description, Qt::DisplayRole).toString(); 258 268 } 259 269
Note:
See TracChangeset
for help on using the changeset viewer.