[03:40] is there a way to ship js files with ubuntu touch app? I can't seem to find them [05:01] is it possible to write to external sd card? [06:30] hello [09:30] Morning everyone. Does anyone know if there's any kind of unique device ID I can get from QML? I was hoping to use the IMEI, but if I'm interpreting this bug report correctly, we're not allowed that information. https://bugs.launchpad.net/ubuntu/+source/qtsystems-opensource-src/+bug/1226844 [09:30] Launchpad bug 1226844 in qtsystems-opensource-src (Ubuntu Trusty) "QtSystemInfo fails when using ofono and there are DBus denials to ofono" [High,Won't fix] [09:31] Also related https://bugs.launchpad.net/ubuntu/+source/qtcreator-plugin-ubuntu/+bug/1338420/ [09:31] Launchpad bug 1226844 in qtsystems-opensource-src (Ubuntu Trusty) "duplicate for #1338420 QtSystemInfo fails when using ofono and there are DBus denials to ofono" [High,Won't fix] [13:35] in order to write to sdcard the only way to do it is using content exchange (which is not documented enough)? [13:35] snizzo, o/ [13:36] ehr, is it a yes? [13:36] snizzo, erm I don't own a device; sdcard is not hte internal card, correct? [13:37] AkivaAvraham: mm well makes no difference to me, I'd just like to write to some folder scanned by music app [13:37] but write permissions are impossible to get because i have to use this content exchange(?) [13:38] snizzo, Because I have only tested this on the desktop; take that into consideration. However; utilizing terminal commands, I have been able to write to folders such as music. [13:38] I wish I knew if it worked on a device. [13:39] snizzo, but do you understand what I mean? like , "echo "happy" > ~/Music/stupid.txt" I recall working [13:39] yeah on desktop it works [13:39] snizzo, do me a favour? [13:39] on ubuntu touch on a device it says you need special permissions [13:39] yeah, tell me [13:40] snizzo, if you get the answer, can you write it down or something and send it to me? I want to add it to a faq and post it on the subreddit. [13:40] AkivaAvraham: sure! [13:40] snizzo, http://www.reddit.com/r/ubuntuappdev also if you have a screenshot of your app, [13:41] Please post it here! I'd love to see what you are working on, and it will help foster the community. [13:44] AkivaAvraham: ok I'll do it. I think it won't be published due to permissions trobules btw. Also this thing of "use our qml components" to save files actually breaks model/view structure too deeply to be mantained efficiently imho (I have same code for qt android version). [13:46] snizzo, is there now a qml component provided by ubuntu (or qml) for saving files to disk? [13:47] AkivaAvraham: for what I've seen, there's some kind of content-exchange (this is the name of permission required also) which enables your app to import/export data from other apps and this should be the right way to save music: sending it to the music app i guess that saves it. [13:48] snizzo, Its not the database is it? [13:48] the u1db or whatever? [13:48] snizzo, sending the music app a file via content-hub will save it in ~/Music/Imported ... if thats what your asking? [13:48] ahayzen, << much more pro than I. :) [13:48] ahayzen: more less yeah [13:48] and music app will read from that folder right? [13:48] ahayzen, << also works on the music app, so he should know [13:49] snizzo, what are you trying to do? (i've missed the start of the conversation) [13:49] ahayzen: I have an app, mostly working that downloads music in mp3 format. [13:49] is it true that directly saving files on Music folder is not the right approach? [13:50] snizzo, i don't think you'll be able to get permission to save into ~/Music ? ... so currently your best bet will probably be to just export the files to the music app which will then put them in ~/Music/Imported [13:51] note you can send multiple at a time as well [13:51] * ahayzen tries to remember if it starts playing them or just queues them [13:52] ahayzen: ok, that's fine for me. Only thing is I use C++/QML and I'm using a C++ model that holds a list of objects that actually downloads the file, so download is handled via C++ code. What's the best approach to "export" those files? [13:52] yeah it'll queue then and then start playing the first one [13:53] snizzo, you'll want to do this via content-hub ... https://developer.ubuntu.com/api/qml/sdk-14.10/Ubuntu.Content.index/ [13:53] Can I do it via C++ or must I use qml? [13:54] snizzo, erm i'm not sure if you can do it via c++ when kenvandine is around he would be the person to ask that probably [13:55] ahayzen: ok... [13:55] snizzo, there is probably a way :) [13:55] ahayzen: anyway, can I ask you just to provide a small example of qml exporting a music file? Like the example in the doc. [13:56] also not perfectly working, just to have a clue [13:56] .... this is one example of an exporter (you just have to change the type to Music) https://code.launchpad.net/~ken-vandine/+junk/hub-exporter [13:57] i also know 'downow' have an exporter to Music as well [13:58] snizzo, ^^ theirs is in mostly c++ so may be interesting to look at http://bazaar.launchpad.net/~nogzatalz/downow/trunk/files/head:/src/downow/ [13:59] snizzo, note in the folder ui/ there is ContentHubOpener.cpp [14:02] ahayzen: these helps for sure! [14:03] snizzo, let me know if you have any issues :) [14:04] ahayzen: in order to ship files with the app (in my case a js file not included by any other file) what should I do, and how can I open in in readonly mode on the phone while the app is running? [14:04] I mean, where will it be installed [14:06] is it right to hardcode /opt/click.........myapp.../current/file? [14:06] snizzo, you would need to put it in the click package...they all go in /opt/click.ubuntu.com/com.ubuntu.developer.your-name.your-app/current/ IIRC ...but can you not access it relatively or via some env var? [14:07] ahayzen: I use this file to be evaluated by QJSEngine via C++ [14:07] it seems crazy but has its sense :) [14:07] ok then no problem :) thanks for the assistance [14:07] snizzo, hmm usually in qml i just put the relative path and then wrap Qt.resolvedUrl() around it [14:10] ahayzen: I hope not to take too much time, I'll try to produce some faqs docs in order to benefit everyone also [14:11] snizzo, cool :) we don't seem to have many docs on developer.ubuntu.com for c++ from what i can see [14:12] ahayzen: Yeah I noticed :) just for curiosity, do you work for canonical? [14:12] snizzo, nope, i'm a student at university :) [14:13] hehe, same fate then :) [14:13] hah [14:13] mhall119, is there any reason why we don't have any c++/qt docs on developer.ubuntu.com? (or am i just blind) [14:17] I think it's not their main target platform however. Qt is enought well documented and they aim to make use qml components instead of c++ for apps. Just speculations ofc :) [14:18] yeah i guess [14:21] ahayzen, speak of the devil [14:22] ahayzen, there is an incredibly good one provided by ics [14:22] they do documentation for c++ too. [14:22] I was just happening to throw together documentation on the subreddit about it. [14:22] AkivaAvraham, hehe yeah :) [14:22] ahayzen, wip http://www.reddit.com/r/UbuntuAppDev/comments/2qy5ko/guide_for_new_ubuntu_developers/ [14:23] scroll to the bottom, and there is a "Learn c++ the qt way" [14:23] AkivaAvraham, i mean the scopes are c++ IIRC ? ... i just wonder if it would be useful even just have a few tutorials of extending QML with c++ on developer.ubuntu.com [14:23] I have hated all other c++ docs, because they will teach you how to use standard libs that are ultimately replaced by qt. [14:24] ahayzen, oh yah; the scopes need documentation. [14:24] ahayzen, I popped into there, and I really really wanted a flowchart of how this was supposed to operate [14:24] hah [14:25] ahayzen, you know what I mean? [14:25] yeah [14:25] maybe I'll make one if I ever gain the courage; I have a good way of making flowcharts :) [14:25] i usually use Dia for diagrams :) [14:26] ahayzen, screenshot? [14:26] ahayzen, I created a template in google spreadsheets [14:26] AkivaAvraham, its a gnome app for doing flowchats/UML/Entity diagrams etc https://wiki.gnome.org/Apps/Dia/Screenshots [14:27] oh that ones pretty nice [14:27] sec [14:28] ahayzen, https://docs.google.com/spreadsheets/d/1Hv6GY0SjyGreuuNziK_1HmTJy6p69gmyNtjFV4yxiVk/edit#gid=381944632 [14:28] I like having it on google docs, cause its easy to edit with multiple people [14:28] AkivaAvraham, yeah thats pretty cool :) [14:29] thanks :) [14:32] ahayzen: which university if I may ask? [14:33] snizzo, Oxford Brookes University [14:58] ahayzen: I can't really understand how to send files via content hub [14:59] snizzo, how far have you got? [15:00] near zero. I can't get how it's structured and what does what since there's really no docs apart from Component names [15:01] ah wait maybe I found something [15:01] snizzo, these two may help https://developer.ubuntu.com/en/apps/platform/guides/content-hub-guide/ https://developer.ubuntu.com/api/qml/sdk-14.10/Ubuntu.Content.index/ [16:40] ahayzen: I somewhat managed to do an export but I have no reaction by the system nor the music app... [16:40] should I specify in handler or peer the music app? [16:42] this is the code I'm using http://pastebin.ubuntu.com/9671823/ [17:55] snizzo, are you doing this on a device? or unity8? [18:06] ahayzen: nexus 5 [18:07] snizzo, ok was just checking you weren't trying to do it in unity7 ;) [18:07] ahayzen: my current code http://pastebin.ubuntu.com/9672284/ [18:12] snizzo, it looks mostly right.... so far i've spotted this possibly missing? onExportRequested: { root.activeTransfer = transfer; .... (i'm just comparing yours to this one http://bazaar.launchpad.net/~ken-vandine/+junk/hub-exporter/view/head:/hub-exporter.qml) [18:13] ahayzen: ok. that btw should work because it pops up the dialog "exporting" but no onExportRequested triggered [18:13] and no file is copied [18:13] snizzo, hmm so does Music appear as an option? or does it not get that far? [18:15] ahh mm no Music doesn't appear as an option it just says "exporting" for a second and then disappear, I think because the operation ends [18:15] snizzo, you should get a dialog appear inwhich you then select to 'open with' music [18:16] ahh no I can't go that far [18:16] what is worse is that no error is shown... [18:17] hah yeah i remember trying to figure all this out when we were adding import support lol [18:20] ahayzen: ah :) any hint on this? I asked just content_exchange_source as permission. Is that right? [18:21] snizzo, yeah content_exchange_source is the policy you want :) [18:22] ahn, I'm running out of bullets... [18:22] snizzo, always save one [18:22] snizzo, i think your missing a ContentPeerPicker {} ? [18:22] ahayzen: AH! that could be! [18:23] snizzo, basically i think your missing the picking bit here.... http://bazaar.launchpad.net/~ken-vandine/+junk/hub-exporter/view/head:/hub-exporter.qml#L393 [18:43] ahayzen: lol it seems it's working finally :D [18:44] snizzo, \o/ [18:57] really thank you for help ahayzen. I'll try to put down a tutorial on what I understood :) [18:57] snizzo, no problem :) its good to see more apps making use of it :) [18:57] snizzo, if you do a tutorial, please link it [18:57] snizzo, i'd like to put it on appdev [18:57] AkivaAvraham: sure :) [18:58] thanks [19:20] Cya [19:20] Zakabanner, bye? [19:40] Happy New Year everyone! [19:40] mzanetti: here by any chance? [20:07] ahayzen: the "canonical" developer story is to write pure QML applications without C++. Of course the situation is that for any non-trivial applications some small amount of C++ is often also required. So I agree there should be some pointers in the documents to get started with that. [20:29] mivoligo, Happy new year. [20:41] mivoligo: hey [21:04] I already asked this morning, but I figured I'd ask again in case someone's here now that wasn't before. Does anyone know if there's any kind of unique device ID I can get from QML? I was hoping to use the IMEI, but none of the DeviceInfo methods seem to return anything. [21:07] TommyBrunn, o/ [21:07] TommyBrunn, you mean the phone model? [21:07] TommyBrunn, or rather if it is a desktop / tv / mobile device? [21:07] No, the imei is unique per physical device [21:07] As in, your phone's imei is different from mine [21:08] Even if we both have the same model [21:08] TommyBrunn, oh like a mac address? [21:08] Pretty much [21:08] * AkivaAvraham is trying to remember if that is right.. [21:08] TommyBrunn, good question... [21:09] \o btw, didn't mean to leave you hanging there. High five. [21:09] TommyBrunn, heh [21:10] TommyBrunn, now I presume you need a unique id for databasing? [21:12] It's for usage metrics. Each event has a user id associated with it, so that you can connect different events with each other (useful when you want to figure out stupid UI stuff, like why some users drop out at a certain point of a form, for example). It doesn't actually have to mean anything, it just has to be unique per device. [21:13] So the imei would have been perfect. [21:23] ajalkane, i just think a few examples showing how you can extend QML with c++ could be of use, or at least linking to the qt docs [21:24] ahayzen: Indeed that, and how to do the main.cpp so that you can have C++ driven QML application [21:24] TommyBrunn, okay interesting... [21:24] ajalkane, as it mentions extending qml with c++ here .. https://developer.ubuntu.com/en/apps/qml/ ... but then doesn't link you to any docs/further reading [21:24] ajalkane, yeah and that :) [21:24] TommyBrunn, my suggestion sucks, because you probably thought of this, but is there a qt function that does this? [21:24] there must be? [21:24] Yes. And it doesn't return anything. I'm guessing it's a permissions thing [21:25] QtSystemInfo [21:25] There's a DeviceInfo component that has a bunch of methods for getting information about the current device. [21:25] mzanetti: hey [21:25] TommyBrunn, what about a mac address though? [21:25] http://stackoverflow.com/questions/15287814/getting-mac-id-in-qt [21:26] I mean this is for networking, so shouldnt it work? [21:26] mzanetti: I see you're busy with the game :) [21:26] mivoligo: hi. I've been creating some levels, yes [21:26] I think every internet device comes with a unique mac address, unless I am mistaken. [21:26] mivoligo: the game is now playable up to level 18 [21:26] It might, but now we're extending QML with C++ to re-implement a module that already exists :P [21:26] mzanetti: I was totally lazy over the holiday [21:26] I'm going to file a bug and see if it is a bug or if it's intentional. [21:27] TommyBrunn, there is a module in qml to grab mac addresses? [21:27] mzanetti: but I have an idea for the next levelpack :) [21:28] ah appears there is. [21:28] TommyBrunn, wish I was better help :) [21:28] Yes [21:28] TommyBrunn, it is sunday so... you should ask at the next Q&A [21:29] mmmm speaking of which [21:29] No worries. I was just hoping there would be someone here who's had the same issue. They do use the SystemInfo module in a core app, so it should work somehow [21:29] mhall119, http://ubuntuonair.com/calendar/ -- empty. [21:30] mivoligo: oh :D but you need someone else to write the json for it :D [21:30] mzanetti: I'll try myself :D but not sure when [21:31] mivoligo: that'd be cool. but otoh, I'd need your graphic skills with some other games too :D [21:31] mzanetti: \o/ happy to help [21:32] mivoligo: not ready yet, but there are some things upcoming. I really want to finish this one first [21:32] mzanetti: great :) About this bug https://bugs.launchpad.net/machines-vs-machines/+bug/1407486 [21:32] Launchpad bug 1407486 in Machines vs. Machines "Tower destruction icon missing" [Undecided,New] [21:33] mzanetti: do you have any idea in mind, I was thinking about putting just big $ sign there [21:33] mivoligo: hmm... there's already $ sign in the price tag [21:34] for some reason I had an arrow in mind [21:34] pointing downwards [21:35] maybe a trash can? [21:35] mzanetti: ok, I'll try something tomorrow [21:36] mivoligo: https://encrypted.google.com/search?tbm=isch&q=tower%20defense%20destroy%20tower&tbs=imgo:1#tbs=imgo:1&tbm=isch&q=destroy+icon [21:36] mzanetti: there's destroyed old Ubuntu logo there :D [21:36] yeah :D [21:37] mzanetti: trash can idea might be the more understandable [21:38] yep, that sounds reasonable [21:38] the most [21:38] mzanetti: btw what do you think about the new destruction animation? [21:38] love it [21:39] I was unsure at first about it [21:39] didn't really like the spirals and the colors [21:39] but now I played it for a while and it's quite cool [21:39] one issue with it is that it should be part of the level pack [21:39] so a different level pack can define other images [21:39] mzanetti: true [21:40] I'll move it over [21:40] :) [21:40] mivoligo: I started to create the tutorial level pack today [21:40] and decided to give that up [21:40] seems too much work for too little gain [21:41] mzanetti: I think so too [21:41] it's not that hard to understand [21:41] yep [21:42] mzanetti: back to destroy animation, I noticed it somehow goes faster for the Boing guys [21:42] really [21:42] * mzanetti checks [21:45] indeed [21:45] and it's smaller :D [21:45] what the... [21:46] mzanetti: animation for Boings is faster, so maybe that's the problem? [21:46] most likely, yes [21:47] mzanetti: I have to finish now, sorry :( [21:47] mivoligo: no problem [21:47] see you around [21:47] mzanetti: see you [21:56] I need help with using the bootsplash [22:09] ahoneybun, as in the one for an app? [22:10] I haven't actually implemented it myself yet, but maybe I can be of help, ahoneybun [22:10] What's the problem? [22:22] ahayzen, yea [22:22] when you click it [22:22] someone gave me a link to the page about them but I cant find it [22:22] ahoneybun, what do you when to do ? eg show text in the header? or something in the centre? [22:23] https://lists.launchpad.net/ubuntu-phone/msg09996.html [22:24] ahoneybun, this one? https://lists.launchpad.net/ubuntu-phone/msg09996.html [22:24] oh TommyBrunn beat me [22:24] You add those values to your .desktop file. For example https://bit.ly/1vOO5lc [22:25] yup :) [22:25] TommyBrunn, I think thats what I needed [22:26] thanks TommyBrunn and ahayzen [22:26] ahoneybun, no problem [22:26] You're welcome [22:27] ahayzen, TommyBrunn http://pastebin.ubuntu.com/9673585/ [22:29] ahoneybun, you may want to add X-Ubuntu-Splash-Title=MyTitle and/or X-Ubuntu-Splash-Color=#111111 as well [22:31] ahayzen, ok thanks [22:32] ahayzen, http://pastebin.ubuntu.com/9673610/? [22:32] ahoneybun, note the #111111 is the hex colour ;) so that would be a very dark grey [22:33] yea I knew it was a color did not know it was dark [22:33] ahoneybun, you probably want it set the same colour as whatever your first page is [22:33] it is the default color for a ubuntu touch app [22:34] ahoneybun, then you can probably leave that row out? i think it picks the same as default [22:34] ok cool [22:34] ahoneybun, otherwise that *should* work :) [22:34] should lol [22:34] never have been able to push a app from the sdk to my phone [22:35] but that is for another time (running android at the moment) [22:35] wow really? [22:35] ahoneybun, can you build a click? [22:35] of what my app? [22:35] yeah [22:36] if I do the command [22:36] in the terminal never have used the sdk to do it [22:36] ahoneybun, yeah then push that across to adb push /path/to/my.click /tmp/my.click .. then do ... adb shell pkcon install-local --allow-untrusted /tmp/my.click [22:36] in the Publish tab I can only validate a package [22:36] ahoneybun, to install it manually [22:36] no building [22:37] ahoneybun, sounds like your kits aren't setup properly ... but you can do the above ^^ right for testing? [22:38] ahayzen, I guess [22:38] I just have a desktop kit installed right now [22:38] took forever [22:38] ahoneybun, yeah you need to setup an arm one [22:38] yea [22:38] ahoneybun, then you switch to that when you want to deploy to the device [22:38] oh [22:39] ahoneybun, where the icon of the computer is on the bottom left you can click it and switch when you have them set up correctly [22:39] yea I got that before [22:40] been switching between my app and the showcase one [22:41] ahoneybun, this may be of use if you haven't seen it before https://developer.ubuntu.com/en/start/ubuntu-sdk/using-device-kits/ [22:41] how do I add a kit? other then the project tab [22:41] ahoneybun, click "manage kits" on the project tab [22:42] ahoneybun, then add from that settings dialog [22:42] but then I have to set everything by hand [22:42] ahoneybun, although i've never done it that way... i used that helper thing at first startup [22:42] oh [22:43] yea that think [22:43] g [22:43] ahoneybun, go to 'Ubuntu' section within that dialog on the left... [22:43] ahoneybun, then 'create click target' [22:43] alright downloading [22:44] \o/ now wait a loooooong time :) [22:44] * ahoneybun wishes he had a Nexus 7 [22:44] trust me I know lol [22:44] lol [22:44] I bought a Nexus 7 the other day, to use for development. [22:44] Turns out it was the 2012 model that isn't supported anymore ;_; [22:44] ahayzen, sometimes I need google maps for driving [22:44] yea I had the 2012 one [22:45] sold it to my brother since it is no longer supported [23:14] hi [23:14] Do you guys know of a QML app that adds calendar events? The documentation is a little sparse: https://developer.ubuntu.com/api/qml/sdk-14.10/qtpim.tutorials-qmlorganizerListView-part2/ [23:14] Hi diego7319 [23:14] api? [23:15] https://developer.ubuntu.com/api/qml/sdk-14.10/QtOrganizer/ [23:16] TommyBrunn, does the default calendar app use just QML? [23:16] TommyBrunn, https://code.launchpad.net/ubuntu-calendar-app [23:18] Thanks. I'm looking it through now. Looks like it uses QtOrganizer, yeah. [23:26] i dont know html5 or qml idk how i found it LOL