VirtualBox

Changeset 50697 in vbox


Ignore:
Timestamp:
Mar 5, 2014 11:21:06 AM (11 years ago)
Author:
vboxsync
Message:

FE/Qt: Medium Manager rework/cleanup: Few comments.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/medium/UIMediumManager.cpp

    r50368 r50697  
    5454
    5555
    56 /* Medium-item: */
     56/** QTreeWidgetItem extension representing Medium Manager item. */
    5757class UIMediumItem : public QTreeWidgetItem
    5858{
    5959public:
    6060
    61     /* Medium-item type: */
     61    /** UIMediumItem type for rtti needs. */
    6262    enum { Type = QTreeWidgetItem::UserType + 1 };
    6363
    64     /* Constructor: Top-level item: */
     64    /** Constructor for top-level item. */
    6565    UIMediumItem(const UIMedium &medium, QTreeWidget *pParent)
    6666        : QTreeWidgetItem(pParent, Type)
     
    6868    { refresh(); }
    6969
    70     /* Constructor: Child item: */
     70    /** Constructor for child item. */
    7171    UIMediumItem(const UIMedium &medium, UIMediumItem *pParent)
    7272        : QTreeWidgetItem(pParent, Type)
     
    7474    { refresh(); }
    7575
    76     /* API: Refresh stuff: */
     76    /** Refreshes item fully. */
    7777    void refreshAll()
    7878    {
     
    8181    }
    8282
    83     /* API: Medium stuff: */
     83    /** Returns UIMedium wrapped by <i>this</i> item. */
    8484    const UIMedium& medium() const { return m_medium; }
     85    /** Defines UIMedium wrapped by <i>this</i> item. */
    8586    void setMedium(const UIMedium &medium)
    8687    {
     
    8990    }
    9091
    91     /* API: Medium-type stuff: */
     92    /** Returns UIMediumType of the wrapped UIMedium. */
    9293    UIMediumType mediumType() const { return m_medium.type(); }
    9394
    94     /* API: State stuff: */
     95    /** Returns KMediumState of the wrapped UIMedium. */
    9596    KMediumState state() const { return m_medium.state(); }
    9697
    97     /* API: ID stuff: */
     98    /** Returns QString <i>ID</i> of the wrapped UIMedium. */
    9899    QString id() const { return m_medium.id(); }
    99100
    100     /* API: Location stuff: */
     101    /** Returns QString <i>location</i> of the wrapped UIMedium. */
    101102    QString location() const { return m_medium.location(); }
    102103
    103     /* API: Hard-disk stuff: */
     104    /** Returns QString <i>hard-disk format</i> of the wrapped UIMedium. */
    104105    QString hardDiskFormat() const { return m_medium.hardDiskFormat(); }
     106    /** Returns QString <i>hard-disk type</i> of the wrapped UIMedium. */
    105107    QString hardDiskType() const { return m_medium.hardDiskType(); }
    106108
    107     /* API: Details stuff: */
     109    /** Returns QString <i>storage details</i> of the wrapped UIMedium. */
    108110    QString details() const { return m_medium.storageDetails(); }
    109111
    110     /* API: Tool-tip stuff: */
     112    /** Returns QString <i>tool-tip</i> of the wrapped UIMedium. */
    111113    QString toolTip() const { return m_medium.toolTip(); }
    112114
    113     /* API: Usage stuff: */
     115    /** Returns QString <i>usage</i> of the wrapped UIMedium. */
    114116    QString usage() const { return m_medium.usage(); }
     117    /** Returns whether wrapped UIMedium is used or not. */
    115118    bool isUsed() const { return m_medium.isUsed(); }
     119    /** Returns whether wrapped UIMedium is used in snapshots or not. */
    116120    bool isUsedInSnapshots() const { return m_medium.isUsedInSnapshots(); }
    117121
    118     /* API: Sorting stuff: */
     122    /** Operator< reimplementation used for sorting purposes. */
    119123    bool operator<(const QTreeWidgetItem &other) const
    120124    {
     
    127131private:
    128132
    129     /* Helper: Refresh stuff: */
     133    /** Refreshes item information such as icon, text and tool-tip. */
    130134    void refresh()
    131135    {
     
    141145    }
    142146
    143     /* Variables: */
     147    /** UIMedium wrapped by <i>this</i> item. */
    144148    UIMedium m_medium;
    145149};
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette