Results 1 to 2 of 2

Thread: How to keep the backlight on(Android,Qt 5.1 RC1)?

  1. #1
    Join Date
    Jun 2013
    Posts
    2
    Qt products
    Qt4 Qt5 Qt/Embedded
    Platforms
    Windows Android

    Default How to keep the backlight on(Android,Qt 5.1 RC1)?

    I develop android app with Qt 5.1.0 RC1.
    I want to keep the backlight on.

    Qt Code:
    1. #include <android/native_activity.h>
    2.  
    3. ANativeActivity *theActivity;
    4. ANativeActivity_setWindowFlags(theActivity,AWINDOW_FLAG_KEEP_SCREEN_ON,0);
    To copy to clipboard, switch view to plain text mode 

    but compile error:
    undefined reference to 'ANativeActivity_setWindowFlags'

    Someone can help me?
    thanks a lot.

  2. #2
    Join Date
    Feb 2010
    Posts
    4
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: How to keep the backlight on(Android,Qt 5.1 RC1)?

    add #include <android/window.h>

Similar Threads

  1. Replies: 2
    Last Post: 8th August 2014, 20:09
  2. QML/Android
    By Viper666 in forum Qt Quick
    Replies: 11
    Last Post: 18th January 2013, 14:13
  3. Android
    By Viper666 in forum Qt Programming
    Replies: 9
    Last Post: 3rd January 2013, 12:45
  4. Qt in Android Possible?
    By Prabha in forum Installation and Deployment
    Replies: 5
    Last Post: 11th May 2011, 07:11
  5. BackLight of a Button
    By anafor2004 in forum Newbie
    Replies: 1
    Last Post: 21st January 2008, 15:55

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.