From f030154fe727e25a2afe1f78b3998c2d2dba95e4 Mon Sep 17 00:00:00 2001 From: Stijn Buys Date: Tue, 18 Aug 2009 09:24:15 +0000 Subject: astyle cleanup, corrects not loading of material textures --- src/sys/consoleinterface.h | 54 +++++++++++++++++++++------------------------- 1 file changed, 24 insertions(+), 30 deletions(-) (limited to 'src/sys/consoleinterface.h') diff --git a/src/sys/consoleinterface.h b/src/sys/consoleinterface.h index 2eae1d8..a7fde2e 100644 --- a/src/sys/consoleinterface.h +++ b/src/sys/consoleinterface.h @@ -34,15 +34,14 @@ typedef std::char_traits Traits; class ConsoleBuffer : public std::basic_streambuf { public: - const std::string & str() const - { + const std::string & str() const { return con_buffer; } - + protected: /// stream overflow virtual int overflow(int c = Traits::eof()); - + private: std::string con_buffer; }; @@ -56,12 +55,11 @@ class ConsoleStream : public std::basic_ostream public: ConsoleStream(); ~ConsoleStream(); - - inline ConsoleBuffer & buf() - { + + inline ConsoleBuffer & buf() { return con_buffer; } - + private: ConsoleBuffer con_buffer; }; @@ -79,55 +77,51 @@ class ConsoleInterface public: /// default constructor ConsoleInterface(); - + /// default destructor virtual ~ConsoleInterface(); - + /// set maximal number of lines in the log void set_logsize(const size_t logsize); - + /// return rcon state - inline bool rcon() - { + inline bool rcon() { return consoleinterface_rcon; } - + /// enable or disable rcon void set_rcon(bool enable = true); - + typedef std::deque Queue; - - inline Queue & rconbuf() - { + + inline Queue & rconbuf() { return consoleinterface_rconbuf; } - - inline Queue & log() - { + + inline Queue & log() { return consoleinterface_log; } - + /// a pointer to the current console instance static ConsoleInterface *instance(); - + /// incoming text event handler void event_text(const std::string & text); - + /// ncurses resize event - virtual void resize() - {}; - + virtual void resize() {}; + protected: /// print one line of text virtual void print(const std::string & text); - + private: /// console singleton static ConsoleInterface *consoleinterface_instance; - + bool consoleinterface_rcon; Queue consoleinterface_rconbuf; - + Queue consoleinterface_log; size_t consoleinterface_logsize; }; -- cgit v1.2.3