Nucleus CMS日本語版SVNをgit-svnしたもの。リポジトリの変換作業用
Revision | e127201e9955cdba5c7bf7ec813aff25f59c8b5a (tree) |
---|---|
Zeit | 2005-03-23 15:08:46 |
Autor | kimitake <kimitake@1ca2...> |
Commiter | kimitake |
updated correct file
git-svn-id: https://svn.sourceforge.jp/svnroot/nucleus-jp/nucleus-jp/branches/branch-3-15@73 1ca29b6e-896d-4ea0-84a5-967f57386b96
@@ -125,7 +125,7 @@ function ahrefThis() { | ||
125 | 125 | } |
126 | 126 | |
127 | 127 | function execAndUpdate(action) { |
128 | - lastSelected.caretPos.execCommand(action); | |
128 | + lastCaretPos.execCommand(action); | |
129 | 129 | updAllPreviews(); |
130 | 130 | } |
131 | 131 |
@@ -204,6 +204,7 @@ function includeOtherMedia(collection, filename) { | ||
204 | 204 | // function to prevent submitting form data twice |
205 | 205 | var submitcount=0; |
206 | 206 | function checkSubmit() { |
207 | + | |
207 | 208 | if (submitcount == 0) { |
208 | 209 | submitcount++; |
209 | 210 | return true; |
@@ -218,6 +219,7 @@ function checkSubmit() { | ||
218 | 219 | // http://www.faqts.com/knowledge_base/view.phtml/aid/1052/fid/130 |
219 | 220 | |
220 | 221 | // stores the caret |
222 | +var lastSelected, lastCaretPos; | |
221 | 223 | function storeCaret (textEl) { |
222 | 224 | |
223 | 225 | // store caret |
@@ -231,13 +233,13 @@ function storeCaret (textEl) { | ||
231 | 233 | nonie_FormType = textEl.name; |
232 | 234 | } |
233 | 235 | |
234 | -var lastSelected; | |
236 | +//var lastSelected; | |
235 | 237 | |
236 | 238 | // inserts text at caret (overwriting selection) |
237 | 239 | function insertAtCaret (text) { |
238 | 240 | var textEl = lastSelected; |
239 | - if (textEl && textEl.createTextRange && textEl.caretPos) { | |
240 | - var caretPos = textEl.caretPos; | |
241 | + if (textEl && textEl.createTextRange && lastCaretPos) { | |
242 | + var caretPos = lastCaretPos; | |
241 | 243 | caretPos.text = caretPos.text.charAt(caretPos.text.length - 1) == ' ' ? text + ' ' : text; |
242 | 244 | } else if (!document.all && document.getElementById) { |
243 | 245 | mozReplace(document.getElementById('input' + nonie_FormType), text); |
@@ -253,8 +255,8 @@ function insertAtCaret (text) { | ||
253 | 255 | function insertAroundCaret (textpre, textpost) { |
254 | 256 | var textEl = lastSelected; |
255 | 257 | |
256 | - if (textEl && textEl.createTextRange && textEl.caretPos) { | |
257 | - var caretPos = textEl.caretPos; | |
258 | + if (textEl && textEl.createTextRange && lastCaretPos) { | |
259 | + var caretPos = lastCaretPos; | |
258 | 260 | caretPos.text = textpre + caretPos.text + textpost; |
259 | 261 | } else if (!document.all && document.getElementById) { |
260 | 262 | mozWrap(document.getElementById('input' + nonie_FormType), textpre, textpost); |
@@ -299,12 +301,12 @@ function getCaretText() { | ||
299 | 301 | if (!document.all && document.getElementById) |
300 | 302 | return mozSelectedText(); |
301 | 303 | else |
302 | - return lastSelected.caretPos.text; | |
304 | + return lastCaretPos.text; | |
303 | 305 | } |
304 | 306 | |
305 | 307 | function isCaretEmpty() { |
306 | - if (lastSelected && lastSelected.createTextRange && lastSelected.caretPos) | |
307 | - return (lastSelected.caretPos.text == ''); | |
308 | + if (lastSelected && lastSelected.createTextRange && lastCaretPos) | |
309 | + return (lastCaretPos.text == ''); | |
308 | 310 | else if (!document.all && document.getElementById) |
309 | 311 | return (mozSelectedText() == ''); |
310 | 312 | else |
@@ -125,7 +125,7 @@ function ahrefThis() { | ||
125 | 125 | } |
126 | 126 | |
127 | 127 | function execAndUpdate(action) { |
128 | - lastSelected.caretPos.execCommand(action); | |
128 | + lastCaretPos.execCommand(action); | |
129 | 129 | updAllPreviews(); |
130 | 130 | } |
131 | 131 |
@@ -204,6 +204,7 @@ function includeOtherMedia(collection, filename) { | ||
204 | 204 | // function to prevent submitting form data twice |
205 | 205 | var submitcount=0; |
206 | 206 | function checkSubmit() { |
207 | + | |
207 | 208 | if (submitcount == 0) { |
208 | 209 | submitcount++; |
209 | 210 | return true; |
@@ -218,6 +219,7 @@ function checkSubmit() { | ||
218 | 219 | // http://www.faqts.com/knowledge_base/view.phtml/aid/1052/fid/130 |
219 | 220 | |
220 | 221 | // stores the caret |
222 | +var lastSelected, lastCaretPos; | |
221 | 223 | function storeCaret (textEl) { |
222 | 224 | |
223 | 225 | // store caret |
@@ -231,13 +233,13 @@ function storeCaret (textEl) { | ||
231 | 233 | nonie_FormType = textEl.name; |
232 | 234 | } |
233 | 235 | |
234 | -var lastSelected; | |
236 | +//var lastSelected; | |
235 | 237 | |
236 | 238 | // inserts text at caret (overwriting selection) |
237 | 239 | function insertAtCaret (text) { |
238 | 240 | var textEl = lastSelected; |
239 | - if (textEl && textEl.createTextRange && textEl.caretPos) { | |
240 | - var caretPos = textEl.caretPos; | |
241 | + if (textEl && textEl.createTextRange && lastCaretPos) { | |
242 | + var caretPos = lastCaretPos; | |
241 | 243 | caretPos.text = caretPos.text.charAt(caretPos.text.length - 1) == ' ' ? text + ' ' : text; |
242 | 244 | } else if (!document.all && document.getElementById) { |
243 | 245 | mozReplace(document.getElementById('input' + nonie_FormType), text); |
@@ -253,8 +255,8 @@ function insertAtCaret (text) { | ||
253 | 255 | function insertAroundCaret (textpre, textpost) { |
254 | 256 | var textEl = lastSelected; |
255 | 257 | |
256 | - if (textEl && textEl.createTextRange && textEl.caretPos) { | |
257 | - var caretPos = textEl.caretPos; | |
258 | + if (textEl && textEl.createTextRange && lastCaretPos) { | |
259 | + var caretPos = lastCaretPos; | |
258 | 260 | caretPos.text = textpre + caretPos.text + textpost; |
259 | 261 | } else if (!document.all && document.getElementById) { |
260 | 262 | mozWrap(document.getElementById('input' + nonie_FormType), textpre, textpost); |
@@ -299,12 +301,12 @@ function getCaretText() { | ||
299 | 301 | if (!document.all && document.getElementById) |
300 | 302 | return mozSelectedText(); |
301 | 303 | else |
302 | - return lastSelected.caretPos.text; | |
304 | + return lastCaretPos.text; | |
303 | 305 | } |
304 | 306 | |
305 | 307 | function isCaretEmpty() { |
306 | - if (lastSelected && lastSelected.createTextRange && lastSelected.caretPos) | |
307 | - return (lastSelected.caretPos.text == ''); | |
308 | + if (lastSelected && lastSelected.createTextRange && lastCaretPos) | |
309 | + return (lastCaretPos.text == ''); | |
308 | 310 | else if (!document.all && document.getElementById) |
309 | 311 | return (mozSelectedText() == ''); |
310 | 312 | else |