Add an open_all_bookmarks option
this option determines if the non-autojoin bookmarks will be opened on startup or not. It is false by default.
This commit is contained in:
parent
6c62f62402
commit
5a5d5812ed
3 changed files with 30 additions and 19 deletions
|
@ -116,9 +116,12 @@ use_bookmarks_method =
|
|||
|
||||
# use this option to force the use of local bookmarks
|
||||
# possible values are: anything/false
|
||||
|
||||
use_remote_bookmarks = true
|
||||
|
||||
# Whether you want all bookmarks, even those without
|
||||
# autojoin, to be open on startup
|
||||
open_all_bookmarks = false
|
||||
|
||||
# What will be put after the name, when using autocompletion at the
|
||||
# beginning of the input. A space will always be added after that
|
||||
after_completion = ,
|
||||
|
|
|
@ -197,6 +197,13 @@ Options related to account configuration, nickname…
|
|||
|
||||
The status message poezio will send when connecting.
|
||||
|
||||
open_all_bookmarks
|
||||
|
||||
**Default value:** ``false``
|
||||
|
||||
If this option is set to ``true``, all remote bookmarks, even
|
||||
those that do not have autojoin, will be opened on startup.
|
||||
(the tabs without autojoin will not be joined)
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -869,6 +869,7 @@ def on_session_start(self, event):
|
|||
if not self.xmpp.anon and config.get('use_remote_bookmarks', True):
|
||||
bookmark.get_remote(self.xmpp)
|
||||
for bm in bookmark.bookmarks:
|
||||
if bm.autojoin or config.get('open_all_bookmarks', False):
|
||||
tab = self.get_tab_by_name(bm.jid, tabs.MucTab)
|
||||
nick = bm.nick if bm.nick else self.own_nick
|
||||
if not tab:
|
||||
|
|
Loading…
Reference in a new issue