d34409ad02ea0d28e08a6c4b089a412fdb3b4c9cvboxsync * VBox Qt GUI - UIGDetailsItem class declaration.
c7814cf6e1240a519cbec0441e033d0e2470ed00vboxsync * Copyright (C) 2012-2013 Oracle Corporation
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync * This file is part of VirtualBox Open Source Edition (OSE), as
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync * available from http://www.virtualbox.org. This file is free software;
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync * you can redistribute it and/or modify it under the terms of the GNU
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync * General Public License (GPL) as published by the Free Software
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync * Foundation, in version 2 as it comes in the "COPYING" file of the
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync/* GUI includes: */
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync/* Forward declaration: */
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync/* UIGDetailsItem types: */
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync UIGDetailsItemType_Group = QGraphicsItem::UserType + 1,
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync UIGDetailsItemType_Set = QGraphicsItem::UserType + 2,
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync UIGDetailsItemType_Element = QGraphicsItem::UserType + 3,
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync UIGDetailsItemType_Preview = QGraphicsItem::UserType + 10
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync/* Details item interface
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync * for graphics details model/view architecture: */
5c6842a1ea283266371775a3763986930313f182vboxsyncclass UIGDetailsItem : public QIWithRetranslateUI4<QIGraphicsWidget>
0a2ea4969a6ceee3798121b462a0d03a1394065fvboxsync /* Notifiers: Build stuff: */
0a2ea4969a6ceee3798121b462a0d03a1394065fvboxsync void sigBuildStep(QString strStepId, int iStepNumber);
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync /* Constructor: */
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync /* API: Cast stuff: */
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync /* API: Model stuff: */
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync /* API: Parent stuff: */
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync /* API: Children stuff: */
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync virtual void removeItem(UIGDetailsItem *pItem) = 0;
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync virtual QList<UIGDetailsItem*> items(UIGDetailsItemType type = UIGDetailsItemType_Any) const = 0;
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync virtual bool hasItems(UIGDetailsItemType type = UIGDetailsItemType_Any) const = 0;
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync virtual void clearItems(UIGDetailsItemType type = UIGDetailsItemType_Any) = 0;
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync /* API: Layout stuff: */
4f1d643b0004170541444c4c0e425568b5ba4bcevboxsync QSizeF sizeHint(Qt::SizeHint which, const QSizeF &constraint = QSizeF()) const;
0a2ea4969a6ceee3798121b462a0d03a1394065fvboxsync /* Handler: Build stuff: */
0a2ea4969a6ceee3798121b462a0d03a1394065fvboxsync virtual void sltBuildStep(QString strStepId, int iStepNumber);
5c6842a1ea283266371775a3763986930313f182vboxsync /* Helper: Translate stuff: */
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync /* Helpers: Paint stuff: */
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync static void configurePainterShape(QPainter *pPainter, const QStyleOptionGraphicsItem *pOption, int iRadius);
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync static void paintFrameRect(QPainter *pPainter, const QRect &rect, int iRadius);
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync static void paintPixmap(QPainter *pPainter, const QRect &rect, const QPixmap &pixmap);
9be5004fe11e14212cde2f4596a4f56675b11b19vboxsync static void paintText(QPainter *pPainter, QPoint point,
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync /* Variables: */
c6d0c503f95d48f31a8a9fcbcef24d7e56a802c5vboxsync/* Allows to build item content synchronously: */
c6d0c503f95d48f31a8a9fcbcef24d7e56a802c5vboxsync /* Notifier: Build stuff: */
c6d0c503f95d48f31a8a9fcbcef24d7e56a802c5vboxsync void sigStepDone(QString strStepId, int iStepNumber);
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync /* Constructor: */
0a2ea4969a6ceee3798121b462a0d03a1394065fvboxsync UIBuildStep(QObject *pParent, QObject *pBuildObject, const QString &strStepId, int iStepNumber);
c6d0c503f95d48f31a8a9fcbcef24d7e56a802c5vboxsync /* Handler: Build stuff: */
88673d909ab003f20795ffab6bc724d9bd75bbdcvboxsync /* Variables: */
54bdb685c29854142c633fceb09a6e0f3bb72132vboxsync#endif /* __UIGDetailsItem_h__ */