mpviewplugins/mpcollectionviewplugin/src/mpcollectionlistcontainer.cpp
changeset 32 c163ef0b758d
parent 29 8192e5b5c935
child 55 f3930dda3342
--- a/mpviewplugins/mpcollectionviewplugin/src/mpcollectionlistcontainer.cpp	Thu May 27 12:49:57 2010 +0300
+++ b/mpviewplugins/mpcollectionviewplugin/src/mpcollectionlistcontainer.cpp	Fri Jun 11 13:36:36 2010 +0300
@@ -50,7 +50,8 @@
       mList(0),
       mNoMusic(0),
       mIndexFeedback(0),
-      mLongPressedIndex(0)
+      mLongPressedIndex(0),
+      mLongPressEnabled(true)
 {
     TX_ENTRY
     mIndexFeedback = new HbIndexFeedback();
@@ -109,8 +110,10 @@
 void MpCollectionListContainer::onLongPressed( HbAbstractViewItem *listViewItem, const QPointF &coords )
 {
     TX_ENTRY
-    mLongPressedIndex = listViewItem->modelIndex().row();
-    emit MpCollectionContainer::itemLongPressed(mLongPressedIndex, coords);
+    if ( mLongPressEnabled ) {
+        mLongPressedIndex = listViewItem->modelIndex().row();
+        emit MpCollectionContainer::itemLongPressed(mLongPressedIndex, coords);
+    }
     TX_EXIT
 }