mirror of
https://github.com/zombieFox/nightTab.git
synced 2024-12-27 00:59:00 +01:00
[refactor] move title into layout render
This commit is contained in:
parent
4ae20b0444
commit
c5f5e1b2d4
@ -1179,7 +1179,6 @@
|
||||
<script src="js/version.js"></script>
|
||||
<script src="js/keyboard.js"></script>
|
||||
<script src="js/background.js"></script>
|
||||
<script src="js/title.js"></script>
|
||||
<script src="js/layout.js"></script>
|
||||
<script src="js/auto-suggest.js"></script>
|
||||
<script src="js/page.js"></script>
|
||||
|
@ -255,7 +255,7 @@ var control = (function() {
|
||||
path: "layout.title",
|
||||
type: "text",
|
||||
func: function() {
|
||||
title.render.name();
|
||||
layout.render.title();
|
||||
}
|
||||
}, {
|
||||
element: helper.e(".control-layout-scrollpastend"),
|
||||
|
@ -15,6 +15,5 @@ keyboard.init();
|
||||
layout.init();
|
||||
background.init();
|
||||
search.init();
|
||||
title.init();
|
||||
header.init();
|
||||
version.init();
|
||||
|
@ -29,6 +29,11 @@ var layout = (function() {
|
||||
};
|
||||
};
|
||||
|
||||
render.title = function() {
|
||||
var title = helper.e("title");
|
||||
title.textContent = state.get().layout.title;
|
||||
};
|
||||
|
||||
var init = function() {
|
||||
render.width();
|
||||
render.padding();
|
||||
|
@ -1,19 +0,0 @@
|
||||
var title = (function() {
|
||||
|
||||
var render = {};
|
||||
|
||||
render.name = function() {
|
||||
helper.e("title").textContent = state.get().layout.title;
|
||||
};
|
||||
|
||||
var init = function() {
|
||||
render.name();
|
||||
};
|
||||
|
||||
// exposed methods
|
||||
return {
|
||||
render: render,
|
||||
init: init
|
||||
};
|
||||
|
||||
})();
|
Loading…
Reference in New Issue
Block a user