core: a new "info" type is used in newMessage for system messages (not comming from outside)
This commit is contained in:
parent
af2554a508
commit
a20e3e2cb8
1 changed files with 16 additions and 12 deletions
|
|
@ -57,8 +57,8 @@ class Const(object):
|
|||
STATIC_BLOG_PARAM_KEYWORDS = "Keywords"
|
||||
STATIC_BLOG_PARAM_DESCRIPTION = "Description"
|
||||
|
||||
## Menus ##
|
||||
|
||||
## Menus ##
|
||||
MENU_GLOBAL = "GLOBAL"
|
||||
MENU_ROOM = "ROOM"
|
||||
MENU_SINGLE = "SINGLE"
|
||||
|
|
@ -66,6 +66,7 @@ class Const(object):
|
|||
MENU_ROSTER_JID_CONTEXT = "ROSTER_JID_CONTEXT"
|
||||
MENU_ROSTER_GROUP_CONTEXT = "MENU_ROSTER_GROUP_CONTEXT"
|
||||
|
||||
|
||||
## Profile and entities ##
|
||||
PROF_KEY_NONE = '@NONE@'
|
||||
PROF_KEY_DEFAULT = '@DEFAULT@'
|
||||
|
|
@ -74,6 +75,9 @@ class Const(object):
|
|||
ENTITY_CAP_HASH = 'CAP_HASH'
|
||||
|
||||
|
||||
## Messages ##
|
||||
MESS_TYPE_INFO = 'info'
|
||||
|
||||
## Configuration ##
|
||||
if BaseDirectory: # skipped when xdg module is not available (should not happen in backend)
|
||||
|
||||
|
|
@ -188,6 +192,7 @@ class Const(object):
|
|||
|
||||
@classmethod
|
||||
def bool(cls, value):
|
||||
"""retour str text value for bool, or bool value for str"""
|
||||
if isinstance(value, bool):
|
||||
return cls.BOOL_TRUE if value else cls.BOOL_FALSE
|
||||
return value.lower() == cls.BOOL_TRUE
|
||||
|
|
|
|||
Loading…
Reference in a new issue