Ignore:
Timestamp:
Mar 15, 2008, 12:55:44 AM (11 years ago)
Author:
Sam Hocevar
Message:
  • Rename the "eh" variable to "wm" because it's a window manager, not an event handler.
  • No longer pass the window manager to functions, there's only one.

Inspired by Win32 Abuse changelog for January 28, 2001:

  • Starting work on singleton code; will get rid of all

references to an arbitrary window_manager* because
there's only going to be one, and it's not ever
going to change.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • abuse/trunk/src/gui.hpp

    r57 r106  
    2121  ico_button(int X, int Y, int ID, int Up, int down, int upa, int downa, ifield *Next, int act_id=-1, char const *help_key=NULL);
    2222
    23   virtual void area(int &x1, int &y1, int &x2, int &y2, window_manager *wm);
    24   virtual void draw_first(image *screen, window_manager *wm) { draw(0,screen,wm); }
    25   virtual void draw(int active, image *screen, window_manager *wm);
    26   virtual void handle_event(event &ev, image *screen, window_manager *wm, input_manager *im);
     23  virtual void area(int &x1, int &y1, int &x2, int &y2);
     24  virtual void draw_first(image *screen) { draw(0,screen); }
     25  virtual void draw(int active, image *screen);
     26  virtual void handle_event(event &ev, image *screen, input_manager *im);
    2727
    2828  virtual char *read() { return (char *)&up; }
     
    4040  public :
    4141  ico_switch_button(int X, int Y, int ID, int start_on, ifield *butts, ifield *Next);
    42   virtual void area(int &x1, int &y1, int &x2, int &y2, window_manager *wm);
    43   virtual void draw_first(image *screen, window_manager *wm) { cur_but->draw_first(screen,wm); }
    44   virtual void draw(int active, image *screen, window_manager *wm) { cur_but->draw(active,screen,wm); act=active; }
    45   virtual void handle_event(event &ev, image *screen, window_manager *wm, input_manager *im);
     42  virtual void area(int &x1, int &y1, int &x2, int &y2);
     43  virtual void draw_first(image *screen) { cur_but->draw_first(screen); }
     44  virtual void draw(int active, image *screen) { cur_but->draw(active,screen); act=active; }
     45  virtual void handle_event(event &ev, image *screen, input_manager *im);
    4646  virtual ifield *unlink(int id);
    4747  virtual char *read() { return cur_but->read(); }
Note: See TracChangeset for help on using the changeset viewer.