50 #ifndef PROPERTY_MODEL_H
51 #define PROPERTY_MODEL_H
54 #include <QAbstractListModel>
64 virtual void pickModeChanged(
const std::string& _mode) {}
65 virtual void mouseEvent(QMouseEvent* _event) {}
67 PropertyModel(QObject *parent = 0) : QAbstractListModel(parent) {}
70 virtual int rowCount(
const QModelIndex & parent = QModelIndex())
const = 0;
71 virtual QVariant data(
const QModelIndex & index,
int role = Qt::DisplayRole)
const = 0;
72 virtual QVariant headerData(
int section, Qt::Orientation orientation,
int role = Qt::DisplayRole)
const = 0;
78 virtual void visualize(QModelIndexList selectedIndices, QWidgetList widgets = QWidgetList()) = 0;
90 virtual void clear(QModelIndexList selectedIndices) = 0;
99 virtual void updateWidget(
const QModelIndexList& selectedIndices) = 0;
This class vizualizes a property.
virtual void removeProperty(QModelIndexList selectedIndices)=0
Removes the selected properties.
virtual void duplicateProperty(QModelIndexList selectedIndices)=0
Duplicates the selected properties.
virtual PropertyInfo getPropertyInfo(const QModelIndex index) const =0
Returns the property info for the property with the given index.
virtual void connectLogs(PropertyVisualizer *propViz)=0
Connects the PropertyVisualizer log signals with the log slot.
virtual QWidget * getWidget()=0
Returns the widget.
virtual void clear(QModelIndexList selectedIndices)=0
Clears the selected property visualization.
QModelIndex indexFromPlainPropName(const QString &propName) const
Returns the index of the property with the given name.
virtual void gatherProperties()=0
Searches for properties and creates PropertyVisualizers.
virtual void objectUpdated()=0
Revisualizes visualized properties.
virtual void visualize(QModelIndexList selectedIndices, QWidgetList widgets=QWidgetList())=0
Visualizes the selected properties.
virtual void hideWidget()=0
Hides the widget.
QModelIndex indexFromFancyPropName(const QString &propName) const
Returns the index of the property with the given name.
Cellection of information about a property.
virtual void updateWidget(const QModelIndexList &selectedIndices)=0
Updates the widget.