leocad/common/lc_timelinewidget.h

40 lines
959 B
C
Raw Normal View History

#pragma once
class lcTimelineWidget : public QTreeWidget
{
Q_OBJECT
public:
lcTimelineWidget(QWidget* Parent);
~lcTimelineWidget();
void Update(bool Clear, bool UpdateItems);
void UpdateSelection();
void InsertStepBefore();
void InsertStepAfter();
void RemoveStep();
void MoveSelection();
void MoveSelectionBefore();
void MoveSelectionAfter();
void SetCurrentStep();
public slots:
void CurrentItemChanged(QTreeWidgetItem* Current, QTreeWidgetItem* Previous);
void ItemSelectionChanged();
void CustomMenuRequested(QPoint Pos);
void PreviewSelection(QTreeWidgetItem* Current);
2015-03-08 01:27:11 +01:00
protected:
void dropEvent(QDropEvent* DropEvent) override;
void mousePressEvent(QMouseEvent* MouseEvent) override;
2020-12-18 21:15:35 +01:00
void mouseDoubleClickEvent(QMouseEvent* MouseEvent) override;
void UpdateModel();
void UpdateCurrentStepItem();
2015-04-15 20:49:17 +02:00
QMap<int, QIcon> mIcons;
QMap<lcPiece*, QTreeWidgetItem*> mItems;
QTreeWidgetItem* mCurrentStepItem;
bool mIgnoreUpdates;
};