screen: do not hardcode the 'default' tag
Signed-off-by: koniu <gkusnierz@gmail.com> Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
parent
7fa363d3fe
commit
8f5f965fab
6
luaa.c
6
luaa.c
|
@ -862,7 +862,6 @@ luaA_loadrc(const char *confpath, bool run)
|
|||
bool
|
||||
luaA_parserc(xdgHandle xdg, const char *confpatharg, bool run)
|
||||
{
|
||||
int screen;
|
||||
char *confpath = NULL;
|
||||
bool ret = false;
|
||||
|
||||
|
@ -899,11 +898,6 @@ bailout:
|
|||
|
||||
p_delete(&confpath);
|
||||
|
||||
/* Assure there's at least one tag */
|
||||
for(screen = 0; screen < globalconf.nscreen; screen++)
|
||||
if(!globalconf.screens[screen].tags.len)
|
||||
tag_append_to_screen(tag_new("default", sizeof("default") - 1),
|
||||
&globalconf.screens[screen]);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
|
9
screen.c
9
screen.c
|
@ -443,15 +443,6 @@ luaA_screen_tags(lua_State *L)
|
|||
tag_append_to_screen(*tag, s);
|
||||
lua_pop(L, 1);
|
||||
}
|
||||
|
||||
/* check there's at least one tag! */
|
||||
if(!s->tags.len)
|
||||
{
|
||||
luaA_warn(L, "screen %d has no tag, taking last resort action and adding default tag\n",
|
||||
s->index);
|
||||
tag_append_to_screen(tag_new("default", sizeof("default") - 1), s);
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue