Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jul 31, 2011, 5:15:13 PM (13 years ago)
Author:
landauf
Message:

Replaced COUT with orxout in core. Tried to set levels and contexts in a more or less useful way, but not really optimized.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/output/src/libraries/core/command/IRC.cc

    r7401 r8806  
    8585        }
    8686        catch (Tcl::tcl_error const &e)
    87         {   COUT(1) << "Tcl (IRC) error: " << e.what();   }
     87        {   orxout(user_error, context::tcl) << "Tcl (IRC) error: " << e.what() << endl;   }
    8888
    8989        this->nickname_ = "orx" + multi_cast<std::string>(static_cast<unsigned int>(rand()));
     
    100100        {
    101101            IRC::getInstance().initialize();
    102             COUT(1) << "Error: IRC client wasn't yet initialized, please try again." << std::endl;
     102            orxout(user_error) << "IRC client wasn't yet initialized, please try again." << endl;
    103103            return false;
    104104        }
     
    110110        }
    111111        catch (Tcl::tcl_error const &e)
    112         {   COUT(1) << "Tcl (IRC) error: " << e.what();   }
     112        {   orxout(user_error, context::tcl) << "Tcl (IRC) error: " << e.what() << endl;   }
    113113
    114114        return false;
     
    139139    void IRC::tcl_say(Tcl::object const &channel, Tcl::object const &nick, Tcl::object const &args)
    140140    {
    141         COUT(0) << "IRC> " << nick.get() << ": " << stripEnclosingBraces(args.get()) << std::endl;
     141        orxout(message) << "IRC> " << nick.get() << ": " << stripEnclosingBraces(args.get()) << endl;
    142142    }
    143143
     
    145145    void IRC::tcl_privmsg(Tcl::object const &query, Tcl::object const &nick, Tcl::object const &args)
    146146    {
    147         COUT(0) << "IRC (" << query.get() << ")> " << nick.get() << ": " << stripEnclosingBraces(args.get()) << std::endl;
     147        orxout(message) << "IRC (" << query.get() << ")> " << nick.get() << ": " << stripEnclosingBraces(args.get()) << endl;
    148148    }
    149149
     
    151151    void IRC::tcl_action(Tcl::object const &channel, Tcl::object const &nick, Tcl::object const &args)
    152152    {
    153         COUT(0) << "IRC> * " << nick.get() << ' ' << stripEnclosingBraces(args.get()) << std::endl;
     153        orxout(message) << "IRC> * " << nick.get() << ' ' << stripEnclosingBraces(args.get()) << endl;
    154154    }
    155155
     
    157157    void IRC::tcl_info(Tcl::object const &channel, Tcl::object const &args)
    158158    {
    159         COUT(0) << "IRC> --> " << stripEnclosingBraces(args.get()) << std::endl;
     159        orxout(message) << "IRC> --> " << stripEnclosingBraces(args.get()) << endl;
    160160    }
    161161}
Note: See TracChangeset for help on using the changeset viewer.