mirror of
https://github.com/kbumsik/VirtScreen.git
synced 2025-03-09 15:40:18 +00:00
Displays error when ARandR is not installed
This commit is contained in:
parent
fb868a4f7f
commit
7e8eeaf0a7
3 changed files with 6 additions and 2 deletions
2
main.qml
2
main.qml
|
@ -146,7 +146,7 @@ Item {
|
||||||
text: ""
|
text: ""
|
||||||
Component.onCompleted : {
|
Component.onCompleted : {
|
||||||
backend.onError.connect(function(errMsg) {
|
backend.onError.connect(function(errMsg) {
|
||||||
errorText.text = "";
|
errorText.text = ""; // To trigger onTextChanged signal
|
||||||
errorText.text = errMsg;
|
errorText.text = errMsg;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -234,9 +234,12 @@ ApplicationWindow {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
Text {
|
Text {
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
|
Layout.fillWidth: true
|
||||||
|
wrapMode: Text.WordWrap
|
||||||
text: errorText.text
|
text: errorText.text
|
||||||
onTextChanged: {
|
onTextChanged: {
|
||||||
if (text) {
|
if (text) {
|
||||||
|
busyDialog.close();
|
||||||
errorDialog.open();
|
errorDialog.open();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -562,7 +562,8 @@ class Backend(QObject):
|
||||||
if not shutil.which(arg.split()[0]):
|
if not shutil.which(arg.split()[0]):
|
||||||
continue
|
continue
|
||||||
program.run(arg)
|
program.run(arg)
|
||||||
break
|
return
|
||||||
|
self.onError.emit('Failed to find a display settings program. Please install ARandR package.')
|
||||||
|
|
||||||
@pyqtSlot()
|
@pyqtSlot()
|
||||||
def stopVNC(self, force=False):
|
def stopVNC(self, force=False):
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue