Changeset 191 in t29-www for en/dev/translation/editor.js
- Timestamp:
- Sep 5, 2010, 9:25:46 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
en/dev/translation/editor.js
r189 r191 9 9 **/ 10 10 11 if(!t29) t29 = {}; // defined in tools.js12 t29.tr = {}; // this namespace 11 if(!t29) t29 = {}; // defined in tools.js 12 if(!t29.tr) t29.tr = {}; // this namespace, also defined in tools.js 13 13 14 14 t29.tr.settings = { 15 15 disable_img_license_system: true, // when tr system enabled, disable img licenses for more cleareness 16 editable_elements: function(){ return $("#content").find("p, ul, ol, blockquote, h2, h3"); },16 editable_elements: function(){ return $("#content").find("p, ul, ol, blockquote, dl, table, h2, h3"); }, 17 17 infobox_default: "<b>Click</b> to contribute a better translation", 18 18 infobox_corrected: "<span class='thanks'>Thank you for your correction.</span> Click to improve your text again.", 19 19 editorbox_heading: "Contribute a better translation", 20 top_notice_text: "<h3>Thank you for improving this page</h3><p>Simply hover the text with your mouse and edit a paragraph by clicking on it.</p>" 20 top_notice_text: "<h3>Thank you for improving this page</h3><p>Simply hover the text with your mouse and edit a paragraph by clicking on it.</p>", 21 21 22 }; 22 23 … … 35 36 if(!t29.tr.is_enabled()) $("body").addClass("tr-disabled"); // prepare 36 37 t29.tr.sidebar = $("#sidebar-tr"); 37 t29.tr.sidebar. find(".tr-enabled .button").click(t29.tr.call("set_enabled",false));38 38 t29.tr.sidebar.append('<span class="arrow tr-enabled"></span>'); 39 t29.tr.sidebar.find(".tr-enabled .button").attr("href","#back_to_normal_mode").click(t29.tr.call("set_enabled",false)); 39 40 // initial value 40 41 //t29.tr.set_enabled(true); … … 198 199 alert("Bad state: Starting editing while editing?"); 199 200 return; // bad 201 } else if(!editing_target_or_false && !t29.tr.is_editing()) { 202 // hab gar nicht bearbeitet. 203 return; 200 204 } 201 205 … … 226 230 // stop editing 227 231 t29.tr.initial_editor = null; 228 // v- falls es noch irgendeinen anderen Muell geben sollte 229 old_editor.add(".tr-editing").attr("contenteditable", "false").removeClass("tr-editing"); 232 if(old_editor) { // falls es noch irgendeinen anderen Muell geben sollte 233 old_editor.add(".tr-editing").attr("contenteditable", "false").removeClass("tr-editing"); 234 } 230 235 t29.tr.editorbox.hide(); 231 236 }
Note: See TracChangeset
for help on using the changeset viewer.