now gear container always has focus

added QTimer
start requestFocus() 300 ms delayed after Page is created
set FocusRetentionPolicy.LoseToFocusable to gear container
--> now we can remove the Button to re-focus :)
Am 02.10.14 20:36, schrieb Tim Windsor:
>
> In gears/assets/main.qml:
>
> > @@ -15,6 +15,7 @@
> >   */
> >  
> >  import bb.cascades 1.3
> > +import my.library 1.0
>
> @ekke <https://github.com/ekke> what's this line here for?
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/blackberry/Cascades-Samples/pull/31/files#r18358344>.
>
here's the corresponding vode from applicationui.cpp

    // need the QTimer to call requestFocus() AFTER the Page was created
    qmlRegisterType<QTimer>("my.library", 1, 0, "QTimer");



-- 

ekke (ekkehard gentz)

BlackBerry Elite Developer
international development mobile apps for BlackBerry 10
workshops - trainings - bootcamps

independent software-architect
senior erp-consultant

max-josefs-platz 30, D-83022 rosenheim, germany
mailto:ekke@ekkes-corner.org
blog: http://ekkes-corner.org
apps and more: http://appbus.org

twitter: @ekkescorner
skype: ekkes-corner
LinkedIn: http://linkedin.com/in/ekkehard/
Xing: http://xing.com/profile/Ekkehard_Gentz
Steuer-Nr: 156/220/30931 FA Rosenheim, UST-ID: DE189929490