- Timestamp:
- Aug 24, 2005, 3:22:31 AM (19 years ago)
- Location:
- trunk/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/lib/coord/p_node.cc
r5118 r5119 78 78 PNode::~PNode () 79 79 { 80 printf("deleting %s::%s\n", this->getClassName(), this->getName());81 80 tIterator<PNode>* iterator = this->children->getIterator(); 82 81 PNode* pn = iterator->firstElement(); -
trunk/src/util/shell.cc
r5118 r5119 69 69 EventHandler* evh = EventHandler::getInstance(); 70 70 evh->subscribe(this, ES_ALL, SDLK_BACKQUOTE); 71 for (int i = 1; i < SDLK_ F15; i++)71 for (int i = 1; i < SDLK_LAST; i++) 72 72 evh->subscribe(this, ES_SHELL, i); 73 73 } … … 105 105 106 106 107 /** 108 * activates the shell 109 * 110 * This also feeds the Last few lines from the main buffers into the displayBuffer 111 */ 107 112 void Shell::activate() 108 113 { … … 119 124 } 120 125 126 /** 127 * deactiveates the Shell. 128 */ 121 129 void Shell::deactivate() 122 130 { … … 130 138 } 131 139 140 /** 141 * sets the size of the text and spacing 142 * @param textSize the size of the Text in Pixels 143 * @param lineSpacing the size of the Spacing between two lines in pixels 144 * 145 * this also rebuilds the entire Text, inputLine and displayBuffer, 146 * to be accurate again. 147 */ 132 148 void Shell::setTextSize(unsigned int textSize, unsigned int lineSpacing) 133 149 { … … 150 166 this->setBufferDisplaySize(this->bufferDisplaySize); 151 167 } 152 153 154 168 155 169 /** … … 421 435 { 422 436 if (EventHandler::getInstance()->getState() == ES_GAME) 423 {424 437 this->activate(); 425 }426 427 438 else 428 {429 439 this->deactivate(); 430 } 431 } 440 } 441 else if (event.type == SDLK_F1) 442 this->help(); 443 else if (event.type == SDLK_F2) 444 this->debug(); 432 445 else if (event.type == SDLK_TAB) 433 446 this->autoComplete(); … … 650 663 } 651 664 652 653 654 665 /** 655 666 * searches for classes, which beginn with classNameBegin … … 719 730 } 720 731 732 void Shell::help() const 733 { 734 PRINT(0)("Help for the most important Shell-commands\n"); 735 PRINT(0)("F1 - HELP; F2 - DEBUG; ` - open/close shell\n"); 736 PRINT(0)("input order:\n"); 737 PRINT(0)("ClassName::objectName function [parameter1, [parameter2 ...]] or\n"); 738 PRINT(0)("Command [parameter]\n"); 739 } 740 721 741 /** 722 742 * displays some nice output from the Shell … … 724 744 void Shell::debug() const 725 745 { 746 PRINT(3)("Debugging output to console (not this shell)\n"); 747 726 748 if (this->pressedKey != SDLK_FIRST) 727 749 printf("%s::%f %f\n", SDLKToKeyname(this->pressedKey), this->delayed, this->repeatDelay); 728 } 750 751 752 char* tmpChar = this->bufferIterator->firstElement(); 753 while(tmpChar != NULL) 754 { 755 printf(tmpChar); 756 tmpChar = this->bufferIterator->nextElement(); 757 } 758 } -
trunk/src/util/shell.h
r5118 r5119 69 69 virtual void draw() const; 70 70 71 void help() const; 71 72 void debug() const; 72 73
Note: See TracChangeset
for help on using the changeset viewer.