Changeset 7a70e26


Ignore:
Timestamp:
Jun 1, 2010, 1:25:15 AM (11 years ago)
Author:
David Benjamin <davidben@mit.edu>
Branches:
master, release-1.7, release-1.8, release-1.9
Children:
7a6e6c7
Parents:
e00355d
Message:
Punt owl_window_children_foreach_onearg

Use GFunc casts everywhere. This horrid and depends on calling
convention, but glib relies on it EVERYWHERE. If our environment doesn't
support it, we'll have worse problems anyway.
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • window.c

    re00355d r7a70e26  
    233233}
    234234
    235 void owl_window_children_foreach_onearg(owl_window *parent, void (*func)(owl_window*))
    236 {
    237   owl_window_children_foreach(parent, (GFunc)func, NULL);
    238 }
    239 
    240235owl_window *owl_window_get_parent(owl_window *w)
    241236{
     
    289284{
    290285  owl_window_show(w);
    291   owl_window_children_foreach_onearg(w, owl_window_show);
     286  owl_window_children_foreach(w, (GFunc)owl_window_show, 0);
    292287}
    293288
     
    331326  owl_window_dirty(w);
    332327  /* map the children */
    333   owl_window_children_foreach_onearg(w, _owl_window_realize);
     328  owl_window_children_foreach(w, (GFunc)_owl_window_realize, 0);
    334329}
    335330
     
    339334    return;
    340335  /* unmap all the children */
    341   owl_window_children_foreach_onearg(w, _owl_window_unrealize);
     336  owl_window_children_foreach(w, (GFunc)_owl_window_unrealize, 0);
    342337  _owl_window_destroy_curses(w);
    343338  /* subwins leave a mess in the parent; dirty it */
     
    367362void owl_window_dirty_children(owl_window *w)
    368363{
    369   owl_window_children_foreach_onearg(w, owl_window_dirty);
     364  owl_window_children_foreach(w, (GFunc)owl_window_dirty, 0);
    370365}
    371366
     
    385380    return;
    386381  _owl_window_redraw(w);
    387   owl_window_children_foreach_onearg(w, _owl_window_redraw_subtree);
     382  owl_window_children_foreach(w, (GFunc)_owl_window_redraw_subtree, 0);
    388383}
    389384
     
    465460  }
    466461  /* recalculate children sizes BEFORE remapping, so that everything can resize */
    467   owl_window_children_foreach_onearg(w, owl_window_recompute_position);
     462  owl_window_children_foreach(w, (GFunc)owl_window_recompute_position, 0);
    468463  if (w->shown) {
    469464    _owl_window_realize(w);
  • window.h

    re00355d r7a70e26  
    3434
    3535void owl_window_children_foreach(owl_window *parent, GFunc func, gpointer user_data);
    36 void owl_window_children_foreach_onearg(owl_window *parent, void (*func)(owl_window*));
    3736owl_window *owl_window_get_parent(owl_window *w);
    3837
Note: See TracChangeset for help on using the changeset viewer.