photosgallery/slideshow/view/src/shwgesturecontrol.cpp
branchRCL_3
changeset 47 f9e827349359
parent 30 a60acebbbd9d
equal deleted inserted replaced
35:420f6808bf21 47:f9e827349359
    77 	TRACER("CShwGestureControl::~CShwGestureControl");
    77 	TRACER("CShwGestureControl::~CShwGestureControl");
    78 	iObservers.ResetAndDestroy();
    78 	iObservers.ResetAndDestroy();
    79     }
    79     }
    80 
    80 
    81 // -----------------------------------------------------------------------------
    81 // -----------------------------------------------------------------------------
    82 // AddObserver
    82 // AddObserverL
    83 // -----------------------------------------------------------------------------
    83 // -----------------------------------------------------------------------------
    84 //
    84 //
    85 void CShwGestureControl::AddObserver(MShwGestureObserver* aObserver) 
    85 void CShwGestureControl::AddObserverL(MShwGestureObserver* aObserver) 
    86     {
    86     {
    87     TRACER("CShwGestureControl::AddObserver");
    87     TRACER("CShwGestureControl::AddObserverL");
    88     GLX_LOG_INFO("CShwGestureControl::AddObserver");
    88     GLX_LOG_INFO("CShwGestureControl::AddObserverL");
    89     __ASSERT_DEBUG( NULL != aObserver , Panic(EGlxPanicNullPointer)); 
    89     __ASSERT_DEBUG( NULL != aObserver , Panic(EGlxPanicNullPointer)); 
    90     
    90     
    91     // dont want to observe the same thing again and again.
    91     // dont want to observe the same thing again and again.
    92     if (iObservers.Find(aObserver) == KErrNotFound)
    92     if (iObservers.Find(aObserver) == KErrNotFound)
    93         {
    93         {
    94         iObservers.Append(aObserver);
    94         iObservers.AppendL(aObserver);
    95         GLX_LOG_INFO1("CShwGestureControl::AddObserver  Observer Added "
    95         GLX_LOG_INFO1("CShwGestureControl::AddObserverL  Observer Added "
    96                 "observer count now [%d]", iObservers.Count());
    96                 "observer count now [%d]", iObservers.Count());
    97         }
    97         }
    98     }
    98     }
    99 
    99 
   100 // -----------------------------------------------------------------------------
   100 // -----------------------------------------------------------------------------
   107     GLX_LOG_INFO("CShwGestureControl::RemoveObserver");
   107     GLX_LOG_INFO("CShwGestureControl::RemoveObserver");
   108     TInt observerPosition = iObservers.Find(aObserver);
   108     TInt observerPosition = iObservers.Find(aObserver);
   109     if (observerPosition != KErrNotFound)
   109     if (observerPosition != KErrNotFound)
   110         {
   110         {
   111         iObservers.Remove(observerPosition);
   111         iObservers.Remove(observerPosition);
   112         GLX_LOG_INFO1("CShwGestureControl::AddObserver  One Observer removed "
   112         GLX_LOG_INFO1("CShwGestureControl::RemoveObserver  One Observer removed "
   113                 "observer count now [%d]", iObservers.Count());
   113                 "observer count now [%d]", iObservers.Count());
   114         }
   114         }
   115     }
   115     }
   116 
   116 
   117 // -----------------------------------------------------------------------------
   117 // -----------------------------------------------------------------------------