Add awesome.startup
This boolean describes if we are still in startup or if our main loop is already running. Signed-off-by: Uli Schlachter <psychon@znc.in>
This commit is contained in:
parent
c1cb7883b5
commit
4d35f430dc
7
luaa.c
7
luaa.c
|
@ -430,6 +430,7 @@ luaA_isloop(lua_State *L, int idx)
|
|||
* \lfield conffile The configuration file which has been loaded.
|
||||
* \lfield version The version of awesome.
|
||||
* \lfield release The release name of awesome.
|
||||
* \lfield startup True if we are still in startup, false otherwise.
|
||||
* \lfield startup_errors Error message for errors that occured during startup.
|
||||
* \lfield composite_manager_running True if a composite manager is running.
|
||||
*/
|
||||
|
@ -459,6 +460,12 @@ luaA_awesome_index(lua_State *L)
|
|||
return 1;
|
||||
}
|
||||
|
||||
if(A_STREQ(buf, "startup"))
|
||||
{
|
||||
lua_pushboolean(L, globalconf.loop == NULL);
|
||||
return 1;
|
||||
}
|
||||
|
||||
if(A_STREQ(buf, "startup_errors") && globalconf.startup_errors.len != 0)
|
||||
{
|
||||
lua_pushstring(L, globalconf.startup_errors.s);
|
||||
|
|
|
@ -7,6 +7,7 @@ module("awesome")
|
|||
-- @field version The version of awesome.
|
||||
-- @field release The release name of awesome.
|
||||
-- @field conffile The configuration file which has been loaded.
|
||||
-- @field startup True if we are still in startup, false otherwise.
|
||||
-- @field startup_errors Error message for errors that occured during startup.
|
||||
-- @field composite_manager_running True if a composite manager is running.
|
||||
-- @class table
|
||||
|
|
Loading…
Reference in New Issue