fnp
/
redakcja.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Generowanie pybundle z wymaganymi bibliotekami na komputerze lokalnym i przerzucanie...
[redakcja.git]
/
project
/
static
/
js
/
button_scripts.js
diff --git
a/project/static/js/button_scripts.js
b/project/static/js/button_scripts.js
index
8c04929
..
40f45f6
100644
(file)
--- a/
project/static/js/button_scripts.js
+++ b/
project/static/js/button_scripts.js
@@
-42,11
+42,11
@@
function ScriptletCenter()
output = start_tag + end_tag;
}
output = start_tag + end_tag;
}
- if (text.length === 0) {
- this.XMLEditorMoveCursorForward(context, params.tag.length + 2);
- }
-
this.XMLEditorReplaceSelectedText(context, output);
this.XMLEditorReplaceSelectedText(context, output);
+
+ if (text.length == 0) {
+ this.XMLEditorMoveCursorForward(context, -params.tag.length-3);
+ }
}.bind(this);
this.scriptlets['lineregexp'] = function(context, params) {
}.bind(this);
this.scriptlets['lineregexp'] = function(context, params) {
@@
-167,7
+167,7
@@
function ScriptletCenter()
for(var i=0; i < verses.length; i++) {
var verse = verses[i].replace(/^\s+/, "").replace(/\s+$/, "");
if(verse) {
for(var i=0; i < verses.length; i++) {
var verse = verses[i].replace(/^\s+/, "").replace(/\s+$/, "");
if(verse) {
- text += (buf ? buf + '
\\
\n' : '') + ebuf;
+ text += (buf ? buf + '
/
\n' : '') + ebuf;
buf = (first ? '<strofa>\n' : '') + verses[i];
ebuf = '';
first = false;
buf = (first ? '<strofa>\n' : '') + verses[i];
ebuf = '';
first = false;