Skip to content

Commit

Permalink
PingPopup: Add first commit
Browse files Browse the repository at this point in the history
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
  • Loading branch information
patrickelectric committed Jun 24, 2018
1 parent e69d97c commit a07d298
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
16 changes: 16 additions & 0 deletions qml/PingPopup.qml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import QtQuick 2.7
import QtQuick.Controls 2.2

Popup {
id: root

// Center popup
x: (mainPage.width - width)/2 - parent.mapToItem(mainPage, 0, 0).x
y: (mainPage.height - height)/2 - parent.mapToItem(mainPage, 0, 0).y

// Get focus and any event
modal: true
focus: true

closePolicy: Popup.CloseOnEscape | Popup.CloseOnPressOutsideParent
}
1 change: 1 addition & 0 deletions resources.qrc
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
<file alias="PingItem.qml">qml/PingItem.qml</file>
<file alias="PingImage.qml">qml/PingImage.qml</file>
<file alias="PingLogger.qml">qml/PingLogger.qml</file>
<file alias="PingPopup.qml">qml/PingPopup.qml</file>
<file alias="PingRelease.qml">qml/PingRelease.qml</file>
<file alias="PingStatus.qml">qml/PingStatus.qml</file>
<file alias="Style.qml">qml/Style.qml</file>
Expand Down

0 comments on commit a07d298

Please sign in to comment.