×
Namespaces

Variants
Actions

Archived:Incorrect values from AknLayoutUtils:LayoutMetricsRect on E71 (Known Issue)

From Nokia Developer Wiki
Jump to: navigation, search

Archived.pngArchived: This article is archived because it is not considered relevant for third-party developers creating commercial solutions today. If you think this article is still relevant, let us know by adding the template {{ReviewForRemovalFromArchive|user=~~~~|write your reason here}}.

The AknLayoutUtils:LayoutMetricsRect() function returns incorrect values for some screen areas on the Nokia E71 and the Nokia E63. This known issue has been verified by Nokia Developer.

Article Metadata
Tested with
Devices(s): Nokia E71 (sw 100.07.76), Nokia E63 (sw 100.21.110)
Compatibility
Platform(s): S60 3rd Edition FP1
S60 3rd Edition FP1
Article
Keywords: LayoutMetricsRect, EStatusPane, EControlPane
Created: mgroeber9110 (03 Dec 2008)
Last edited: hamishwillee (20 Jun 2012)

Description

On the Nokia E71 (sw version 100.07.76) LayoutMetricsRect() returns the following incorrect coordinates:

Layout component Top left Bottom right
EStatusPane,EStatusPaneTop (0, 0) (320, -53)
EControlPane (0, 293) (320, 320)

Both the bottom right corner of EStatusPane and the vertical position of EControlPane are incorrect. However, the height of the control pane is correct.

Solution

Use coordinates of other areas which return correct values (for example, AknLayoutUtils::ENaviPane) and knowledge of screen size to adjust the bottom right corner of the status pane and to move the control pane area upwards to be aligned with the bottom of the screen:

 #include <aknutils.h>
#include <hal.h>
 
AknLayoutUtils::LayoutMetricsRect( AknLayoutUtils::EStatusPane,
statusPaneRect );
 
AknLayoutUtils::LayoutMetricsRect( AknLayoutUtils::EControlPane,
controlPaneRect );
 
AknLayoutUtils::LayoutMetricsRect( AknLayoutUtils::ENaviPane,
naviPaneRect );
 
AknLayoutUtils::LayoutMetricsRect( AknLayoutUtils::EScreen,
screenRect );
 
// Adjust area so that bottom aligns with bottom of screen
if( controlPaneRect.iBr.iY > screenRect.Height() )
{
controlPaneRect.Move( 0, screenRect.Height() - controlPaneRect.iBr.iY );
}
// Adjust bottom right coordinate of StatusPane rect
if(naviPaneRect.iBr.iY < 0)
{
statusPaneRect.iBr.iY = naviPaneRect.iBr.iY;
}
This page was last modified on 20 June 2012, at 03:05.
37 page views in the last 30 days.

Was this page helpful?

Your feedback about this content is important. Let us know what you think.

 

Thank you!

We appreciate your feedback.

×