*fix* use XFlush to really make use of the tooltip timeouts and do not rely on some timer running in the background
*fix* moved panel_refresh in the mainloop to the top for panels without a clock for updating first and then going to the pselect statement *changed* battery updates every 5 secs (I do not know if this is a good value...) *fix* blinking urgent windows has a panel_refresh now git-svn-id: http://tint2.googlecode.com/svn/trunk@270 121b4492-b84c-0410-8b4c-0d4edfb3f3cc
This commit is contained in:
@@ -62,7 +62,7 @@ void init_tooltip()
|
||||
|
||||
XSetWindowAttributes attr;
|
||||
attr.override_redirect = True;
|
||||
attr.event_mask = ExposureMask;
|
||||
attr.event_mask = StructureNotifyMask;
|
||||
if (g_tooltip.window) XDestroyWindow(server.dsp, g_tooltip.window);
|
||||
g_tooltip.window = XCreateWindow(server.dsp, server.root_win, 0, 0, 100, 20, 0, server.depth, InputOutput, CopyFromParent, CWOverrideRedirect|CWEventMask, &attr);
|
||||
}
|
||||
@@ -106,10 +106,11 @@ void tooltip_trigger_show(Task* task, int x_root, int y_root)
|
||||
|
||||
void tooltip_show()
|
||||
{
|
||||
stop_timeouts();
|
||||
if (!g_tooltip.mapped) {
|
||||
g_tooltip.mapped = True;
|
||||
XMapWindow(server.dsp, g_tooltip.window);
|
||||
//tooltip_update();
|
||||
XFlush(server.dsp);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -198,7 +199,7 @@ void tooltip_update()
|
||||
return;
|
||||
}
|
||||
|
||||
//printf("tooltip_update\n");
|
||||
// printf("tooltip_update\n");
|
||||
tooltip_update_geometry();
|
||||
tooltip_adjust_geometry();
|
||||
XMoveResizeWindow(server.dsp, g_tooltip.window, x, y, width, height);
|
||||
@@ -254,9 +255,11 @@ void tooltip_trigger_hide(Tooltip* tooltip)
|
||||
|
||||
void tooltip_hide()
|
||||
{
|
||||
stop_timeouts();
|
||||
if (g_tooltip.mapped) {
|
||||
g_tooltip.mapped = False;
|
||||
XUnmapWindow(server.dsp, g_tooltip.window);
|
||||
XFlush(server.dsp);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user