Skip to content

Commit 17c0c90

Browse files
committed
Add settings for showing outline panel at startup
1 parent d0e840f commit 17c0c90

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

addons/cb.panel.outline/client.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
define([
2+
"settings",
23
"views/panel"
3-
], function(PanelOutlineView) {
4+
], function(settings, PanelOutlineView) {
45
var commands = codebox.require("core/commands/toolbar");
56
var app = codebox.require("core/app");
67
var panels = codebox.require("core/panels");
@@ -25,5 +26,5 @@ define([
2526
}));
2627

2728
// Open panel during startup
28-
panel.open();
29+
if (settings.user.get("startup")) panel.open();
2930
});

addons/cb.panel.outline/settings.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,17 @@ define([], function() {
66
'namespace': "outline",
77
'title': "Outline",
88
'defaults': {
9-
'separator': "."
9+
'separator': ".",
10+
'startup': false
1011
},
1112
'fields': {
1213
'separator': {
1314
'label': 'Tag Parts Separator',
1415
'type': "text"
16+
},
17+
'startup': {
18+
'label': 'Show Outline Panel at Startup',
19+
'type': "checkbox"
1520
}
1621
}
1722
});

0 commit comments

Comments
 (0)