added global event bus. refactored targets screen

This commit is contained in:
Lasan Mahaliyana
2026-06-30 21:21:34 +05:30
parent 7e74fbb3f3
commit ce37bcef6d
11 changed files with 225 additions and 120 deletions
+2 -3
View File
@@ -4,10 +4,10 @@ import QtQuick.Controls
import QtQuick.Shapes
import Qt.labs.platform as Platform
import QtCore
import "."
Rectangle {
id: dropZone
signal fileSelected(string filePath)
color: "transparent"
Platform.FileDialog {
id: fileDialog
@@ -17,13 +17,12 @@ Rectangle {
nameFilters: ["All files (*)"]
onAccepted: {
fileSelected(fileDialog.file);
EventBus.fileSelected(fileDialog.file);
}
onRejected: {
console.log("File picker canceled");
}
}
//signal fileDropped(string path)
DropArea {
anchors.fill: parent