Changeset 7198 in orxonox.OLD for trunk/src/lib/shell
- Timestamp:
- Mar 8, 2006, 2:30:19 PM (19 years ago)
- Location:
- trunk/src/lib/shell
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/lib/shell/shell.cc
r6780 r7198 43 43 SHELL_COMMAND(textsize, Shell, setTextSize) 44 44 ->describe("Sets the size of the Text size, linespacing") 45 ->defaultValues(1 , 15, 0);45 ->defaultValues(15, 0); 46 46 SHELL_COMMAND(textcolor, Shell, setTextColor) 47 47 ->describe("Sets the Color of the Shells Text (red, green, blue, alpha)") 48 ->defaultValues( 4,SHELL_DEFAULT_TEXT_COLOR);48 ->defaultValues(SHELL_DEFAULT_TEXT_COLOR); 49 49 SHELL_COMMAND(backgroundcolor, Shell, setBackgroundColor) 50 50 ->describe("Sets the Color of the Shells Background (red, green, blue, alpha)") 51 ->defaultValues( 4,SHELL_DEFAULT_BACKGROUND_COLOR);51 ->defaultValues(SHELL_DEFAULT_BACKGROUND_COLOR); 52 52 SHELL_COMMAND(backgroundimage, Shell, setBackgroundImage) 53 53 ->describe("sets the background image to load for the Shell"); 54 54 SHELL_COMMAND(font, Shell, setFont) 55 55 ->describe("Sets the font of the Shell") 56 ->defaultValues( 1,SHELL_DEFAULT_FONT);56 ->defaultValues(SHELL_DEFAULT_FONT); 57 57 58 58 /** -
trunk/src/lib/shell/shell_command.cc
r6222 r7198 292 292 293 293 /** 294 * sets default Values of the Commands 295 * @param count how many default Values to set. 296 * @param ... the default Values in order. They will be cast to the right type 297 * @returns itself 298 * 299 * Be aware, that when you use this Function, you !!MUST!! match the input as 300 * count, [EXACTLY THE SAME AS IF YOU WOULD CALL THE FUNCTION UP TO count ARGUMENTS] 301 */ 302 ShellCommand* ShellCommand::defaultValues(unsigned int count, ...) 294 * @brief set the default values of the executor 295 * @param value0 the first default value 296 * @param value1 the second default value 297 * @param value2 the third default value 298 * @param value3 the fourth default value 299 * @param value4 the fifth default value 300 */ 301 ShellCommand* ShellCommand::defaultValues(const MultiType& value0, const MultiType& value1, 302 const MultiType& value2, const MultiType& value3, 303 const MultiType& value4) 303 304 { 304 305 if (this == NULL) 305 306 return NULL; 306 307 307 va_list values; 308 va_start(values, count); 309 310 this->executor->defaultValues(count, values); 308 this->executor->defaultValues(value0, value1, value2, value3, value4); 311 309 312 310 return this; -
trunk/src/lib/shell/shell_command.h
r5784 r7198 65 65 ShellCommand* describe(const char* description); 66 66 ShellCommand* setAlias(const char* alias); 67 ShellCommand* defaultValues(unsigned int count, ...); 67 ShellCommand* defaultValues(const MultiType& value0 = MT_NULL, const MultiType& value1 = MT_NULL, 68 const MultiType& value2 = MT_NULL, const MultiType& value3 = MT_NULL, 69 const MultiType& value4 = MT_NULL); 68 70 69 71 static ShellCommand* registerCommand(const char* commandName, const char* className, const Executor& executor);
Note: See TracChangeset
for help on using the changeset viewer.