Skip to content

Commit

Permalink
+ fix override/restore cursor issue with task panel
Browse files Browse the repository at this point in the history
  • Loading branch information
wwmayer committed Jul 12, 2014
1 parent f91c64a commit 8f7966e
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions src/Gui/iisTaskPanel/src/iisiconlabel.cpp
Expand Up @@ -19,6 +19,7 @@ iisIconLabel::iisIconLabel(const QIcon &icon, const QString &title, QWidget *par
m_underlineOver(true)
{
setFocusPolicy(Qt::StrongFocus);
setCursor(Qt::PointingHandCursor);

myFont.setWeight(0);
myPen.setStyle(Qt::NoPen);
Expand All @@ -28,8 +29,8 @@ iisIconLabel::iisIconLabel(const QIcon &icon, const QString &title, QWidget *par

iisIconLabel::~iisIconLabel()
{
if (m_changeCursorOver)
QApplication::restoreOverrideCursor();
//if (m_changeCursorOver)
// QApplication::restoreOverrideCursor();
}

void iisIconLabel::setSchemePointer(iisIconLabelScheme **pointer)
Expand Down Expand Up @@ -141,8 +142,8 @@ void iisIconLabel::enterEvent ( QEvent * /*event*/ )
{
m_over = true;

if (m_changeCursorOver)
QApplication::setOverrideCursor(Qt::PointingHandCursor);
//if (m_changeCursorOver)
// QApplication::setOverrideCursor(Qt::PointingHandCursor);

update();
}
Expand All @@ -152,8 +153,8 @@ void iisIconLabel::leaveEvent ( QEvent * /*event*/ )
m_over = false;
update();

if (m_changeCursorOver)
QApplication::restoreOverrideCursor();
//if (m_changeCursorOver)
// QApplication::restoreOverrideCursor();
}

void iisIconLabel::mousePressEvent ( QMouseEvent * event )
Expand Down

0 comments on commit 8f7966e

Please sign in to comment.