Add support for tooltips for system tray icons
frank.richter at gmail.com
Fri Aug 25 14:45:00 CDT 2006
On 25.08.2006 21:10, James Liggett wrote:
> On Fri, 2006-08-25 at 20:19 +0200, Frank Richter wrote:
>> Hm, wouldn't it be more economic to try to use one tooltip for all icons?
>>From a purely memory-consumption standpoint, yes. But there are still
> issues with that. One is that we'd have to handle every mouse event to
> see where the cursor is to make sure the tooltip had the right text for
> the right icon.
AFAICS tooltip can contain multiple "tools". Each tool is given a
rectangle. So perhaps make one tool per icon, with matching rectangle?
Second is the window-rectangle issue. the problem is
> that once a tray docks our icon, we basically don't own it, so we don't
> know exactly what the tray is going to do with it, and thus we don't
> know exactly where the window is going to be, and I don't see a viable
> way to find out.
Is there no way to get notifications of window movements? At any rate,
getting right rectangles seems crucial for tooltips to work properly.
Thus, we need to have one tooltip per icon window for
> this to work. In fact, there's a small bug in my submitted patch. If you
> use it, start one program that uses a tray icon. Then start another
> program that uses an icon. Close out the first program so that only the
> second icon is left in the tray. You'll notice that the tooltip for this
> remaining icon doesn't work anymore, because the window's rectangle
> changed behind Explorer's back. My current solution is to associate
> tooltips with whole windows (using the TTF_IDISHWND flag in the
> TTTOOLINFO.uFlags parameter) instead of rectangular areas. This way,
> icons' tooltips continue to function even if their positions in the tray
> are changed.
How does the tooltip track the correct rect then? If it can do it, you
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 250 bytes
Desc: OpenPGP digital signature
Url : http://www.winehq.org/pipermail/wine-devel/attachments/20060825/ad0626a5/signature.pgp
More information about the wine-devel