Skip to content

Commit

Permalink
fix ui inconsistencies
Browse files Browse the repository at this point in the history
Signed-off-by: swurl <[email protected]>
  • Loading branch information
crueter committed Dec 25, 2024
1 parent 477fe29 commit 88c3deb
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 4 deletions.
3 changes: 2 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ set(CMAKE_AUTORCC ON)
option(USE_SYSTEM_NTCORE OFF "Use the system NTCore (Linux only)")
option(USE_SYSTEM_PROTOBUF OFF "Use the system protobuf (Linux only)")

find_package(Qt6 6.7 REQUIRED COMPONENTS Quick Multimedia)
find_package(Qt6 6.7 REQUIRED COMPONENTS Quick Multimedia QuickControls2)
add_subdirectory(3rd_party EXCLUDE_FROM_ALL)

qt_standard_project_setup(REQUIRES 6.7)
Expand Down Expand Up @@ -186,6 +186,7 @@ set_target_properties(${Dashboard_EXEC_NAME} PROPERTIES
target_link_libraries(${Dashboard_EXEC_NAME}
PRIVATE Qt6::Quick
Qt6::Multimedia
Qt6::QuickControls2
BuildConfig
ntcore
)
Expand Down
10 changes: 7 additions & 3 deletions Main.qml
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import QtQuick
import QtQuick.Controls

import QtQuick.Controls.Universal

import QFRCDashboard

ApplicationWindow {
Expand All @@ -10,6 +12,9 @@ ApplicationWindow {
visible: true
title: titleManager.title

Universal.theme: Universal.Dark
Universal.accent: "Lime"

AccentEditor {
id: accentEditor

Expand Down Expand Up @@ -59,7 +64,8 @@ ApplicationWindow {
delegate: MenuItem {
text: qsTr("&" + index + ". " + modelData)
onTriggered: {
if (modelData === "" || modelData === null) return;
if (modelData === "" || modelData === null)
return
tlm.clear()
tlm.load(modelData)
}
Expand Down Expand Up @@ -109,5 +115,3 @@ ApplicationWindow {
anchors.fill: parent
}
}


4 changes: 4 additions & 0 deletions main.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#include <QGuiApplication>
#include <QQuickStyle>
#include <QQmlApplicationEngine>
#include <QQmlContext>
#include <TabListModel.h>
Expand All @@ -22,6 +23,9 @@ int main(int argc, char *argv[])
app.setApplicationName(BuildConfig.APP_NAME);
app.setApplicationVersion(BuildConfig.versionString());

qDebug() << QQuickStyle::name();
QQuickStyle::setStyle("Universal");

TopicStore store(&app);

TopicListModel *topics = new TopicListModel(store, &app);
Expand Down

0 comments on commit 88c3deb

Please sign in to comment.