Nokia mobile phone Development: responds to changes in the flip action and camera direction

Source: Internet
Author: User

Series 60 C ++ developers can now write some application software to respond to users turning on or off the phone cover, or changing the orientation of the Mobile Camera. The above two user actions may occur on the Nokia N90 multimedia terminal. This type of software event is supported since Series 60 2nd Edition Feature Pack 2. For example, when a user closes the terminal, the developer can automatically transfer the output to the external screen for display. When the user opens the terminal, the output is automatically transferred to the Internal screen (usually the internal screen is large ).

To add such features to an application, simply add some event processing handles to ceikappui: handlekeyeventl. The corresponding events (teventcode) are eeventscreendevicechanged, eeventcaseopened, and eeventcaseclosed. When the camera is rotated, it is a key event of the eeventkeyup and eeventkeydown types.

The following sample code is used to check the current camera orientation:

# Include <Ecam. h> // link against Ecam. Lib
Ccamera * cam = ccamera: newl (* This, 0 );
Tcamerainfo Info;
Cam-> camerainfo (Info );
Tcameraorientation orientation = info. iorientation;

More information

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.