menufw/menufwui/mmwidgets/inc/mmgrid.h
branchRCL_3
changeset 102 ba63c83f4716
parent 88 3321d3e205b6
--- a/menufw/menufwui/mmwidgets/inc/mmgrid.h	Wed Sep 15 12:00:00 2010 +0300
+++ b/menufw/menufwui/mmwidgets/inc/mmgrid.h	Wed Oct 13 14:18:30 2010 +0300
@@ -12,7 +12,7 @@
 * Contributors:
 *
 * Description:  CMmGrid declaration
-*  Version     : %version: MM_32.1.26 % << Don't touch! Updated by Synergy at check-out.
+*  Version     : %version: MM_32.1.25 % << Don't touch! Updated by Synergy at check-out.
 *
 */
 
@@ -397,6 +397,25 @@
     void ProcessScrollEventL( CEikScrollBar* aScrollBar,
             TEikScrollEvent aEventType );
 
+    /**
+     * Handles periodic events from @c iRedrawTimer.
+     * Such events are generated at equal time intervals while
+     * the view is being scrolled using the scrollbar.
+     * This function typically calls @c ProcessScrollEventL,
+     * which actually scrolls the view and causes a redraw.
+     */
+    void HandleRedrawTimerEventL();
+
+private:
+    /**
+     * Callback function for @c iRedrawTimer.
+     * It simply calls @c HandleRedrawTimerEventL and returns 0.
+     *
+     * @param aPtr A pointer to CMmGrid object.
+     * @return 0 (always).
+     */
+    static TInt RedrawTimerCallback( TAny* aPtr );
+
 private:
     /**
      * Grid model.
@@ -453,6 +472,26 @@
      */
     TPoint iButton1DownPos;
 
+    /**
+     * ETrue if the view is being scrolled with the scrollbar.
+     */
+    TBool iScrollbarThumbIsBeingDragged;
+
+    /**
+     * Stores the number of scrollbar events that were ignored.
+     * It is only used while scrolling the view using scrollbar,
+     * in such situation the scroll events that this object receives
+     * are ignored, and actual scrolling is done only when
+     * iRedrawTimer completes.
+     */
+    TInt iSkippedScrollbarEventsCount;
+
+    /**
+     * A timer that initiates redraws at certain time intervals.
+     * It is used to refresh the view while scrolling with
+     * the scrollbar.
+     */
+    CPeriodic* iRedrawTimer;
     };
 
 #endif // C_MMGRID_H