Merge lp:~yohanboniface/ubuntu-calendar-app/DatePicker into lp:ubuntu-calendar-app
- DatePicker
- Merge into trunk
Status: | Superseded |
---|---|
Proposed branch: | lp:~yohanboniface/ubuntu-calendar-app/DatePicker |
Merge into: | lp:ubuntu-calendar-app |
Diff against target: |
419 lines (+110/-184) 4 files modified
NewEvent.qml (+101/-89) TimePicker.qml (+0/-95) dateExt.js (+6/-0) tests/autopilot/calendar_app/tests/test_calendar.py (+3/-0) |
To merge this branch: | bzr merge lp:~yohanboniface/ubuntu-calendar-app/DatePicker |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Ubuntu Phone Apps Jenkins Bot | continuous-integration | Needs Fixing | |
Alan Pope πΊπ§π± π¦ (community) | Approve | ||
David Planella | Needs Fixing | ||
Mihir Soni | Needs Fixing | ||
Olivier Tilloy (community) | Needs Fixing | ||
Kunal Parmar | Needs Fixing | ||
Review via email: mp+212163@code.launchpad.net |
This proposal has been superseded by a proposal from 2014-06-06.
Commit message
Add the native Ubuntu UI DatePicker.
Also, allow to change the date value of the event.
Description of the change
Add the native Ubuntu UI DatePicker.
Also, allow to change the date value of the event.
For now the progress are blocked because I can't test the native DatePicker with autopilot.
I propose it as merge anyway as suggested by David today on IRC, for preparing the incoming hackdays.
See update from zsombi today:
2014-03-21 12:28:04 zsombi ybon: are you using the DatePicker or the PickerPanel?
2014-03-21 12:29:45 ybon zsombi: PickerPanel.
2014-03-21 12:30:26 zsombi ybon: ok. anyway, we don't have emulators yet neither for DatePicker nor for PickerPanel.
2014-03-21 12:30:40 ybon hehe, ok ;)
2014-03-21 12:31:23 zsombi ybon: so we need emus for both... and anyway we need emus for them :)
2014-03-21 12:32:14 ybon ;)
2014-03-21 12:32:17 ybon thanks for the update :)
David Planella (dpm) wrote : | # |
Yohan, as Kunal is saying, could you do:
bzr merge lp:ubuntu-calendar-app
(resolve conflicts if there are any)
bzr commit -m"Merged from trunk"
bzr push lp:~yohanboniface/ubuntu-calendar-app/DatePicker
Then Launchpad should take care of updating the Merge Proposal for you.
Thanks!
ybon (yohanboniface) wrote : | # |
I will do asap!
I'm in the train today, but will take time tonight or tomorrow morning for this and other comments from Kunal :)
ybon (yohanboniface) wrote : | # |
Done on this branch :)
Kunal Parmar (pkunal-parmar) wrote : | # |
it seems there is still some merge issue, you seems to be removing reminder related support.
ybon (yohanboniface) wrote : | # |
How do I check that?
Here is what I have:
ybon@edoardo:
Nothing to do.
ybon (yohanboniface) wrote : | # |
Ah, sorry, you meant I've made a mistake while merging in the past.
Still figuring out how to do a proper diff between to branches in Bazaar (but I can do it with "diff" command line).
Can you be a little more specific on what's missing?
ybon (yohanboniface) wrote : | # |
OK, got it:
> //remove old reminder value
> var oldVisualReminder = event.detail(
> if(oldVisualRem
> event.removeDet
> }
>
> var oldAudibleReminder = event.detail(
> if(oldAudibleRe
> event.removeDet
> }
>
> var reminderTime = Defines.
> if( reminderTime !== 0 ) {
> var visualReminder = Qt.createQmlObj
> visualReminder.
> visualReminder.
> visualReminder.
> visualReminder.
> event.setDetail
>
> var audibleReminder = Qt.createQmlObj
> audibleReminder
> audibleReminder
> audibleReminder
> event.setDetail
> }
>
Commit to come.
Kunal Parmar (pkunal-parmar) wrote : | # |
I dont know much bzr either, but you can get master and check diff using meld diff.
ybon (yohanboniface) wrote : | # |
Done, thanks for checking again :)
Olivier Tilloy (osomon) wrote : | # |
The calendar_
Since autopilot emulators for the new picker components are not available yet, we have two options:
1) introspect the picker components in the test (essentially, write our own custom emulators for them as a temporary stopgap measure until the SDK team provide official emulators), this has the downside of being fragile in case the implementation changes on the UITK side
2) temporarily skip the test (decorating it with @unittest.skip, including a link to the bug report that tracks the need for official emulators)
Mihir Soni (mihirsoni) wrote : | # |
Also,
as discussed in today's hangout.
we'll have to change the design of changing start end dateTime.
Kunal Parmar (pkunal-parmar) wrote : | # |
287 + property var recurrenceValue: [ RecurrenceRule.
288 + RecurrenceRule.
289 + RecurrenceRule.
290 + RecurrenceRule.
291 + RecurrenceRule.
292 +
293 + property var recurrenceLabel: [ i18n.tr("Once"),
294 + i18n.tr("Daily"),
295 + i18n.tr("Weekly"),
296 + i18n.tr("Monthly"),
297 + i18n.tr("Yearly")];
This code also looks like from old branch. Please merge this changes as well.
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:208
http://
Executed test runs:
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
Mihir Soni (mihirsoni) wrote : | # |
Could you please merge with trunk and resolve the conflicts ?
ybon (yohanboniface) wrote : | # |
Done.
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:209
http://
Executed test runs:
UNSTABLE: http://
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
Click here to trigger a rebuild:
http://
Victor Thompson (vthompson) wrote : | # |
Ybon,
Could you merge trunk into this branch so you get the fix for a bug that prevents the app from running correctly on the device [1]?
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:210
http://
Executed test runs:
UNSTABLE: http://
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
Click here to trigger a rebuild:
http://
David Planella (dpm) wrote : | # |
In order for this to pass, the autopilot test will need to be fixed too before we can merge it.
ybon (yohanboniface) wrote : | # |
Thanks for clarifying the needs, David.
I guess you are talking about the one I've commented on #206?
One question: last time I've raised this on IRC, there was no autopilot handler for the native Ubuntu UI DatePicker. Are you aware of any update on this side?
If not, are you expecting that I do this by hand?
Alan Pope πΊπ§π± π¦ (popey) wrote : | # |
Have asked Leo Arias (elopio) to help us with this.
ybon (yohanboniface) wrote : | # |
Thanks popey :)
Alan Pope πΊπ§π± π¦ (popey) wrote : | # |
Ok, Leo should have some time this week to work on this.
Leo Arias (elopio) wrote : | # |
It's ready for review:
https:/
https:/
It would be nice if you could take a look and see if it works for your use cases.
Alan Pope πΊπ§π± π¦ (popey) wrote : | # |
Seems the jenkins job on https:/
Alan Pope πΊπ§π± π¦ (popey) wrote : | # |
Speaking to Leo, the above merge to datepicker-
Alan Pope πΊπ§π± π¦ (popey) wrote : | # |
The ui toolkit merge appears to have landed now, so this can land.
Alan Pope πΊπ§π± π¦ (popey) wrote : | # |
This needs re-merging with trunk.
ybon (yohanboniface) wrote : | # |
Given how much trunk as diverged and that bazaar is quite bugged on complex merges, I think the best option is to rerun by hand the commits on top of trunk on a new branch.
I will try to do that this week, but if someone want to take it⦠;)
David Planella (dpm) wrote : | # |
> Given how much trunk as diverged and that bazaar is quite bugged on complex
> merges, I think the best option is to rerun by hand the commits on top of
> trunk on a new branch.
Thanks Yohan. Bzr should handle complex merges just fine, and this one shouldn't be too complex after all: it just happens that the two branches have diverged in time. Where I strongly disagree is that rerunning old commits by hand would be a better solution: I think it'd be much less work to let a VCS do the merge automatically and resolve any conflicts afterwards.
In fact, I've just had a go at it (*), and the result was the following:
Text conflict in NewEvent.qml
Text conflict in tests/autopilot
2 conflicts encountered.
So essentially conflicts in two files only. The one on the test_calendar.py is trivial to resolve. NewEvent.qml has 6 conflicts, some of which are simple to resolve, but ultimately, to be on the safe side, they require someone familiar with this branch to fix them.
> I will try to do that this week, but if someone want to take it⦠;)
Ultimately, the changes will need to be applied in your branch if we want to merge it, so it'd be great if you could update your branch (no one else has got the permissions to do so, unless they take it over, branch off it, and submit a new MP themselves). But please let us know if you need help on this.
(*) bzr branch lp:~yohanboniface/ubuntu-calendar-app/DatePicker
cd DatePicker
bzr merge lp:ubuntu-calendar-app
ybon (yohanboniface) wrote : | # |
Thanks for this, David. :)
Have you looked at the "{" in the merged files? I've just run the merge to have a look, and (sadly as often with bzr in my experience) they seem messed up to me in NewEvent.qml :/
In the past I've other bad experiences with automatic merges, like some pieces of code not being removed as expected.
David Planella (dpm) wrote : | # |
So I've had a go at it, and while I cannot say whether in all automatic merges the braces are still matched, they seemed all ok to me on this one. I've merged to trunk and resolved all conflicts on a new branch I've just pushed to LP.
So would you mind doing a 'bzr merge lp:~dpm/ubuntu-calendar-app/DatePicker' onto your branch (it should apply cleanly), have a quick look over it, and then push to your branch?
Thanks!
ybon (yohanboniface) wrote : | # |
Done!
Thanks *you* :)
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:211
http://
Executed test runs:
UNSTABLE: http://
deb: http://
SUCCESS: http://
SUCCESS: http://
Click here to trigger a rebuild:
http://
Leo Arias (elopio) wrote : | # |
I'm looking at the failing test so you won't need to skip it.
It seems to be failing in trunk too, so shouldn't be related to your branch.
Nicholas Skaggs (nskaggs) wrote : | # |
Nicholas Skaggs (nskaggs) wrote : | # |
Leo has pointed out there is a regression that exists in trunk; coming from the toolkit component or the app itself in regards to the textfield. Tapping the field doesn't set focus on the first tap.
I'm investigating the source of this regression.
Nicholas Skaggs (nskaggs) wrote : | # |
The regression is caused by the additional button introduced in r300.
Something funny is occuring in the toolkit. The popover is not closing and eating the first event. I'm trying to put together a small example to demonstrate the issue.
Nicholas Skaggs (nskaggs) wrote : | # |
The bug has been filed here: https:/
Nicholas Skaggs (nskaggs) wrote : | # |
I think you can edit the newevent test to workaround the regression, but barring that please include the bug as the reason you are skipping the test.
Nicholas Skaggs (nskaggs) wrote : | # |
Resubmitting after rebasing to trunk and fixing tests
Unmerged revisions
Preview Diff
1 | === modified file 'NewEvent.qml' |
2 | --- NewEvent.qml 2014-05-31 09:54:55 +0000 |
3 | +++ NewEvent.qml 2014-06-05 11:53:12 +0000 |
4 | @@ -23,6 +23,16 @@ |
5 | property alias scrollY: flickable.contentY |
6 | property bool isEdit: false |
7 | |
8 | + onStartDateChanged: { |
9 | + startDateInput.text = Qt.formatDateTime(startDate, "dd MMM yyyy"); |
10 | + startTimeInput.text = Qt.formatDateTime(startDate, "hh:mm"); |
11 | + } |
12 | + |
13 | + onEndDateChanged: { |
14 | + endDateInput.text = Qt.formatDateTime(endDate, "dd MMM yyyy"); |
15 | + endTimeInput.text = Qt.formatDateTime(endDate, "hh:mm"); |
16 | + } |
17 | + |
18 | Component.onCompleted: { |
19 | // If startDate is setted by argument we have to not change it |
20 | //Set the nearest current time. |
21 | @@ -38,7 +48,7 @@ |
22 | } |
23 | |
24 | if(event === null){ |
25 | - isEdit =false; |
26 | + isEdit = false; |
27 | addEvent(); |
28 | } |
29 | else{ |
30 | @@ -54,13 +64,10 @@ |
31 | startTime.text = Qt.formatDateTime(startDate, "dd MMM yyyy hh:mm"); |
32 | endTime.text = Qt.formatDateTime(endDate, "dd MMM yyyy hh:mm"); |
33 | } |
34 | - |
35 | //Editing Event |
36 | function editEvent(e) { |
37 | startDate =new Date(e.startDateTime); |
38 | endDate = new Date(e.endDateTime); |
39 | - startTime.text = Qt.formatDateTime(e.startDateTime, "dd MMM yyyy hh:mm"); |
40 | - endTime.text = Qt.formatDateTime(e.endDateTime, "dd MMM yyyy hh:mm"); |
41 | |
42 | if(e.displayLabel) { |
43 | titleEdit.text = e.displayLabel; |
44 | @@ -124,7 +131,7 @@ |
45 | //Save the new or Existing event |
46 | function saveToQtPim() { |
47 | internal.clearFocus() |
48 | - if ( startDate >= endDate ) { |
49 | + if ( startDate >= endDate && !allDayEventCheckbox.checked) { |
50 | PopupUtils.open(errorDlgComponent,root,{"text":i18n.tr("End time can't be before start time")}); |
51 | } else { |
52 | event.startDateTime = startDate; |
53 | @@ -192,6 +199,16 @@ |
54 | pageStack.pop(); |
55 | } |
56 | } |
57 | + |
58 | + function openDatePicker (element, caller, callerProperty, mode) { |
59 | + element.highlighted = true; |
60 | + var picker = PickerPanel.openDatePicker(caller, callerProperty, mode); |
61 | + if (!picker) return; |
62 | + picker.closed.connect(function () { |
63 | + element.highlighted = false; |
64 | + }); |
65 | + } |
66 | + |
67 | // Calucate default hour and minute for start and end time on event |
68 | function roundDate(date) { |
69 | var tempDate = new Date(date) |
70 | @@ -228,22 +245,6 @@ |
71 | } |
72 | } |
73 | |
74 | - Component { |
75 | - id: timePicker |
76 | - TimePicker { |
77 | - } |
78 | - } |
79 | - |
80 | - Rectangle { |
81 | - id: availableArea |
82 | - |
83 | - width: parent.width |
84 | - color: "red" |
85 | - opacity: 0.5 |
86 | - z: 100 |
87 | - } |
88 | - |
89 | - |
90 | Flickable{ |
91 | id: flickable |
92 | |
93 | @@ -288,13 +289,13 @@ |
94 | contentWidth: width |
95 | contentHeight: column.height |
96 | |
97 | - Column{ |
98 | + Column { |
99 | id: column |
100 | |
101 | width: parent.width |
102 | spacing: units.gu(1) |
103 | |
104 | - UbuntuShape{ |
105 | + UbuntuShape { |
106 | width:parent.width |
107 | height: timeColumn.height |
108 | |
109 | @@ -304,65 +305,77 @@ |
110 | anchors.centerIn: parent |
111 | spacing: units.gu(1) |
112 | |
113 | - NewEventEntryField{ |
114 | - id: dateField |
115 | - title: i18n.tr("Date") |
116 | - width: parent.width |
117 | - objectName: "dateInput" |
118 | - |
119 | - text: Qt.formatDateTime(startDate,"dd MMM yyyy"); |
120 | - |
121 | - MouseArea{ |
122 | - anchors.fill: parent |
123 | - onClicked: { |
124 | - } |
125 | - } |
126 | - } |
127 | - |
128 | - NewEventEntryField{ |
129 | - id: startTime |
130 | - title: i18n.tr("Start") |
131 | - width: parent.width |
132 | - objectName: "startTimeInput" |
133 | - |
134 | - text: Qt.formatDateTime(startDate, "dd MMM yyyy hh:mm"); |
135 | - |
136 | - MouseArea{ |
137 | - anchors.fill: parent |
138 | - onClicked: { |
139 | - internal.clearFocus() |
140 | - var popupObj = PopupUtils.open(timePicker,root,{"hour": startDate.getHours(),"minute":startDate.getMinutes()}); |
141 | - popupObj.accepted.connect(function(startHour, startMinute) { |
142 | - var newDate = startDate; |
143 | - newDate.setHours(startHour, startMinute); |
144 | - startDate = newDate; |
145 | - startTime.text = Qt.formatDateTime(startDate, "dd MMM yyyy hh:mm"); |
146 | - }) |
147 | - } |
148 | - } |
149 | - } |
150 | - |
151 | - ThinDivider{} |
152 | - |
153 | - NewEventEntryField{ |
154 | - id: endTime |
155 | - title: i18n.tr("End") |
156 | - width: parent.width |
157 | - objectName: "endTimeInput" |
158 | - |
159 | - text: Qt.formatDateTime(endDate,"dd MMM yyyy hh:mm"); |
160 | - |
161 | - MouseArea{ |
162 | - anchors.fill: parent |
163 | - onClicked: { |
164 | - internal.clearFocus() |
165 | - var popupObj = PopupUtils.open(timePicker,root,{"hour": endDate.getHours(),"minute":endDate.getMinutes()}); |
166 | - popupObj.accepted.connect(function(startHour, startMinute) { |
167 | - var newDate = endDate; |
168 | - newDate.setHours(startHour, startMinute); |
169 | - endDate = newDate; |
170 | - endTime.text = Qt.formatDateTime(endDate, "dd MMM yyyy hh:mm"); |
171 | - }) |
172 | + Item { |
173 | + width: parent.width |
174 | + height: startDateInput.height |
175 | + |
176 | + NewEventEntryField{ |
177 | + id: startDateInput |
178 | + title: i18n.tr("Start") |
179 | + objectName: "startTimeInput" |
180 | + |
181 | + text: "" |
182 | + |
183 | + width: allDayEventCheckbox.checked ? parent.width : parent.width / 2 |
184 | + |
185 | + MouseArea{ |
186 | + anchors.fill: parent |
187 | + onClicked: openDatePicker(startDateInput, root, "startDate", "Years|Months|Days") |
188 | + } |
189 | + } |
190 | + |
191 | + NewEventEntryField{ |
192 | + id: startTimeInput |
193 | + title: i18n.tr("at") |
194 | + objectName: "startTimeInput" |
195 | + |
196 | + text: "" |
197 | + |
198 | + width: (parent.width / 2) - units.gu(1) |
199 | + anchors.right: parent.right |
200 | + visible: !allDayEventCheckbox.checked |
201 | + |
202 | + MouseArea{ |
203 | + anchors.fill: parent |
204 | + onClicked: openDatePicker(startTimeInput, root, "startDate", "Hours|Minutes") |
205 | + } |
206 | + } |
207 | + } |
208 | + |
209 | + Item { |
210 | + width: parent.width |
211 | + height: endDateInput.height |
212 | + visible: !allDayEventCheckbox.checked |
213 | + |
214 | + NewEventEntryField{ |
215 | + id: endDateInput |
216 | + title: i18n.tr("End") |
217 | + objectName: "endDateInput" |
218 | + |
219 | + text: "" |
220 | + |
221 | + width: parent.width / 2 |
222 | + |
223 | + MouseArea{ |
224 | + anchors.fill: parent |
225 | + onClicked: openDatePicker(endDateInput, root, "endDate", "Years|Months|Days") |
226 | + } |
227 | + } |
228 | + |
229 | + NewEventEntryField{ |
230 | + id: endTimeInput |
231 | + title: i18n.tr("at") |
232 | + objectName: "endTimeInput" |
233 | + |
234 | + text: "" |
235 | + |
236 | + width: (parent.width / 2) - units.gu(1) |
237 | + anchors.right: parent.right |
238 | + |
239 | + MouseArea{ |
240 | + anchors.fill: parent |
241 | + onClicked: openDatePicker(endTimeInput, root, "endDate", "Hours|Minutes") |
242 | + |
243 | } |
244 | } |
245 | } |
246 | @@ -382,14 +395,11 @@ |
247 | CheckBox { |
248 | id: allDayEventCheckbox |
249 | checked: false |
250 | - |
251 | - onCheckedChanged: { |
252 | - startTime.visible = !checked; |
253 | - endTime.visible = !checked; |
254 | - } |
255 | } |
256 | } |
257 | |
258 | + ThinDivider{} |
259 | + |
260 | NewEventEntryField{ |
261 | id: titleEdit |
262 | width: parent.width |
263 | @@ -553,8 +563,10 @@ |
264 | titleEdit.focus = false |
265 | locationEdit.focus = false |
266 | personEdit.focus = false |
267 | - startTime.focus = false |
268 | - endTime.focus = false |
269 | + startDateInput.focus = false |
270 | + startTimeInput.focus = false |
271 | + endDateInput.focus = false |
272 | + endTimeInput.focus = false |
273 | messageEdit.focus = false |
274 | } |
275 | } |
276 | |
277 | === removed file 'TimePicker.qml' |
278 | --- TimePicker.qml 2013-10-07 12:56:19 +0000 |
279 | +++ TimePicker.qml 1970-01-01 00:00:00 +0000 |
280 | @@ -1,95 +0,0 @@ |
281 | -/* |
282 | - * Copyright (C) 2013 Michael Zanetti <michael_zanetti@gmx.net> |
283 | - * |
284 | - * This program is free software; you can redistribute it and/or modify |
285 | - * it under the terms of the GNU General Public License as published by |
286 | - * the Free Software Foundation; version 3. |
287 | - * |
288 | - * This program is distributed in the hope that it will be useful, |
289 | - * but WITHOUT ANY WARRANTY; without even the implied warranty of |
290 | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
291 | - * GNU General Public License for more details. |
292 | - * |
293 | - * You should have received a copy of the GNU General Public License |
294 | - * along with this program. If not, see <http://www.gnu.org/licenses/>. |
295 | - */ |
296 | - |
297 | -import QtQuick 2.0 |
298 | -import Ubuntu.Components 0.1 |
299 | -import Ubuntu.Components.Popups 0.1 |
300 | - |
301 | -Dialog { |
302 | - id: root |
303 | - title: i18n.tr("Time") |
304 | - height: units.gu(100) |
305 | - |
306 | - property alias hour: hourScroller.currentIndex |
307 | - property alias minute: minuteScroller.currentIndex |
308 | - |
309 | - signal accepted(int hours, int minutes) |
310 | - signal rejected() |
311 | - |
312 | - QtObject { |
313 | - id: priv |
314 | - |
315 | - property date now: new Date() |
316 | - } |
317 | - |
318 | - contents: [ |
319 | - Row { |
320 | - height: units.gu(24) |
321 | - Scroller { |
322 | - id: hourScroller |
323 | - objectName: "hourScroller" |
324 | - anchors { |
325 | - top: parent.top |
326 | - bottom: parent.bottom |
327 | - } |
328 | - width: parent.width / 2 |
329 | - labelText: i18n.tr("Hour") |
330 | - |
331 | - min: 00 |
332 | - max: 23 |
333 | - currentIndex: priv.now.getHours() |
334 | - } |
335 | - Scroller { |
336 | - id: minuteScroller |
337 | - objectName: "minuteScroller" |
338 | - anchors { |
339 | - top: parent.top |
340 | - bottom: parent.bottom |
341 | - } |
342 | - width: parent.width / 2 |
343 | - labelText: i18n.tr("Minute") |
344 | - |
345 | - min: 00 |
346 | - max: 59 |
347 | - currentIndex: priv.now.getMinutes() |
348 | - } |
349 | - }, |
350 | - Row { |
351 | - spacing: units.gu(1) |
352 | - Button { |
353 | - objectName: "TimePickerCancelButton" |
354 | - text: i18n.tr("Cancel") |
355 | - onClicked: { |
356 | - root.rejected() |
357 | - PopupUtils.close(root) |
358 | - } |
359 | - width: (parent.width - parent.spacing) / 2 |
360 | - } |
361 | - Button { |
362 | - objectName: "TimePickerOKButton" |
363 | - text: i18n.tr("OK") |
364 | - color: "#dd4814" |
365 | - |
366 | - onClicked: { |
367 | - root.accepted(root.hour, root.minute) |
368 | - PopupUtils.close(root) |
369 | - } |
370 | - width: (parent.width - parent.spacing) / 2 |
371 | - } |
372 | - } |
373 | - |
374 | - ] |
375 | -} |
376 | |
377 | === modified file 'dateExt.js' |
378 | --- dateExt.js 2014-03-22 03:07:26 +0000 |
379 | +++ dateExt.js 2014-06-05 11:53:12 +0000 |
380 | @@ -90,6 +90,12 @@ |
381 | && this.getFullYear() === otherDay.getFullYear() ); |
382 | } |
383 | |
384 | +Date.prototype.mergeDate = function (d) { |
385 | + this.setFullYear(d.getFullYear()); |
386 | + this.setMonth(d.getMonth()); |
387 | + this.setDate(d.getDate()); |
388 | +} |
389 | + |
390 | function weekCount(year, month_number) { |
391 | var firstOfMonth = new Date(year, month_number, 1); |
392 | var lastOfMonth = new Date(year, month_number+1, 0); |
393 | |
394 | === modified file 'tests/autopilot/calendar_app/tests/test_calendar.py' |
395 | --- tests/autopilot/calendar_app/tests/test_calendar.py 2014-05-23 11:36:56 +0000 |
396 | +++ tests/autopilot/calendar_app/tests/test_calendar.py 2014-06-05 11:53:12 +0000 |
397 | @@ -14,12 +14,14 @@ |
398 | from testtools.matchers import Equals, Not, Is, NotEquals |
399 | |
400 | import time |
401 | +import unittest |
402 | |
403 | from calendar_app.tests import CalendarTestCase |
404 | |
405 | |
406 | class TestMainView(CalendarTestCase): |
407 | |
408 | + @unittest.skip |
409 | def _scroll_time_picker_to_time(self, picker, hours, minutes): |
410 | # Scroll hours to selected value |
411 | scroller = picker.select_single("Scroller", objectName="hourScroller") |
412 | @@ -44,6 +46,7 @@ |
413 | self.assertThat(scroller.currentIndex, Eventually( |
414 | Equals((current_index + 1) % 60))) |
415 | |
416 | + @unittest.skip |
417 | def test_new_event(self): |
418 | """test add new event """ |
419 | #go to today |
looks like you need to merge your branch with latest code.