On Tue,  3 Jul 2012 at 19:35:37 +0200, Rodolfo García Peñas wrote:
> 
> The function wIconCreate has now a new interface:
> 
> -WIcon * wIconCreate(WWindow *wwin);
> +WIcon *wIconCreate(WWindow *wwin, WScreen *scr, char *command,
> +                  char *instance, char *class, int tile_type);
> 
> This new interface is easy to set, because the screen, instance and class
> are included in the WWindow struct. Only command and tile_type are added.
> 
> This change is done to join the functions wIconCreate and
> wIconCreateWithIconFile.


> -             wwin->icon = wIconCreate(wwin);
> +             wwin->icon = wIconCreate(wwin, wwin->screen_ptr, NULL, 
> wwin->wm_instance,
> +                                      wwin->wm_class, TILE_NORMAL);
> +


> -     aicon->icon = wIconCreate(leader_win);
> +     aicon->icon = wIconCreate(leader_win, scr, NULL, 
> leader_win->wm_instance, leader_win->wm_class, TILE_NORMAL);

There must be another way. This is simply too ugly to live.

If you want the icon for a window 'wwin' you should simply
say wIconCreate(wwin). That's it, direct and simple.

You are proposing to pollute the call with all this other stuff that
can be obtained trivially from wwin. That makes the interface more
complicated. No.


-- 
To unsubscribe, send mail to [email protected].

Reply via email to