Jan 25, 2012 at 1:22 PM
Edited Jan 25, 2012 at 1:51 PM
|
We have tried to use this tooltip service to extend the show duration to 30 seconds with a dynamical, databinding DataGrid to show some cell information. We have met the issue of not-closing tooltips -- same tooltip popup can occur many times and unable
to close...
We are forced to roll back to the default tooltip service, which only shows tooltips for 5 seconds.
We do not need any animation to bring up a tooltip, only extend its life so that the user have time to read the info in it.
Could someone give me a hint as to how to fix tooltips do not close issue?
I have added the following methods
ToolTipService class:
public static void CloseAllToolTips()
{
lock (locker)
{
if (elementsAndToolTips.Count > 0)
{
foreach (var kvp in elementsAndToolTips)
{
kvp.Value.IsOpen = false;
kvp.Value.Timer.StopAndReset();
}
}
}
}
public static void RemoveAllToolTips()
{
lock (locker)
{
if (elementsAndToolTips.Count > 0)
{
foreach (var kvp in elementsAndToolTips)
{
kvp.Value.IsOpen = false;
kvp.Value.Timer.StopAndReset();
}
}
elementsAndToolTips.Clear();
}
}
to close the tooltips with some event, but still see some tooltips do not go away.
|