X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=synfig-core%2Ftrunk%2Fsrc%2Fsynfig%2Fnode.h;h=85ad5ebab382f323a0988320bcc7ad970e7a8af5;hb=c732f2078f9ed4393bff0e761beab709e49b6c4c;hp=2705830a7bbdc4ccfc38f79329d08587652e3335;hpb=fdc6a114ef93e7728172b14cbd5da9cd7982d282;p=synfig.git diff --git a/synfig-core/trunk/src/synfig/node.h b/synfig-core/trunk/src/synfig/node.h index 2705830..85ad5eb 100644 --- a/synfig-core/trunk/src/synfig/node.h +++ b/synfig-core/trunk/src/synfig/node.h @@ -37,6 +37,11 @@ /* === M A C R O S ========================================================= */ +// When a PasteCanvas layer has a non-zero 'time offset' parameter, should +// the waypoints shown for the canvas be adjusted? This currently only +// partially works - see the TODO at the end of layer_pastecanvas.cpp +#define ADJUST_WAYPOINTS_FOR_TIME_OFFSET + /* === T Y P E D E F S ===================================================== */ /* === C L A S S E S & S T R U C T S ======================================= */ @@ -58,6 +63,10 @@ public: { } +#ifdef _DEBUG + const char *c_str()const; +#endif + const GUID& get_guid()const { return guid; } const Time& get_time()const { return time; } Interpolation get_before()const { return before; } @@ -122,7 +131,7 @@ private: //! \writeme GUID guid_; - //! cached time values for all the childrens + //! cached time values for all the children mutable time_set times; //! \writeme @@ -238,6 +247,32 @@ guid_cast(const synfig::GUID& guid) return etl::handle::cast_dynamic(synfig::find_node(guid)); } +#ifdef _DEBUG +template +synfig::String set_string(T start, T end) +{ + synfig::String ret("["); + bool started = false; + + while (start != end) + { + if (started) ret += ", "; + else started = true; + + ret += synfig::String((*start).c_str()); + start++; + } + + return ret + "]"; +} + +template +synfig::String set_string(T set) +{ + return set_string(set.begin(), set.end()); +} +#endif // _DEBUG + typedef etl::handle NodeHandle; }; // END of namespace synfig