Commit 1ee9f23f authored by Karel Slaný's avatar Karel Slaný

Renamed nearly all QML pages.

parent 09d80703
/*
* Copyright (C) 2014-2016 CZ.NIC
* Copyright (C) 2014-2017 CZ.NIC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -21,7 +21,6 @@
* the two.
*/
import QtQuick 2.7
import QtQuick.Controls 2.0
import QtQuick.Window 2.1
......@@ -46,21 +45,21 @@ ApplicationWindow {
}
// define all pages for stackview
property Component accountsPage: AccountsPage {}
property Component messagesPage: MessagesPage {}
property Component messagesMenuPage: MessagesMenuPage {}
property Component messageMenuPage: MessageMenuPage {}
property Component messageDetailPage: MessageDetailPage {}
property Component messageDetailMenuPage: MessageDetailMenuPage {}
property Component accountDetailPage: AccountDetailPage {}
property Component accountSettingsPage: AccountSettingsPage {}
property Component accountMenuPage: AccountMenuPage {}
property Component aboutPage: AboutPage {}
property Component settingsMainPage: SettingsMainPage {}
property Component settingsGeneralPage: SettingsGeneralPage {}
property Component settingsSyncPage: SettingsSyncPage {}
property Component settingsStoragePage: SettingsStoragePage {}
property Component pinPage: PinPage {}
property Component pageAboutApp: PageAboutApp {}
property Component pageAccountDetail: PageAccountDetail {}
property Component pageAccountList: PageAccountList {}
property Component pageMenuaccount: PageMenuAccount {}
property Component pageMenuDatovkaSettings: PageMenuDatovkaSettings {}
property Component pageMenuMessage: PageMenuMessage {}
property Component pageMenuMessageDetail: PageMenuMessageDetail {}
property Component pageMenuMessageList: PageMenuMessageList {}
property Component pageMessageDetail: PageMessageDetail {}
property Component pageMessageList: PageMessageList {}
property Component pageSettingsAccount: PageSettingsAccount {}
property Component pageSettingsGeneral: PageSettingsGeneral {}
property Component pageSettingsPin: PageSettingsPin {}
property Component pageSettingsStorage: PageSettingsStorage {}
property Component pageSettingsSync: PageSettingsSync {}
// header background color
property string mainHeaderBgColor: "#00539b"
......@@ -111,7 +110,7 @@ ApplicationWindow {
id: pageView
anchors.fill: parent
visible: true
initialItem: accountsPage
initialItem: pageAccountList
}
}
Rectangle {
......
/*
* Copyright (C) 2014-2016 CZ.NIC
* Copyright (C) 2014-2017 CZ.NIC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -21,12 +21,11 @@
* the two.
*/
import QtQuick 2.7
import QtQuick.Controls 2.0
Component {
id: aboutDialog
id: aboutApp
Item {
id: aboutLayout
property int myWidht: aboutLayout.width - 2 * defaultMargin
......
/*
* Copyright (C) 2014-2016 CZ.NIC
* Copyright (C) 2014-2017 CZ.NIC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -25,7 +25,7 @@ import QtQuick 2.7
import QtQuick.Controls 2.0
Component {
id: accountdetailpage
id: pageAccountDetail
Item {
id: acntDetailPage
Rectangle {
......
/*
* Copyright (C) 2014-2016 CZ.NIC
* Copyright (C) 2014-2017 CZ.NIC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -30,7 +30,7 @@ import QtGraphicalEffects 1.0
import cz.nic.mobileDatovka.messages 1.0
Component {
id: accountspage
id: pageAccountList
Item {
id: mainPage
Component.onCompleted: {
......@@ -58,7 +58,7 @@ Component {
anchors.fill: parent
onClicked: {
gUserName = ""
pageView.push(aboutPage, StackView.Immediate)
pageView.push(pageAboutApp, StackView.Immediate)
}
}
}
......@@ -88,7 +88,7 @@ Component {
MouseArea {
anchors.fill: parent
onClicked: {
pageView.push(settingsMainPage, StackView.Immediate)
pageView.push(pageMenuDatovkaSettings, StackView.Immediate)
}
}
}
......@@ -105,7 +105,7 @@ Component {
anchors.fill: parent
onClicked: {
gUserName = ""
pageView.push(accountSettingsPage, StackView.Immediate)
pageView.push(pageSettingsAccount, StackView.Immediate)
}
}
}
......@@ -199,7 +199,7 @@ Component {
statusBar.visible = false
gAcntName = rAcntName
gUserName = rUserName
pageView.push(accountMenuPage, StackView.Immediate)
pageView.push(pageMenuaccount, StackView.Immediate)
}
}
}
......@@ -285,7 +285,7 @@ Component {
gMsgType = MessageType.TYPE_RECEIVED
statusBar.visible = false
messages.fillMessageList(rUserName, MessageType.TYPE_RECEIVED)
pageView.push(messagesPage, StackView.Immediate)
pageView.push(pageMessageList, StackView.Immediate)
}
}
Rectangle {
......@@ -351,7 +351,7 @@ Component {
gMsgType = MessageType.TYPE_SENT
statusBar.visible = false
messages.fillMessageList(rUserName, MessageType.TYPE_SENT)
pageView.push(messagesPage, StackView.Immediate)
pageView.push(pageMessageList, StackView.Immediate)
}
}
Rectangle {
......
/*
* Copyright (C) 2014-2016 CZ.NIC
* Copyright (C) 2014-2017 CZ.NIC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -21,7 +21,6 @@
* the two.
*/
import QtQuick 2.7
import QtQuick.Controls 2.0
import QtQuick.Window 2.1
......@@ -29,9 +28,8 @@ import QtQuick.Layouts 1.2
import QtQuick.Dialogs 1.2
import QtGraphicalEffects 1.0
Component {
id: accountMenuPage
id: menuAccount
Item {
id: mainLayout
property int myWidht: mainLayout.width - 2 * defaultMargin
......@@ -169,9 +167,9 @@ Component {
anchors.fill: parent
onClicked: {
if (index == 0) {
pageView.push(accountSettingsPage, StackView.Immediate)
pageView.push(pageSettingsAccount, StackView.Immediate)
} else if (index == 1) {
pageView.push(accountDetailPage, StackView.Immediate)
pageView.push(pageAccountDetail, StackView.Immediate)
accounts.fillAccountInfo(gUserName)
} else if (index == 2) {
files.deleteFileDb(gUserName)
......
/*
* Copyright (C) 2014-2016 CZ.NIC
* Copyright (C) 2014-2017 CZ.NIC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -21,7 +21,6 @@
* the two.
*/
import QtQuick 2.7
import QtQuick.Controls 2.0
import QtQuick.Window 2.1
......@@ -29,9 +28,8 @@ import QtQuick.Layouts 1.2
import QtQuick.Dialogs 1.2
import QtGraphicalEffects 1.0
Component {
id: mainSettingsDialog
id: menuDatovkamainSettings
Item {
id: mainLayout
property int myWidht: mainLayout.width - 2 * defaultMargin
......@@ -160,15 +158,15 @@ Component {
onClicked: {
if (index == 1) {
gUserName = ""
pageView.push(accountSettingsPage, StackView.Immediate)
pageView.push(pageSettingsAccount, StackView.Immediate)
} else if (index == 2) {
pageView.push(settingsGeneralPage, StackView.Immediate)
pageView.push(pageSettingsGeneral, StackView.Immediate)
} else if (index == 3) {
pageView.push(settingsSyncPage, StackView.Immediate)
pageView.push(pageSettingsSync, StackView.Immediate)
} else if (index == 4) {
pageView.push(settingsStoragePage, StackView.Immediate)
pageView.push(pageSettingsStorage, StackView.Immediate)
} else if (index == 5) {
pageView.push(pinPage, StackView.Immediate)
pageView.push(pageSettingsPin, StackView.Immediate)
} else {
pageView.pop(StackView.Immediate)
}
......
/*
* Copyright (C) 2014-2016 CZ.NIC
* Copyright (C) 2014-2017 CZ.NIC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -21,7 +21,6 @@
* the two.
*/
import QtQuick 2.7
import QtQuick.Controls 2.0
import QtQuick.Window 2.1
......@@ -31,7 +30,7 @@ import QtGraphicalEffects 1.0
import cz.nic.mobileDatovka.messages 1.0
Component {
id: messageMenuPage
id: menuMessage
Item {
id: mainLayout
property int myWidht: mainLayout.width - 2 * defaultMargin
......
/*
* Copyright (C) 2014-2016 CZ.NIC
* Copyright (C) 2014-2017 CZ.NIC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -21,7 +21,6 @@
* the two.
*/
import QtQuick 2.7
import QtQuick.Controls 2.0
import QtQuick.Window 2.1
......@@ -31,7 +30,7 @@ import QtGraphicalEffects 1.0
import cz.nic.mobileDatovka.messages 1.0
Component {
id: messageDetailMenuPage
id: menuMessageDetail
Item {
id: mainLayout
property int myWidht: mainLayout.width - 2 * defaultMargin
......
/*
* Copyright (C) 2014-2016 CZ.NIC
* Copyright (C) 2014-2017 CZ.NIC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -21,7 +21,6 @@
* the two.
*/
import QtQuick 2.7
import QtQuick.Controls 2.0
import QtQuick.Window 2.1
......@@ -31,7 +30,7 @@ import QtGraphicalEffects 1.0
import cz.nic.mobileDatovka.messages 1.0
Component {
id: messagesMenuPage
id: menuMessageList
Item {
id: mainLayout
property int myWidht: mainLayout.width - 2 * defaultMargin
......
/*
* Copyright (C) 2014-2016 CZ.NIC
* Copyright (C) 2014-2017 CZ.NIC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -21,7 +21,6 @@
* the two.
*/
import QtQuick 2.7
import QtQuick.Controls 2.0
import QtQuick.Window 2.1
......@@ -31,7 +30,7 @@ import QtGraphicalEffects 1.0
import cz.nic.mobileDatovka.messages 1.0
Component {
id: messageDetailPage
id: pageMessageDetail
Item {
id: msgDetailPage
Component.onCompleted: {
......@@ -117,7 +116,7 @@ Component {
MouseArea {
anchors.fill: parent
onClicked: {
pageView.push(messageDetailMenuPage, StackView.Immediate)
pageView.push(pageMenuMessageDetail, StackView.Immediate)
}
}
}
......
/*
* Copyright (C) 2014-2016 CZ.NIC
* Copyright (C) 2014-2017 CZ.NIC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -21,7 +21,6 @@
* the two.
*/
import QtQuick 2.7
import QtQuick.Controls 2.0
import QtQuick.Window 2.1
......@@ -31,7 +30,7 @@ import QtGraphicalEffects 1.0
import cz.nic.mobileDatovka.messages 1.0
Component {
id: messagespage
id: pageMessageList
Item {
id: msgListPage
Component.onCompleted: {
......@@ -104,7 +103,7 @@ Component {
anchors.fill: parent
onClicked: {
statusBar.visible = false
pageView.push(messagesMenuPage, StackView.Immediate)
pageView.push(pageMenuMessageList, StackView.Immediate)
}
}
}
......@@ -262,7 +261,7 @@ Component {
onClicked: {
gMsgId = rMsgId
statusBar.visible = false
pageView.push(messageDetailPage, StackView.Immediate)
pageView.push(pageMessageDetail, StackView.Immediate)
messages.markMessageAsLocallyRead(gUserName, rMsgId, true)
messages.fillMessageDetail(gUserName, rMsgId)
files.fillFileList(gUserName, rMsgId)
......@@ -271,7 +270,7 @@ Component {
gMsgId = rMsgId
gCanDeleteMsg = compareMsgDate(rDelivTime)
statusBar.visible = false
pageView.push(messageMenuPage, StackView.Immediate)
pageView.push(pageMenuMessage, StackView.Immediate)
}
}
Rectangle {
......
/*
* Copyright (C) 2014-2016 CZ.NIC
* Copyright (C) 2014-2017 CZ.NIC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -21,13 +21,12 @@
* the two.
*/
import QtQuick 2.7
import QtQuick.Controls 2.0
import QtQuick.Dialogs 1.2
Component {
id: accountSettingsDialog
id: settingsAccount
Item {
id: mainLayout
property bool isNewAccount: (gUserName == "")
......
/*
* Copyright (C) 2014-2016 CZ.NIC
* Copyright (C) 2014-2017 CZ.NIC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -21,12 +21,11 @@
* the two.
*/
import QtQuick 2.7
import QtQuick.Controls 2.0
Component {
id: settingsDialog
id: settingsGeneral
Item {
id: mainLayout
property string sectionName: "general"
......
......@@ -21,13 +21,12 @@
* the two.
*/
import QtQuick 2.7
import QtQuick.Controls 2.0
import cz.nic.mobileDatovka 1.0
Component {
id: pinPage
id: settingsPin
Item {
id: mainItem
Component.onCompleted: {
......
......@@ -21,13 +21,12 @@
* the two.
*/
import QtQuick 2.7
import QtQuick.Controls 2.0
import cz.nic.mobileDatovka 1.0
Component {
id: settingsDialog
id: settingsStorage
Item {
id: mainLayout
property string sectionName: "storage"
......
/*
* Copyright (C) 2014-2016 CZ.NIC
* Copyright (C) 2014-2017 CZ.NIC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -21,12 +21,11 @@
* the two.
*/
import QtQuick 2.7
import QtQuick.Controls 2.0
Component {
id: settingsDialog
id: settingsSync
Item {
id: mainLayout
property string sectionName: "sync"
......
......@@ -29,10 +29,6 @@
<file>fileicons/fileicon_docx.png</file>
<file>fileicons/fileicon_mpeg.png</file>
<file>fileicons/fileicon_pptx.png</file>
<file>../qml/pages/AccountsPage.qml</file>
<file>../qml/pages/MessageDetailPage.qml</file>
<file>../qml/pages/MessagesPage.qml</file>
<file>../qml/main.qml</file>
<file>ui/account-box.svg</file>
<file>ui/account-key.svg</file>
<file>ui/account-plus.svg</file>
......@@ -82,8 +78,6 @@
<file>ui/timer.svg</file>
<file>ui/timetable.svg</file>
<file>ui/wan.svg</file>
<file>../qml/pages/AccountDetailPage.qml</file>
<file>../qml/pages/AccountSettingsPage.qml</file>
<file>ui/received-msg.svg</file>
<file>ui/received-msgs.svg</file>
<file>ui/sent-msg.svg</file>
......@@ -97,19 +91,25 @@
<file>ui/sync.svg</file>
<file>ui/sync-all.svg</file>
<file>ui/up.svg</file>
<file>../qml/pages/AboutPage.qml</file>
<file>datovka.png</file>
<file>cznic.png</file>
<file>ui/datovka@2x.png</file>
<file>../qml/pages/PinPage.qml</file>
<file>../qml/pages/SettingsSyncPage.qml</file>
<file>../qml/pages/SettingsGeneralPage.qml</file>
<file>../qml/pages/SettingsMainPage.qml</file>
<file>../qml/pages/SettingsStoragePage.qml</file>
<file>../qml/pages/AccountMenuPage.qml</file>
<file>../qml/pages/MessageDetailMenuPage.qml</file>
<file>../qml/pages/MessageMenuPage.qml</file>
<file>../qml/pages/MessagesMenuPage.qml</file>
<file>../qml/components/SpinBoxZeroMax.qml</file>
<file>../qml/pages/PageAboutApp.qml</file>
<file>../qml/pages/PageAccountDetail.qml</file>
<file>../qml/pages/PageAccountList.qml</file>
<file>../qml/pages/PageMenuAccount.qml</file>
<file>../qml/pages/PageMenuDatovkaSettings.qml</file>
<file>../qml/pages/PageMenuMessage.qml</file>
<file>../qml/pages/PageMenuMessageDetail.qml</file>
<file>../qml/pages/PageMenuMessageList.qml</file>
<file>../qml/pages/PageMessageDetail.qml</file>
<file>../qml/pages/PageMessageList.qml</file>
<file>../qml/pages/PageSettingsAccount.qml</file>
<file>../qml/pages/PageSettingsGeneral.qml</file>
<file>../qml/pages/PageSettingsPin.qml</file>
<file>../qml/pages/PageSettingsStorage.qml</file>
<file>../qml/pages/PageSettingsSync.qml</file>
<file>../qml/main.qml</file>
</qresource>
</RCC>
......@@ -62,21 +62,21 @@ struct QmlTypeEntry {
*/
static
const struct QmlTypeEntry qmlPages[] = {
{ "AccountsPage", 1, 0 },
{ "MessagesPage", 1, 0 },
{ "MessageMenuPage", 1, 0 },
{ "MessagesMenuPage", 1, 0 },
{ "MessageDetailPage", 1, 0 },
{ "MessageDetailMenuPage", 1, 0 },
{ "AccountDetailPage", 1, 0 },
{ "AccountSettingsPage", 1, 0 },
{ "AccountMenuPage", 1, 0 },
{ "AboutPage", 1, 0 },
{ "PinPage", 1, 0 },
{ "SettingsMainPage", 1, 0 },
{ "SettingsGeneralPage", 1, 0 },
{ "SettingsSyncPage", 1, 0 },
{ "SettingsStoragePage", 1, 0 },
{ "PageAboutApp", 1, 0 },
{ "PageAccountDetail", 1, 0 },
{ "PageAccountList", 1, 0 },
{ "PageMenuAccount", 1, 0 },
{ "PageMenuDatovkaSettings", 1, 0 },
{ "PageMenuMessage", 1, 0 },
{ "PageMenuMessageDetail", 1, 0 },
{ "PageMenuMessageList", 1, 0 },
{ "PageMessageDetail", 1, 0 },
{ "PageMessageList", 1, 0 },
{ "PageSettingsAccount", 1, 0 },
{ "PageSettingsGeneral", 1, 0 },
{ "PageSettingsPin", 1, 0 },
{ "PageSettingsStorage", 1, 0 },
{ "PageSettingsSync", 1, 0 },
{ NULL, 0, 0 }
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment