- training_area_telegrams.cpp: Fixed QJsonObject initializer syntax (Qt6 requires {{}} not ({}))
- training_area_telegrams.cpp: Fixed fromJson() methods to access m_* members directly
- training_area_telegrams.cpp: Fixed brace mismatches in multiple toJson() methods
- training_area_telegrams.h: Changed Header struct to public members for consistency
- tx_mixin.cpp: Fixed getEquipmentNumber() template for direct member access
- lts_coordinate.cpp: Added missing #include <iomanip>
- MIGRATION_STATUS.md: Added migration progress tracking document
C++17 constraint enforced due to RTI Connext DDS 7.7.0 incompatibility with C++20+
Build status: BUILD_RTI=OFF successful (0 errors, warnings only)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
95 lines
1.7 KiB
C++
95 lines
1.7 KiB
C++
|
|
|
|
#pragma once
|
|
#include "EventTools.h"
|
|
#include "LineMap.h"
|
|
|
|
#include <QtWidgets/QComboBox>
|
|
#include <QtCore/QObject>
|
|
#include <QtCore/QPair>
|
|
#include <QtCore/QPoint>
|
|
#include <QtWidgets/QWidget>
|
|
|
|
namespace NGL
|
|
{
|
|
class INGLLogger;
|
|
|
|
}
|
|
class QPushButton;
|
|
class QLabel;
|
|
|
|
namespace LtsTimelineClassic
|
|
{
|
|
|
|
class TimelineIndicatorTest;
|
|
|
|
class TimelineIndicator : public QWidget
|
|
{
|
|
Q_OBJECT
|
|
|
|
friend class TimelineIndicatorTest;
|
|
|
|
static const int s_TimeTextDistanceTolerancePixels = 10;
|
|
static const int s_pbSize = 18;
|
|
|
|
public:
|
|
explicit TimelineIndicator(QWidget* parent);
|
|
~TimelineIndicator();
|
|
|
|
qint64 zoomFactorPoints() const
|
|
{
|
|
return m_zoomFactorPoints * 1000;
|
|
}
|
|
|
|
void refreshData();
|
|
|
|
private:
|
|
QVector<qint64> m_timeArray;
|
|
qint64 m_zoomFactorPoints;
|
|
QPushButton* m_pbZoom;
|
|
QPushButton* m_pbUnzoom;
|
|
QComboBox* m_cbZoomLevel;
|
|
int m_currentTextHeight;
|
|
int m_currentTextWidth;
|
|
LineMap m_lineMap;
|
|
int m_sectionPos;
|
|
int m_sectionSize;
|
|
|
|
protected:
|
|
NGL::INGLLogger& m_logger;
|
|
void paintEvent(QPaintEvent*);
|
|
|
|
public:
|
|
// Public getter for testing
|
|
QComboBox* zoomLevelComboBox() const { return m_cbZoomLevel; }
|
|
|
|
signals:
|
|
|
|
void signalSetTimelineRange(qint64 min, qint64 max);
|
|
|
|
void signalSetZoomFactor(qint64 zoomFactor);
|
|
|
|
void signalResetLineList();
|
|
|
|
void signalAddLine(int posX, qint64 time);
|
|
|
|
void signalZoomChanged();
|
|
|
|
private slots:
|
|
void afterZoom();
|
|
|
|
public slots:
|
|
|
|
void slotSectionResized(int logicalIndex, int oldSize, int newSize);
|
|
|
|
void slotZoom();
|
|
|
|
void slotUnzoom();
|
|
|
|
void slotResetLineList();
|
|
|
|
void slotAddLine(double posX, qint64 time);
|
|
};
|
|
|
|
} // namespace LtsTimelineClassic
|