From d21f22e2c07d61bf15ee3af91869901adb6f0cde Mon Sep 17 00:00:00 2001 From: tsepez Date: Fri, 2 Sep 2016 17:34:21 -0700 Subject: Make CPDF_ClipPath have a CPDF_ClipPathData rather than inheriting. Make Data private to the ClipPath class which manages it transparently for its callers. This prevents the callers from having to remember to make a copy before dirtying the shared data, since the operations that modify state will do this under the covers for us. Review-Url: https://codereview.chromium.org/2301263003 --- core/fxcrt/include/cfx_count_ref.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'core/fxcrt') diff --git a/core/fxcrt/include/cfx_count_ref.h b/core/fxcrt/include/cfx_count_ref.h index aac18b166a..95132a73ca 100644 --- a/core/fxcrt/include/cfx_count_ref.h +++ b/core/fxcrt/include/cfx_count_ref.h @@ -10,6 +10,8 @@ #include "core/fxcrt/include/cfx_retain_ptr.h" #include "core/fxcrt/include/fx_system.h" +// A shared object with Copy on Write semantics that makes it appear as +// if each one were independent. template class CFX_CountRef { public: -- cgit v1.2.3