mirror of
https://invent.kde.org/system/dolphin
synced 2024-09-19 16:31:21 +00:00
fixed possible crash when showing tooltips and switching between views
BUG: 161201 CCMAIL: ubuntu@martin-graesslin.com svn path=/trunk/KDE/kdebase/apps/; revision=818325
This commit is contained in:
parent
b5c7a2ebb9
commit
d9ec7ac7a3
|
@ -21,11 +21,15 @@
|
|||
|
||||
#include "dolphinmodel.h"
|
||||
#include "dolphinsortfilterproxymodel.h"
|
||||
#include "ktooltip.h"
|
||||
#include "kicon.h"
|
||||
|
||||
#include <kformattedballoontipdelegate.h>
|
||||
#include <kicon.h>
|
||||
#include <ktooltip.h>
|
||||
|
||||
#include <QTimer>
|
||||
|
||||
K_GLOBAL_STATIC(KFormattedBalloonTipDelegate, g_delegate);
|
||||
|
||||
ToolTipManager::ToolTipManager(QAbstractItemView* parent,
|
||||
DolphinSortFilterProxyModel* model) :
|
||||
QObject(parent),
|
||||
|
@ -34,10 +38,9 @@ ToolTipManager::ToolTipManager(QAbstractItemView* parent,
|
|||
m_proxyModel(model),
|
||||
m_timer(0),
|
||||
m_item(),
|
||||
m_pos(),
|
||||
m_delegate()
|
||||
m_pos()
|
||||
{
|
||||
KToolTip::setToolTipDelegate(&m_delegate);
|
||||
KToolTip::setToolTipDelegate(g_delegate);
|
||||
|
||||
m_dolphinModel = static_cast<DolphinModel*>(m_proxyModel->sourceModel());
|
||||
connect(parent, SIGNAL(entered(const QModelIndex&)),
|
||||
|
|
|
@ -24,7 +24,6 @@
|
|||
#include <QPoint>
|
||||
|
||||
#include <kfileitem.h>
|
||||
#include <kformattedballoontipdelegate.h>
|
||||
|
||||
class DolphinModel;
|
||||
class DolphinSortFilterProxyModel;
|
||||
|
@ -71,7 +70,6 @@ private:
|
|||
QTimer* m_timer;
|
||||
KFileItem m_item;
|
||||
QPoint m_pos;
|
||||
KFormattedBalloonTipDelegate m_delegate;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue