aboutsummaryrefslogtreecommitdiff
path: root/src/lua/common/Proxy.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/lua/common/Proxy.h')
-rw-r--r--src/lua/common/Proxy.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/lua/common/Proxy.h b/src/lua/common/Proxy.h
index 60658ec..8323ead 100644
--- a/src/lua/common/Proxy.h
+++ b/src/lua/common/Proxy.h
@@ -11,12 +11,11 @@ namespace lua
class Proxy
{
public:
- void bind(Reference* ref, const char* t)
+ void bind(RefBase* ref)
{
if (ref == nullptr)
return;
reference = ref;
- type = t;
}
void release()
@@ -25,7 +24,6 @@ namespace lua
{
reference->release();
reference = nullptr;
- type = nullptr;
}
}
@@ -35,8 +33,12 @@ namespace lua
return *(Ref<T>*) reference;
}
- const char* type; // type name and metatable name
- Reference* reference; // acctual object binded
+ const char* getObjectType()
+ {
+ return reference->type;
+ }
+
+ RefBase* reference;
};