aboutsummaryrefslogtreecommitdiffstats
path: root/infrastructure
diff options
context:
space:
mode:
authorAlexander Sulfrian <alexander@sulfrian.net>2010-02-05 04:18:00 +0100
committerAlexander Sulfrian <alexander@sulfrian.net>2010-02-05 04:18:00 +0100
commit6fb20c578f97c66125122ff9a71751a946083328 (patch)
treec66a89092c17cb490d834c472f6d5814897a0012 /infrastructure
parent81b20c4de67bad271f848eb2dd492c9da0b43678 (diff)
downloadetherpad-6fb20c578f97c66125122ff9a71751a946083328.tar.gz
etherpad-6fb20c578f97c66125122ff9a71751a946083328.tar.xz
etherpad-6fb20c578f97c66125122ff9a71751a946083328.zip
remove other headline properties on setting (no sense in setting two headlines at one region)
Diffstat (limited to 'infrastructure')
-rw-r--r--infrastructure/ace/www/ace2_inner.js7
1 files changed, 7 insertions, 0 deletions
diff --git a/infrastructure/ace/www/ace2_inner.js b/infrastructure/ace/www/ace2_inner.js
index a6233d3..645e406 100644
--- a/infrastructure/ace/www/ace2_inner.js
+++ b/infrastructure/ace/www/ace2_inner.js
@@ -2086,6 +2086,13 @@ function OUTER(gscope) {
[[attributeName,'']]);
}
else {
+ if (attributeName == 'h1' || attributeName == 'h2' || attributeName == 'h3' ||
+ attributeName == 'h4' || attributeName == 'h5' || attributeName == 'h6') {
+ performDocumentApplyAttributesToRange(rep.selStart, rep.selEnd,
+ [['h1',''], ['h2',''], ['h3',''],
+ ['h4',''], ['h5',''], ['h6','']]);
+ }
+
performDocumentApplyAttributesToRange(rep.selStart, rep.selEnd,
[[attributeName,'true']]);
}