Changeset 792
- Timestamp:
- 11/14/2007 04:57:34 PM (3 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
branches/1.1.6.4/3rdparty/plugins/wikkaedit/wikkaedit.js
r783 r792 39 39 if (this.we_actionsMenuEnabled) 40 40 this.initActions(); 41 41 42 //var we_ta_container = this.we_ta; // without textarea_container (old method) 43 var we_ta_container = document.getElementById("textarea_container"); // with textarea_container 44 42 45 // add a toolbar before textarea 43 46 this.we_toolbar = document.createElement("div"); 44 47 this.we_toolbar.id = "wikkatoolbar"; 45 48 this.we_toolbar.innerHTML = this.genToolbar(); 46 this.we_ta.parentNode.insertBefore(this.we_toolbar, this.we_ta);49 we_ta_container.parentNode.insertBefore(this.we_toolbar, we_ta_container); 47 50 48 51 // submenu … … 50 53 this.we_submenu.id = "wikkasubmenu"; 51 54 this.we_submenu.style.visibility = "hidden"; 52 this.we_ta.parentNode.insertBefore(this.we_submenu, this.we_ta); //this.we_help.nextSibling);55 we_ta_container.parentNode.insertBefore(this.we_submenu, we_ta_container); //this.we_help.nextSibling); 53 56 54 57 // search & replace … … 60 63 this.we_search.style.width = "500px"; // width & height can't be moved to the CSS, else JS can't read these values later 61 64 this.we_search.style.height = "180px"; 62 this.we_ta.parentNode.insertBefore(this.we_search, this.we_ta.nextSibling);63 64 // dummy textarea, used to scroll th is.we_ta to the right position65 we_ta_container.parentNode.insertBefore(this.we_search, we_ta_container.nextSibling); 66 67 // dummy textarea, used to scroll the textarea to the right position 65 68 // it is hidden, but it needs to be inserted to the page to work 66 69 this.we_searchTa = document.createElement("textarea"); … … 70 73 this.we_searchTa.style.visibility = "hidden"; 71 74 this.we_searchTa.style.scroll = "auto"; 72 this.we_ta.parentNode.insertBefore(this.we_searchTa, this.we_ta.nextSibling);75 we_ta_container.parentNode.insertBefore(this.we_searchTa, we_ta_container.nextSibling); 73 76 } 74 77 … … 81 84 this.we_help.innerHTML = this.we_helpPreviousContent; // contains at least a character to keep constant height 82 85 this.we_help.style.display = (this.we_actionsMenuEnabled ? "" : "none"); 83 this.we_ta.parentNode.insertBefore(this.we_help, this.we_ta.nextSibling.nextSibling); // next*2 to skip following <br/>86 we_ta_container.parentNode.insertBefore(this.we_help, we_ta_container.nextSibling.nextSibling); // next*2 to skip following <br/> 84 87 // tooltip 85 88 this.we_tooltip = document.createElement("div"); 86 89 this.we_tooltip.id = "wikkatooltip"; 87 90 this.we_tooltip.style.visibility = "hidden" 88 this.we_ta.parentNode.insertBefore(this.we_tooltip, this.we_help.nextSibling);91 we_ta_container.parentNode.insertBefore(this.we_tooltip, this.we_help.nextSibling); 89 92 } 90 93 … … 94 97 this.we_log.innerHTML = "log<br/>"; 95 98 this.we_log.style.display = "none"; 96 this.we_ta.parentNode.insertBefore(this.we_log, this.we_ta.nextSibling);99 we_ta_container.parentNode.insertBefore(this.we_log, we_ta_container.nextSibling); 97 100 98 101 // make sure nothing is selectionned in the textarea