Merge lp:~pkunal-parmar/ubuntu-calendar-app/RefreshIssue into lp:ubuntu-calendar-app

Proposed by Kunal Parmar
Status: Merged
Approved by: Mihir Soni
Approved revision: 536
Merged at revision: 537
Proposed branch: lp:~pkunal-parmar/ubuntu-calendar-app/RefreshIssue
Merge into: lp:ubuntu-calendar-app
Diff against target: 50 lines (+12/-10)
2 files modified
TimeLineBase.qml (+11/-0)
TimeLineBaseComponent.qml (+1/-10)
To merge this branch: bzr merge lp:~pkunal-parmar/ubuntu-calendar-app/RefreshIssue
Reviewer Review Type Date Requested Status
Mihir Soni Approve
Ubuntu Phone Apps Jenkins Bot continuous-integration Approve
Review via email: mp+240850@code.launchpad.net

Commit message

Now that Timeline views are loaded asynchronously, we need to add refresh events on Object creation

Description of the change

Now that Timeline views are loaded asynchronously, we need to add refresh events on Object creation

To post a comment you must log in.
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Approve (continuous-integration)
Revision history for this message
Mihir Soni (mihirsoni) wrote :

Looks good to me.
Thanks kunal

Revision history for this message
Mihir Soni (mihirsoni) wrote :

LGTM !

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'TimeLineBase.qml'
2--- TimeLineBase.qml 2014-10-21 20:51:00 +0000
3+++ TimeLineBase.qml 2014-11-06 13:51:23 +0000
4@@ -27,6 +27,17 @@
5 property int hourHeight: units.gu(10)
6 property var model;
7
8+ Component.onCompleted: {
9+ bubbleOverLay.createEvents();
10+ model.addModelChangeListener(destroyAllChildren);
11+ model.addModelChangeListener(createEvents);
12+ }
13+
14+ Component.onDestruction: {
15+ model.removeModelChangeListener(destroyAllChildren);
16+ model.removeModelChangeListener(createEvents);
17+ }
18+
19 MouseArea {
20 anchors.fill: parent
21 objectName: "mouseArea"
22
23=== modified file 'TimeLineBaseComponent.qml'
24--- TimeLineBaseComponent.qml 2014-10-22 18:46:59 +0000
25+++ TimeLineBaseComponent.qml 2014-11-06 13:51:23 +0000
26@@ -151,6 +151,7 @@
27 height: parent.height
28 delegate: comp
29 day: startDay.addDays(index)
30+ model: mainModel
31
32 Loader{
33 objectName: "weekdevider"
34@@ -173,16 +174,6 @@
35 destroyAllChildren();
36 }
37 }
38-
39- model: mainModel
40- Component.onCompleted: {
41- model.addModelChangeListener(destroyAllChildren);
42- model.addModelChangeListener(createEvents);
43- }
44- Component.onDestruction: {
45- model.removeModelChangeListener(destroyAllChildren);
46- model.removeModelChangeListener(createEvents);
47- }
48 }
49 }
50 }

Subscribers

People subscribed via source and target branches

to status/vote changes: