This commit is contained in:
sevin7676 2015-04-18 08:27:22 -04:00
commit a0a31e16a2

View file

@ -44,16 +44,11 @@ oop.inherits(FoldMode, BaseFoldMode);
* Inheriting cstyle folding because it handles the region comment folding
* and special block comment folding appropriately.
*
* Cstyle's getCommentRegionBlock() contains the sql comment characters '--'.
* Cstyle's getCommentRegionBlock() contains the sql comment characters '--' for end region block.
*/
this.foldingStartMarker = /(\bCASE\b|\bBEGIN\b)|^\s*(\/\*)/i;
this.foldingStopMarker = /^(\bEND\b)|^[\s\*]*(\*\/)/i;
// this.foldingStopMarker = /(\bEND\b)|^[\s\*]*(\*\/)/i;?need hat?
// this.foldingStopMarker = /^(?!\bCASE\b|\bBEGIN\b)(\bEND\b)|^[\s\*]*(\*\/)/i;
// this.foldingStopMarker = /^(?!\bCASE\b|\bBEGIN\b).*(\bEND\b)|^[\s\*]*(\*\/)/i;
this.foldingStopMarker = /(\bEND\b)|^[\s\*]*(\*\/)/i;
this.startRegionRe = /^\s*(\/\*|--)#?region\b/;
this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
@ -70,7 +65,7 @@ oop.inherits(FoldMode, BaseFoldMode);
if (range && !range.isMultiLine()) {
if (forceMultiline) {
range = this.getSectionRange(session, row);
console.log('getSectionRange',range);
console.log('getSectionRange', range);
}
else if (foldStyle != "all") range = null;
}