Settings: build list of actions
This commit is contained in:
parent
fa0181815b
commit
8cc1d4c19f
@ -0,0 +1,28 @@
|
|||||||
|
if(Debug.debug)
|
||||||
|
console.log("[settings.js] loading settings script!");
|
||||||
|
|
||||||
|
// document.getElementById("uw-version").textContent = browser.runtime.getManifest().version;
|
||||||
|
|
||||||
|
var settings = new Settings(undefined, () => updateConfig());
|
||||||
|
|
||||||
|
function updateConfig() {
|
||||||
|
loadConfig();
|
||||||
|
}
|
||||||
|
|
||||||
|
function loadConfig() {
|
||||||
|
loadActions();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// setup:
|
||||||
|
|
||||||
|
async function initSettings() {
|
||||||
|
await settings.init();
|
||||||
|
loadConfig();
|
||||||
|
}
|
||||||
|
|
||||||
|
initSettings();
|
@ -40,7 +40,7 @@ var ui = {
|
|||||||
|
|
||||||
// Customization settings
|
// Customization settings
|
||||||
customization: {
|
customization: {
|
||||||
actionList: BaseElement.fromExisting(document.getElementById('_customization_actions')),
|
actionList: BaseElement.fromExisting(document.getElementById('_customization_action_list')),
|
||||||
actionItems: [],
|
actionItems: [],
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -230,9 +230,13 @@
|
|||||||
<script src="../../js/conf/ExtensionConf.js"></script>
|
<script src="../../js/conf/ExtensionConf.js"></script>
|
||||||
<script src="../../js/lib/Settings.js"></script>
|
<script src="../../js/lib/Settings.js"></script>
|
||||||
|
|
||||||
|
<script src="../../js/lib/KeyboardShortcutParser.js"></script>
|
||||||
|
|
||||||
<!-- ui libs -->
|
<!-- ui libs -->
|
||||||
<script src="../../js/lib/libghettoui/BaseElement.js"></script>
|
<script src="../../js/lib/libghettoui/BaseElement.js"></script>
|
||||||
<script src="./js/settingsvars.js"></script>
|
<script src="../../js/lib/libghettoui/settings/ActionItem.js"></script>
|
||||||
<script src="./js/settings.js"></script>
|
<script src="js/settingsvars.js"></script>
|
||||||
|
<script src="js/customization.js"></script>
|
||||||
|
<script src="js/settings.js"></script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
Loading…
Reference in New Issue
Block a user