Browse Source

Merge pull request #7959 from karroffel/powerstate-ptrcall-fix

really fixed PTRCALL now
Rémi Verschelde 8 years ago
parent
commit
131631b009
3 changed files with 2 additions and 6 deletions
  1. 1 0
      core/method_ptrcall.h
  2. 1 5
      core/variant.cpp
  3. 0 1
      core/variant.h

+ 1 - 0
core/method_ptrcall.h

@@ -120,6 +120,7 @@ MAKE_PTRARG(PoolVector2Array);
 MAKE_PTRARG(PoolVector3Array);
 MAKE_PTRARG(PoolVector3Array);
 MAKE_PTRARG(PoolColorArray);
 MAKE_PTRARG(PoolColorArray);
 MAKE_PTRARG(Variant);
 MAKE_PTRARG(Variant);
+MAKE_PTRARG(PowerState);
 
 
 
 
 //this is for Object
 //this is for Object

+ 1 - 5
core/variant.cpp

@@ -2178,11 +2178,6 @@ Variant::operator IP_Address() const {
 	return IP_Address( operator String() );
 	return IP_Address( operator String() );
 }
 }
 
 
-Variant::operator PowerState() const
-{
-	return (PowerState) operator int();
-}
-
 Variant::Variant(bool p_bool) {
 Variant::Variant(bool p_bool) {
 
 
 	type=BOOL;
 	type=BOOL;
@@ -2653,6 +2648,7 @@ Variant::Variant(const IP_Address& p_address) {
 	memnew_placement( _data._mem, String( p_address ) );
 	memnew_placement( _data._mem, String( p_address ) );
 }
 }
 
 
+
 Variant::Variant(const Variant& p_variant) {
 Variant::Variant(const Variant& p_variant) {
 
 
 	type=NIL;
 	type=NIL;

+ 0 - 1
core/variant.h

@@ -255,7 +255,6 @@ public:
 	operator Orientation() const;
 	operator Orientation() const;
 
 
 	operator IP_Address() const;
 	operator IP_Address() const;
-	operator PowerState() const;
 
 
 
 
 	Variant(bool p_bool);
 	Variant(bool p_bool);