diff -r 85902f042028 -r a5e7a4f63858 uifw/EikStd/dlgsrc/EIKDPAGE.CPP --- a/uifw/EikStd/dlgsrc/EIKDPAGE.CPP Wed Sep 15 12:29:17 2010 +0300 +++ b/uifw/EikStd/dlgsrc/EIKDPAGE.CPP Wed Oct 13 14:50:15 2010 +0300 @@ -1384,38 +1384,6 @@ } } - // If control height is greater then screen. Make sure that edwin's cursor is visible - if (controlType == EEikCtEdwin && controlHeight > Rect().Height()) - { - CEikEdwin* edwin = dynamic_cast(capCtrl->iControl); - if (edwin) - { - TInt pos = edwin->CursorPos(); - TRect linerect; - TRAP_IGNORE( linerect = edwin->TextLayout()->GetLineRectL(pos, pos) ); - - TPoint capctrlpos = capCtrl->Position(); - TPoint edwinpos = edwin->Position(); - if (edwinpos.iY - capctrlpos.iY + (linerect.iTl.iY + linerect.iBr.iY)/2 > Rect().Height()/2) // cursor not fully visible - { - TInt offset = edwinpos.iY - capctrlpos.iY + (linerect.iTl.iY + linerect.iBr.iY)/2 - Rect().Height()/2; - if (topYPosOfControlWhichMustBeViewable + offset + Rect().Height() <= bottomYPosOfControlWhichMustBeViewable) - { - topYPosOfControlWhichMustBeViewable += offset; - bottomYPosOfControlWhichMustBeViewable = topYPosOfControlWhichMustBeViewable + Rect().Height(); - } - else - { - topYPosOfControlWhichMustBeViewable = bottomYPosOfControlWhichMustBeViewable - Rect().Height(); - } - } - else - { - bottomYPosOfControlWhichMustBeViewable = topYPosOfControlWhichMustBeViewable + Rect().Height(); - } - } - } - SetDataPosition( topYPosOfControlWhichMustBeViewable, bottomYPosOfControlWhichMustBeViewable, aForceResize ); if ( aLine != iLastExposedLine ) @@ -1969,10 +1937,9 @@ AknLayoutScalable_Avkon::listscroll_form_pane(), AknLayoutScalable_Avkon::scroll_pane_cp8()); - //Using Rect() instead of main pane rect for supporting partial input mode. - //TRect scrollBarParent( MainPane().Size() ); - AknLayoutUtils::LayoutVerticalScrollBar(iPageContainer->ScrollBar(), Rect(), layout.LayoutLine()); - + TRect scrollBarParent( MainPane().Size() ); + + AknLayoutUtils::LayoutVerticalScrollBar(iPageContainer->ScrollBar(), scrollBarParent, layout.LayoutLine()); if(!ScbState() && iCurrentLine!=-1 && iCurrentLine < iLines->Count() ) { CEikCaptionedControl *ctrl = (*iLines)[iCurrentLine]; @@ -2245,8 +2212,6 @@ { ExposeLine( iCurrentLine, ETrue ); } - TRAP_IGNORE( RecordLinesL() ); - DrawDeferred(); break; case KAknMessageFocusLost: @@ -2262,15 +2227,6 @@ ShowFocus( EFalse, ETrue ); } } - //Stop physics and synchronize the page to reset KS - //when page losing foreground. - if ( IsEditable() && iExtension->iScrolling - && iPhysics->OngoingPhysicsAction() == - CAknPhysics::EAknPhysicsActionDragging ) - { - iPhysics->Stop(); - Synchronize(); - } break; default: @@ -3213,7 +3169,7 @@ if ( ( touchedLine < iLines->Count() ) && ( touchedLine != iCurrentLine ) ) { - TRAP_IGNORE( (*iLines)[touchedLine]->ActivateL() ); + (*iLines)[touchedLine]->ActivateL(); if ( LineIsFocusable( touchedLine ) ) { @@ -4453,15 +4409,32 @@ iPageSelector = aPageSelector; } -void CEikDialogPageContainer::SetPageFormSized(const TRect& aRect) +void CEikDialogPageContainer::SetPageFormSized() { iForm = ETrue; // // Form layout - // + // + + /** Dialog page container and page have the same size */ + TRect mainPaneRect; + AknLayoutUtils::LayoutMetricsRect( AknLayoutUtils::EMainPane, mainPaneRect ); + mainPaneRect = TRect( mainPaneRect.Size() ); // Moving to point (0, 0) + TAknLayoutRect formPaneLt; + formPaneLt.LayoutRect( mainPaneRect, AknLayoutScalable_Avkon::listscroll_form_pane().LayoutLine() ); + formPaneLt.LayoutRect( formPaneLt.Rect(), AknLayoutScalable_Avkon::list_form_gen_pane().LayoutLine() ); - SetRect(aRect); + // + // End of form layout + // + + if ( formPaneLt.Rect() != Rect() ) + { + // TODO: use static method to do variation between traditional scrolling and panning when available + //SetRect( formPaneLt.Rect() ); + SetRect( mainPaneRect ); + } /** Only forms have line highlight animations. Animation creation is delayed * here.