[Qt-qml] Popups and Keyboard Focus

Vinayakam Murugan mvinayakam at gmail.com
Fri Feb 11 03:03:33 CET 2011


Hello


I have a popup QML which could be invoked from any screen

Popup.QML

FocusScope{

     anchors.fill:parent

    visible:false

     x:300

    y:100

    Image{

        source:"popup.png"

        BaseButton {

            id:buttonOk

            buttonText:"Ok"

            KeyNavigation.right:buttonCancel

            x:0

            onButtonClicked:{popup.visible=false;}

        }

         BaseButton {

            id: buttonCancel

            x:400

            focus:true

            KeyNavigation.left:buttonOk;

            buttonText:"Cancel"

         }

    }

 }



The problem I am facing is that once I click on Ok here and hide the popup,
the keyboard focus is lost. Is there a way I can have the focus on the
screen which invoked it.


Warm Regards
~~~~~~~~~~~~~~~
Vinayak

http://www.flickr.com/photos/rightplacerighttime/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt.nokia.com/pipermail/qt-qml/attachments/20110210/c29786cb/attachment.html 


More information about the Qt-qml mailing list