QtOrientationTest
axeljaeger
(Talk | contribs) (Update to no longer use own emulator) |
hamishwillee
(Talk | contribs) m (Hamishwillee - Change to use new video player which works with Lumia 920 and other mobile browsers) |
||
| (4 intermediate revisions by one user not shown) | |||
| Line 1: | Line 1: | ||
| − | [[Category:Qt]][[Category:Qt | + | [[Category:Qt]][[Category:Qt Mobility]][[Category:Symbian]][[Category:Code Examples]][[Category:UI]][[Category:S60 5th Edition]] |
| − | {{ | + | {{ArticleMetaData <!-- v1.2 --> |
| − | | | + | |sourcecode= [[Media:Orientationtest.zip]] |
| − | | | + | |installfile= <!-- Link to installation file (e.g. [[Media:The Installation File.sis]]) --> |
|devices= Nokia 5800 XpressMusic, Nokia N97 mini | |devices= Nokia 5800 XpressMusic, Nokia N97 mini | ||
| − | | | + | |sdk= <!-- SDK(s) built and tested against (e.g. [http://linktosdkdownload/ Nokia Qt SDK 1.1]) --> |
| + | |platform= S60 5th Edition | ||
| + | |devicecompatability= <!-- Compatible devices (e.g.: All* (must have GPS) ) --> | ||
| + | |dependencies= <!-- Any other/external dependencies e.g.: Google Maps Api v1.0 --> | ||
| + | |signing= <!-- Empty or one of Self-Signed, DevCert, Manufacturer --> | ||
| + | |capabilities= <!-- Capabilities required by the article/code example (e.g. Location, NetworkServices. --> | ||
| + | |keywords= Orientation, Sensor, Accelerometer | ||
| + | |language= <!-- Language category code for non-English topics - e.g. Lang-Chinese --> | ||
| + | |translated-by= <!-- [[User:XXXX]] --> | ||
| + | |translated-from-title= <!-- Title only --> | ||
| + | |translated-from-id= <!-- Id of translated revision --> | ||
| + | |review-by= <!-- After re-review: [[User:username]] --> | ||
| + | |review-timestamp= <!-- After re-review: YYYYMMDD --> | ||
| + | |update-by= <!-- After significant update: [[User:username]]--> | ||
| + | |update-timestamp= <!-- After significant update: YYYYMMDD --> | ||
| + | |creationdate= 20100329 | ||
| + | |author= [[User:Axeljaeger]] | ||
| + | <!-- The following are not in current metadata --> | ||
|subcategory= Qt Mobility API | |subcategory= Qt Mobility API | ||
| − | |||
| − | |||
}} | }} | ||
| − | =Overview= | + | ==Overview== |
The QtOrientationTest shows shows how to obtain the device orientation and adopt the user interface accordingly. An arrow is shown on the display that is pointing "upwards". If the device is flat on the table or face down, either a circle with a dot or a cross is shown, meaning you look to the pointy end of the arrow or from the back to the fletchings. | The QtOrientationTest shows shows how to obtain the device orientation and adopt the user interface accordingly. An arrow is shown on the display that is pointing "upwards". If the device is flat on the table or face down, either a circle with a dot or a cross is shown, meaning you look to the pointy end of the arrow or from the back to the fletchings. | ||
| − | =In action= | + | ==In action== |
See the application in action on youtube: | See the application in action on youtube: | ||
| − | + | <mediaplayer>http://www.youtube.com/watch?v=-R8zATxLW80</mediaplayer> | |
| − | =Testing the application= | + | ==Testing the application== |
The example is meant to be run either on a symbian device or in the simulator of the Nokia Qt SDK. | The example is meant to be run either on a symbian device or in the simulator of the Nokia Qt SDK. | ||
| − | Because of the usage of sensors from the QtMobility-APIs, ReadDeviceData-capability is needed on symbian. This capability cannot be granted to a self signed application. Use | + | Because of the usage of sensors from the QtMobility-APIs, ReadDeviceData-capability is needed on symbian. This capability cannot be granted to a self signed application. Use Symbian signed online to test. |
| − | =Download= | + | ==Download== |
[[File:Orientationtest.zip]] | [[File:Orientationtest.zip]] | ||
| − | =Planed updates= | + | ==Planed updates== |
| − | As soon as Nokia publishes an official API to lock the screen orientation and thus disabling auto rotation, the example will be updated and then also work on maemo/maego. Currently there is | + | As soon as Nokia publishes an official API to lock the screen orientation and thus disabling auto rotation, the example will be updated and then also work on maemo/maego. Currently there is still a bit of native code to lock screen orientation on Symbian. No such code is provided for Maemo. |
| − | =History= | + | ==History== |
{| border="1" | {| border="1" | ||
|29 March 2010 | |29 March 2010 | ||
| − | |Initial version that was submitted to the QtMobility-contest. This one was actually not using QtMobility but the so called "[[ | + | |Initial version that was submitted to the QtMobility-contest. This one was actually not using QtMobility but the so called "[[Archived:Mobile Extensions|Mobile Extensions]]" |
|- | |- | ||
|1 August 2010 | |1 August 2010 | ||
| Line 39: | Line 54: | ||
|Updated version that no longer uses an own emulator because simulator from Nokia Qt SDK from version 1.0.1 supports setting orientations when using the scripts provided here http://bugreports.qt.nokia.com/browse/QTSIM-63 | |Updated version that no longer uses an own emulator because simulator from Nokia Qt SDK from version 1.0.1 supports setting orientations when using the scripts provided here http://bugreports.qt.nokia.com/browse/QTSIM-63 | ||
|} | |} | ||
| − | |||
| − | |||
Revision as of 05:58, 30 January 2013
Article Metadata
Code Example
Tested with
Compatibility
Article
Contents |
Overview
The QtOrientationTest shows shows how to obtain the device orientation and adopt the user interface accordingly. An arrow is shown on the display that is pointing "upwards". If the device is flat on the table or face down, either a circle with a dot or a cross is shown, meaning you look to the pointy end of the arrow or from the back to the fletchings.
In action
See the application in action on youtube: The media player is loading...
Testing the application
The example is meant to be run either on a symbian device or in the simulator of the Nokia Qt SDK.
Because of the usage of sensors from the QtMobility-APIs, ReadDeviceData-capability is needed on symbian. This capability cannot be granted to a self signed application. Use Symbian signed online to test.
Download
Planed updates
As soon as Nokia publishes an official API to lock the screen orientation and thus disabling auto rotation, the example will be updated and then also work on maemo/maego. Currently there is still a bit of native code to lock screen orientation on Symbian. No such code is provided for Maemo.
History
| 29 March 2010 | Initial version that was submitted to the QtMobility-contest. This one was actually not using QtMobility but the so called "Mobile Extensions" |
| 1 August 2010 | Updated version that now uses the new sensor API from QtMobility |
| 19 September 2010 | Updated version that no longer uses an own emulator because simulator from Nokia Qt SDK from version 1.0.1 supports setting orientations when using the scripts provided here http://bugreports.qt.nokia.com/browse/QTSIM-63 |

