Re: event/signal "on-top" [ clarification ]



Just had a look at www.touchtunes.com :-)

And finally I caught the idea - you want to build a semi "visual authoring
tool", like a little shockwave, authorware, ... based on Gtk+ and Glade.

But back to your original problem... we're getting to deep into details, I
don't want to think about - that's your job ;-)

If you want to know, if you are "on top" I would do

gboolean on_top(GtkWidget *me)
{
        if( me != NULL ) {
                while( me->parent != NULL && ! IS_GTK_WINDOW( me ) )
                        me = me->parent;
                if( IS_GTK_WINDOW( me ) )
                        return gtk_window_has_toplevel_focus
                                ( GTK_WINDOW( me ) );
        }
        return FALSE;
}

or gtk_window_is_active()

HTH

Jan-Marek



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