=== _salem is now known as salem_ [01:50] popey: not yet, I'm still waiting on mandel to get it to me === chriadam|away is now known as chriadam === salem_ is now known as _salem [02:25] Are there any resources on building application indicators? All the documentation seems to have been taken off developer.ubuntu.com === fginther is now known as fginther|away [04:08] man, I'm so happy with the QZ81 app... it even has the TK85 keyboard! Having the emulator for my first computer in my pocket is so so awesome! === chihchun_afk is now known as chihchun === dpm-afk is now known as dpm [06:03] good morning === oSoMoN_ is now known as oSoMoN [07:15] mzanetti, morning! I built upon your changes to switch between production and sandbox and I now have a branch that generates separate packages, one for each plugin: https://code.launchpad.net/~dpm/reminders-app/switch-to-production/+merge/224503 - the only place I still see we're hardcoding the UOA provider is here: http://bazaar.launchpad.net/~reminders-app-dev/reminders-app/trunk/view/head:/src/app/qml/reminders.qml#L132 - so I guess w [07:15] e need to pass through the --sandbox argument to the main qml file too. What's the best way to do this? [07:54] dpm: hi [07:54] just reading your mail... not really following tho [07:57] hi mzanetti, so in here: QString hostname = m_useSandbox ? EVERNOTE_SANDBOX_HOST : EVERNOTE_HOST; it seems we might be able to just read the hostname using the Online Accounts API, rather than checking the sandbox argument [07:58] dpm: how would you do that? [07:58] dpm: I've seen the "account->value()" thing.. [07:58] but: where to get the "account" from? [07:58] that's where we ask mardy for documentation on how to use the Online Accounts API in C++ :) ^ [07:59] dpm, mzanetti: if you want, you can do the same from QML; or do you need C++? [08:00] dpm: so what I mean... we're using the QML api for it... I don't think its a good idea to connect to another api from 2 different points [08:00] mardy: oh yeah, that'd be better [08:00] mardy: qml, that is [08:01] mzanetti: http://developer.ubuntu.com/api/qml/sdk-14.10/Ubuntu.OnlineAccounts.AccountService/ [08:01] so I get the hostname... along with the selected accounts. ok. works for me [08:01] mzanetti: read the "settings" property [08:01] mardy: ack, thanks [08:02] mzanetti: something like accountService.settings.hostname (if the key is called hostname) [08:02] yep... will figure it [08:02] mzanetti, mardy, I'm not too sure how to do it via QML. We're shipping 2 plugins (sandbox, production), and their service names are different (evernote vs. evernote-sandbox). [08:02] mzanetti: I think that in that case the needs to be added to the .service file, not to the .provider file [08:02] we're not using the hostname from QML atm [08:03] so we'd still need a way to switch services in QML [08:03] dpm: not sure what you mean [08:03] mzanetti, http://bazaar.launchpad.net/~reminders-app-dev/reminders-app/trunk/view/head:/src/app/qml/reminders.qml#L132 [08:03] dpm: if we have 2 plugins, each of them has a url hardcoded... [08:03] dpm: the user selects an account. we get a pointer to that account and read the hostname associated with that [08:03] right, but from QML we're not accessing the host url, we specify services [08:04] but didn't mardy just tell us a way to get to the host url? [08:04] mzanetti, yes, but we're not using the host URL in QML [08:05] well, we're not right now... but if I get that information I'd change my branch in a way to use that instead of the bool useSnadbox flag [08:07] mzanetti, right, and I'm not debating that. What I mean is that in QML selecting the host name will not be enough to switch providers, as the QML API needs to specify "service" to load the values from the right .service file (we install both evernote.service and evernote-sandbox.service) [08:07] dpm: yeah sure... you select an account [08:07] dpm: and we'll use the hostname associated with that account [08:08] we're not letting the user to select the hostname in the reminders app [08:08] maybe I'm still misunderstanding :/ [08:09] mzanetti, yeah, yeah, I get that, but regardless of the host name, what's not clear to me is how we select an account in QML (evernote vs.evernote-sandbox) [08:10] dpm: we have the 2 plugins installed. When you open the accounts settings page to add a new one, you'll see it twice in there [08:10] mzanetti, yes, that's clear. What I don't know is how we switch between them in the app [08:10] dpm: ah... if you have multiple accounts, we already pop up a dialog which lets you select the account [08:10] iirc. [08:11] so when the reminders app starts up and there are multiple possible accounts, you'll get a list to select which account you want [08:11] and that list will contain sandbox and production server accounts [08:12] Oh... I guess I see your point... we can't get both account types in one list [08:12] is that what you mean? [08:13] mzanetti, exactly: http://pastebin.ubuntu.com/7704704/ [08:13] ok.. got it now [08:14] mardy: any chance there's a way to get an AccountsServiceModel containing accounts from multiple services? [08:14] dpm: right... worst case we'll just go with the -s switch [08:14] as you already wrote [08:14] mzanetti, yeah, that might be an option [08:25] mzanetti, I've replied to your comment on https://code.launchpad.net/~dpm/reminders-app/switch-to-production/+merge/224503 - mardy, do you have any ideas on that (see last comment)? [08:32] dpm: commented [08:35] thanks mardy [08:37] dpm: yep, what mardy wrote would be my suggestion too. "building" the same code twice with different flags to replace key and hostname at build time [08:40] mzanetti, mardy, that sounds sensible to me too, and I understand how the key and hostname can be replaced. However, we still need two sets of files to be installed, right? http://pastebin.ubuntu.com/7704802/ [08:40] dpm: yes, I think so [08:40] dpm: yes. having it installed twice is ok. but not having to maintain the code twice [09:01] mardy: hmm... the settings object seems to be empty here [09:02] at least JSON.stringify(accountService.settings) gives me just {} [09:02] mzanetti: weird! Can you push the branch somewhere? [09:03] mardy: yep. lemme just do one more check first [09:07] mardy: https://code.launchpad.net/~mzanetti/reminders-app/use-production-servers/+merge/224499 [09:08] mardy: line 42 [09:09] afaiu it should contain things like "RequestEndpoint" and such [09:09] is that correct? [09:11] mzanetti: so, the fact is that the