Permalink
Browse files

Tidy up some convenience functions

  • Loading branch information...
1 parent 4ced122 commit af511a6e5fc472f6fcfe6177c2ca7553e8dbfa62 @vinniefalco committed May 31, 2012
Showing with 15 additions and 14 deletions.
  1. +15 −14 LuaBridge.h
View
@@ -4687,6 +4687,19 @@ class Namespace
//==============================================================================
/**
+ Retrieve the global namespace.
+
+ It is recommended to put your namespace inside the global namespace, and then
+ add your classes and functions to it, rather than adding many classes and
+ functions directly to the global namespace.
+*/
+inline Namespace getGlobalNamespace (lua_State* L)
+{
+ return Namespace::getGlobalNamespace (L);
+}
+
+//------------------------------------------------------------------------------
+/**
Push objects onto the Lua stack.
*/
template <class T>
@@ -4695,6 +4708,7 @@ inline void push (lua_State* L, T t)
Stack <T>::push (L, t);
}
+//------------------------------------------------------------------------------
/**
Set a global value in the lua_State.
*/
@@ -4705,22 +4719,9 @@ inline void setglobal (lua_State* L, T t, char const* name)
lua_setglobal (L, name);
}
-//==============================================================================
-/**
- Retrieve the global namespace.
-
- It is recommended to put your namespace inside the global namespace, and then
- add your classes and functions to it, rather than adding many classes and
- functions directly to the global namespace.
-*/
-inline Namespace getGlobalNamespace (lua_State* L)
-{
- return Namespace::getGlobalNamespace (L);
-}
-
//------------------------------------------------------------------------------
/**
- Control metatable hiding setting.
+ Change whether or not metatables are hidden (on by default).
*/
inline void setHideMetatables (bool shouldHide)
{

0 comments on commit af511a6

Please sign in to comment.