Add possibility to delay showing wxRichToolTip.

Optionally show the tooltip after a delay instead of doing it immediately when
Show() is called.

Closes #14846.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72997 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2012-11-23 14:32:15 +00:00
parent 77c8efc8c3
commit 3c3b6f6063
9 changed files with 91 additions and 38 deletions

View File

@@ -3,7 +3,7 @@
// Purpose: wxRichToolTipGenericImpl declaration.
// Author: Vadim Zeitlin
// Created: 2011-10-18
// RCS-ID: $Id: wxhead.h,v 1.12 2010-04-22 12:44:51 zeitlin Exp $
// RCS-ID: $Id$
// Copyright: (c) 2011 Vadim Zeitlin <vadim@wxwidgets.org>
// Licence: wxWindows licence
///////////////////////////////////////////////////////////////////////////////
@@ -30,13 +30,15 @@ public:
// This is pretty arbitrary, we could follow MSW and use some multiple
// of double-click time here.
m_timeout = 5000;
m_delay = 0;
}
virtual void SetBackgroundColour(const wxColour& col,
const wxColour& colEnd);
virtual void SetCustomIcon(const wxIcon& icon);
virtual void SetStandardIcon(int icon);
virtual void SetTimeout(unsigned milliseconds);
virtual void SetTimeout(unsigned milliseconds,
unsigned millisecondsDelay = 0);
virtual void SetTipKind(wxTipKind tipKind);
virtual void SetTitleFont(const wxFont& font);
@@ -52,7 +54,8 @@ private:
wxColour m_colStart,
m_colEnd;
unsigned m_timeout;
unsigned m_timeout,
m_delay;
wxTipKind m_tipKind;