EvanZhu0721 / 公开仓库
SBMS
SBMS complete the calculation rules for the default logical desktop topology relationship and the physical dimensions of the displays in the Windows multi-screen collaboration system.
文件
../ pagescontrols.slint16.0 KBlaunch-intro.slint7.9 KBquick-access.slint13.9 KBremove-group-dialog.slint3.2 KBseven-segment.slint4.4 KBtheme.slint2.1 KBtray-icon.svg314 Bui/remove-group-dialog.slint3.2 KB
1
import { DialogActionButton } from "controls.slint";2
import { MdTokens } from "theme.slint";3
4
export component RemoveGroupDialog inherits FocusScope {5
in-out property <int> pending-remove-index: -1;6
callback remove-group(int);7
8
key-pressed(event) => {9
if event.text == Key.Escape {10
root.pending-remove-index = -1;11
return accept;12
}13
return reject;14
}15
16
Rectangle {17
width: parent.width;18
height: parent.height;19
background: #66000000;20
21
TouchArea {22
accessible-role: none;23
clicked => { root.pending-remove-index = -1; }24
}25
26
dialog := Rectangle {27
x: (parent.width - self.width) / 2;28
y: (parent.height - self.height) / 2;29
width: 320px;30
height: 184px;31
background: MdTokens.surface;32
border-width: 1px;33
border-color: MdTokens.outline-variant;34
border-radius: 28px;35
36
TouchArea {37
accessible-role: none;38
}39
40
VerticalLayout {41
padding: 20px;42
spacing: MdTokens.space-1;43
44
Text {45
height: 28px;46
text: "Remove mapping group?";47
color: MdTokens.on-surface;48
font-size: MdTokens.type-title-large;49
font-weight: MdTokens.weight-medium;50
vertical-alignment: center;51
}52
53
Text {54
height: 52px;55
text: "Its target, sizing and stream settings will be discarded.";56
color: MdTokens.on-surface-variant;57
font-size: MdTokens.type-body-medium;58
wrap: word-wrap;59
}60
61
HorizontalLayout {62
height: MdTokens.target;63
spacing: MdTokens.space-1;64
Rectangle { horizontal-stretch: 1; }65
DialogActionButton {66
text: "Cancel";67
field-label: "Cancel removing mapping group";68
clicked => { root.pending-remove-index = -1; }69
}70
DialogActionButton {71
text: "Remove";72
field-label: "Confirm removing mapping group";73
destructive: true;74
clicked => {75
root.remove-group(root.pending-remove-index);76
root.pending-remove-index = -1;77
}78
}79
}80
}81
}82
}83
}84