How to Lock Application Screen Orientation in Symbian

From Qt Wiki
Revision as of 15:47, 14 January 2015 by Maintenance script (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Overview

This code snippet shows how one can have their application screen (ui) to be locked to a particular orientation (landscape or portrait mode)

In your Project profile (.pro) file

You must add the cone.lib, eikcore.lib, and avkon.lib Symbian libraries into the Qt for S60 build for orientation handling.

In your main.cpp file

Note

In the latest Qt Creator you get an option to lock the orientation as a part of the application creation wizard.