Apply clang-format to Lts/Common and DTC/enum headers

- Formatted all CodeGen module files (9 files)
- Formatted LtsAppDescriptor module files
- Formatted LtsAppManager/AppChooser files
- Applied clang-format to all DTC and enum headers across modules
- Removed coordTransTests from CommonUnitTestsPlaceholder (moved to tests/)

Cosmetic changes only, no functional modifications.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
torstenandCopilot committed 2026-08-19 14:46:29 +02:00
1 parent 1881d68aef
commit d6b6ffce7c
848 files changed
+89305 -100020

No files matched your search

+75 -73
View File
@@ -1,16 +1,13 @@
#pragma once
#include <QObject>
#include "ltswidgets_export.h"
#include <QWidget>
#include <QVector>
#include <QShortcut>
#include <QMap>
#include <QObject>
#include <QShortcut>
#include <QVector>
#include <QWidget>
class QMenu;
class QLabel;
@@ -26,91 +23,96 @@ class LtsDragIcon;
struct ShortCut
{
int key = 0;
QShortcut *shortcut = nullptr;
QString name;
QString identifier;
LtsDragIcon *icon = nullptr;
QString keyName() const {return shortcut ? shortcut->key().toString() : QString();}
void clear();
int key = 0;
QShortcut* shortcut = nullptr;
QString name;
QString identifier;
LtsDragIcon* icon = nullptr;
explicit ShortCut(QWidget *parent = nullptr)
: shortcut(new QShortcut(parent))
{}
~ShortCut() { delete shortcut; }
ShortCut(const ShortCut &o)
: key(o.key)
, name(o.name)
, identifier(o.identifier)
, icon(o.icon)
{
if (o.shortcut)
QString keyName() const
{
delete shortcut;
shortcut = new QShortcut(o.shortcut->key(), qobject_cast<QWidget*>(o.shortcut->parent()), nullptr, nullptr, o.shortcut->context());
return shortcut ? shortcut->key().toString() : QString();
}
}
ShortCut &operator=(const ShortCut &o)
{
if (&o == this)
return *this;
void clear();
key = o.key;
name = o.name;
identifier = o.identifier;
icon = o.icon;
QWidget *parent = qobject_cast<QWidget*>(shortcut->parent());
delete shortcut;
if (o.shortcut)
shortcut = new QShortcut(o.shortcut->key(), qobject_cast<QWidget*>(o.shortcut->parent()), nullptr, nullptr, o.shortcut->context());
else
shortcut = new QShortcut(parent);
return *this;
}
explicit ShortCut(QWidget* parent = nullptr) : shortcut(new QShortcut(parent)) {}
~ShortCut()
{
delete shortcut;
}
ShortCut(const ShortCut& o) : key(o.key), name(o.name), identifier(o.identifier), icon(o.icon)
{
if (o.shortcut)
{
delete shortcut;
shortcut = new QShortcut(o.shortcut->key(), qobject_cast<QWidget*>(o.shortcut->parent()), nullptr, nullptr,
o.shortcut->context());
}
}
ShortCut& operator=(const ShortCut& o)
{
if (&o == this)
return *this;
key = o.key;
name = o.name;
identifier = o.identifier;
icon = o.icon;
QWidget* parent = qobject_cast<QWidget*>(shortcut->parent());
delete shortcut;
if (o.shortcut)
shortcut = new QShortcut(o.shortcut->key(), qobject_cast<QWidget*>(o.shortcut->parent()), nullptr, nullptr,
o.shortcut->context());
else
shortcut = new QShortcut(parent);
return *this;
}
};
class LTSWIDGETS_EXPORT LtsToolBarArea : public QWidget
{
Q_OBJECT
public:
explicit LtsToolBarArea(QWidget *parent = nullptr);
~LtsToolBarArea();
Q_OBJECT
public:
explicit LtsToolBarArea(QWidget* parent = nullptr);
~LtsToolBarArea();
void addMenuEntry(LtsDragIcon *entry, LtsDragIcon *after = nullptr);
void clearToolBarArea();
void addMenuEntry(LtsDragIcon* entry, LtsDragIcon* after = nullptr);
void clearToolBarArea();
void setMenuEntries(const QVector<LtsDragIcon *> &actions);
QStringList menuEntries() const;
void setMenuEntries(const QVector<LtsDragIcon*>& actions);
QStringList menuEntries() const;
bool setFunctionKey(int fkey, const QString &action);
QMap<int, QString> functionKeys() const;
bool setFunctionKey(int fkey, const QString& action);
QMap<int, QString> functionKeys() const;
bool removeFunctionKey(const QString &action);
void removeMenuAction(LtsDragIcon *icon);
bool removeFunctionKey(const QString& action);
void removeMenuAction(LtsDragIcon* icon);
public slots:
void showContextMenu(const QPoint &pos);
void functionKeyMenuTriggered();
public slots:
void showContextMenu(const QPoint& pos);
void functionKeyMenuTriggered();
protected:
void dragEnterEvent(QDragEnterEvent *event) override;
void dropEvent(QDropEvent *event) override;
protected:
void dragEnterEvent(QDragEnterEvent* event) override;
void dropEvent(QDropEvent* event) override;
private:
QMenu* functionKeyMenu(QWidget *parent);
QString m_currentIdentifierForContextMenue;
private:
QMenu* functionKeyMenu(QWidget* parent);
QString m_currentIdentifierForContextMenue;
QVector<LtsDragIcon *> m_buttonMap;
QVector<LtsDragIcon *> m_foreignButtonMap;
QMap<int, ShortCut> m_functionKeys;
QLabel *m_dummyLabel;
QVector<LtsDragIcon*> m_buttonMap;
QVector<LtsDragIcon*> m_foreignButtonMap;
QMap<int, ShortCut> m_functionKeys;
QLabel* m_dummyLabel;
Ui::LtsToolBarArea *m_ui;
Ui::LtsToolBarArea* m_ui;
void saveSettings();
void saveSettings();
};
}
} // namespace LtsWidgets