2017-09-01 13:13:12 +00:00
|
|
|
import QtQuick 2.9
|
|
|
|
import QtQuick.Controls 2.2
|
2017-10-26 03:52:49 +00:00
|
|
|
import "controls"
|
2017-09-01 13:13:12 +00:00
|
|
|
import "pages"
|
2017-09-02 10:17:51 +00:00
|
|
|
import com.fortfirewall 1.0
|
2017-09-01 13:13:12 +00:00
|
|
|
|
|
|
|
ApplicationWindow {
|
2017-09-03 05:57:35 +00:00
|
|
|
id: appWindow
|
2017-09-01 13:13:12 +00:00
|
|
|
|
2017-09-07 05:43:33 +00:00
|
|
|
width: 1025
|
|
|
|
height: 768
|
2017-12-23 06:50:52 +00:00
|
|
|
minimumWidth: 800
|
2017-09-02 14:25:47 +00:00
|
|
|
minimumHeight: 600
|
2017-09-01 13:13:12 +00:00
|
|
|
|
|
|
|
font.pixelSize: 16
|
|
|
|
|
2017-09-02 10:17:51 +00:00
|
|
|
readonly property FortSettings fortSettings: fortManager.fortSettings
|
|
|
|
readonly property FirewallConf firewallConf: fortManager.firewallConfToEdit
|
2017-09-11 06:16:51 +00:00
|
|
|
|| fortManager.firewallConf
|
2017-09-02 10:17:51 +00:00
|
|
|
|
2017-09-03 05:57:35 +00:00
|
|
|
onClosing: {
|
|
|
|
if (visible) {
|
|
|
|
close.accepted = false;
|
|
|
|
closeWindow();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-09-01 13:13:12 +00:00
|
|
|
function closeWindow() {
|
2017-09-03 05:57:35 +00:00
|
|
|
fortManager.closeWindow();
|
2017-09-01 13:13:12 +00:00
|
|
|
}
|
|
|
|
|
2017-09-05 11:06:21 +00:00
|
|
|
FileUtil {
|
|
|
|
id: fileUtil
|
|
|
|
}
|
|
|
|
|
2017-11-01 13:49:11 +00:00
|
|
|
GuiUtil {
|
|
|
|
id: guiUtil
|
|
|
|
}
|
|
|
|
|
2017-09-05 11:06:21 +00:00
|
|
|
NetUtil {
|
|
|
|
id: netUtil
|
|
|
|
}
|
|
|
|
|
|
|
|
OsUtil {
|
|
|
|
id: osUtil
|
|
|
|
}
|
|
|
|
|
2017-10-26 03:52:49 +00:00
|
|
|
TextContextMenu {
|
|
|
|
id: textContextMenu
|
|
|
|
}
|
|
|
|
|
2017-09-22 04:20:36 +00:00
|
|
|
Loader {
|
2017-09-01 13:13:12 +00:00
|
|
|
anchors.fill: parent
|
2017-09-22 04:20:36 +00:00
|
|
|
sourceComponent: appWindow.visible ? mainPageComponent : undefined
|
|
|
|
}
|
|
|
|
|
|
|
|
Component {
|
|
|
|
id: mainPageComponent
|
|
|
|
MainPage {
|
|
|
|
Keys.onEscapePressed: closeWindow()
|
2017-09-01 13:13:12 +00:00
|
|
|
|
2017-09-22 04:20:36 +00:00
|
|
|
Component.onCompleted: opened()
|
|
|
|
Component.onDestruction: closed()
|
|
|
|
}
|
2017-09-01 13:13:12 +00:00
|
|
|
}
|
|
|
|
}
|