You Are Here:

Community: Wiki

This page was last modified on 16 September 2009, at 14:20.

How to make a full-screen application using Symbian C++

From Forum Nokia Wiki

Reviewer Approved   
There are different methods for making full-screen applications.

Cover the system panes

This simple method is used when the application has a traditional view architecture where the view is not a full-screen view. To make the view full screen, call the CCoeControl::SetExtentToWholeScreen() method in the CMyView::ConstructL method before the ActivateL() call.

Remember that the underlying panes are still drawn and this will take time and processor power. It is better to hide them if you want to use the whole screen.

void CMyView::ConstructL(const TRect& aRect)
{
// Create a window for this application view
CreateWindowL();
 
// Set the window size
SetRect(aRect);
 
// This view is a full-screen view.
SetExtentToWholeScreen();
 
// Activate the window, which makes it ready to be drawn
ActivateL();
}

SetExtentToWholeScreen() is not recommended when the application is skinned (from S60 2nd Edition onwards; see figure). However, full-screen applications do not want the skin feature anyway, so this should not be a problem. (This needs to be updated. Some full-screen applications *do* want the skin feature. Any updates here for full-screen 'skinned' apps?)

Image:FullscreenExample.png

Hiding

The status pane and softkeys can be hidden. The status pane can be hidden from the AppUi with the command

#include <eikbtgpc.h> 
#include <avkon.rsg>
StatusPane()->MakeVisible(EFalse);

Softkeys can be hidden from the AppUi with the Cba()->MakeVisible(EFalse); command, which activates the “null” softkeys. The default softkeys have no effect after that. To activate the default option menu and the Back key immediately after the keys are pressed, manually handle the key presses. This can be done in the HandleKeyEventL() method as follows:

TKeyResponse  CMyAppUi::HandleKeyEventL(
const TKeyEvent& aKeyEvent,TEventCode aType)
{
// Left or right softkey pressed
if (aType==EEventKeyDown &&
(aKeyEvent.iScanCode == EStdKeyDevice0 ||
aKeyEvent.iScanCode == EStdKeyDevice1))
{
Cba()->MakeVisible(ETrue);
}
else
{
Cba()->MakeVisible(EFalse);
}
 
return EKeyWasNotConsumed;
}

After that, you can use whole screen when drawing.

See also

Related Wiki Articles

No related wiki articles found

Rate This

 
Bookmark this page: DeliciousDiggFacebookGoogleYahooStumbleUponRedditDiigoTechnocratiTwitter  Share this page Share this page Print this Page Print this page Invite a friend Invite a friend
京ICP备05048969号    Email Newsletters Press Terms & Conditions Privacy Policy Sitemap Contact Us © 2009 Nokia 
RDF Facets: qdcZidentifierQSxhttpE3aE2fE2fwikiE2eforumE2enokiaE2ecomE2findeE78E2ephpE2fFileE3aMicrokernelE5fArchitectureE2eGIFX qdcZtypeQUqfnZE45E78cludedFromGeneralE4cistingsQ qdcZtypeQUqfntypeZCommunityContentQ qdcZtypeQUqfntypeZE52esourceQ qdcZtypeQUqfntypeZWebpageQ qdcZtypeQUqfntypeZWikiContentQ qdcZtypeQUqmarsZManagedE52esourceQ qdcZtypeQUqwebZInformationE52esourceQ qdcZtypeQUqwebZPageQ qdcZtypeQUqwebZE52esourceQ qdcZtypeQUqrdfsZE52esourceQ qfnZtypeQUqfntypeZCommunityContentQ qfnZtypeQUqfntypeZE52esourceQ qfnZtypeQUqfntypeZWebpageQ qfnZtypeQUqfntypeZWikiContentQ qmarsZlanguageQUxhttpE3aE2fE2fswE2enokiaE2ecomE2flanguageE2d1E2fenX qrdfZtypeQUqfnZE45E78cludedFromGeneralE4cistingsQ qrdfZtypeQUqfntypeZCommunityContentQ qrdfZtypeQUqfntypeZE52esourceQ qrdfZtypeQUqfntypeZWebpageQ qrdfZtypeQUqfntypeZWikiContentQ qrdfZtypeQUqmarsZManagedE52esourceQ qrdfZtypeQUqwebZInformationE52esourceQ qrdfZtypeQUqwebZPageQ qrdfZtypeQUqwebZE52esourceQ qrdfZtypeQUqrdfsZE52esourceQ