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

Proposed by Kunal Parmar
Status: Merged
Approved by: Kunal Parmar
Approved revision: 629
Merged at revision: 697
Proposed branch: lp:~pkunal-parmar/ubuntu-calendar-app/UrlInvocation
Merge into: lp:ubuntu-calendar-app
Diff against target: 62 lines (+33/-8)
1 file modified
calendar.qml (+33/-8)
To merge this branch: bzr merge lp:~pkunal-parmar/ubuntu-calendar-app/UrlInvocation
Reviewer Review Type Date Requested Status
Ubuntu Phone Apps Jenkins Bot continuous-integration Approve
Bartosz Kosiorek (community) Approve
Mihir Soni Pending
Review via email: mp+255234@code.launchpad.net

Commit message

resolves 1426519

handing the invocation from URL

Description of the change

resolves 1426519

handing the invocation from URL

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: Needs Fixing (continuous-integration)
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
Andrea Bernabei (faenil) wrote :

code comment added

Revision history for this message
Kunal Parmar (pkunal-parmar) wrote :
Revision history for this message
Andrea Bernabei (faenil) :
Revision history for this message
Kunal Parmar (pkunal-parmar) wrote :

Hi Andrea, Your comment was very helpful.

Now I modified the code, can you have a another look.

Thanks

Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Needs Fixing (continuous-integration)
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
Andrea Bernabei (faenil) wrote :

minor comments from me, looks good otherwise, thanks :)

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
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Approve (continuous-integration)
Revision history for this message
Bartosz Kosiorek (gang65) wrote :

It is working perfectly for me.

review: Approve
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
Kunal Parmar (pkunal-parmar) wrote :

Thanks Gang65,

Seems like some issue with AP, I will have a look and try to fix it.

628. By Kunal Parmar

merge from trunk

Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
Kunal Parmar (pkunal-parmar) wrote :

AP fails does not seem like regression from this MR, but not sure why testcases are failing ramdomly

629. By Kunal Parmar

test

Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Approve (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'calendar.qml'
--- calendar.qml 2015-01-22 20:07:30 +0000
+++ calendar.qml 2015-07-18 01:29:50 +0000
@@ -95,6 +95,21 @@
95 footerColor: "#ECECEC"95 footerColor: "#ECECEC"
96 anchorToKeyboard: true96 anchorToKeyboard: true
9797
98 Connections {
99 target: UriHandler
100 onOpened: {
101 var uri = uris[0]
102 if(uri !== undefined && url != "") {
103 var commands = uri.split("://")[1].split("=");
104 if(commands[0].toLowerCase() === "eventid") {
105 // calendar://eventid=??
106 if( eventModel ) {
107 eventModel.showEventFromId(commands[1]);
108 }
109 }
110 }
111 }
112 }
98113
99 PageStack {114 PageStack {
100 id: pageStack115 id: pageStack
@@ -168,18 +183,28 @@
168 collectionFilter.ids = collectionIds;183 collectionFilter.ids = collectionIds;
169 }184 }
170185
186 function showEventFromId(eventId) {
187 if(eventId === undefined || eventId === "") {
188 return;
189 }
190
191 var requestId = "";
192 var callbackFunc = function(id,fetchedItems) {
193 if( requestId === id && fetchedItems.length > 0 ) {
194 pageStack.push(Qt.resolvedUrl("EventDetails.qml"),{"event":fetchedItems[0],"model": eventModel});
195 }
196 eventModel.onItemsFetched.disconnect( callbackFunc );
197 }
198
199 eventModel.onItemsFetched.connect( callbackFunc );
200 requestId = eventModel.fetchItems(eventId);
201 }
202
171 Component.onCompleted: {203 Component.onCompleted: {
172 delayedApplyFilter();204 delayedApplyFilter();
173205
174 if (args.values.eventid) {206 if (args.values.eventid) {
175 var requestId = "";207 showEventFromId(args.values.eventid);
176 eventModel.onItemsFetched.connect( function(id,fetchedItems) {
177 if( requestId === id && fetchedItems.length > 0 ) {
178 var event = fetchedItems[0];
179 pageStack.push(Qt.resolvedUrl("EventDetails.qml"),{"event":event,"model": eventModel});
180 }
181 });
182 requestId = eventModel.fetchItems([args.values.eventid]);
183 }208 }
184 }209 }
185 }210 }

Subscribers

People subscribed via source and target branches

to status/vote changes: