/srv/irclogs.ubuntu.com/2015/07/23/#ubuntu-app-devel.txt

=== chihchun_afk is now known as chihchun
dholbachgood morning07:10
didrockszsombi: hey! I have a small question vs theming/default property in QML08:29
didrockszsombi: I have a generic component which has a hilight property (and I change some other properties based on that)08:29
didrocksmy thought was to due something like:08:30
didrockscolor: hilight ? "white" : color08:30
didrocksfor instance08:30
didrocksbut then the color is black on my Label for instance, not the default ubuntu theme color08:30
didrocksI wan't to know if there is a best practice about "change this property only if this property has this value, otherwise leave default"08:30
didrocks(ideally not in onCompleted as this could be dynamic)08:31
didrocksdo you think it's a case for Binding { when: }?08:40
=== chriadam is now known as chriadam|away
davmor2popey: clock app,  I start in EN_US, I add Paris France as a City, I change the language to Espana Espana, The list of cities updates so Paris Francia is displayed, but the translation is still in EN_US on the actual clock page09:57
popeyeh?09:57
popeywhere did you change the language to Espana Espana ?09:57
davmor2popey: system settings, so you select the first Spanish setting under the English ones09:58
popeycan you do me a screenshot?09:59
popeyof where you're seeing something incorrect09:59
davmor2popey: system-settings → Language & Text → World map Display......09:59
davmor2popey: yeap firing it up one second10:00
popeyta10:00
davmor2popey:  In English on the main clock page http://people.canonical.com/~davmor2/paris-in-en.png in spanish on the add city list http://people.canonical.com/~davmor2/paris-in-es.png10:04
davmor2popey: it's like the city list in the clock face isn't translatable10:05
davmor2popey: does it make more sense now?10:08
popeynot really10:08
popeythe word "Paris" _is_ translated in your second screenshot10:08
popeyParis (english) is París (spanish) [note the accent over the i]  i -> í10:08
davmor2popey: and it is the sam language being used in both screenshots10:08
davmor2same even10:09
popeyoh I see10:09
davmor2popey: ie the first should look the same as the second10:09
popeygotcha10:09
davmor2popey: I'll write out the steps for you one second10:09
* popey checks existing phone10:09
popeyunlikely to be a regression10:10
popeydavmor2: yeah, confirmed it's the same on the version in the store10:13
popeywant me to write the bug up?10:13
popeyhttp://people.canonical.com/~alan/screenshots/device-2015-07-23-111416.png10:14
davmor2http://paste.ubuntu.com/11924502/10:14
popeyon my retail bq running stock clock10:14
davmor2popey: I can write up the bug, If it is in the current clock App I will let this one pass but obviously it will fail next time :)10:15
popeythanks davmor210:16
popeywill bring it up at the meeting later today if you do it before then :)10:16
davmor2popey: https://bugs.launchpad.net/ubuntu-clock-app/+bug/1477492  and I'll pass the click you gave me now :)10:22
ubot5Ubuntu bug 1477492 in Ubuntu Clock App "Cities not translated on the main clock page if language is switched" [Undecided,New]10:22
DanChapmanlooks like the city get's saved as a string to the clockDB in the current locale, so on replay of that after the locale change would still bring back the string for the original language.10:22
popeymagic, thanks Saviq10:22
popeyer, davmor210:22
popeysorry Saviq :)10:22
Saviqpopey, you're welcome anyway10:22
davmor2popey: Saviq and davmor2 how the hell did you even get those two crossed?10:23
mihirrenatu: ping10:23
Saviqdavmor2, we just looks so alike10:23
Saviq-s10:23
popeyfinger slightly to the left then pressed tab :)10:23
mihirrenatu: could you pelase review this MP https://code.launchpad.net/~gary-wzl77/qtorganizer5-eds/fix_1445577/+merge/264489 ?10:23
Saviqover-eager completion FTW10:23
popeymihir: see comment from DanChapman on that bug :S10:24
mihiri don't see DanChapman's comment :-10:25
mihirpopey: you talking about this bug right , https://bugs.launchpad.net/ubuntu-calendar-app/+bug/144557710:25
ubot5Ubuntu bug 1445577 in Ubuntu Calendar App "Edit of reminder vaults event time back x hours" [High,Confirmed]10:25
popeymihir: 11:22 < DanChapman> looks like the city get's saved as a string to the clockDB in the current locale, so on replay of that after the locale change would  still bring back the string for the original language.10:26
DanChapmanhttp://bazaar.launchpad.net/~ubuntu-clock-dev/ubuntu-clock-app/utopic-3.0/view/head:/app/worldclock/WorldCityList.qml#L353 looks like where the raw string is being saved10:27
popeythanks DanChapman10:27
davmor2DanChapman, popey: yeah that was my assumption on seeing it,  I figured it was just placing the string as it was somewhere and that collection was missing the translation part so the string wasn't updating on the fly as it were10:33
DanChapmanIt's definately an interesting one to solve :-)10:36
davmor2DanChapman: I would hope that QML/QT wuold be clever enough to understand the difference between x = "boo" and x = i18n.tr"boo"  and would save it to the database/dictionary whatever in the correct format right?10:41
davmor2DanChapman: if so then in theory it's a really trivial fix10:42
=== JanC_ is now known as JanC
=== _salem is now known as salem_
zsombididrocks: uuuh... sorry for late reply14:30
zsombididrocks: so you do color: hightlight ? "white" : color14:31
zsombididrocks: in here the LValue color is undefined, so it'll be black14:31
zsombiif you want to use the default color when the highlight is not set, use states14:31
zsombididrocks: like Label { id: label; states: State { name: "hilghlighted"; when: highlight; PropertyChange { target: label; color: "white" }}}14:33
didrockszsombi: no worry :) I think that's mostly how I handled it (with Bindings, which seems equivalent to state in that case for me), thanks!14:34
zsombididrocks: Bindings is not equivalent14:34
didrockszsombi: yeah, I'll use states here, makes more sense14:35
zsombididrocks: that also preserves the state, but it doesn't restore the original values properly14:35
didrocksindeed14:35
zsombididrocks: states do14:35
didrocksI'll use this then14:36
didrockszsombi: btw, I was wondering about how I can access to a property from an object id by its name (a string)14:36
zsombididrocks: if you know the id, and the property name, then simply <id>.<property>14:36
zsombididrocks: but you may get in trouble if the object with the id doesn't exist or the property is not found14:37
didrockszsombi: the thing is that I want to pass that as a parameter I guess this example will make more sense: http://paste.ubuntu.com/11925470/14:38
didrocksFoo.qml needs the property (and not the value of the property)14:38
zsombididrocks: Binding on <property>..... wow... weird way to use it ;)14:39
didrockszsombi: just an example to illustrate what I want to pass to it :)14:41
zsombididrocks: it would work, but remember, using var type for proerties does hurt in performance14:41
didrockszsombi: actually, it doesn't work :/14:41
zsombididrocks: so if you know the type you expect, you shoudl use that14:41
didrocksit does pass the value, not the property itself14:41
zsombididrocks: yes, the property won't be passed for sure14:41
zsombididrocks: you'd need the property name itself?14:42
didrockszsombi: is there a way from the object id and property name (as a string) to resolve to the property?14:42
didrockszsombi: I guess you are maybe doing something like that for the StateSaver14:43
zsombididrocks: in C++ there is :)14:43
zsombididrocks: you can enumerate the properties of a QObject14:43
zsombididrocks: also in JS14:43
zsombiso in QML as well14:43
didrockszsombi: sounds, hem :p14:43
zsombididrocks: for (var p in object) print(p)14:43
didrocksyeah, not that elegant I guess14:44
zsombididrocks: also, you can access the property in JS through <id>["property_name"] syntax14:44
didrocksoh, like any json object?14:44
* didrocks tries14:44
zsombididrocks: but you said you know the property name...14:44
zsombiyes14:44
didrockszsombi: yeah, that's exactly what I was looking for :)14:45
didrocksthanks a lot for your help14:45
didrocks(working well)14:45
zsombididrocks: awesome ;)14:46
ahoneybunrpadovani: are you around?15:14
rpadovaniahoneybun, at your disposal15:15
ahoneybunrpadovani: would you like my help with your blogs? English translations I mean :)15:15
rpadovaniahoneybun, :D If you want to correct my drafts I'll be more than grateful :-)15:18
ahoneybunok cool, want to me work on your newest blog post or help with your next one?15:18
rpadovaniahoneybun, I don't have any other blog post in mind atm, so if you work on my last one it would be awesome. Thank you *so* much15:20
rpadovanireally, I can't say how much I appreciate that15:21
ahoneybunI'll work on the Meizu MX4 OTA-5 one then15:21
ahoneybunI thank you for the updates about that device15:21
rpadovanithanks :-) I'll drop you an email when I'm thinking to a new article :-)15:21
ahoneybunawesome rpadovani I'll have this done in a few15:23
mzanettipopey, how about a hangout? :)15:33
popeyhey15:33
ahoneybunrpadovani: can you msg me your email?15:45
=== chihchun is now known as chihchun_afk
ahoneybunLook good rpadovani ?16:17
rpadovaniahoneybun, looks awesome, I already updated my website, thanks so much!16:20
ahoneybunNp rpadovani happy to help16:21
=== chihchun_afk is now known as chihchun
=== chihchun is now known as chihchun_afk
=== chihchun_afk is now known as chihchun
=== chihchun is now known as chihchun_afk
=== JamesTai1 is now known as JamesTait
mardykenvandine: hi! I'm trying to do something with the content hub, but I don't know if it's possible :-)18:19
mardykenvandine: when my app gets an incoming transfer, I want to show information on what is the source (application name and icon)18:19
kenvandineah...18:20
mardykenvandine: so, I have a ContentPeer {} element, and when I get an incoming transfer, I set its appId to transfer.source18:20
kenvandinewell, the appId of the source should be there18:20
kenvandineyeah18:20
mardykenvandine: when the source is webbrowser-app it doesn't work: no name or icon is loaded18:21
mardykenvandine: is it because it's not a click app?18:21
kenvandineshouldn't be18:21
kenvandineso...18:21
kenvandineit's possible that you need the appId when the ContentPeer is constructed18:21
* kenvandine doesn't recall offhand18:22
mardykenvandine: but even when not using the ContentPeer, I get this when trying to load the icon: QML ImageWithFallback: Failed to get image from provider: image://content-hub/webbrowser-app18:22
kenvandineElleo, ^^ do you think that should work with our image provider?18:30
kenvandinei think that might only work if the peer is created18:30
mardykenvandine: I wonder if it's because the webbrowser-app doesn't register itself as a CH source?18:45
kenvandinemardy, oh... perhaps19:07
mardykenvandine: so, if an app can save images (like the browser), but doesn't have a pool of images available to choose from, this app won't be a CH source, but it can still use the CH to send images to other apps, right?19:12
kenvandinemardy, right19:14
kenvandinebut it does it via download manager19:14
kenvandinei hands off the download19:14
kenvandineand download manager charges it19:14
kenvandinemardy, you can't pick content from the browser19:14
mardykenvandine: ah, so the webbrowser app doesn't talk to the CH directly?19:15
kenvandineit does to get a list of peers19:15
kenvandineand it's still the source of the transfer19:15
kenvandinebut it's special :)19:15
mardykenvandine: that is before or after the download has completed?19:15
kenvandinebefore19:15
mardykenvandine: OK, I need to study it a bit :-)19:17
kenvandinemardy, check with Elleo tomorrow, he knows more about the image provider19:17
mardykenvandine: ok, I will, thanks19:17
robert35Hi, is there a way to port the "qt-creator example project" 'CollidingMice' to run it on a ubuntu phone device emulator ?20:44
robert35up20:55
robert35otherwise said, is there a proper way to code C++ app without using (or not to much) Qml ?20:56
kalikianarobert35: I don't know what example you're talking about. But you'll need some QML to bring up graphics. You can't use traditional QtWidgets. Unless of course you go all openGL(ES) or SDL20:57
robert35yes a litlle bit is not a major problem, but i want my app to be structured from c++ , not from qml20:58
kalikianaI'd suggest to try the QML app with a C++ plugin in QtCreator20:59
robert35the exampl app is available within qt-creator ide (on the example tab)21:00
kalikianaat least to get an idea of how it can work21:00
kalikianaand you can just as well do the reverse, C++ app with QML UI21:00
kalikianait's a matter of taste21:00
robert35i ll give it a try...let see21:01
=== chihchun_afk is now known as chihchun
=== salem_ is now known as _salem

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