diff options
| author | Albrecht Schlosser <albrechts.fltk@online.de> | 2010-06-15 07:49:26 +0000 |
|---|---|---|
| committer | Albrecht Schlosser <albrechts.fltk@online.de> | 2010-06-15 07:49:26 +0000 |
| commit | 37ef57934fd28c3f663d88898f4f6c6eb20e595e (patch) | |
| tree | 9308ded7eb80afce0018b5ba1aae024d665396fc /src | |
| parent | 41f7ed547713d710d9418867257d58001c19c872 (diff) | |
Fixed regressions introduced with svn -r 7627.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7640 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src')
| -rw-r--r-- | src/Fl_x.cxx | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/Fl_x.cxx b/src/Fl_x.cxx index 5b7f2c520..863f9e794 100644 --- a/src/Fl_x.cxx +++ b/src/Fl_x.cxx @@ -138,7 +138,9 @@ void Fl::add_fd(int n, void (*cb)(int, void*), void* v) { void Fl::remove_fd(int n, int events) { int i,j; +# if !USE_POLL maxfd = -1; // recalculate maxfd on the fly +# endif for (i=j=0; i<nfds; i++) { # if USE_POLL if (pollfds[i].fd == n) { @@ -152,8 +154,8 @@ void Fl::remove_fd(int n, int events) { if (!e) continue; // if no events left, delete this fd fd[i].events = e; } -# endif if (fd[i].fd > maxfd) maxfd = fd[i].fd; +# endif // move it down in the array if necessary: if (j<i) { fd[j] = fd[i]; @@ -1588,6 +1590,13 @@ void Fl_X::make_xid(Fl_Window* win, XVisualInfo *visual, Colormap colormap) XFree(hints); } + // set the window type for menu and tooltip windows to avoid animations (compiz) + if (win->menu_window() || win->tooltip_window()) { + Atom net_wm_type = XInternAtom(fl_display, "_NET_WM_WINDOW_TYPE", False); + Atom net_wm_type_kind = XInternAtom(fl_display, "_NET_WM_WINDOW_TYPE_MENU", False); + int ret = XChangeProperty(fl_display, xp->xid, net_wm_type, XA_ATOM, 32, PropModeReplace, (unsigned char*)&net_wm_type_kind, 1); + } + XMapWindow(fl_display, xp->xid); if (showit) { win->set_visible(); |
