Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 4362 in orxonox.OLD for orxonox/trunk/src


Ignore:
Timestamp:
May 28, 2005, 2:52:27 PM (20 years ago)
Author:
patrick
Message:

orxonox/trunk: type specific event handling routine

Location:
orxonox/trunk/src/util/event
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/util/event/event.h

    r4361 r4362  
    2323  int offset;                      //!< offset in the event type array
    2424  char cmd[CMD_LENGHT];            //!< the command delivered
     25  int type;                        //!< the type field
    2526  bool bPressed;                   //!< is true, if the button/mouse was pressed, false if released
    2627       
  • orxonox/trunk/src/util/event/event_handler.cc

    r4361 r4362  
    223223        case SDL_KEYDOWN:
    224224          ev.bPressed = true;
    225           listener = this->listeners[this->state][event.key.keysym.sym];
    226           //if( listener != NULL)
    227             //listener->process();
     225          ev.type = event.key.keysym.sym;
    228226          break;
    229227        case SDL_KEYUP:
    230           /*
    231           strcpy( cmd.cmd, aliases->keys[event.key.keysym.sym]);
    232           cmd.bUp = true;
    233           if( strlen (cmd.cmd) > 0) relay(&cmd);
    234           */
     228          ev.bPressed = false;
     229          ev.type = event.key.keysym.sym;
    235230          break;
    236231        case SDL_MOUSEMOTION:
     
    267262          break;
    268263        }
    269     }
    270 }
     264
     265      listener = this->listeners[this->state][event.key.keysym.sym];
     266      //if( listener != NULL)
     267      //listener->process();
     268     
     269    }
     270}
  • orxonox/trunk/src/util/event/event_handler.h

    r4355 r4362  
    1212
    1313class EventListener;
    14 template<class T> class tList;
     14
    1515
    1616
     
    2424    ES_GAME_MENU,
    2525    ES_MENU,
     26
     27    ES_ALL,
    2628
    2729    ES_NUMBER,
Note: See TracChangeset for help on using the changeset viewer.