Changeset 1268 for code/branches/merge/src/core
- Timestamp:
- May 13, 2008, 10:13:17 PM (17 years ago)
- Location:
- code/branches/merge/src/core
- Files:
-
- 2 edited
-
InputHandler.cc (modified) (15 diffs)
-
InputManager.cc (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
code/branches/merge/src/core/InputHandler.cc
r1219 r1268 55 55 std::string keyNames[] = { 56 56 "UNASSIGNED", 57 "ESCAPE",58 "1",59 "2",60 "3",61 "4",62 "5",63 "6",64 "7",65 "8",66 "9",67 "0",68 "MINUS",69 "EQUALS",70 "BACK",71 "TAB",72 "Q",73 "W",74 "E",75 "R",76 "T",77 "Y",78 "U",79 "I",80 "O",81 "P",82 "LBRACKET",83 "RBRACKET",84 "RETURN",85 "LCONTROL",86 "A",87 "S",88 "D",89 "F",90 "G",91 "H",92 "J",93 "K",94 "L",95 "SEMICOLON",96 "APOSTROPHE",97 "GRAVE",98 "LSHIFT",99 "BACKSLASH",100 "Z",101 "X",102 "C",103 "V",104 "B",105 "N",106 "M",107 "COMMA",108 "PERIOD",109 "SLASH",110 "RSHIFT",111 "MULTIPLY",112 "LMENU",113 "SPACE",114 "CAPITAL",115 "F1",116 "F2",117 "F3",118 "F4",119 "F5",120 "F6",121 "F7",122 "F8",123 "F9",124 "F10",125 "NUMLOCK",126 "SCROLL",127 "NUMPAD7",128 "NUMPAD8",129 "NUMPAD9",130 "SUBTRACT",131 "NUMPAD4",132 "NUMPAD5",133 "NUMPAD6",134 "ADD",135 "NUMPAD1",136 "NUMPAD2",137 "NUMPAD3",138 "NUMPAD0",139 "DECIMAL",57 "ESCAPE", 58 "1", 59 "2", 60 "3", 61 "4", 62 "5", 63 "6", 64 "7", 65 "8", 66 "9", 67 "0", 68 "MINUS", 69 "EQUALS", 70 "BACK", 71 "TAB", 72 "Q", 73 "W", 74 "E", 75 "R", 76 "T", 77 "Y", 78 "U", 79 "I", 80 "O", 81 "P", 82 "LBRACKET", 83 "RBRACKET", 84 "RETURN", 85 "LCONTROL", 86 "A", 87 "S", 88 "D", 89 "F", 90 "G", 91 "H", 92 "J", 93 "K", 94 "L", 95 "SEMICOLON", 96 "APOSTROPHE", 97 "GRAVE", 98 "LSHIFT", 99 "BACKSLASH", 100 "Z", 101 "X", 102 "C", 103 "V", 104 "B", 105 "N", 106 "M", 107 "COMMA", 108 "PERIOD", 109 "SLASH", 110 "RSHIFT", 111 "MULTIPLY", 112 "LMENU", 113 "SPACE", 114 "CAPITAL", 115 "F1", 116 "F2", 117 "F3", 118 "F4", 119 "F5", 120 "F6", 121 "F7", 122 "F8", 123 "F9", 124 "F10", 125 "NUMLOCK", 126 "SCROLL", 127 "NUMPAD7", 128 "NUMPAD8", 129 "NUMPAD9", 130 "SUBTRACT", 131 "NUMPAD4", 132 "NUMPAD5", 133 "NUMPAD6", 134 "ADD", 135 "NUMPAD1", 136 "NUMPAD2", 137 "NUMPAD3", 138 "NUMPAD0", 139 "DECIMAL", 140 140 "","", 141 "OEM_102",142 "F11",143 "F12",141 "OEM_102", 142 "F11", 143 "F12", 144 144 "","","","","","","","","","","", 145 "F13",146 "F14",147 "F15",145 "F13", 146 "F14", 147 "F15", 148 148 "","","","","","","","","","", 149 "KANA",149 "KANA", 150 150 "","", 151 "ABNT_C1",151 "ABNT_C1", 152 152 "","","","","", 153 "CONVERT",154 "", 155 "NOCONVERT",156 "", 157 "YEN",158 "ABNT_C2",153 "CONVERT", 154 "", 155 "NOCONVERT", 156 "", 157 "YEN", 158 "ABNT_C2", 159 159 "","","","","","","","","","","","","","", 160 "NUMPADEQUALS",160 "NUMPADEQUALS", 161 161 "","", 162 "PREVTRACK",163 "AT",164 "COLON",165 "UNDERLINE",166 "KANJI",167 "STOP",168 "AX",169 "UNLABELED",170 "NEXTTRACK",162 "PREVTRACK", 163 "AT", 164 "COLON", 165 "UNDERLINE", 166 "KANJI", 167 "STOP", 168 "AX", 169 "UNLABELED", 170 "NEXTTRACK", 171 171 "","", 172 "NUMPADENTER",173 "RCONTROL",172 "NUMPADENTER", 173 "RCONTROL", 174 174 "","", 175 "MUTE",176 "CALCULATOR",177 "PLAYPAUSE",178 "", 179 "MEDIASTOP",175 "MUTE", 176 "CALCULATOR", 177 "PLAYPAUSE", 178 "", 179 "MEDIASTOP", 180 180 "","","","","","","","","", 181 "VOLUMEDOWN",182 "", 183 "VOLUMEUP",184 "", 185 "WEBHOME",186 "NUMPADCOMMA",187 "", 188 "DIVIDE",189 "", 190 "SYSRQ",191 "RMENU",181 "VOLUMEDOWN", 182 "", 183 "VOLUMEUP", 184 "", 185 "WEBHOME", 186 "NUMPADCOMMA", 187 "", 188 "DIVIDE", 189 "", 190 "SYSRQ", 191 "RMENU", 192 192 "","","","","","","","","","","","", 193 "PAUSE",194 "", 195 "HOME",196 "UP",197 "PGUP",198 "", 199 "LEFT",200 "", 201 "RIGHT",202 "", 203 "END",204 "DOWN",205 "PGDOWN",206 "INSERT",207 "DELETE",193 "PAUSE", 194 "", 195 "HOME", 196 "UP", 197 "PGUP", 198 "", 199 "LEFT", 200 "", 201 "RIGHT", 202 "", 203 "END", 204 "DOWN", 205 "PGDOWN", 206 "INSERT", 207 "DELETE", 208 208 "","","","","","","", 209 "LWIN",210 "RWIN",211 "APPS",212 "POWER",213 "SLEEP",209 "LWIN", 210 "RWIN", 211 "APPS", 212 "POWER", 213 "SLEEP", 214 214 "","","", 215 "WAKE",216 "", 217 "WEBSEARCH",218 "WEBFAVORITES",219 "WEBREFRESH",220 "WEBSTOP",221 "WEBFORWARD",222 "WEBBACK",223 "MYCOMPUTER",224 "MAIL",225 "MEDIASELECT"215 "WAKE", 216 "", 217 "WEBSEARCH", 218 "WEBFAVORITES", 219 "WEBREFRESH", 220 "WEBSTOP", 221 "WEBFORWARD", 222 "WEBBACK", 223 "MYCOMPUTER", 224 "MAIL", 225 "MEDIASELECT" 226 226 }; 227 227 for (int i = 0; i < numberOfKeys_s; i++) … … 229 229 230 230 std::string mouseButtonNames[] = { 231 "MouseLeft", "MouseRight", "MouseMiddle",232 "MouseButton3", "MouseButton4", "MouseButton5",233 "MouseButton6", "MouseButton7" };231 "MouseLeft", "MouseRight", "MouseMiddle", 232 "MouseButton3", "MouseButton4", "MouseButton5", 233 "MouseButton6", "MouseButton7" }; 234 234 for (int i = 0; i < numberOfMouseButtons_s; i++) 235 235 mouseButtonNames_[i] = mouseButtonNames[i]; … … 393 393 // binding.commandStr = binding.evaluation.getCommandString(); 394 394 //} 395 COUT( 3) << "Executing command: " << binding.commandStr << std::endl;395 COUT(ORX_DEBUG) << "Keybinding: Executing command: " << binding.commandStr << std::endl; 396 396 CommandExecutor::execute(binding.commandStr); 397 397 } … … 407 407 bool KeyBinder::keyPressed(const OIS::KeyEvent &e) 408 408 { 409 COUT(3) << "Key: " << e.key << std::endl;409 //COUT(ORX_DEBUG) << "Key: " << e.key << std::endl; 410 410 // find the appropriate key binding 411 411 executeBinding(bindingsKeyPress_[int(e.key)]); … … 459 459 { 460 460 CommandExecutor::execute(cmdStr); 461 COUT(3) << "Executing command: " << cmdStr << std::endl;461 //COUT(3) << "Executing command: " << cmdStr << std::endl; 462 462 } 463 463 … … 477 477 { 478 478 CommandExecutor::execute(cmdStr); 479 COUT(3) << "Executing command: " << cmdStr << std::endl;479 //COUT(3) << "Executing command: " << cmdStr << std::endl; 480 480 } 481 481 … … 495 495 { 496 496 CommandExecutor::execute(cmdStr); 497 COUT(3) << "Executing command: " << cmdStr << std::endl;497 //COUT(3) << "Executing command: " << cmdStr << std::endl; 498 498 } 499 499 … … 508 508 { 509 509 CommandExecutor::execute(cmdStr); 510 COUT(3) << "Executing command: " << cmdStr << std::endl;510 //COUT(3) << "Executing command: " << cmdStr << std::endl; 511 511 } 512 512 … … 521 521 { 522 522 CommandExecutor::execute(cmdStr); 523 COUT(3) << "Executing command: " << cmdStr << std::endl;523 //COUT(3) << "Executing command: " << cmdStr << std::endl; 524 524 } 525 525 … … 534 534 { 535 535 CommandExecutor::execute(cmdStr); 536 COUT(3) << "Executing command: " << cmdStr << std::endl;536 //COUT(3) << "Executing command: " << cmdStr << std::endl; 537 537 } 538 538 … … 586 586 //bool GUIInputHandler::keyPressed(const OIS::KeyEvent &e) 587 587 //{ 588 ////CEGUI::System::getSingleton().injectKeyDown( arg.key );589 ////CEGUI::System::getSingleton().injectChar( arg.text );588 ////CEGUI::System::getSingleton().injectKeyDown( arg.key ); 589 ////CEGUI::System::getSingleton().injectChar( arg.text ); 590 590 // return true; 591 591 //} … … 597 597 //bool GUIInputHandler::keyReleased(const OIS::KeyEvent &e) 598 598 //{ 599 ////CEGUI::System::getSingleton().injectKeyUp( arg.key );599 ////CEGUI::System::getSingleton().injectKeyUp( arg.key ); 600 600 // return true; 601 601 //} … … 607 607 //bool GUIInputHandler::mouseMoved(const OIS::MouseEvent &e) 608 608 //{ 609 ////CEGUI::System::getSingleton().injectMouseMove( arg.state.X.rel, arg.state.Y.rel );609 ////CEGUI::System::getSingleton().injectMouseMove( arg.state.X.rel, arg.state.Y.rel ); 610 610 // return true; 611 611 //} … … 618 618 //bool GUIInputHandler::mousePressed(const OIS::MouseEvent &e, OIS::MouseButtonID id) 619 619 //{ 620 ////CEGUI::System::getSingleton().injectMouseButtonDown(convertOISMouseButtonToCegui(id));620 ////CEGUI::System::getSingleton().injectMouseButtonDown(convertOISMouseButtonToCegui(id)); 621 621 // return true; 622 622 //} … … 629 629 //bool GUIInputHandler::mouseReleased(const OIS::MouseEvent &e, OIS::MouseButtonID id) 630 630 //{ 631 ////CEGUI::System::getSingleton().injectMouseButtonUp(convertOISMouseButtonToCegui(id));631 ////CEGUI::System::getSingleton().injectMouseButtonUp(convertOISMouseButtonToCegui(id)); 632 632 // return true; 633 633 //} -
code/branches/merge/src/core/InputManager.cc
r1219 r1268 92 92 if (state_ == IS_UNINIT) 93 93 { 94 CCOUT(3) << "Initialising Input System..." << std::endl; 94 95 CCOUT(ORX_DEBUG) << "Initialising OIS components..." << std::endl; 95 96
Note: See TracChangeset
for help on using the changeset viewer.










