mirror of
https://github.com/gnosygnu/xowa.git
synced 2026-03-02 03:49:30 +00:00
v2.8.5.1
This commit is contained in:
@@ -25,7 +25,7 @@ public class Xoh_lnke_wtr_tst {
|
||||
@Test public void Caption() {fxt.Test_parse_page_wiki_str("[irc://a b]" , "<a href=\"irc://a\" class=\"external text\" rel=\"nofollow\">b</a>");}
|
||||
@Test public void Caption_wtxt() {fxt.Test_parse_page_wiki_str("[irc://a ''b'']" , "<a href=\"irc://a\" class=\"external text\" rel=\"nofollow\"><i>b</i></a>");}
|
||||
@Test public void Xowa_protocol() {
|
||||
String img = "<img src=\"file:///mem/xowa/user/test_user/app/img/xowa/protocol.png\"/>";
|
||||
String img = "<img src=\"file:///mem/xowa/bin/any/xowa/file/app.general/xowa_exec.png\"/>";
|
||||
fxt.Wiki().Sys_cfg().Xowa_proto_enabled_(true);
|
||||
fxt.Test_parse_page_wiki_str("[xowa-cmd:\"a\" z]" , "<a href=\"xowa-cmd:a\">z" + img + "</a>");
|
||||
fxt.Test_parse_page_wiki_str("[xowa-cmd:\"a.b('c_d');\" z]" , "<a href=\"xowa-cmd:a.b('c_d');\">z" + img + "</a>");
|
||||
|
||||
@@ -173,7 +173,7 @@ public class Xop_lnke_wkr implements Xop_ctx_wkr {
|
||||
byte[] xwiki_wiki = xo_url_parser_url.Wiki_bry();
|
||||
byte[] xwiki_page = xo_url_parser_url.Page_bry();
|
||||
byte[] ttl_bry = xo_url_parser_url.Page_bry();
|
||||
Xoa_ttl ttl = Xoa_ttl.parse_(wiki, ttl_bry);
|
||||
Xoa_ttl ttl = Xoa_ttl.parse(wiki, ttl_bry);
|
||||
if (ttl != null && ttl.Wik_itm() != null) {
|
||||
xwiki_wiki = ttl.Wik_itm().Domain_bry();
|
||||
xwiki_page = ttl.Page_url();
|
||||
|
||||
@@ -81,7 +81,7 @@ public class Xog_redlink_mgr implements GfoInvkAble {
|
||||
if (variants_enabled) {
|
||||
Xowd_page_itm vnt_page = vnt_mgr.Convert_ttl(wiki, lnki.Ttl());
|
||||
if (vnt_page != null) {
|
||||
Xoa_ttl vnt_ttl = Xoa_ttl.parse_(wiki, lnki.Ttl().Ns().Id(), vnt_page.Ttl_page_db());
|
||||
Xoa_ttl vnt_ttl = Xoa_ttl.parse(wiki, lnki.Ttl().Ns().Id(), vnt_page.Ttl_page_db());
|
||||
html_itm.Html_atr_set(lnki_id, "href", "/wiki/" + String_.new_u8(vnt_ttl.Full_url()));
|
||||
if (!String_.Eq(vnt_mgr.Html_style(), ""))
|
||||
html_itm.Html_atr_set(lnki_id, "style", vnt_mgr.Html_style());
|
||||
|
||||
@@ -68,5 +68,6 @@ public class Xop_log_basic_wkr implements GfoInvkAble {
|
||||
, Tid_timeline = 3
|
||||
, Tid_score = 4
|
||||
, Tid_hiero = 5
|
||||
, Tid_math = 6
|
||||
;
|
||||
}
|
||||
|
||||
@@ -1062,7 +1062,7 @@ public class Xop_para_wkr_basic_tst {
|
||||
, " <div class=\"thumbcaption\">"
|
||||
, " <div class=\"magnify\">"
|
||||
, " <a href=\"/wiki/" + ns + ":" + ttl + "\" class=\"internal\" title=\"Enlarge\">"
|
||||
, " <img src=\"file:///mem/xowa/user/test_user/app/img/file/magnify-clip.png\" width=\"15\" height=\"11\" alt=\"\" />"
|
||||
, " <img src=\"file:///mem/xowa/bin/any/xowa/file/mediawiki.file/magnify-clip.png\" width=\"15\" height=\"11\" alt=\"\" />"
|
||||
, " </a>"
|
||||
, " </div>"
|
||||
, " " + caption + ""
|
||||
|
||||
@@ -28,7 +28,7 @@ public class Xop_util {
|
||||
Bry_bfr tmp_bfr = Bry_bfr.new_();
|
||||
RandomAdp random_gen = RandomAdp_.new_();
|
||||
for (int i = 0; i < len; i += 7) {
|
||||
int rand = random_int_ary == null ? random_gen.Next(Int_.MaxValue) : random_int_ary[i / 7];
|
||||
int rand = random_int_ary == null ? random_gen.Next(Int_.Max_value) : random_int_ary[i / 7];
|
||||
String rand_str = Int_.Xto_str_hex(Bool_.N, Bool_.Y, rand & 0xfffffff); // limits value to 268435455
|
||||
tmp_bfr.Add_str_a7(rand_str);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user