Skip to content
Permalink
Browse files

Move keyboard style to a resource file

  • Loading branch information
martonborzak committed Jan 3, 2020
1 parent d3cc63c commit 5255f589f2978eb9abf05d5fb8c064433659bc56
Showing with 16 additions and 2 deletions.
  1. +13 −0 keyboard.qrc
  2. +1 −1 main.qml
  3. +2 −1 sources/main.cpp
@@ -6,5 +6,18 @@
<file>keyboard/layouts/en_GB/main.qml</file>
<file>keyboard/layouts/en_GB/numbers.qml</file>
<file>keyboard/layouts/en_GB/symbols.qml</file>
<file>keyboard/QtQuick/VirtualKeyboard/Styles/remotestyle/style.qml</file>
<file>keyboard/QtQuick/VirtualKeyboard/Styles/remotestyle/images/backspace-868482.svg</file>
<file>keyboard/QtQuick/VirtualKeyboard/Styles/remotestyle/images/check-868482.svg</file>
<file>keyboard/QtQuick/VirtualKeyboard/Styles/remotestyle/images/enter-868482.svg</file>
<file>keyboard/QtQuick/VirtualKeyboard/Styles/remotestyle/images/globe-868482.svg</file>
<file>keyboard/QtQuick/VirtualKeyboard/Styles/remotestyle/images/handwriting-868482.svg</file>
<file>keyboard/QtQuick/VirtualKeyboard/Styles/remotestyle/images/hidekeyboard-868482.svg</file>
<file>keyboard/QtQuick/VirtualKeyboard/Styles/remotestyle/images/search-868482.svg</file>
<file>keyboard/QtQuick/VirtualKeyboard/Styles/remotestyle/images/selectionhandle-bottom.svg</file>
<file>keyboard/QtQuick/VirtualKeyboard/Styles/remotestyle/images/shift-80c342.svg</file>
<file>keyboard/QtQuick/VirtualKeyboard/Styles/remotestyle/images/shift-868482.svg</file>
<file>keyboard/QtQuick/VirtualKeyboard/Styles/remotestyle/images/shift-c5d6b6.svg</file>
<file>keyboard/QtQuick/VirtualKeyboard/Styles/remotestyle/images/textmode-868482.svg</file>
</qresource>
</RCC>
@@ -46,7 +46,7 @@ ApplicationWindow {
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////\
//
// CURRENT SOFTWARE VERSION
property real _current_version: 0.1 // change this when bumping the software version
property real _current_version: 0.2 // change this when bumping the software version

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -53,7 +53,6 @@
static Q_LOGGING_CATEGORY(CLASS_LC, "main");

int main(int argc, char* argv[]) {
qputenv("QML2_IMPORT_PATH", "/keyboard");
qputenv("QT_IM_MODULE", QByteArray("qtvirtualkeyboard"));
qputenv("QT_VIRTUALKEYBOARD_LAYOUT_PATH", "qrc:/keyboard/layouts");
qputenv("QT_VIRTUALKEYBOARD_STYLE", "remotestyle");
@@ -63,6 +62,8 @@ int main(int argc, char* argv[]) {
QGuiApplication app(argc, argv);
QQmlApplicationEngine engine;

engine.addImportPath("qrc:/keyboard");

// Get the applications dir path and expose it to QML (prevents setting the JSON config variable)
QString appPath = app.applicationDirPath();
QString macPath = QFileInfo(appPath + "/../").canonicalPath() + QString("/Contents/Resources");

0 comments on commit 5255f58

Please sign in to comment.
You can’t perform that action at this time.