aboutsummaryrefslogtreecommitdiffstats
path: root/app
diff options
context:
space:
mode:
authorScott Murray <scott.murray@konsulko.com>2022-03-07 15:58:03 -0500
committerScott Murray <scott.murray@konsulko.com>2022-03-07 16:01:38 -0500
commit70dfe121582cda2c82c794e5af6550b5c1a237c4 (patch)
tree88a79bcac0e13f5165041217e2a324019b6fcaf3 /app
parent32596d1152e7a94bc62734dc222a3d99c14e1fe5 (diff)
Update for app framework removalmarlin_12.93.0marlin/12.93.012.93.0
Changes: - Remove the autobuild scripts and config.xml used by the app framework widget build. - Update the qmake files to just build a "tbtnavi" binary and install it into /usr/bin by default. - Remove the code in main.cpp that handled reading the WebSocket command-line arguments and passing them to binding related code. - Removed signal-composer wrapper instantiation in main.cpp, but the related QML has been left alone now, this will need to be revisited once something else is in place for vehicle signals (e.g. perhaps a simple VISS API wrapper in libqtappfw that leverages kuksa.val). Bug-AGL: SPEC-4283 Signed-off-by: Scott Murray <scott.murray@konsulko.com> Change-Id: I9ea3b5aff37ad5013815afaab07823194350b26d
Diffstat (limited to 'app')
-rw-r--r--app/app.pri1
-rw-r--r--app/app.pro16
-rw-r--r--app/main.cpp32
3 files changed, 9 insertions, 40 deletions
diff --git a/app/app.pri b/app/app.pri
deleted file mode 100644
index 5dad652..0000000
--- a/app/app.pri
+++ /dev/null
@@ -1 +0,0 @@
-DESTDIR = $${OUT_PWD}/../package/root/bin
diff --git a/app/app.pro b/app/app.pro
index fbe53a4..8889208 100644
--- a/app/app.pro
+++ b/app/app.pro
@@ -1,17 +1,11 @@
-TARGET = tbtnavi
TEMPLATE = app
+TARGET = tbtnavi
QT = qml network quick positioning location widgets gui-private
-PKGCONFIG += qtappfw-navigation qtappfw-signal-composer wayland-client
+PKGCONFIG += qtappfw-navigation wayland-client
CONFIG += c++1z link_pkgconfig wayland-scanner
-CONFIG(release, debug|release) {
- QMAKE_POST_LINK = $(STRIP) --strip-unneeded $(TARGET)
-}
-
-include(app.pri)
-
SOURCES += \
main.cpp \
navigation_client.cpp \
@@ -37,3 +31,9 @@ RESOURCES += \
WAYLANDCLIENTSOURCES += \
protocol/agl-shell-desktop.xml
+
+target.path = /usr/bin
+target.files += $${OUT_PWD}/$${TARGET}
+target.CONFIG = no_check_exist executable
+
+INSTALLS += target
diff --git a/app/main.cpp b/app/main.cpp
index 645d2f7..1be4efa 100644
--- a/app/main.cpp
+++ b/app/main.cpp
@@ -8,7 +8,6 @@
#include <QtQml/QQmlContext>
#include <QtQuick/QQuickWindow>
#include <navigation.h>
-#include <signalcomposer.h>
#include <QScreen>
#include "navigation_client.h"
@@ -99,15 +98,6 @@ int main(int argc, char *argv[])
QCoreApplication::setApplicationVersion("0.1.0");
app.setDesktopFileName(graphic_role);
- QCommandLineParser parser;
- parser.addPositionalArgument("port", app.translate("main", "port for binding"));
- parser.addPositionalArgument("secret", app.translate("main", "secret for binding"));
- parser.addHelpOption();
- parser.addVersionOption();
- parser.process(app);
- QStringList positionalArguments = parser.positionalArguments();
- QUrl bindingAddress;
-
QPlatformNativeInterface *native = qApp->platformNativeInterface();
agl_shell_desktop = register_agl_shell_desktop(native);
if (!agl_shell_desktop) {
@@ -118,24 +108,6 @@ int main(int argc, char *argv[])
std::shared_ptr<struct agl_shell_desktop> shell{agl_shell_desktop, agl_shell_desktop_destroy};
Shell *aglShell = new Shell(shell, nullptr);
- int port = 0;
- QString token;
- if (positionalArguments.length() == 2) {
- port = positionalArguments.takeFirst().toInt();
- token = positionalArguments.takeFirst();
- bindingAddress.setScheme(QStringLiteral("ws"));
- bindingAddress.setHost(QStringLiteral("localhost"));
- bindingAddress.setPort(port);
- bindingAddress.setPath(QStringLiteral("/api"));
- QUrlQuery query;
- query.addQueryItem(QStringLiteral("token"), token);
- bindingAddress.setQuery(query);
- }
- fprintf(stderr, "[tbtnavi] app_name: %s, port: %d, token: %s.\n",
- graphic_role.toStdString().c_str(),
- port,
- token.toStdString().c_str());
-
/* inform the compositor that the window be placed on a different
* output */
QScreen *screen_to_put = find_qscreen(OUTPUT_ID);
@@ -160,9 +132,7 @@ int main(int argc, char *argv[])
File_Operation file;
context->setContextProperty("fileOperation", &file);
- Navigation *navigation = new Navigation(bindingAddress, context);
-
- context->setContextProperty("SignalComposer", new SignalComposer(bindingAddress, context));
+ Navigation *navigation = new Navigation(context);
engine.load(QUrl(QStringLiteral("qrc:qml/Main.qml")));