Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
PIM
Kalendar
Commits
a5afd08c
Commit
a5afd08c
authored
Nov 07, 2021
by
Claudio Cambra
Browse files
Fixed occurrence end num spinbox
parent
c79f7c70
Pipeline
#94890
passed with stage
in 4 minutes and 57 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/contents/ui/IncidenceEditor.qml
View file @
a5afd08c
...
...
@@ -433,7 +433,7 @@ Kirigami.ScrollablePage {
Layout.leftMargin
:
Kirigami
.
Units
.
largeSpacing
visible
:
repeatComboBox
.
currentIndex
>
0
// Not "Never" index
function
setOcurrence
()
{
function
setOc
c
urrence
()
{
root
.
incidenceWrapper
.
setRegularRecurrence
(
recurScaleRuleCombobox
.
currentValue
,
recurFreqRuleSpinbox
.
value
);
if
(
recurScaleRuleCombobox
.
currentValue
===
IncidenceWrapper
.
Weekly
)
{
...
...
@@ -461,12 +461,12 @@ Kirigami.ScrollablePage {
Layout.fillWidth
:
true
visible
:
repeatComboBox
.
currentIndex
===
5
// Make sure it defaults to something
onVisibleChanged
:
if
(
visible
&&
currentIndex
<
0
)
{
currentIndex
=
0
;
customRecurrenceLayout
.
setOcurrence
();
}
onVisibleChanged
:
if
(
visible
&&
currentIndex
<
0
)
{
currentIndex
=
0
;
customRecurrenceLayout
.
setOc
c
urrence
();
}
textRole
:
"
display
"
valueRole
:
"
interval
"
onCurrentValueChanged
:
if
(
visible
)
{
customRecurrenceLayout
.
setOcurrence
();
customRecurrenceLayout
.
setOc
c
urrence
();
repeatComboBox
.
currentIndex
=
5
;
// Otherwise resets to default daily/weekly/etc.
}
currentIndex
:
{
...
...
@@ -499,7 +499,7 @@ Kirigami.ScrollablePage {
delegate
:
Kirigami.BasicListItem
{
text
:
modelData
.
display
onClicked
:
{
customRecurrenceLayout
.
setOcurrence
();
customRecurrenceLayout
.
setOc
c
urrence
();
repeatComboBox
.
currentIndex
=
5
;
// Otherwise resets to default daily/weekly/etc.
}
}
...
...
@@ -575,7 +575,7 @@ Kirigami.ScrollablePage {
text
:
i18nc
(
"
%1 is the day number of month
"
,
"
The %1 of each month
"
,
LabelUtils
.
numberToString
(
dateOfMonth
))
checked
:
root
.
incidenceWrapper
.
recurrenceData
.
type
===
6
// Monthly on day (1st of month)
onClicked
:
customRecurrenceLayout
.
setOcurrence
()
onClicked
:
customRecurrenceLayout
.
setOc
c
urrence
()
}
QQC2.RadioButton
{
property
int
dayOfWeek
:
incidenceStartDateCombo
.
dateFromText
.
getDay
()
>
0
?
...
...
@@ -636,18 +636,18 @@ Kirigami.ScrollablePage {
RowLayout
{
Layout.fillWidth
:
true
visible
:
endRecurType
.
currentIndex
===
2
onVisibleChanged
:
if
(
visible
)
{
root
.
incidenceWrapper
.
setRecurrenceOcurrences
(
recurOcurrenceEndSpinbox
.
value
)
}
onVisibleChanged
:
if
(
visible
)
{
root
.
incidenceWrapper
.
setRecurrenceOc
c
urrences
(
recurOc
c
urrenceEndSpinbox
.
value
)
}
QQC2.SpinBox
{
id
:
recurOcurrenceEndSpinbox
id
:
recurOc
c
urrenceEndSpinbox
Layout.fillWidth
:
true
from
:
1
value
:
root
.
incidenceWrapper
.
recurrenceData
.
duration
onValueChanged
:
if
(
visible
)
{
root
.
incidenceWrapper
.
setRecurrenceOcurrences
(
value
)
}
onValueChanged
:
if
(
visible
)
{
root
.
incidenceWrapper
.
setRecurrenceOc
c
urrences
(
value
)
}
}
QQC2.Label
{
text
:
i18np
(
"
occurrence
"
,
"
occurrences
"
,
recurOcurrenceEndSpinbox
.
value
)
text
:
i18np
(
"
occurrence
"
,
"
occurrences
"
,
recurOc
c
urrenceEndSpinbox
.
value
)
}
}
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment