diff --git a/Motus/BackKey.qml b/Motus/BackKey.qml index 33306891aea956ee951732419a595707f5334f97..3ee275997a9455d987c2170267975535103e138e 100644 --- a/Motus/BackKey.qml +++ b/Motus/BackKey.qml @@ -17,7 +17,7 @@ Item { width: 100 height: 30 anchors.verticalCenter: parent.verticalCenter - source: "qrc:/qtquickplugin/images/template_image.png" + source: "qrc:/back_key.png" anchors.horizontalCenter: parent.horizontalCenter fillMode: Image.PreserveAspectFit } diff --git a/Motus/CMakeLists.txt b/Motus/CMakeLists.txt index 12c3cd004d244da06afd9de34d4f9075dca9ab61..e9ddbc6e3417070c819e76873a3d8473051b49b9 100644 --- a/Motus/CMakeLists.txt +++ b/Motus/CMakeLists.txt @@ -19,7 +19,6 @@ qt_add_qml_module(appMotus Main.qml RESOURCES Ressources.qrc QML_FILES Case.qml - QML_FILES Case.qml QML_FILES Key.qml QML_FILES BackKey.qml QML_FILES Bouton.qml diff --git a/Motus/Main.qml b/Motus/Main.qml index 563a7fad9affe75164e07b7f3a6d881dcd7bcff5..ac3f942014758c05524b0321bd985103d66c0848 100644 --- a/Motus/Main.qml +++ b/Motus/Main.qml @@ -57,6 +57,16 @@ Window { } } + + Image { + id: testImage + source: "qrc:/back_key.png" + width: 100 + height: 100 + anchors.left: parent.left + anchors.top: parent.top + } + Rectangle { id: rectangle1 y: 666 @@ -374,7 +384,7 @@ Window { width: 100 height: 60 anchors.verticalCenter: parent.verticalCenter - imageSource: "qrc:/Ressources/back_key.png" + imageSource: "qrc:/back_key.png" } } } diff --git a/Motus/Ressources.qrc b/Motus/Ressources.qrc index c5a7ac98a7680f7da21edc378155630ad76fd3a7..6c7eb073031421e4ebd0a99ba5f60a2d1b15a0b0 100644 --- a/Motus/Ressources.qrc +++ b/Motus/Ressources.qrc @@ -5,5 +5,6 @@ <file>Case.qml</file> <file>Key.qml</file> <file>words_alpha.txt</file> + <file>back_key.png</file> </qresource> </RCC> diff --git a/Motus/wordchooser.cpp b/Motus/wordchooser.cpp index 0f487670e4f734d2fd71b2337d80d54f47d85d27..fe0abe66c595dc6668f2a0c187b61b5f137aad05 100644 --- a/Motus/wordchooser.cpp +++ b/Motus/wordchooser.cpp @@ -9,7 +9,7 @@ WordChooser::WordChooser(QObject *parent) : QObject(parent) { } void WordChooser::loadWords() { - QFile file(":/words_alpha.txt"); // adapte le chemin si besoin + QFile file("qrc:/words_alpha.txt"); if (file.open(QIODevice::ReadOnly | QIODevice::Text)) { QTextStream in(&file); while (!in.atEnd()) {