Files
qt-migration-legatus/qt6-after/qt6-migrated-legatus/TetraIF/LogView/LogViewField.hpp
T
torstenandCopilot c9411c04e1 Fix Qt6 compatibility issues and exclude tests from release build
- tests/CMakeLists.txt: Wrap migration_tests in RELEASE_BUILD conditional
- LogViewModels.cpp: Change BackgroundColorRole to BackgroundRole for Qt6
- LogViewField.hpp/cpp: Add m_logger member variable
- LogViewInjectionThread.hpp/cpp: Add m_logger member variable
- LogViewGui.hpp/cpp: Add m_logger member variable, fix QString::split() usage
- LogViewTetraTelegramsParser.hpp: Add m_logger, change QStringRef to QStringView
- LogViewTelegramEdit.hpp: Fix QModelIndex include path (QtGui→QtCore)
- LogViewModels.hpp: Fix QAbstractTableModel include path (QtGui→QtCore)
- PrtCnv/CMakeLists.txt: Add CMAKE_CURRENT_BINARY_DIR for export header, exclude LastTest from release
- CoPrtCnv/CMakeLists.txt: Add PrtCnv include paths for prtcnvlib_export.h
- Lts/Common/CodeGen/CMakeLists.txt: Add CMAKE_CURRENT_BINARY_DIR for export header
- Lts/Proxies/TrainingAreaBase/Plugins/CMakeLists.txt: Exclude WlsTetra from release scope

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-10-09 20:19:27 +00:00

141 lines
2.9 KiB
C++

#pragma once
#include <QtCore/QStringList>
#include <QtCore/QVector>
#include "logger.h"
namespace N_LogView
{
class LogViewXdrElement;
class LogViewField
{
public:
enum E_FieldKind
{
e_FieldKindBorder,
e_FieldKindEdit,
e_FieldKindTab,
e_FieldKindTabChild,
e_FieldKindPodArray,
e_FieldKindPodArrayChild
};
LogViewField(const QString& a_name, const E_FieldKind a_kind, const LogViewXdrElement* a_xdrElement);
virtual ~LogViewField();
LogViewField *clone(int arrayIdx) const;
QString cleanName() const { return makeClean(m_Name); }
QString name() const { return m_Name; }
void setName(const QString &newVal) { m_Name = newVal; }
void addChild(LogViewField* a_child);
void removeLastChild();
LogViewField *child(int arrayIdx);
int childCount() const { return m_Child.size(); }
QString type() const { return m_type; }
void setType(const QString &type) { m_type = type; }
LogViewField::E_FieldKind kind() const { return m_Kind; }
void addValue(const QString &value);
void addValueBinaryHex(const QString &value);
QString value(int arrayIdx, const bool a_doNotMakeSpecialConversions = false) const;
int valueListSize() const { return m_ValueList.size(); }
bool isRightAligned() const { return m_IsRightAligned; }
void setIsRightAligned(bool newVal) { m_IsRightAligned = newVal; }
QString toolTipText() const { return m_ToolTipText; }
void setToolTipText(const QString &newVal) { m_ToolTipText = newVal; }
int64_t getHighestValue() const;
int64_t getLowestValue() const;
void dump(const QString &a_indent = QString()) const;
static QString makeClean(const QString &text);
int size() const { return m_Size; }
void setSize(int newVal) { m_Size = newVal; }
const LogViewXdrElement* xdrElement() const { return m_XdrElement; }
bool isDateTimeField() const;
bool isMSecsField() const;
uint16_t maxArraySize() const { return m_MaxArraySize; }
void setMaxArraySize(uint16_t newVal, const bool a_isDynamic);
bool isDynamicArray() const { return m_IsDynamicArray; }
bool hasContent() const { return m_HasContent; }
void setHasContent(bool newVal) { m_HasContent = newVal; }
void setDeleteXdr(bool bDelete) { m_bDeleteXdr = bDelete; }
void setJsonPath(const QStringList &path) { m_jsonPath = path; }
QStringList jsonPath() const { return m_jsonPath; }
protected:
Logger& m_logger;
QString m_Name;
QString m_type;
QStringList m_ValueList;
QStringList m_jsonPath;
bool m_IsRightAligned;
QString m_ToolTipText;
uint16_t m_Offset;
int m_Size;
uint16_t m_MaxArraySize;
bool m_IsDynamicArray;
bool m_HasContent;
bool m_bDeleteXdr;
QVector<LogViewField*> m_Child;
E_FieldKind m_Kind;
const LogViewXdrElement *m_XdrElement;
private:
};
}