From ebd21e9249ff747d247c6dff1fa7105a2aa6a345 Mon Sep 17 00:00:00 2001 From: Jared Adams Date: Mon, 16 Apr 2012 20:43:30 -0600 Subject: [PATCH] Fix some issues with last commit --- plugins/Brushes.h | 8 +++++++- plugins/tiletypes.cpp | 3 ++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/plugins/Brushes.h b/plugins/Brushes.h index 97ddc44c0..a525d279c 100644 --- a/plugins/Brushes.h +++ b/plugins/Brushes.h @@ -196,6 +196,12 @@ private: Core *c_; }; -std::ostream &operator<<(std::ostream &stream, const Brush& brush) { +inline std::ostream &operator<<(std::ostream &stream, const Brush& brush) { stream << brush.str(); + return stream; +} + +inline std::ostream &operator<<(std::ostream &stream, const Brush* brush) { + stream << brush->str(); + return stream; } diff --git a/plugins/tiletypes.cpp b/plugins/tiletypes.cpp index 41627a852..546f9c2c5 100644 --- a/plugins/tiletypes.cpp +++ b/plugins/tiletypes.cpp @@ -325,7 +325,7 @@ void printState(color_ostream &out) { out << "Filter: " << filter << std::endl << "Paint: " << paint << std::endl - << "Brush: " << brush->str() << std::endl; + << "Brush: " << brush << std::endl; } //zilpin: These two functions were giving me compile errors in VS2008, so I cheated with the C style loop below, just to get it to build. @@ -559,6 +559,7 @@ bool processTileType(color_ostream & out, TileType &paint, std::vector