From: Victor Cebollada Date: Thu, 5 May 2016 06:38:21 +0000 (+0100) Subject: Svace issues. X-Git-Tag: dali_1.1.33~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F94%2F68494%2F2;p=platform%2Fcore%2Fuifw%2Fdali-adaptor.git Svace issues. * Add undefined and private copy constructors and assignment operators to avoid copies. Change-Id: I7ff0665f11f5b557ddb76e15b016ebda6eaaa808 Signed-off-by: Victor Cebollada --- diff --git a/text/dali/internal/glyphy/vector-font-cache.cpp b/text/dali/internal/glyphy/vector-font-cache.cpp index 972327a..23ad8ba 100644 --- a/text/dali/internal/glyphy/vector-font-cache.cpp +++ b/text/dali/internal/glyphy/vector-font-cache.cpp @@ -204,6 +204,15 @@ struct VectorFontCache::Impl glyphy_arc_accumulator_destroy( mAccumulator ); } +private: + + // Declared private and left undefined to avoid copies. + Impl( const Impl& ); + // Declared private and left undefined to avoid copies. + Impl& operator=( const Impl& ); + +public: + FT_Library mFreeTypeLibrary; ///< A handle to a FreeType library instance. vector mIdLookup; diff --git a/text/dali/internal/glyphy/vector-font-cache.h b/text/dali/internal/glyphy/vector-font-cache.h index 91fa2e4..cb04606 100644 --- a/text/dali/internal/glyphy/vector-font-cache.h +++ b/text/dali/internal/glyphy/vector-font-cache.h @@ -108,7 +108,7 @@ private: VectorFontCache( const VectorFontCache& ); // Undefined assignment constructor. - VectorFontCache& operator=( VectorFontCache& ); + VectorFontCache& operator=( const VectorFontCache& ); private: diff --git a/text/dali/internal/text-abstraction/bidirectional-support-impl.h b/text/dali/internal/text-abstraction/bidirectional-support-impl.h index 65b1711..ab180c2 100644 --- a/text/dali/internal/text-abstraction/bidirectional-support-impl.h +++ b/text/dali/internal/text-abstraction/bidirectional-support-impl.h @@ -107,7 +107,7 @@ private: BidirectionalSupport( const BidirectionalSupport& ); // Undefined assignment constructor. - BidirectionalSupport& operator=( BidirectionalSupport& ); + BidirectionalSupport& operator=( const BidirectionalSupport& ); private: diff --git a/text/dali/internal/text-abstraction/font-client-impl.h b/text/dali/internal/text-abstraction/font-client-impl.h index aea274c..8cc77ad 100644 --- a/text/dali/internal/text-abstraction/font-client-impl.h +++ b/text/dali/internal/text-abstraction/font-client-impl.h @@ -179,7 +179,7 @@ private: FontClient( const FontClient& ); // Undefined assignment constructor. - FontClient& operator=( FontClient& ); + FontClient& operator=( const FontClient& ); private: diff --git a/text/dali/internal/text-abstraction/font-client-plugin-impl.h b/text/dali/internal/text-abstraction/font-client-plugin-impl.h index d43e350..9f997a2 100644 --- a/text/dali/internal/text-abstraction/font-client-plugin-impl.h +++ b/text/dali/internal/text-abstraction/font-client-plugin-impl.h @@ -442,6 +442,15 @@ private: */ void CacheFontPath( FT_Face ftFace, FontId id, PointSize26Dot6 pointSize, const FontPath& path ); +private: + + // Declared private and left undefined to avoid copies. + Plugin( const Plugin& ); + // Declared private and left undefined to avoid copies. + Plugin& operator=( const Plugin& ); + +private: + FT_Library mFreeTypeLibrary; ///< A handle to a FreeType library instance. unsigned int mDpiHorizontal; ///< Horizontal dpi. diff --git a/text/dali/internal/text-abstraction/shaping-impl.h b/text/dali/internal/text-abstraction/shaping-impl.h index 2944cc7..e528817 100644 --- a/text/dali/internal/text-abstraction/shaping-impl.h +++ b/text/dali/internal/text-abstraction/shaping-impl.h @@ -83,7 +83,7 @@ private: Shaping( const Shaping& ); // Undefined assignment constructor. - Shaping& operator=( Shaping& ); + Shaping& operator=( const Shaping& ); struct Plugin; Plugin* mPlugin;