Merge lp:~mardy/reminders-app/app-access2 into lp:reminders-app

Proposed by Alberto Mardegan
Status: Merged
Approved by: David Planella
Approved revision: 45
Merged at revision: 143
Proposed branch: lp:~mardy/reminders-app/app-access2
Merge into: lp:reminders-app
Diff against target: 160 lines (+40/-3)
7 files modified
CMakeLists.txt (+4/-0)
com.ubuntu.reminders_reminders.application (+11/-0)
debian/control (+1/-0)
debian/reminders-app.install (+1/-0)
manifest.json (+2/-1)
src/app/qml/reminders.qml (+9/-2)
src/app/qml/ui/AccountSelectorPage.qml (+12/-0)
To merge this branch: bzr merge lp:~mardy/reminders-app/app-access2
Reviewer Review Type Date Requested Status
Ubuntu Phone Apps Jenkins Bot continuous-integration Approve
David Planella Approve
Review via email: mp+219798@code.launchpad.net

Commit message

Request access to the Evernote account

Use the new OnlineAccounts.Client module to setup the Evernote account.

Description of the change

Request access to the Evernote account

Use the new OnlineAccounts.Client module to setup the Evernote account.

Notes:
- I tested this only on the desktop.
- (not directly related to this branch) The AccountSelectorPage will never open, because it's impossible to add a second account; I'd suggest adding an "Accounts" button on the toolbar to open it, so that we allow selecting accounts and create new ones. Or just remove the AccountSelectorPage, if we don't want to support having more than one account.

To post a comment you must log in.
lp:~mardy/reminders-app/app-access2 updated
43. By Alberto Mardegan

Translate button label

44. By Alberto Mardegan

Add missing dependency

Revision history for this message
David Planella (dpm) wrote :

This works well on the device, but when running the app from the desktop with Qt Creator, I get:

 file:///tmp/build-app-access2-Desktop-Default/src/app/qml/reminders.qml:326:17: Cannot assign to non-existent property "applicationId"
                      applicationId: "com.ubuntu.reminders_reminders"
                      ^
I manually installed /usr/share/accounts/applications/com.ubuntu.reminders_reminders.application, but that did not seem to make a difference.

Revision history for this message
Alberto Mardegan (mardy) wrote :

In the last commit I added "qtdeclarative5-online-accounts-client0.1 (>= 0.3)" to debian/control; do you have it? (I have 0.3+14.10.20140506.1-0ubuntu1, FWIW)

Revision history for this message
David Planella (dpm) wrote :

I do, but while the 0.3 version is the same, you seem to have a more recent date, and for utopic

$ apt-cache policy qtdeclarative5-online-accounts-client0.1
qtdeclarative5-online-accounts-client0.1:
  Instaŀlat: 0.3+14.04.20140328-0ubuntu3
  Candidat: 0.3+14.04.20140328-0ubuntu3
  Taula de versió:
 *** 0.3+14.04.20140328-0ubuntu3 0
        500 http://de.archive.ubuntu.com/ubuntu/ trusty/universe amd64 Packages
        100 /var/lib/dpkg/status

lp:~mardy/reminders-app/app-access2 updated
45. By Alberto Mardegan

Update dependency version

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
David Planella (dpm) wrote :

Thanks, it seems that on 14.04 we'll need a backported version of some Online Accounts packages for Reminders to work. Alberto has put them in the core apps PPA, so if you are developing on 14.04, make sure you've added that PPA and that you update these packages:

qtdeclarative5-online-accounts-client0.1 (version: 0.3+14.10.20140506.1-0ubuntu2)
ubuntu-system-settings-online-accounts (version: 0.3+14.10.20140506.1)

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

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'CMakeLists.txt'
--- CMakeLists.txt 2014-05-12 11:19:30 +0000
+++ CMakeLists.txt 2014-05-16 12:52:31 +0000
@@ -12,6 +12,7 @@
1212
13set(APP_NAME reminders)13set(APP_NAME reminders)
14set(DESKTOP_FILE "${PROJECT_NAME}.desktop")14set(DESKTOP_FILE "${PROJECT_NAME}.desktop")
15set(APPLICATION_FILE "${PROJECT_NAME}_${APP_NAME}.application")
15set(ICON ${APP_NAME}.png)16set(ICON ${APP_NAME}.png)
16set(AUTOPILOT_DIR reminders)17set(AUTOPILOT_DIR reminders)
17set(APP_HARDCODE reminders)18set(APP_HARDCODE reminders)
@@ -33,6 +34,7 @@
33 set(BIN_DIR /lib/${ARCH_TRIPLET}/bin)34 set(BIN_DIR /lib/${ARCH_TRIPLET}/bin)
34 set(DATA_DIR /)35 set(DATA_DIR /)
35 set(DESKTOP_DIR ${DATA_DIR})36 set(DESKTOP_DIR ${DATA_DIR})
37 set(APPLICATION_DIR ${DATA_DIR})
36 if(NOT BZR_REVNO)38 if(NOT BZR_REVNO)
37 set(BZR_REVNO "latest")39 set(BZR_REVNO "latest")
38 endif(NOT BZR_REVNO)40 endif(NOT BZR_REVNO)
@@ -50,6 +52,7 @@
50 set(DATA_DIR ${CMAKE_INSTALL_DATADIR}/${APP_HARDCODE})52 set(DATA_DIR ${CMAKE_INSTALL_DATADIR}/${APP_HARDCODE})
51 set(ICON "${CMAKE_INSTALL_PREFIX}/${DATA_DIR}/${ICON}")53 set(ICON "${CMAKE_INSTALL_PREFIX}/${DATA_DIR}/${ICON}")
52 set(DESKTOP_DIR ${CMAKE_INSTALL_DATADIR}/applications)54 set(DESKTOP_DIR ${CMAKE_INSTALL_DATADIR}/applications)
55 set(APPLICATION_DIR ${CMAKE_INSTALL_DATADIR}/accounts/applications)
53endif(CLICK_MODE)56endif(CLICK_MODE)
5457
55file(GLOB_RECURSE I18N_SRC_FILES58file(GLOB_RECURSE I18N_SRC_FILES
@@ -64,6 +67,7 @@
6467
65configure_file(${DESKTOP_FILE}.in ${CMAKE_CURRENT_BINARY_DIR}/${DESKTOP_FILE})68configure_file(${DESKTOP_FILE}.in ${CMAKE_CURRENT_BINARY_DIR}/${DESKTOP_FILE})
66install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${DESKTOP_FILE} DESTINATION ${DESKTOP_DIR})69install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${DESKTOP_FILE} DESTINATION ${DESKTOP_DIR})
70install(FILES ${APPLICATION_FILE} DESTINATION ${APPLICATION_DIR})
67 71
68# Tests72# Tests
69enable_testing()73enable_testing()
7074
=== added file 'com.ubuntu.reminders_reminders.application'
--- com.ubuntu.reminders_reminders.application 1970-01-01 00:00:00 +0000
+++ com.ubuntu.reminders_reminders.application 2014-05-16 12:52:31 +0000
@@ -0,0 +1,11 @@
1<?xml version="1.0" encoding="UTF-8" ?>
2<application id="com.ubuntu.reminders_reminders">
3 <description>Reminders</description>
4
5 <services>
6 <service id="evernote">
7 <description>Synchronize your reminders with Evernote</description>
8 </service>
9 </services>
10
11</application>
012
=== modified file 'debian/control'
--- debian/control 2014-05-08 17:56:49 +0000
+++ debian/control 2014-05-16 12:52:31 +0000
@@ -22,6 +22,7 @@
22 qtdeclarative5-evernote0.1,22 qtdeclarative5-evernote0.1,
23 qtdeclarative5-ubuntu-ui-toolkit-plugin | qt-components-ubuntu,23 qtdeclarative5-ubuntu-ui-toolkit-plugin | qt-components-ubuntu,
24 qtdeclarative5-localstorage-plugin,24 qtdeclarative5-localstorage-plugin,
25 qtdeclarative5-online-accounts-client0.1 (>= 0.3+14.10.20140506),
25 qtdeclarative5-quicklayouts-plugin,26 qtdeclarative5-quicklayouts-plugin,
26 qtdeclarative5-qtquick2-plugin,27 qtdeclarative5-qtquick2-plugin,
27 signon-plugin-oauth2 (>= 0.19-0~57~),28 signon-plugin-oauth2 (>= 0.19-0~57~),
2829
=== modified file 'debian/reminders-app.install'
--- debian/reminders-app.install 2014-01-30 13:45:37 +0000
+++ debian/reminders-app.install 2014-05-16 12:52:31 +0000
@@ -1,4 +1,5 @@
1usr/bin/*1usr/bin/*
2usr/share/accounts/applications/*
2usr/share/applications/*3usr/share/applications/*
3usr/share/locale4usr/share/locale
4usr/share/reminders/*5usr/share/reminders/*
56
=== modified file 'manifest.json'
--- manifest.json 2014-05-07 19:11:05 +0000
+++ manifest.json 2014-05-16 12:52:31 +0000
@@ -4,6 +4,7 @@
4 "architecture": "armhf",4 "architecture": "armhf",
5 "hooks": {5 "hooks": {
6 "reminders": {6 "reminders": {
7 "account-application": "com.ubuntu.reminders_reminders.application",
7 "apparmor": "apparmor.json",8 "apparmor": "apparmor.json",
8 "desktop": "com.ubuntu.reminders.desktop"9 "desktop": "com.ubuntu.reminders.desktop"
9 }10 }
@@ -19,4 +20,4 @@
19 "x-test": {20 "x-test": {
20 "autopilot": "reminders"21 "autopilot": "reminders"
21 }22 }
22}
23\ No newline at end of file23\ No newline at end of file
24}
2425
=== modified file 'src/app/qml/reminders.qml'
--- src/app/qml/reminders.qml 2014-05-10 09:22:59 +0000
+++ src/app/qml/reminders.qml 2014-05-16 12:52:31 +0000
@@ -24,6 +24,7 @@
24import "ui"24import "ui"
25import Evernote 0.125import Evernote 0.1
26import Ubuntu.OnlineAccounts 0.126import Ubuntu.OnlineAccounts 0.1
27import Ubuntu.OnlineAccounts.Client 0.1
2728
28/*!29/*!
29 \brief MainView with a Label and Button elements.30 \brief MainView with a Label and Button elements.
@@ -320,11 +321,17 @@
320 }321 }
321 }322 }
322323
324 Setup {
325 id: setup
326 applicationId: "com.ubuntu.reminders_reminders"
327 providerId: "evernote"
328 }
329
323 Button {330 Button {
324 objectName: "openAccountButton"331 objectName: "openAccountButton"
325 text: i18n.tr("Open account settings")332 text: i18n.tr("Add account")
326 color: UbuntuColors.orange333 color: UbuntuColors.orange
327 onClicked: Qt.openUrlExternally("settings:///system/online-accounts")334 onClicked: setup.exec()
328 }335 }
329 }336 }
330 }337 }
331338
=== modified file 'src/app/qml/ui/AccountSelectorPage.qml'
--- src/app/qml/ui/AccountSelectorPage.qml 2014-03-13 18:11:32 +0000
+++ src/app/qml/ui/AccountSelectorPage.qml 2014-05-16 12:52:31 +0000
@@ -20,6 +20,7 @@
20import Ubuntu.Components 0.120import Ubuntu.Components 0.1
21import Ubuntu.Components.ListItems 0.121import Ubuntu.Components.ListItems 0.1
22import Ubuntu.OnlineAccounts 0.122import Ubuntu.OnlineAccounts 0.1
23import Ubuntu.OnlineAccounts.Client 0.1
23import Evernote 0.124import Evernote 0.1
2425
25Page {26Page {
@@ -32,6 +33,12 @@
3233
33 signal accountSelected(var handle)34 signal accountSelected(var handle)
3435
36 Setup {
37 id: setup
38 applicationId: "com.ubuntu.reminders_reminders"
39 providerId: "evernote"
40 }
41
35 Column {42 Column {
36 anchors { fill: parent; margins: units.gu(2) }43 anchors { fill: parent; margins: units.gu(2) }
37 spacing: units.gu(1)44 spacing: units.gu(1)
@@ -51,6 +58,11 @@
51 onClicked: root.accountSelected(accountServiceHandle)58 onClicked: root.accountSelected(accountServiceHandle)
52 }59 }
53 }60 }
61
62 footer: Button {
63 text: i18n.tr("Add account")
64 onClicked: setup.exec()
65 }
54 }66 }
55 }67 }
5668

Subscribers

People subscribed via source and target branches