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/demo.cpp

    r88 r106  
    3535extern void fade_out(int steps);
    3636
    37 void get_event(event &ev, window_manager *wm)
     37void get_event(event &ev)
    3838{ wm->get_event(ev);
    3939  switch (ev.type)
     
    5757}
    5858
    59 int event_waiting(window_manager *wm)
     59int event_waiting()
    6060{ return wm->event_waiting(); }
    6161
     
    120120        int32_t mx,my;
    121121        the_game->game_to_mouse(player_list->pointer_x,player_list->pointer_y,player_list,mx,my);
    122         eh->set_mouse_position(small_render ? mx*2 : mx, small_render ? my*2 : my);
     122        wm->set_mouse_position(small_render ? mx*2 : mx, small_render ? my*2 : my);
    123123      }
    124124      else
     
    210210      l_difficulty=initial_difficulty;
    211211      the_game->set_state(MENU_STATE);
    212       eh->push_event(new event(ID_NULL,NULL));
     212      wm->push_event(new event(ID_NULL,NULL));
    213213
    214214      view *v=player_list;
Note: See TracChangeset for help on using the changeset viewer.