Added Lua function edje.version().
Also cleaned up the changelog date from my last commit. Oops. SVN revision: 66977
This commit is contained in:
parent
8bf05691f5
commit
870e48eeca
|
@ -272,9 +272,13 @@
|
||||||
* Unswallow object that are about to be swallowed if necessary.
|
* Unswallow object that are about to be swallowed if necessary.
|
||||||
* Add EDJE_ASPECT_PREFER_SOURCE.
|
* Add EDJE_ASPECT_PREFER_SOURCE.
|
||||||
|
|
||||||
2011-11-07 David Seikel (onefang)
|
2012-01-07 David Seikel (onefang)
|
||||||
|
|
||||||
* Lua: Calling non exstent functions no longer crashes scripts.
|
* Lua: Calling non exstent functions no longer crashes scripts.
|
||||||
This is so that future scripts will still work with old libraries,
|
This is so that future scripts will still work with old libraries,
|
||||||
and lets us add the "host can provide Lua API" feature soon.
|
and lets us add the "host can provide Lua API" feature soon.
|
||||||
|
|
||||||
|
2012-01-09 David Seikel (onefang)
|
||||||
|
|
||||||
|
* Lua: Added edje.version().
|
||||||
|
|
||||||
|
|
|
@ -7,6 +7,7 @@ Additions:
|
||||||
|
|
||||||
* "recalc" smart callback for object size changes
|
* "recalc" smart callback for object size changes
|
||||||
* EDJE_ASPECT_PREFER_SOURCE.
|
* EDJE_ASPECT_PREFER_SOURCE.
|
||||||
|
* edje.version() Lua function.
|
||||||
|
|
||||||
Improvements:
|
Improvements:
|
||||||
* speedup load time of Edje file.
|
* speedup load time of Edje file.
|
||||||
|
|
|
@ -104,6 +104,10 @@ collections {
|
||||||
print("lua::init ... " .. D.val);
|
print("lua::init ... " .. D.val);
|
||||||
edje.echo("lua::echo('hello world')");
|
edje.echo("lua::echo('hello world')");
|
||||||
|
|
||||||
|
--// How to check the edje version.
|
||||||
|
version = edje.version();
|
||||||
|
print("The edje version number is " .. version.major .. "." .. version.minor);
|
||||||
|
|
||||||
--// actually add the timer to call mycb in 1.23 sec
|
--// actually add the timer to call mycb in 1.23 sec
|
||||||
D.tim = edje.timer(1.23, mycb);
|
D.tim = edje.timer(1.23, mycb);
|
||||||
D.tra = edje.transition(5.0, mycb3);
|
D.tra = edje.transition(5.0, mycb3);
|
||||||
|
|
|
@ -614,6 +614,7 @@ static int _elua_echo(lua_State *L);
|
||||||
static int _elua_date(lua_State *L);
|
static int _elua_date(lua_State *L);
|
||||||
static int _elua_looptime(lua_State *L);
|
static int _elua_looptime(lua_State *L);
|
||||||
static int _elua_seconds(lua_State *L);
|
static int _elua_seconds(lua_State *L);
|
||||||
|
static int _elua_version(lua_State *L);
|
||||||
|
|
||||||
static int _elua_objgeom(lua_State *L);
|
static int _elua_objgeom(lua_State *L);
|
||||||
static int _elua_objpos(lua_State *L);
|
static int _elua_objpos(lua_State *L);
|
||||||
|
@ -649,6 +650,7 @@ static const struct luaL_reg _elua_edje_funcs [] =
|
||||||
{"date", _elua_date}, // get date in a table
|
{"date", _elua_date}, // get date in a table
|
||||||
{"looptime", _elua_looptime}, // get loop time
|
{"looptime", _elua_looptime}, // get loop time
|
||||||
{"seconds", _elua_seconds}, // get seconds
|
{"seconds", _elua_seconds}, // get seconds
|
||||||
|
{"version", _elua_version}, // edje version
|
||||||
|
|
||||||
// query edje - size, pos
|
// query edje - size, pos
|
||||||
{"geom", _elua_objgeom}, // get while edje object geometry in canvas
|
{"geom", _elua_objgeom}, // get while edje object geometry in canvas
|
||||||
|
@ -801,6 +803,25 @@ _elua_seconds(lua_State *L) // Stack usage [-0, +1, -]
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
@page luaref
|
||||||
|
@subsubsection edje_version edje:version()
|
||||||
|
|
||||||
|
Retrieves the current edje version number.
|
||||||
|
|
||||||
|
@returns A table with these fields:
|
||||||
|
- integer major: The edje version major number.
|
||||||
|
- integer minor: The edje version minor number.
|
||||||
|
|
||||||
|
@since 1.2.0
|
||||||
|
*/
|
||||||
|
static int
|
||||||
|
_elua_version(lua_State *L) // Stack usage [-4, +5, em]
|
||||||
|
{
|
||||||
|
_elua_ret(L, "%major %minor", EDJE_VERSION_MAJOR, EDJE_VERSION_MINOR); // Stack usage [-4, +5, em]
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
//-------------
|
//-------------
|
||||||
/**
|
/**
|
||||||
@page luaref
|
@page luaref
|
||||||
|
|
Loading…
Reference in New Issue