TAknScreenModes Class Reference

API published in: S60 3rd Ed FP 1

Link against: avkon.lib

Capability Information

Required Capabilities

None


#include <aknscreenmode.h>

Detailed Description

TAknScreenModes is a collection of available screen modes on this device, with API for setting an application's screen mode.

Public Member Functions

IMPORT_C TInt  Count () const
  Get the number of screen modes.
IMPORT_C TAknScreenMode  operator[] (TInt aIndex) const
  Get screen mode information by index.
  TAknScreenModes (const SAknLayoutConfig &aInfo)

Static Public Member Functions

static IMPORT_C TAknScreenModes  GetModes ()
  Factory function.
static IMPORT_C void  SetAppUiScreenModeL (CAknAppUiBase *aAppUi, const TAknScreenMode &aMode)
  Set the screen mode for an application UI.

Protected Attributes

const SAknLayoutConfig &  iInfo

Constructor & Destructor Documentation

TAknScreenModes::TAknScreenModes const SAknLayoutConfig &  aInfo  ) 
 

Member Function Documentation

IMPORT_C TInt TAknScreenModes::Count  )  const
 

Get the number of screen modes.

Returns:
The number of screen modes.
static IMPORT_C TAknScreenModes TAknScreenModes::GetModes  )  [static]
 

Factory function.

Returns:
A constructed TAknScreenModes object.
IMPORT_C TAknScreenMode TAknScreenModes::operator[] TInt  aIndex  )  const
 

Get screen mode information by index.

Parameters:
aIndex,the  screen mode index, must be in the range [0, Count()).
Returns:
Information about a screen mode.
static IMPORT_C void TAknScreenModes::SetAppUiScreenModeL CAknAppUiBase aAppUi,
const TAknScreenMode aMode
[static]
 

Set the screen mode for an application UI.

The application will be displayed in the selected screen mode. The application will no longer respond to hardware or software events which would normally affect screen mode. It will be permanently fixed to the selected screen mode. By using this API, the application effectively declares itself to be non-scalable. Notifier dialogs and other non-full-screen UI will appear in the selected screen mode when displayed over this app. Other full-screen applications will not be affected by this call, except in that switching between this app and other apps using different screen modes will be slow. The screen mode selected must be one returned through the API of this class. There are no fixed screen modes which will appear on every device. The emulator may support many screen modes, but any particular device will probably only support one or two modes. Setting a screen mode may result in the application looking low resolution, badly positioned, the wrong shape, incorrect for certain hardware configurations (eg softkeys in the wrong place), only taking up part of the screen, other applications being visible behind it and generally bad in many other ways. It is strongly recommended that application authors write their applications to be scalable, rather than use this API. If an application wants a fixed orientation, it should use CAknAppUiBase::SetOrientationL(). Note: this API has no effect on non-full-screen app UIs.

Parameters:
aAppUi  The app UI.
aMode  A screen mode accessed through this API.

Field Documentation

const SAknLayoutConfig& TAknScreenModes::iInfo [protected]
 

The documentation for this class was generated from the following file:

Copyright © Nokia Corporation 2001-2008
Back to top