Rename config options, add separatyorWidth option
Signed-off-by: Juraj Oravec <sgd.orava@gmail.com>
This commit is contained in:
parent
a3ecd173aa
commit
18e8e33e18
@ -33,8 +33,9 @@ class ToolbarTools(Falkon.PluginInterface, QtCore.QObject):
|
||||
self.config = {
|
||||
"settingsFile": os.path.join(settingsPath, "ToolbarTools", "settings.ini"),
|
||||
"spacers": 2,
|
||||
"maxWidth": 150,
|
||||
"separators": 2
|
||||
"spacerMaxWidth": 150,
|
||||
"separators": 2,
|
||||
"separatorWidth": 10
|
||||
}
|
||||
|
||||
plugins = Falkon.MainApplication.instance().plugins()
|
||||
@ -55,7 +56,7 @@ class ToolbarTools(Falkon.PluginInterface, QtCore.QObject):
|
||||
|
||||
def onMainWindowCreated(self, window):
|
||||
for id in range(1, self.config["spacers"] + 1):
|
||||
spacer = Spacer(id, self.config["maxWidth"])
|
||||
spacer = Spacer(id, self.config["spacerMaxWidth"])
|
||||
window.navigationBar().addWidget(spacer, spacer.id(), spacer.name())
|
||||
|
||||
if window not in self.spacers:
|
||||
@ -63,7 +64,7 @@ class ToolbarTools(Falkon.PluginInterface, QtCore.QObject):
|
||||
self.spacers[window][id] = spacer
|
||||
|
||||
for id in range(1, self.config["separators"] + 1):
|
||||
separator = Separator(id)
|
||||
separator = Separator(id, self.config["separatorWidth"])
|
||||
window.navigationBar().addWidget(separator, separator.id(), separator.name())
|
||||
|
||||
if window not in self.separators:
|
||||
|
Loading…
Reference in New Issue
Block a user