Thu Feb 12 23:59:49 1998 Owen Taylor <owt1@cornell.edu>
* gtk/gtksignal.[ch] gtk/gtkmain.[ch] gtk/gtkcontainer.[ch]
gtk/gtkselection.[ch] gdk/gdk.[ch] gtktypeutils.h
Replaced all _interp functions with _full functions.
(_interp functions left in for compatibility until 0.99.5).
Difference: _full functions take _both_ a C-language callback and a
marshaller, and simply ignore the C-language callback
if the marshaller is present. This allows the destroy notification
to be used without marshalling.
gtk_selection_add_handler[_full]() regularized to agree
with other callbacks.
Also, added gtk_input_add_full() to the header file.
(gtk_input_add_interp() was never there)
* gtk/gtkmain.[ch] gtk/gtkwidget.c: Idle functions are now prioritized.
Added new function gtk_idle_add_priority to create
an idle with a specified priority (default is zero)
constants #defined - GTK_PRIORITY_[HIGH/INTERNAL/DEFAULT/LOW]
(redraws, resizes run at GTK_PRIORITY_INTERNAL)
* gtk/gtkentry.c gtk/testselection.c: changes to keep up with change
to gtkselection.c.
Wed Feb 11 00:18:31 1998 Tim Janik <timj@gimp.org>
* gtk/gtksignal.h:
* gtk/gtksignal.c: new function gtk_signal_handler_pending() returning
the id of the next handler pending for that signal or 0.
put struct GtkHandler back into gtksignal.c along with
gtk_signal_get_handlers.
Tue Feb 10 07:12:07 1998 Tim Janik <timj@gimp.org>
* gtk/gtksignal.h:
* gtk/gtksignal.c:
ok, there have been several severe bugs in the signal handler
referencing and ->next connection stuff. these bugs caused
invokations of handlers that are disconnected and - worse -
destroyed already. invokation of *destroyd* handlers mean:
anything can be executed , because the handler structure can just
as well be realocated.
at the cost of an extra ->prev field per handler we should have a
reasonable stable system now, because of the various places that
can cause a handler to be disconnected (*any* handler invokation can
cause *any* or *all* handlers to be disconnected, there is no way
around a doubly linked list, actually handler disconnection has never
worked correctly because of this.
handlers are connected together via a *doubly* linked list now, and it
is *not* valid to remove a handler out of this list untill all its
references have been droped, i.e. handler->ref_count==0.
to prevent emissions of disconnected but still referenced handlers,
disconnected handlers are simply marked as blocked and get an id of 0
which is an invalid signal handler id.
the handler->id has been changed to have 28 significant bits (using
alignment gaps), since 65536 (old range: guint16) signal connections
(as a total) can easily be reached by complex applications.
this whole handler thingy is at least as tedious as writing doubly
linked list implementations ;)
Mon Feb 9 16:42:21 1998 Miguel de Icaza <miguel@nuclecu.unam.mx>
* gtk/gtksignal.c (gtk_signal_get_handlers): no longer a private
routine;
gtksignal.h: export gtk_signal_get_handlers and GtkHandlers type.
Tue Feb 3 15:09:55 1998 Tim Janik <timj@gimp.org>
* gtk/gtksignal.c (gtk_signal_real_emit): for the emission
of AFTER signals, fetch the objects signals via
gtk_signal_get_handlers again. some handlers might have
been removed or added. not doing this would mess up the
memchunk allocation of signal handlers (this had been
triggered by multiple *_while_alive connections), bad, bad, bad!
(gtk_handlers_run): do the referencing on signal handlers
unconditionally, the invokation of AFTER handlers will now take
care of modified lists.
* gtk/gtksignal.h: added gtk_signal_connect_while_alive.
Mon Feb 2 04:15:08 1998 Tim Janik <timj@gimp.org>
* gtk/gtkcontainer.h:
* gtk/gtkcontainer.c: GTK_RESIZE_NEEDED is a private flag now.
(gtk_container_register_toplevel): new function.
(gtk_container_unregister_toplevel): new function.
* gtk/gtkmain.c: GTK_LEAVE_PENDING is a private flag now.
* gtk/gtkmenu.c: call gtk_container_register_toplevel in
gtk_menu_class_init instead of this dirty gtk_widget_set_parent(,NULL)
hack. new default handler gtk_menu_destroy for calling
gtk_container_unregister_toplevel. removed GTK_ANCHORED, GTK_UNMAPPED.
* gtk/gtkobject.h: macro cleanups, added GTK_DESTROYED flag.
* gtk/gtkobject.c: only emit DESTROY signal if !GTK_OBJECT_DESTROYED
(object).
* gtk/gtkprivate.h: new file that will not be automatically included.
it holds the private flags for GtkWidget along with it's SET/UNSET
and examination macros.
* gtk/gtkwidget.c: private flags: GTK_RESIZE_NEEDED, GTK_REDRAW_PENDING,
GTK_RESIZE_PENDING, GTK_IN_REPARENT, GTK_USER_STYLE. GTK_ANCHORED is
replaced by GTK_TOPLEVEL. added missing UNSET for GTK_IN_REPARENT.
removed the gtk_widget_set_parent(, NULL) hack for toplevels.
upon destroy free memory for widgets with GTK_WIDGET_HAS_SHAPE_MASK.
* gtk/gtkwidget.h: split up the widget flags into a public and a private
portion. added an extra field private_flags to GtkWidget without making
it bigger by using an alignment gap of 16 bit. macro cleanups.
* gtk/gtkwindow.c: removed GTK_ANCHORED. new function gtk_window_destroy
for calling gtk_container_unregister_toplevel. removed the
gtk_widget_set_parent(,NULL), call gtk_container_register_toplevel
instead. remove GTK_UNMAPPED. GTK_RESIZE_NEEDED is private now.
* gtk/gtksignal.c (gtk_signal_disconnect): removed a bug on
removal that cut off the handler list -> living_objects == 0
with testgtk. made some warnings more descriptive.
new function gtk_signal_connect_object_while_alive, which
will automatically destroy the connection once one of the objects
is destroyed. didn't include this before removal of the above
mentioned bug.
* reflected refcounting revolution in ChangeLog
Sun Jan 25 19:15:32 1998 Tim Janik <timj@gimp.org>
* gtk/gtkwidget.h (enum): added new widget flag GTK_LEAVE_PENDING.
* gtk/gtkmain.c (gtk_main_iteration_do): if a widget has
GTK_LEAVE_PENDING set, send it its LEAVE_NOTIFY event, regardless
of a grab or sensitivity.
changed the compression code for enter/leave notify events to
free *both* compressed event, and removed an unneccessary call
to g_list_remove.
* ChangeLog: finally catched up with the recent changes on my part.
Sun Jan 18 03:57:52 1998 Tim Janik <timj@psynet.net>
* gtk/gtkframe.c: gtk_*_get_arg() and gtk_*_set_arg() implementations.
* gtk/gtkobject.c: new arg `GtkObject::object_signal' similar to
`GtkObject::signal'. check for class type in gtk_object_{setv|getv}.
* gtk/gtkobject.c:
* gtk/gtksignal.c:
* gtk/gtktypeutils.h:
* gtk/gtktypeutils.c: added GTK_TYPE_DOUBLE.
* gtk/gtkwidget.c: new args `has_focus' and `has_default'.
* gtk/gtkwindow.c: new arg `window_position'.