]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/ktooltip.cpp
when changing the view mode if the preview is turned on, the directory must get reloa...
[dolphin.git] / src / ktooltip.cpp
index 3c1da3fba409fd2d5f23c798087467cc9a95286a..39e06b4c7851c99e5d824c90acad4784b1bfaa2a 100644 (file)
@@ -95,6 +95,7 @@ QVariant KToolTipItem::data(int role) const
 void KToolTipItem::setData(int role, const QVariant &data)
 {
     d->map[role] = data;
+    KToolTipManager::instance()->update();
 }
 
 
@@ -471,6 +472,7 @@ void KToolTipManager::showTip(const QPoint &pos, KToolTipItem *item)
     hideTip();
     label->showTip(pos, item);
     currentItem = item;
+    m_tooltipPos = pos;
 }
 
 void KToolTipManager::hideTip()
@@ -509,6 +511,13 @@ void KToolTipManager::setDelegate(KToolTipDelegate *delegate)
     m_delegate = delegate;
 }
 
+void KToolTipManager::update()
+{
+    if (currentItem == 0)
+        return;
+    label->showTip(m_tooltipPos, currentItem);
+}
+
 KToolTipDelegate *KToolTipManager::delegate() const
 {
     return m_delegate;