uifw/AvKon/aknphysics/src/aknphysicsconeobserver.cpp
branchRCL_3
changeset 19 aecbbf00d063
parent 10 3d340a0166ff
child 20 d48ab3b357f1
equal deleted inserted replaced
18:fcdfafb36fe7 19:aecbbf00d063
   287                     CCoeControl* child = iViewControl->ComponentControl( i );
   287                     CCoeControl* child = iViewControl->ComponentControl( i );
   288                     if ( child && child->IsVisible() && !child->OwnsWindow() )
   288                     if ( child && child->IsVisible() && !child->OwnsWindow() )
   289                         {
   289                         {
   290                         if ( child->Rect().Contains( aEvent->iPosition ) )
   290                         if ( child->Rect().Contains( aEvent->iPosition ) )
   291                             {
   291                             {
   292                             target = ETargetChildControl;
   292                             target = ETargetOtherControl;
   293                             }
   293                             }
   294                         }
   294                         }
   295                     }
   295                     }
   296                 }
   296                 }
   297             }
   297             }
   317         {
   317         {
   318         iDragObserver->RegisterEventPosition( aEvent );
   318         iDragObserver->RegisterEventPosition( aEvent );
   319         }
   319         }
   320 
   320 
   321     if ( aEvent->iType == TPointerEvent::EButton1Up && 
   321     if ( aEvent->iType == TPointerEvent::EButton1Up && 
   322          iPhysics->IsPanningDrawOmitted() && 
   322          iPhysics->IsPanningDrawOmitted() )
   323          eventTarget == ETargetViewControl )
       
   324         {
   323         {
   325         // Ensure that the last panning position gets drawn if the last
   324         // Ensure that the last panning position gets drawn if the last
   326         // view redraw was omitted due to too high CPU use.
   325         // view redraw was omitted due to too high CPU use.
   327         iPhysics->DrawViewInCurrentPosition();
   326         iPhysics->DrawViewInCurrentPosition();
   328         }
   327         }
   345     
   344     
   346     // Check if flick should be stopped
   345     // Check if flick should be stopped
   347     if ( ongoingAction == CAknPhysics::EAknPhysicsActionFlicking )
   346     if ( ongoingAction == CAknPhysics::EAknPhysicsActionFlicking )
   348         {
   347         {
   349         // Event not targeted to view - stop flick
   348         // Event not targeted to view - stop flick
   350         if (aTargetControl && (eventTarget == ETargetOtherControl 
   349         if ( ( eventTarget == ETargetOtherControl || 
   351                 || (eventTarget == ETargetChildControl && aTargetControl
   350                 eventTarget == ETargetChildControl ) && aTargetControl )
   352                 != iWindowControl)))
       
   353             {
   351             {
   354             stopPhysics = ETrue;
   352             stopPhysics = ETrue;
   355             aTargetControl->IgnoreEventsUntilNextPointerUp();
   353             aTargetControl->IgnoreEventsUntilNextPointerUp();
   356             }
   354             }
   357         }
   355         }