Add a way to put a custom view in front of a dialog.

Conference Creation:
- Add a waiting view while creating a conference.
- Move to conferences list on success
-
This commit is contained in:
Julien Wadel 2022-08-25 18:08:13 +02:00
parent 9b2867ad41
commit d0461d5ec2
19 changed files with 127 additions and 15 deletions

View file

@ -1938,6 +1938,11 @@ Klik her: <a href="%1">%1</a>
<extracomment>&apos;Send invite via Email&apos; : Label for checkbox for sending invitations with mailer.</extracomment>
<translation type="unfinished"></translation>
</message>
<message>
<source>busyOperations</source>
<extracomment>&apos;Operations in progress, please wait&apos; : Waiting message till the end of operations when creating a conference.</extracomment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Notice</name>

View file

@ -1938,6 +1938,11 @@ Klicken Sie hier: &lt;a href=&quot;%1&quot;&gt;%1&lt;/a&gt;
<extracomment>&apos;Send invite via Email&apos; : Label for checkbox for sending invitations with mailer.</extracomment>
<translation type="unfinished"></translation>
</message>
<message>
<source>busyOperations</source>
<extracomment>&apos;Operations in progress, please wait&apos; : Waiting message till the end of operations when creating a conference.</extracomment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Notice</name>

View file

@ -1938,6 +1938,11 @@ Click here: &lt;a href=&quot;%1&quot;&gt;%1&lt;/a&gt;
<extracomment>&apos;Send invite via Email&apos; : Label for checkbox for sending invitations with mailer.</extracomment>
<translation>Send invite via Email</translation>
</message>
<message>
<source>busyOperations</source>
<extracomment>&apos;Operations in progress, please wait&apos; : Waiting message till the end of operations when creating a conference.</extracomment>
<translation>Operations in progress, please wait</translation>
</message>
</context>
<context>
<name>Notice</name>

View file

@ -1938,6 +1938,11 @@ Haga clic aquí: &lt;a href=&quot;%1&quot;&gt;%1 &lt;/a&gt;
<extracomment>&apos;Send invite via Email&apos; : Label for checkbox for sending invitations with mailer.</extracomment>
<translation type="unfinished"></translation>
</message>
<message>
<source>busyOperations</source>
<extracomment>&apos;Operations in progress, please wait&apos; : Waiting message till the end of operations when creating a conference.</extracomment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Notice</name>

View file

@ -1938,6 +1938,11 @@ Cliquez ici : &lt;a href=&quot;%1&quot;&gt;%1&lt;/a&gt;
<extracomment>&apos;Send invite via Email&apos; : Label for checkbox for sending invitations with mailer.</extracomment>
<translation type="unfinished"></translation>
</message>
<message>
<source>busyOperations</source>
<extracomment>&apos;Operations in progress, please wait&apos; : Waiting message till the end of operations when creating a conference.</extracomment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Notice</name>

View file

@ -1926,6 +1926,11 @@ Kattintson ide: &lt;a href=&quot;%1&quot;&gt;%1&lt;/a&gt;
<extracomment>&apos;Send invite via Email&apos; : Label for checkbox for sending invitations with mailer.</extracomment>
<translation type="unfinished"></translation>
</message>
<message>
<source>busyOperations</source>
<extracomment>&apos;Operations in progress, please wait&apos; : Waiting message till the end of operations when creating a conference.</extracomment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Notice</name>

View file

@ -1938,6 +1938,11 @@ Clicca: &lt;a href=&quot;%1&quot;&gt;%1&lt;/a&gt;
<extracomment>&apos;Send invite via Email&apos; : Label for checkbox for sending invitations with mailer.</extracomment>
<translation>Invita tramite Email</translation>
</message>
<message>
<source>busyOperations</source>
<extracomment>&apos;Operations in progress, please wait&apos; : Waiting message till the end of operations when creating a conference.</extracomment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Notice</name>

View file

@ -1926,6 +1926,11 @@
<extracomment>&apos;Send invite via Email&apos; : Label for checkbox for sending invitations with mailer.</extracomment>
<translation type="unfinished"></translation>
</message>
<message>
<source>busyOperations</source>
<extracomment>&apos;Operations in progress, please wait&apos; : Waiting message till the end of operations when creating a conference.</extracomment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Notice</name>

View file

@ -1950,6 +1950,11 @@ Spustelėkite čia: &lt;a href=&quot;%1&quot;&gt;%1&lt;/a&gt;
<extracomment>&apos;Send invite via Email&apos; : Label for checkbox for sending invitations with mailer.</extracomment>
<translation type="unfinished"></translation>
</message>
<message>
<source>busyOperations</source>
<extracomment>&apos;Operations in progress, please wait&apos; : Waiting message till the end of operations when creating a conference.</extracomment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Notice</name>

View file

@ -1938,6 +1938,11 @@ Clique aqui: &lt;a href=&quot;%1&quot;&gt;%1 &lt;/a&gt;
<extracomment>&apos;Send invite via Email&apos; : Label for checkbox for sending invitations with mailer.</extracomment>
<translation type="unfinished"></translation>
</message>
<message>
<source>busyOperations</source>
<extracomment>&apos;Operations in progress, please wait&apos; : Waiting message till the end of operations when creating a conference.</extracomment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Notice</name>

View file

@ -1950,6 +1950,11 @@
<extracomment>&apos;Send invite via Email&apos; : Label for checkbox for sending invitations with mailer.</extracomment>
<translation>Отправить приглашение через электронную почту</translation>
</message>
<message>
<source>busyOperations</source>
<extracomment>&apos;Operations in progress, please wait&apos; : Waiting message till the end of operations when creating a conference.</extracomment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Notice</name>

View file

@ -1938,6 +1938,11 @@ Klicka här: &lt;a href=&quot;%1&quot;&gt;%1&lt;/a&gt;
<extracomment>&apos;Send invite via Email&apos; : Label for checkbox for sending invitations with mailer.</extracomment>
<translation type="unfinished"></translation>
</message>
<message>
<source>busyOperations</source>
<extracomment>&apos;Operations in progress, please wait&apos; : Waiting message till the end of operations when creating a conference.</extracomment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Notice</name>

View file

@ -1926,6 +1926,11 @@ Buraya tıklayın: &lt;a href=&quot;%1&quot;&gt;%1&lt;/a&gt;
<extracomment>&apos;Send invite via Email&apos; : Label for checkbox for sending invitations with mailer.</extracomment>
<translation type="unfinished"></translation>
</message>
<message>
<source>busyOperations</source>
<extracomment>&apos;Operations in progress, please wait&apos; : Waiting message till the end of operations when creating a conference.</extracomment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Notice</name>

View file

@ -1950,6 +1950,11 @@
<extracomment>&apos;Send invite via Email&apos; : Label for checkbox for sending invitations with mailer.</extracomment>
<translation type="unfinished"></translation>
</message>
<message>
<source>busyOperations</source>
<extracomment>&apos;Operations in progress, please wait&apos; : Waiting message till the end of operations when creating a conference.</extracomment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Notice</name>

View file

@ -1926,6 +1926,11 @@
<extracomment>&apos;Send invite via Email&apos; : Label for checkbox for sending invitations with mailer.</extracomment>
<translation type="unfinished"></translation>
</message>
<message>
<source>busyOperations</source>
<extracomment>&apos;Operations in progress, please wait&apos; : Waiting message till the end of operations when creating a conference.</extracomment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Notice</name>

View file

@ -34,6 +34,7 @@ Rectangle {
: DialogStyle.buttons.rightMargin
default property alias _content: content.data
property alias foregroundItem: foregroundItemData.data
readonly property bool contentIsEmpty: {
return _content == null || !_content.length
@ -111,4 +112,8 @@ Rectangle {
visible: children.length>0
}
}
Item{
id: foregroundItemData
anchors.fill: parent
}
}

View file

@ -21,24 +21,19 @@ DialogPlus {
property ConferenceInfoModel conferenceInfoModel: ConferenceInfoModel{}
onConferenceInfoModelChanged: selectedParticipants.setAddresses(conferenceInfoModel)
property bool forceSchedule : false
property int creationState: 0
Timer{
id: closeDelay
interval: 2000
onTriggered: conferenceManager.exit(1)
}
property int creationState: 0// -1=error, 0=Idle, 1=processing, 2=processed
Connections{
target: conferenceInfoModel
onConferenceCreated: {
if( conferenceInfoModel.inviteMode == 0 ) {
closeDelay.start()
conferenceManager.creationState = 2
conferenceManager.exit(1)
}
}
onConferenceCreationFailed:{ conferenceManager.creationState = -1 }
onInvitationsSent: {
closeDelay.start()
conferenceManager.creationState = 2
conferenceManager.exit(1)
}
}
@ -167,13 +162,10 @@ DialogPlus {
}
, Icon{
id: creationStatus
height: 15
width: 15
height: 10
width: 10
visible: icon != ''
icon: conferenceManager.creationState==2 ? 'led_green'
: conferenceManager.creationState==-1 ? 'led_red'
: conferenceManager.creationState==1 ? 'led_orange'
: ''
icon:conferenceManager.creationState==-1 ? 'led_red' : ''
}
]
@ -600,4 +592,35 @@ DialogPlus {
//----------------------------------------------------
}
}
foregroundItem: Item{
id: busyPanel
anchors.fill: parent
visible: conferenceManager.creationState == 1
MouseArea{// Grabber
anchors.fill: parent
cursorShape: Qt.ArrowCursor
}
Rectangle{
anchors.fill: parent
opacity: 0.6
color: 'white'
}
ColumnLayout{
anchors.centerIn: parent
spacing: 10
BusyIndicator{
Layout.preferredHeight: 20
Layout.preferredWidth: 20
Layout.alignment: Qt.AlignCenter
color: NewConferenceStyle.busy.color
}
Text{
Layout.fillWidth: true
color: NewConferenceStyle.busy.color
//: 'Operations in progress, please wait' : Waiting message till the end of operations when creating a conference.
text: qsTr('busyOperations')
font.pointSize: NewConferenceStyle.busy.pointSize
}
}
}
}

View file

@ -241,7 +241,11 @@ ApplicationWindow {
onClicked: {
window.detachVirtualWindow()
window.attachVirtualWindow(Utils.buildAppDialogUri('NewConference')
,{})
,{}, function (status) {
if( status){
setView('Conferences')
}
})
}
TooltipArea{
visible: !SettingsModel.videoConferenceEnabled

View file

@ -17,6 +17,11 @@ QtObject {
property color addressesAdminColor: ColorsList.add(sectionName+'_addresses_admin', 'g').color
property color requiredColor: ColorsList.add(sectionName+'_required_text', 'g').color
property QtObject busy: QtObject{
property color color: ColorsList.add(sectionName+'_busy', 'i').color
property real pointSize: Units.dp * 10
}
property QtObject titles: QtObject{
property color textColor: ColorsList.add(sectionName+'_schedule_titles', 'g').color
property int weight: Font.DemiBold