gdk_pointer_grab() problem



Hi All,

I've been trying to write an application (using Glade) which grabs the
mouse as soon as it starts.
However I've been unable to reach any success. If I try to do

  gtk_widget_show (window1);

  grab_widget = lookup_widget(window1, "fixed1");

  gdk_pointer_grab(grab_widget->window,
                    TRUE, 0,
                    NULL, NULL, GDK_CURRENT_TIME);

I get no visible result.

However, if I do it from some signals, such as from button_clicked, it
works. Can somebody enlighten me?
GTK 1.2.6.

I've been searching both the GTK/GDK docs as well as mailing lists to
clarify this issue without success.

--
Best Regards
Vladimir Ivaschenko
Certified Linux Engineer (RHCE)
Francoudi & Stephanou Ltd - http://www.francoudi.com






[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]