Changeset 1502 for code/trunk/src/core/OutputHandler.cc
- Timestamp:
- Jun 1, 2008, 3:54:20 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk/src/core/OutputHandler.cc
r1062 r1502 35 35 #include "CoreSettings.h" 36 36 #include "ConsoleCommand.h" 37 #include "Shell.h" 37 38 38 39 namespace orxonox 39 40 { 40 ConsoleCommandShortcutGeneric(log, createExecutor(createFunctor(&OutputHandler::log), "log", AccessLevel::None)); 41 SetConsoleCommandShortcutGeneric(log, createConsoleCommand(createFunctor(&OutputHandler::log), "log" )); 42 SetConsoleCommandShortcutGeneric(error, createConsoleCommand(createFunctor(&OutputHandler::error), "error" )); 43 SetConsoleCommandShortcutGeneric(warning, createConsoleCommand(createFunctor(&OutputHandler::warning), "warning")); 44 SetConsoleCommandShortcutGeneric(info, createConsoleCommand(createFunctor(&OutputHandler::info), "info" )); 45 SetConsoleCommandShortcutGeneric(debug, createConsoleCommand(createFunctor(&OutputHandler::debug), "debug" )); 41 46 42 47 /** … … 82 87 83 88 /** 89 @brief Returns the Shell's OutputBuffer. This is mere placed here to avoid 90 recompiling the entire project when Shell.h changes. 91 @return The OutputBuffer of the Shell 92 */ 93 OutputBuffer& OutputHandler::getShellOutputBuffer() 94 { 95 return Shell::getInstance().getOutputBuffer(); 96 } 97 98 /** 84 99 @brief Overloaded << operator, redirects the output to the console and the logfile. 85 100 @param sb The streambuffer that should be shown in the console … … 96 111 this->logfile_.flush(); 97 112 } 113 114 if (OutputHandler::getSoftDebugLevel(OutputHandler::LD_Shell) >= this->outputLevel_) 115 Shell::getInstance().getOutputBuffer() << sb; 98 116 99 117 return *this; … … 116 134 } 117 135 136 if (OutputHandler::getSoftDebugLevel(OutputHandler::LD_Shell) >= this->outputLevel_) 137 Shell::getInstance().getOutputBuffer() << manipulator; 138 118 139 return *this; 119 140 } … … 134 155 this->logfile_.flush(); 135 156 } 157 158 if (OutputHandler::getSoftDebugLevel(OutputHandler::LD_Shell) >= this->outputLevel_) 159 Shell::getInstance().getOutputBuffer() << manipulator; 136 160 137 161 return *this; … … 154 178 } 155 179 180 if (OutputHandler::getSoftDebugLevel(OutputHandler::LD_Shell) >= this->outputLevel_) 181 Shell::getInstance().getOutputBuffer() << manipulator; 182 156 183 return *this; 157 184 }
Note: See TracChangeset
for help on using the changeset viewer.