Cleanup
This commit is contained in:
parent
167d3caa5d
commit
8da30b216f
3 changed files with 7 additions and 54 deletions
|
@ -6,7 +6,7 @@ Item {
|
|||
readonly property string screenHomeIntroGifEx1: "qrc:/ScreenHomeIntroGifEx1.qml"
|
||||
|
||||
readonly property int screenWidth: 380
|
||||
readonly property int screenHeight: 640
|
||||
readonly property int screenHeight: 680
|
||||
|
||||
readonly property int defaultMargin: 20
|
||||
|
||||
|
@ -26,20 +26,4 @@ Item {
|
|||
}
|
||||
return false
|
||||
}
|
||||
|
||||
function trX(x) {
|
||||
return x
|
||||
}
|
||||
|
||||
function trY(y) {
|
||||
return y
|
||||
}
|
||||
|
||||
function trW(w) {
|
||||
return w
|
||||
}
|
||||
|
||||
function trH(h) {
|
||||
return h
|
||||
}
|
||||
}
|
||||
|
|
|
@ -22,7 +22,6 @@ PageBase {
|
|||
FlickableType {
|
||||
id: fl
|
||||
anchors.top: caption.bottom
|
||||
anchors.bottom: logo.top
|
||||
contentHeight: content.height
|
||||
|
||||
ColumnLayout {
|
||||
|
@ -150,9 +149,4 @@ PageBase {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
Logo {
|
||||
id: logo
|
||||
anchors.bottom: parent.bottom
|
||||
}
|
||||
}
|
||||
|
|
|
@ -8,7 +8,6 @@ import Qt.labs.platform
|
|||
import Qt.labs.folderlistmodel
|
||||
import QtQuick.Dialogs
|
||||
import QtQuick.Controls.Basic
|
||||
import "./"
|
||||
import "Controls"
|
||||
import "Pages"
|
||||
import "Pages/Protocols"
|
||||
|
@ -23,10 +22,10 @@ Window {
|
|||
id: root
|
||||
visible: true
|
||||
width: GC.screenWidth
|
||||
height: GC.isDesktop() ? GC.screenHeight + titleBar.height : GC.screenHeight
|
||||
minimumWidth: 360
|
||||
height: GC.screenHeight
|
||||
minimumWidth: GC.isDesktop() ? 360 : 0
|
||||
minimumHeight: GC.isDesktop() ? 640 : 0
|
||||
onClosing: {
|
||||
onClosing: function() {
|
||||
console.debug("QML onClosing signal")
|
||||
UiLogic.onCloseWindow()
|
||||
}
|
||||
|
@ -85,29 +84,6 @@ Window {
|
|||
}
|
||||
}
|
||||
|
||||
TitleBar {
|
||||
id: titleBar
|
||||
anchors.top: root.top
|
||||
visible: GC.isDesktop()
|
||||
DragHandler {
|
||||
grabPermissions: TapHandler.CanTakeOverFromAnything
|
||||
onActiveChanged: {
|
||||
if (active) {
|
||||
root.startSystemMove();
|
||||
}
|
||||
}
|
||||
target: null
|
||||
}
|
||||
onCloseButtonClicked: {
|
||||
if (UiLogic.currentPageValue === PageEnum.Start ||
|
||||
UiLogic.currentPageValue === PageEnum.NewServer) {
|
||||
Qt.quit()
|
||||
} else {
|
||||
root.hide()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
y: GC.isDesktop() ? titleBar.height : 0
|
||||
anchors.fill: parent
|
||||
|
@ -120,16 +96,15 @@ Window {
|
|||
anchors.fill: parent
|
||||
focus: true
|
||||
|
||||
onCurrentItemChanged: {
|
||||
//console.debug("QML onCurrentItemChanged " + pageLoader.currentItem)
|
||||
onCurrentItemChanged: function() {
|
||||
UiLogic.currentPageValue = currentItem.page
|
||||
}
|
||||
|
||||
onDepthChanged: {
|
||||
onDepthChanged: function() {
|
||||
UiLogic.pagesStackDepth = depth
|
||||
}
|
||||
|
||||
Keys.onPressed: {
|
||||
Keys.onPressed: function(event) {
|
||||
UiLogic.keyPressEvent(event.key)
|
||||
event.accepted = true
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue