--- a/uifw/EikStd/coctlsrc/eikcba.cpp Tue Sep 14 21:48:24 2010 +0300
+++ b/uifw/EikStd/coctlsrc/eikcba.cpp Wed Sep 15 12:29:17 2010 +0300
@@ -132,7 +132,7 @@
result = ETrue;
}
}
-
+ _AKNTRACE( "IsMskEnabledLayoutActive is %d", result );
_AKNTRACE_FUNC_EXIT;
return result;
}
@@ -784,9 +784,10 @@
*/
TBool Active() const
{
- _AKNTRACE_FUNC_ENTER;
- _AKNTRACE_FUNC_EXIT;
- return iOwner.IsVisible() && !iOwner.IsEmpty();
+ TBool ret;
+ ret = iOwner.IsVisible() && !iOwner.IsEmpty();
+ _AKNTRACE( "Active is %d", ret );
+ return ret;
}
/*
@@ -2956,8 +2957,8 @@
// If the status pane is invisible in landscape, softkey need to draw frame to cover
// the area of combine pane.
CEikStatusPaneBase* statusPane = CEikStatusPaneBase::Current();
- if (statusPane && !statusPane->IsVisible() && isLandscapeOrient &&
- statusPane->PaneCapabilities(TUid::Uid(EEikStatusPaneUidCombined)).IsInCurrentLayout())
+ if ( ( iCbaFlags & EEikCbaFlagAppMskIcon ) || ( statusPane && !statusPane->IsVisible() && isLandscapeOrient &&
+ statusPane->PaneCapabilities(TUid::Uid(EEikStatusPaneUidCombined)).IsInCurrentLayout()))
{
iFlags.Set( ECbaCombinePaneUncovered );
}
@@ -2983,90 +2984,95 @@
// If status indicators and clock are shown in control pane area,
// then remove those areas from cba window region.
//
- // NOTE: MSK is not supported in landscape.
+ //
+ // NOTE: MSK is not supported in landscape except the flag EEikCbaFlagAppMskIcon is defined .
//
- if ( statusPane &&
+
+ if ( !(iCbaFlags & EEikCbaFlagAppMskIcon ) )
+ {
+ if( statusPane &&
statusPane->IsVisible() &&
AknStatuspaneUtils::ExtendedFlatLayoutActive() )
- {
- if ( iBgIID == KAknsIIDQsnBgAreaControlMp )
- {
- if ( !iIsClockIndicBgIIDSet )
+ {
+ if ( iBgIID == KAknsIIDQsnBgAreaControlMp )
{
- statusPane->SetCbaAreaBackgroundID(
- iBgIID,
- CEikStatusPaneBase::EDrawDeferred );
- iIsClockIndicBgIIDSet = ETrue;
- }
- }
- else
- {
- if ( statusPane->CbaAreaBackgroundID() != iBgIID )
- {
- statusPane->SetCbaAreaBackgroundID(
- iBgIID,
- CEikStatusPaneBase::EDrawDeferred );
+ if ( !iIsClockIndicBgIIDSet )
+ {
+ statusPane->SetCbaAreaBackgroundID(
+ iBgIID,
+ CEikStatusPaneBase::EDrawDeferred );
+ iIsClockIndicBgIIDSet = ETrue;
+ }
}
- }
-
- if ( statusPane->PaneCapabilities(
- TUid::Uid( EEikStatusPaneUidCombined ) ).IsInCurrentLayout() )
- {
- TRect combinedPaneRect( 0, 0, 0, 0 );
- TRAPD( err,
- combinedPaneRect =
- statusPane->PaneRectL( TUid::Uid(
- EEikStatusPaneUidCombined ) ) );
-
- if ( !err )
+ else
{
- TPoint cbaPositionRelativeToScreen( PositionRelativeToScreen() );
- TRect cbaRectRelativeToScreen( cbaPositionRelativeToScreen, Size() );
-
- if ( cbaRectRelativeToScreen.Intersects( combinedPaneRect ) )
+ if ( statusPane->CbaAreaBackgroundID() != iBgIID )
{
- combinedPaneRect.Move(
- -cbaPositionRelativeToScreen.iX,
- -cbaPositionRelativeToScreen.iY );
-
- region.SubRect( combinedPaneRect );
+ statusPane->SetCbaAreaBackgroundID(
+ iBgIID,
+ CEikStatusPaneBase::EDrawDeferred );
}
}
- }
- else
- {
- TRect digitalClockRect( 0, 0, 0, 0 );
- TRect indicatorRect( 0, 0, 0, 0 );
-
- TRAPD( err1,
- indicatorRect = statusPane->PaneRectL( TUid::Uid(
- EEikStatusPaneUidIndic ) ) );
-
- TRAPD( err2,
- digitalClockRect = statusPane->PaneRectL( TUid::Uid(
- EEikStatusPaneUidDigitalClock ) ) );
+
+ if ( statusPane->PaneCapabilities(
+ TUid::Uid( EEikStatusPaneUidCombined ) ).IsInCurrentLayout() )
+ {
+ TRect combinedPaneRect( 0, 0, 0, 0 );
+ TRAPD( err,
+ combinedPaneRect =
+ statusPane->PaneRectL( TUid::Uid(
+ EEikStatusPaneUidCombined ) ) );
- if ( !err1 && !err2 )
+ if ( !err )
+ {
+ TPoint cbaPositionRelativeToScreen( PositionRelativeToScreen() );
+ TRect cbaRectRelativeToScreen( cbaPositionRelativeToScreen, Size() );
+
+ if ( cbaRectRelativeToScreen.Intersects( combinedPaneRect ) )
+ {
+ combinedPaneRect.Move(
+ -cbaPositionRelativeToScreen.iX,
+ -cbaPositionRelativeToScreen.iY );
+
+ region.SubRect( combinedPaneRect );
+ }
+ }
+ }
+ else
{
- TPoint cbaPositionRelativeToScreen( PositionRelativeToScreen() );
- TRect cbaRectRelativeToScreen( cbaPositionRelativeToScreen, Size() );
-
- if ( cbaRectRelativeToScreen.Intersects( indicatorRect ) )
+ TRect digitalClockRect( 0, 0, 0, 0 );
+ TRect indicatorRect( 0, 0, 0, 0 );
+
+ TRAPD( err1,
+ indicatorRect = statusPane->PaneRectL( TUid::Uid(
+ EEikStatusPaneUidIndic ) ) );
+
+ TRAPD( err2,
+ digitalClockRect = statusPane->PaneRectL( TUid::Uid(
+ EEikStatusPaneUidDigitalClock ) ) );
+
+ if ( !err1 && !err2 )
{
- indicatorRect.Move(
- -cbaPositionRelativeToScreen.iX,
- -cbaPositionRelativeToScreen.iY );
+ TPoint cbaPositionRelativeToScreen( PositionRelativeToScreen() );
+ TRect cbaRectRelativeToScreen( cbaPositionRelativeToScreen, Size() );
+
+ if ( cbaRectRelativeToScreen.Intersects( indicatorRect ) )
+ {
+ indicatorRect.Move(
+ -cbaPositionRelativeToScreen.iX,
+ -cbaPositionRelativeToScreen.iY );
- region.SubRect( indicatorRect );
- }
+ region.SubRect( indicatorRect );
+ }
- if ( cbaRectRelativeToScreen.Intersects( digitalClockRect ) )
- {
- digitalClockRect.Move(
- -cbaPositionRelativeToScreen.iX,
- -cbaPositionRelativeToScreen.iY );
+ if ( cbaRectRelativeToScreen.Intersects( digitalClockRect ) )
+ {
+ digitalClockRect.Move(
+ -cbaPositionRelativeToScreen.iX,
+ -cbaPositionRelativeToScreen.iY );
- region.SubRect( digitalClockRect );
+ region.SubRect( digitalClockRect );
+ }
}
}
}
@@ -3564,6 +3570,7 @@
{
if( button1->IsDimmed() )
{
+ _AKNTRACE_FUNC_EXIT;
return EKeyWasConsumed;
}
// Return immediately if the button is invisible
@@ -3601,6 +3608,7 @@
{
if( button2->IsDimmed() )
{
+ _AKNTRACE_FUNC_EXIT;
return EKeyWasConsumed;
}
// Return immediately if the button is invisible.
@@ -3655,7 +3663,8 @@
&& !Window().IsFaded() )
{
if( buttonMSK->IsDimmed() )
- {
+ {
+ _AKNTRACE_FUNC_EXIT;
return EKeyWasConsumed;
}
if (KControlArrayCBAButtonMSKPosn < iControlArray->Count())
@@ -3883,6 +3892,7 @@
if( button1->IsDimmed() )
{
CCoeControl::HandlePointerEventL( aPointerEvent );
+ _AKNTRACE_FUNC_EXIT;
return;
}
if ( button1->IsVisible() )
@@ -3947,6 +3957,7 @@
if( button2->IsDimmed() )
{
CCoeControl::HandlePointerEventL( aPointerEvent );
+ _AKNTRACE_FUNC_EXIT;
return;
}
if ( button2->IsVisible() )
@@ -4013,6 +4024,7 @@
if( buttonMSK->IsDimmed() )
{
CCoeControl::HandlePointerEventL( aPointerEvent );
+ _AKNTRACE_FUNC_EXIT;
return;
}
if ( buttonMSK->IsVisible() )
@@ -4551,6 +4563,7 @@
// Embedded CBA doesn't draw anything
if ( iFlags.IsSet( ECbaInsideDialog ) )
{
+ _AKNTRACE_FUNC_EXIT;
return;
}
@@ -4559,6 +4572,7 @@
CWindowGc &gc = SystemGc();
iExtension->DrawSemiTransparency( gc );
+ _AKNTRACE_FUNC_EXIT;
return;
}
@@ -5270,7 +5284,7 @@
TRect posInScreen( cbarect.Rect() );
TBool mskEnabledInPlatform( iMSKEnabledInPlatform &&
- IsMskEnabledLayoutActive() );
+ ( IsMskEnabledLayoutActive() || ( iCbaFlags & EEikCbaFlagAppMskIcon ) ) );
TBool mskEnabledInApplication( AknLayoutUtils::MSKEnabled() && iMSKset );
@@ -7736,11 +7750,14 @@
//
TBool CEikCba::MskAllowed() const
{
- _AKNTRACE_FUNC_ENTER;
- _AKNTRACE_FUNC_EXIT;
- return ( iMSKEnabledInPlatform &&
- AknLayoutUtils::MSKEnabled() &&
- IsMskEnabledLayoutActive() );
+ _AKNTRACE_FUNC_ENTER;
+ TBool ret = EFalse;
+ ret = iMSKEnabledInPlatform &&
+ ( ( AknLayoutUtils::MSKEnabled() &&
+ IsMskEnabledLayoutActive() ) || ( iCbaFlags & EEikCbaFlagAppMskIcon ) );
+ _AKNTRACE( "MskAllowed is %d", ret );
+ _AKNTRACE_FUNC_EXIT;
+ return ret;
}
@@ -7879,6 +7896,10 @@
void CEikCba::UpdateMultipleMarkingSoftkey()
{
_AKNTRACE_FUNC_ENTER;
+ if ( iFlags.IsSet( ECbaEmbedded ) )
+ {
+ return;
+ }
if ( iFlags.IsSet( ECbaSingleClickEnabled )
&& iExtension && iExtension->iItemActionMenu )
{