Initial commit
This commit is contained in:
commit
b7d90b9afe
16245 files changed
+3396666
No files matched your search
+76
@@ -0,0 +1,76 @@
|
||||
/**
|
||||
* @RDE_HEADER@
|
||||
* passive container for view which only draws QPushButtons to save ressources
|
||||
* $Id$
|
||||
* $HeadURL$
|
||||
* $Author$
|
||||
* Created by Mike Wille, SLSE, 2014-10-01
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "EventList.h"
|
||||
#include "LineMap.h"
|
||||
#include "Range.h"
|
||||
|
||||
#include <QObject>
|
||||
|
||||
|
||||
class QPainter;
|
||||
class QStyleOptionViewItem;
|
||||
|
||||
|
||||
namespace LtsTimelineClassic
|
||||
{
|
||||
|
||||
/**
|
||||
* @brief passive container for view which only draws QPushButtons to save ressources
|
||||
* contains many Events (EventWidget)
|
||||
* only paints the widgets (widgets are not user-accessible)
|
||||
*/
|
||||
class PassiveEventContainer: public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
/**
|
||||
* @brief sets all required values in class and with the given event list
|
||||
* @param eventList event list to manage by this pevcon
|
||||
* @param parent parent
|
||||
*/
|
||||
explicit PassiveEventContainer(bool ignoreKnownRanges, QObject *parent = nullptr);
|
||||
|
||||
~PassiveEventContainer();
|
||||
|
||||
/**
|
||||
* @brief draws all widgets on itself (which lies directly on the view) by considering the parameters
|
||||
* @param painter painter to draw all containers on the view
|
||||
* @param option style options of coherant row & column
|
||||
* @param max last event in timeline in seconds since epoch
|
||||
* @param min first event in timeline in seconds since epoch
|
||||
* @param scrollBarPosition scrollbar positiion in seconds since epoch
|
||||
* @param zoomFactor zoom factor in percent points
|
||||
*/
|
||||
void paint(QPainter *painter, const QStyleOptionViewItem &option, const LineMap &lineMap, const QVector<Range> &knownRanges) const;
|
||||
|
||||
/**
|
||||
* @brief returns event list of pevcon (to create a new acecon which needs a event list)
|
||||
* @return event list
|
||||
*/
|
||||
EventGraphicList getEventGraphicList() const;
|
||||
|
||||
/**
|
||||
* @brief sets event list of pevcon
|
||||
* @eventList new event list
|
||||
*/
|
||||
void setEventList(const EventGraphicList &eventGraphicList);
|
||||
|
||||
private:
|
||||
EventGraphicList m_eventGraphicList;
|
||||
bool m_ignoreKnownRanges;
|
||||
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
Q_DECLARE_METATYPE(LtsTimelineClassic::PassiveEventContainer *)
|
||||
Reference in new issue
Block a user