-
Notifications
You must be signed in to change notification settings - Fork 60
/
Copy pathWindowEntry.qml
83 lines (65 loc) · 1.81 KB
/
WindowEntry.qml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
import QtQuick 2.12
import QtGraphicalEffects 1.12
import QtQuick.Layouts 1.12
import QtQuick.Controls 2.14
import Qt.Singleton 1.0
import "qrc:/common"
import "qrc:/common/qmlQianDialog"
import "qrc:/common/qmlQianHints"
Rectangle {
id: windowEntry
color: skin.mainColor
gradient: skin.gradient
Message{
id:messageTip
z: 1
parent: Overlay.overlay
}
function message(type, message) {
if(type!=='success'&&type!=='error'&&type!=='info'){
return false
}
messageTip.open(type, message)
}
BlogDialog {
id: skinQianDialog
backParent: windowEntry
parent: Overlay.overlay
onAccept: {
message('success', "You clicked the accept button!")
skinQianDialog.close();
}
}
Component.onCompleted: {
skinQianDialog.dialogOpen()
}
layer.enabled: skin.windowShadow && !appStartAnimation.running && !rootWindow.maximized? true : false
layer.effect: DropShadow {
color: "#000000"
}
ColumnLayout {
anchors.fill: parent
spacing: 0
WindowTilte {
color: skin.titleColor
Layout.fillWidth: true
Layout.preferredHeight: contentList.fullscreen ? 0 : 42
Layout.alignment: Qt.AlignTop
Behavior on Layout.preferredHeight {
NumberAnimation { duration: 300 }
}
clip: true
}
ContentList {
id: contentList
Layout.fillHeight: true
Layout.fillWidth: true
}
}
SequentialAnimation {
id: appStartAnimation
running: true
NumberAnimation { target: windowEntry;
properties: "scale"; from: 0.3; to: 1.0; easing.type: Easing.InOutQuad; duration: 200 }
}
}