summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMurray Cumming <murrayc@murrayc.com>2006-09-27 18:38:57 +0000
committerMurray Cumming <murrayc@murrayc.com>2006-09-27 18:38:57 +0000
commit61ab5341af289257ce1b10528150fdbdcb770e4e (patch)
tree8e707e8f91e287e5fd5085cef16463a836e420c5
parent6e6b4af5b7de8e17208f42a6031bf05342e91416 (diff)
2006-09-27 Murray Cumming <murrayc@murrayc.com>
* cairomm/refptr.h: cast_static() and cast_dynamic(): Use the refcount_() accessor instead of the member variable, to avoid compilation errors, as we already doing in the templated copy constructor.
-rw-r--r--ChangeLog7
-rw-r--r--cairomm/refptr.h14
2 files changed, 14 insertions, 7 deletions
diff --git a/ChangeLog b/ChangeLog
index c83bee9..0ce9bd1 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2006-09-27 Murray Cumming <murrayc@murrayc.com>
+
+ * cairomm/refptr.h: cast_static() and cast_dynamic():
+ Use the refcount_() accessor instead of the member variable,
+ to avoid compilation errors, as we already doing in the
+ templated copy constructor.
+
1.2.2:
2006-08-21 Jonathon Jongsma <jonathon.jongsma@gmail.com>
diff --git a/cairomm/refptr.h b/cairomm/refptr.h
index b0ee3d5..8e49fe2 100644
--- a/cairomm/refptr.h
+++ b/cairomm/refptr.h
@@ -2,7 +2,7 @@
#ifndef _cairo_REFPTR_H
#define _cairo_REFPTR_H
-/* $Id: refptr.h,v 1.5 2006-07-11 18:54:10 murrayc Exp $ */
+/* $Id: refptr.h,v 1.6 2006-09-27 18:38:57 murrayc Exp $ */
/* Copyright 2005 The cairomm Development Team
*
@@ -342,8 +342,8 @@ RefPtr<T_CppObject> RefPtr<T_CppObject>::cast_dynamic(const RefPtr<T_CastFrom>&
{
T_CppObject *const pCppObject = dynamic_cast<T_CppObject*>(src.operator->());
- if(pCppObject && src.pCppRefcount_)
- ++(*(src.pCppRefcount_));
+ if(pCppObject && src.refcount_())
+ ++(*(src.refcount_()));
return RefPtr<T_CppObject>(pCppObject); //TODO: Does an unnecessary extra reference() on the C object.
}
@@ -355,8 +355,8 @@ RefPtr<T_CppObject> RefPtr<T_CppObject>::cast_static(const RefPtr<T_CastFrom>& s
{
T_CppObject *const pCppObject = static_cast<T_CppObject*>(src.operator->());
- if(pCppObject && src.pCppRefcount_)
- ++(*(src.pCppRefcount_));
+ if(pCppObject && src.refcount_())
+ ++(*(src.refcount_()));
return RefPtr<T_CppObject>(pCppObject); //TODO: Does an unnecessary extra reference() on the C object.
}
@@ -368,8 +368,8 @@ RefPtr<T_CppObject> RefPtr<T_CppObject>::cast_const(const RefPtr<T_CastFrom>& sr
{
T_CppObject *const pCppObject = const_cast<T_CppObject*>(src.operator->());
- if(pCppObject && src.pCppRefcount_)
- ++(*(src.pCppRefcount_));
+ if(pCppObject && src.refcount_())
+ ++(*(src.refcount_()));
return RefPtr<T_CppObject>(pCppObject); //TODO: Does an unnecessary extra reference() on the C object.
}