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
7065b026
Commit
7065b026
authored
Sep 18, 2022
by
Claudio Cambra
Browse files
Use standard keys for view navigation actions
Signed-off-by:
Claudio Cambra
<
claudio.cambra@gmail.com
>
parent
a60fe179
Pipeline
#234107
canceled with stage
in 3 minutes and 48 seconds
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/contents/ui/MainViews/HourlyView.qml
View file @
7065b026
...
...
@@ -106,20 +106,21 @@ Kirigami.Page {
readonly
property
Kirigami.Action
previousAction
:
Kirigami.Action
{
icon.name
:
"
go-previous
"
text
:
i18n
(
"
Previous Week
"
)
shortcut
:
"
Left
"
shortcut
:
StandardKey
.
MoveToPreviousPage
onTriggered
:
setToDate
(
DateUtils
.
addDaysToDate
(
pathView
.
currentItem
.
startDate
,
-
root
.
daysToShow
))
displayHint
:
Kirigami
.
DisplayHint
.
IconOnly
}
readonly
property
Kirigami.Action
nextAction
:
Kirigami.Action
{
icon.name
:
"
go-next
"
text
:
i18n
(
"
Next Week
"
)
shortcut
:
"
Right
"
shortcut
:
StandardKey
.
MoveToNextPage
onTriggered
:
setToDate
(
DateUtils
.
addDaysToDate
(
pathView
.
currentItem
.
startDate
,
root
.
daysToShow
))
displayHint
:
Kirigami
.
DisplayHint
.
IconOnly
}
readonly
property
Kirigami.Action
todayAction
:
Kirigami.Action
{
icon.name
:
"
go-jump-today
"
text
:
i18n
(
"
Now
"
)
shortcut
:
StandardKey
.
MoveToStartOfLine
onTriggered
:
setToDate
(
new
Date
(),
true
,
true
);
}
...
...
src/contents/ui/MainViews/MonthView.qml
View file @
7065b026
...
...
@@ -62,20 +62,21 @@ Kirigami.Page {
readonly
property
Kirigami.Action
previousAction
:
Kirigami.Action
{
icon.name
:
"
go-previous
"
text
:
i18n
(
"
Previous Month
"
)
shortcut
:
"
Left
"
shortcut
:
StandardKey
.
MoveToPreviousPage
onTriggered
:
setToDate
(
DateUtils
.
addMonthsToDate
(
pathView
.
currentItem
.
firstDayOfMonth
,
-
1
))
displayHint
:
Kirigami
.
DisplayHint
.
IconOnly
}
readonly
property
Kirigami.Action
nextAction
:
Kirigami.Action
{
icon.name
:
"
go-next
"
text
:
i18n
(
"
Next Month
"
)
shortcut
:
"
Right
"
shortcut
:
StandardKey
.
MoveToNextPage
onTriggered
:
setToDate
(
DateUtils
.
addMonthsToDate
(
pathView
.
currentItem
.
firstDayOfMonth
,
1
))
displayHint
:
Kirigami
.
DisplayHint
.
IconOnly
}
readonly
property
Kirigami.Action
todayAction
:
Kirigami.Action
{
icon.name
:
"
go-jump-today
"
text
:
i18n
(
"
Today
"
)
shortcut
:
StandardKey
.
MoveToStartOfLine
onTriggered
:
setToDate
(
new
Date
())
}
actions
{
...
...
src/contents/ui/MainViews/ScheduleView.qml
View file @
7065b026
...
...
@@ -122,20 +122,21 @@ Kirigami.Page {
readonly
property
Kirigami.Action
previousAction
:
Kirigami.Action
{
icon.name
:
"
go-previous
"
text
:
i18n
(
"
Previous Month
"
)
shortcut
:
"
Left
"
shortcut
:
StandardKey
.
MoveToPreviousPage
onTriggered
:
setToDate
(
DateUtils
.
addMonthsToDate
(
pathView
.
currentItem
.
firstDayOfMonth
,
-
1
))
displayHint
:
Kirigami
.
DisplayHint
.
IconOnly
}
readonly
property
Kirigami.Action
nextAction
:
Kirigami.Action
{
icon.name
:
"
go-next
"
text
:
i18n
(
"
Next Month
"
)
shortcut
:
"
Right
"
shortcut
:
StandardKey
.
MoveToNextPage
onTriggered
:
setToDate
(
DateUtils
.
addMonthsToDate
(
pathView
.
currentItem
.
firstDayOfMonth
,
1
))
displayHint
:
Kirigami
.
DisplayHint
.
IconOnly
}
readonly
property
Kirigami.Action
todayAction
:
Kirigami.Action
{
icon.name
:
"
go-jump-today
"
text
:
i18n
(
"
Today
"
)
shortcut
:
StandardKey
.
MoveToStartOfLine
onTriggered
:
setToDate
(
new
Date
())
}
...
...
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