1
0
mirror of https://github.com/gnosygnu/xowa.git synced 2026-03-02 03:49:30 +00:00

Cfg: Add defaults loader

This commit is contained in:
gnosygnu
2016-12-11 10:04:40 -05:00
parent c10e34d26e
commit f1396e13c7
18 changed files with 164 additions and 33 deletions

View File

@@ -77,12 +77,6 @@ public class Xop_hdr_wkr implements Xop_ctx_wkr {
if (dirty)
hdr.Init_by_parse(hdr_len, bgn_manual, end_manual);
// section-editable
// if ( ctx.Wiki().Parser_mgr().Hdr__section_editable__enabled()
// && Bry_.Eq(src, cur_pos, cur_pos + Xop_section_mgr.Len__meta, Xop_section_mgr.Bry__meta)) {
// ctx.Wiki().Parser_mgr().Hdr__section_editable__mgr().Parse(hdr, ctx.Page().Ttl().Full_db(), src, cur_pos, src_len); // SECTION_EDIT
// }
// gobble ws; hdr gobbles up trailing ws; EX: "==a== \n\t \n \nb" gobbles up all 3 "\n"s; otherwise para_wkr will process <br/>
cur_pos = Find_fwd_while_ws_hdr_version(src, cur_pos, src_len);
ctx.Para().Process_block__bgn_n__end_y(Xop_xnde_tag_.Tag__h2);

View File

@@ -32,7 +32,7 @@ public class Xop_section_mgr implements Gfo_invk {
public void Init_by_wiki(Xowe_wiki wiki) {
this.app = wiki.Appe();
this.wiki = wiki;
this.enabled = wiki.App().Cfg().Bind_bool(wiki, gplx.xowa.htmls.core.wkrs.hdrs.Xoh_section_editable_.Cfg__section_editing__enabled, this); // SECTION_EDIT
this.enabled = wiki.App().Cfg().Bind_bool(wiki, gplx.xowa.htmls.core.wkrs.hdrs.Xoh_section_editable_.Cfg__section_editing__enabled, this);
this.tidy_mgr = wiki.Html_mgr().Tidy_mgr();
}
public byte[] Slice_section(Xoa_url url, Xoa_ttl ttl, byte[] src) {