Discussion Board

Results 1 to 2 of 2
  1. #1
    Regular Contributor jawadakhtar's Avatar
    Join Date
    Sep 2008
    Location
    Karachi, Pakistan
    Posts
    98
    Hi,

    Can we listen to Power Key press when device is locked. I tried with QApplication::symbianEventFilter(const QSymbianEvent *event) but it gives code 21 some times twice or thrice. It also gives same code (21) on press of Menu button. Can we differentiate between these keys when device is locked?

    Secondly, I want to check the key press and hold for certain period of time, for e.g. 1/4 of second. Can we detect when Power key released ? As currently the symbianEventFilter() sends the key code when the power key is pressed but not on release.

    I am using C7 with Symbian Anna.

    Regards,

    Jawad.

  2. #2
    Regular Contributor treinio's Avatar
    Join Date
    Oct 2008
    Location
    Oslo, Norway
    Posts
    329
    I don't think you can solve this with symbianEventFilter or any other Qt API. For your application to receive key events even when in background/active keylock you'll need to request key capture from window server session as discussed here. But if I remember correctly, power key might be off-limits for key capture as it's reserved for sysapp.

Similar Threads

  1. Capture long key press in E75 when keypad is locked
    By pedramz in forum Symbian C++
    Replies: 2
    Last Post: 2009-11-22, 17:27
  2. long press when keypad is locked
    By a.alsayed in forum Symbian C++
    Replies: 1
    Last Post: 2009-11-22, 16:23
  3. Replies: 14
    Last Post: 2009-11-16, 13:16
  4. Can a background application detect a key press when keypad is locked??
    By rohanwaugh in forum Symbian User Interface
    Replies: 17
    Last Post: 2009-08-14, 10:20
  5. Replies: 4
    Last Post: 2009-04-29, 11:22

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2013 All rights reserved