Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Calindori
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
6
Issues
6
List
Boards
Labels
Service Desk
Milestones
Merge Requests
2
Merge Requests
2
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Plasma Mobile
Calindori
Commits
b30d2add
Commit
b30d2add
authored
Apr 24, 2019
by
Dimitris Kardarakos
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
POC against sink with nextcloud todos
parent
8d08d3c5
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
110 additions
and
5 deletions
+110
-5
src/contents/ui/Main.qml
src/contents/ui/Main.qml
+99
-0
src/contents/ui/TodosView.qml
src/contents/ui/TodosView.qml
+11
-5
No files found.
src/contents/ui/Main.qml
View file @
b30d2add
...
...
@@ -23,6 +23,7 @@ import org.kde.kirigami 2.0 as Kirigami
import
QtQuick
.
Controls
2.4
as
Controls2
import
org
.
kde
.
phone
.
calindori
0.1
as
Calindori
import
"
Utils.js
"
as
Utils
import
org
.
kube
.
framework
1.0
as
Kube
Kirigami.ApplicationWindow
{
id
:
root
...
...
@@ -37,6 +38,12 @@ Kirigami.ApplicationWindow {
title
:
"
Calindori
"
actions
:
[
Kirigami.Action
{
id
:
onlineCalendars
text
:
"
Online Calendars
"
onTriggered
:
root
.
pageStack
.
push
(
accountSwitcher
);
},
Kirigami.Action
{
id
:
calendarActions
...
...
@@ -260,6 +267,98 @@ Kirigami.ApplicationWindow {
}
}
Kube.CheckedEntities
{
id
:
calendarFilterCollector
}
Component
{
id
:
accountSwitcher
Kirigami.Page
{
Kube.ListView
{
id
:
listView
anchors.fill
:
parent
Layout.fillWidth
:
true
Layout.maximumHeight
:
Math
.
min
(
contentHeight
,
parent
.
height
-
Kube
.
Units
.
gridUnit
)
Layout.preferredHeight
:
contentHeight
spacing
:
Kube
.
Units
.
smallSpacing
model
:
Kube.CheckableEntityModel
{
id
:
calendarModel
type
:
"
calendar
"
roles
:
[
"
name
"
,
"
color
"
,
"
enabled
"
]
sortRole
:
"
name
"
filter
:
{}
//root.editMode ? {} : {enabled: true}
accountId
:
""
checkedEntities
:
calendarFilterCollector
}
delegate
:
Kube.ListDelegate
{
id
:
delegate
width
:
listView
.
availableWidth
height
:
Kube
.
Units
.
gridUnit
hoverEnabled
:
true
background
:
Item
{}
RowLayout
{
anchors.fill
:
parent
spacing
:
Kube
.
Units
.
smallSpacing
Kube.CheckBox
{
id
:
checkBox
opacity
:
0.9
visible
:
root
.
editMode
checked
:
model
.
checked
||
model
.
enabled
onCheckedChanged
:
{
model
.
checked
=
checked
model
.
enabled
=
checked
}
indicator
:
Rectangle
{
width
:
Kube
.
Units
.
gridUnit
*
0.8
height
:
Kube
.
Units
.
gridUnit
*
0.8
color
:
model
.
color
Rectangle
{
id
:
highlight
anchors.fill
:
parent
visible
:
checkBox
.
hovered
||
checkBox
.
visualFocus
color
:
Kube
.
Colors
.
highlightColor
opacity
:
0.4
}
Kube.Icon
{
anchors.centerIn
:
parent
height
:
Kube
.
Units
.
gridUnit
width
:
Kube
.
Units
.
gridUnit
visible
:
checkBox
.
checked
iconName
:
Kube
.
Icons
.
checkbox_inverted
}
}
}
Kube.Label
{
id
:
label
Layout.fillWidth
:
true
text
:
model
.
name
color
:
Kube
.
Colors
.
highlightedTextColor
elide
:
Text
.
ElideLeft
clip
:
true
}
Rectangle
{
visible
:
!
root
.
editMode
width
:
Kube
.
Units
.
gridUnit
*
0.8
height
:
Kube
.
Units
.
gridUnit
*
0.8
radius
:
width
/
2
color
:
model
.
color
}
}
}
}
}
}
ConfirmationSheet
{
id
:
deleteSheet
...
...
src/contents/ui/TodosView.qml
View file @
b30d2add
...
...
@@ -22,6 +22,7 @@ import QtQuick.Controls 2.4 as Controls2
import
QtQuick
.
Layouts
1.11
import
org
.
kde
.
kirigami
2.4
as
Kirigami
import
org
.
kde
.
phone
.
calindori
0.1
as
Calindori
import
org
.
kube
.
framework
1.0
as
Kube
Kirigami.Page
{
id
:
root
...
...
@@ -56,18 +57,23 @@ Kirigami.Page {
pageStack
.
pop
(
todoPage
);
}
}
}
Kube.CalendarSelector
{
id
:
accountSwitcher
visible
:
false
}
Kirigami.CardsListView
{
id
:
cardsListview
anchors.fill
:
parent
model
:
Calindori.TodosModel
{
filterdt
:
root
.
todoDt
memorycalendar
:
root
.
calendar
.
memorycalendar
// model: Calindori.TodosModel {
// filterdt: root.todoDt
// memorycalendar: root.calendar.memorycalendar
// }
model
:
Kube.TodoModel
{
calendarFilter
:
accountSwitcher
.
enabledCalendars
}
delegate
:
Kirigami.Card
{
banner.title
:
model
.
summary
banner.titleLevel
:
3
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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