/srv/irclogs.ubuntu.com/2016/06/23/#ubuntu-app-devel.txt

=== chihchun_afk is now known as chihchun
=== athairus is now known as afkthairus
dubstar_04Good morning!! Any DownloadManager experts?06:46
=== tsdgeos_ is now known as tsdgeos
dubstar_04Good morning!! Any DownloadManager experts?08:20
popeydubstar_04: i think Elleo and kenvandine are the ones I'd point to :)08:44
dubstar_04popey: Thanks08:51
popeyken will be asleep right now tho08:52
dubstar_04Elleo: kenvandine: I can download items using the download manager. when i select the download in the filetransfer indicator my app opens but there doesnt seem to be a way to handle the file or tell what triggered the app to open.08:52
dubstar_04I was expecting this to be handled by the contentHub transfers. Am I missing something?08:53
dubstar_04popey: hopefully he will see it later.08:54
popeyyou could look at other apps which receive files like docviewer?08:55
popeyor music?08:55
dubstar_04popey: doc viewer uses this: https://developer.ubuntu.com/api/apps/qml/sdk-15.04.4/Ubuntu.Components.UriHandler/09:04
dubstar_04thanks!!09:04
kalikiana_t1mp: You need to update components.api https://code.launchpad.net/~tpeeters/ubuntu-ui-toolkit/apl-header-height/+merge/29816609:21
t1mpright09:22
t1mpthanks :)09:22
krampstudioHi, I need some help in ubuntu touch scope  development in JS.09:26
krampstudioI don't get how I can add filters to the scope09:26
krampstudiohttp://paste.ubuntu.com/17737732/09:28
krampstudionear line 3809:29
krampstudioany appdevs?09:40
rpadovanidavidcalle, ^^09:42
=== _salem is now known as salem_
davidcallekrampstudio: hi, let me have a look!10:28
davidcallekrampstudio: there is a pretty good example here http://bazaar.launchpad.net/~marcustomlinson/unity-js-scopes/filters_example/view/head:/examples/filters/src/filters.js10:32
davidcallekrampstudio: you can disregard lines 42>343, this part is just creating fake results to display10:32
davidcallekrampstudio: if you are still blocked with the example, try pinging marcustomlinson about it in #ubuntu-touch, he is the author of the example and maintainer of the JS api10:34
krampstudiothanks davidcalle10:44
krampstudioI'll let you know10:44
=== chihchun_afk is now known as chihchun
=== davidcalle is now known as davidcalle_afk
=== afkthairus is now known as athairus
=== javiercrowsoft1 is now known as javiercrowsoft
=== javiercrowsoft1 is now known as javiercrowsoft
=== JanC is now known as Guest91547
=== JanC_ is now known as JanC
Dubstar_04kenvandine: are you about?20:14
kenvandineDubstar_04, yup, what's up?20:14
Dubstar_04I was wondering if you could help me with some contenthub stuff?20:14
kenvandinesure20:15
Dubstar_04I would like to get the 'real' filename of the file being received in onImportRequested:20:16
Dubstar_04is that possible?20:16
Dubstar_04the transfer url seems to have extra formatting in.20:17
kenvandinewhat do you mean by "real"20:17
kenvandineit's just a QUrl20:17
Dubstar_04so the 'real' filename would be 'myawesomefile.ext'20:18
kenvandineok20:18
kenvandineQUrl provides api for that kind of thing, but I don't think it's exposed via qml20:19
Dubstar_04the url.toString() gives the path to the file but the filename is /myawesomefile_-_3289892383879.ext20:19
kenvandineit would probably be safe to split on '/' an use the end20:20
Dubstar_04it would be cool if i could do url.fileName and i get the real filename20:20
Dubstar_04or transfer.items[i].fileName20:21
kenvandinethe fileName is usually not very useful without the path20:21
kenvandinebut i guess for display ?20:21
Dubstar_04I want to open the file in my app and display the correct name. the user can then save the file if they wish.20:22
kenvandineyou could look at filemanager-app to see what they do for parsing paths/files20:22
Dubstar_04i could regex it but if some crazy person uses _-_ in the filename i could end up with all sorts of weird results?20:24
kenvandineit should be safe to just split on '/'20:24
kenvandinea filename won't have that20:25
kenvandinethen use the last item in the array20:25
Dubstar_04this is the url file:///home/phablet/.cache/design.marthamengineering/HubIncoming/1/JamesLineCircle_-_360808331247353977.dxf20:26
kenvandineright20:27
kenvandinesplit('/')20:27
Dubstar_04the original filename was JamesLineCircle.dxf20:27
kenvandineoh...20:27
kenvandinecontenthub didn't add the _-_36080833124735397720:28
Dubstar_04oh20:28
kenvandineDubstar_04, content-hub itself doesn't change the file name20:28
kenvandinethe app creating the transfer must be20:28
Dubstar_04kenvandine: double oh20:28
Dubstar_04maybe this is coming from telegram then?20:28
kenvandinehas to be20:29
Dubstar_04I have been sharing files using telegram and opening them from there.20:29
kenvandinecontent-hub isn't doing it20:29
Dubstar_04great!! simple solution.20:29
kenvandine:)20:29
Dubstar_04thanks.20:29
Dubstar_04next question;20:29
kenvandinenp20:29
Dubstar_04do items clicked in the filetransfer indicator go through content hub?20:30
kenvandineDubstar_04, depends :)20:30
kenvandinedownloads from the browser?20:30
kenvandineDubstar_04, the answer is not automatically20:30
Dubstar_04so i use downloadmanager to download a file. when its complete i want to click the item in the indicator, it opens my app but i dont know how to handle it.20:31
Dubstar_04no browser involved.20:32
kenvandinei think your app would need to create the transfer as well as the download and reference them20:32
kenvandineElleo, ^^20:32
kenvandineDubstar_04, Elleo had done that work20:33
kenvandinethe transfer object can have the download ID20:33
* kenvandine doesn't remember how it works :)20:33
Dubstar_04Yeah its not clear in the docs and i can't find any examples.20:34
kenvandinei'm actually not sure if that is available in the QML API20:34
kenvandineit was done for the browser20:34
Dubstar_04kenvandine: thankyou.20:47
kenvandineDubstar_04, sorry i couldn't help more, Elleo will be around in the morning20:47
Dubstar_04kenvandine: you have been a lot of help.20:49

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!