writing mode fix

This commit is contained in:
life
2014-05-13 17:17:13 +08:00
parent 6ed0e30d2b
commit 5244c89987
5 changed files with 6 additions and 4 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -292,11 +292,13 @@ function switchEditor(isMarkdown) {
// 刚开始没有
editorIframeTabindex(2);
$("#wmd-input").attr("tabindex", 3);
$("#leanoteNav").show();
} else {
$("#mdEditor").css("z-index", 3).show();
editorIframeTabindex(3);
$("#wmd-input").attr("tabindex", 2);
$("#leanoteNav").hide();
}
}

View File

@ -27,7 +27,7 @@ tinymce.PluginManager.add('leanote_nav', function(editor) {
titles += "</ul>";
$("#leanoteNavContent").html(titles).height("auto"); // auto
if(!hs.length) {
$("#leanoteNavContent").html("&nbsp; ");
$("#leanoteNavContent").html("&nbsp; Nothing...");
}
// 这里, resize Height

View File

@ -1 +1 @@
tinymce.PluginManager.add("leanote_nav",function(t){function n(){var n=t.getBody(),o=$(n),a=o.html();if(e!=a){e=a;for(var i=o.find("h1,h2,h3,h4,h5,h6").toArray(),l="<ul>",h=0;h<i.length;++h){var c=$(i[h]).text(),r=i[h].tagName.toLowerCase();l+='<li class="nav-'+r+'"><a data-a="'+r+"-"+encodeURI(c)+'" onclick="scrollTo(this, \''+r+"', '"+c+"')\">"+c+"</a></li>"}l+="</ul>",$("#leanoteNavContent").html(l).height("auto"),i.length||$("#leanoteNavContent").html("&nbsp; ");var d=$("#leanoteNavContent").height(),g=$("#editorContent_ifr").height()-29;d>g&&$("#leanoteNavContent").height(g)}}var e="";t.on("init",function(){window.setTimeout(function(){n(),t.on("setcontent beforeadd undo paste",n),t.on("ExecCommand",function(){n()}),t.on("click",function(){n(),$("body").trigger("click")})},0)})});
tinymce.PluginManager.add("leanote_nav",function(t){function n(){var n=t.getBody(),o=$(n),a=o.html();if(e!=a){e=a;for(var i=o.find("h1,h2,h3,h4,h5,h6").toArray(),h="<ul>",l=0;l<i.length;++l){var c=$(i[l]).text(),r=i[l].tagName.toLowerCase();h+='<li class="nav-'+r+'"><a data-a="'+r+"-"+encodeURI(c)+'" onclick="scrollTo(this, \''+r+"', '"+c+"')\">"+c+"</a></li>"}h+="</ul>",$("#leanoteNavContent").html(h).height("auto"),i.length||$("#leanoteNavContent").html("&nbsp; Nothing...");var d=$("#leanoteNavContent").height(),g=$("#editorContent_ifr").height()-29;d>g&&$("#leanoteNavContent").height(g)}}var e="";t.on("init",function(){window.setTimeout(function(){n(),t.on("setcontent beforeadd undo paste",n),t.on("ExecCommand",function(){n()}),t.on("click",function(){n(),$("body").trigger("click")})},0)})});