diff --git a/editor.php b/editor.php index 888a0a3..c419790 100644 --- a/editor.php +++ b/editor.php @@ -214,7 +214,7 @@ function createNewCMInstance(num) { var filepath = top.ICEcoder.openFiles[top.ICEcoder.selectedTab-1]; var filename = filepath.substr(filepath.lastIndexOf("/")+1); var fileExt = filename.substr(filename.lastIndexOf(".")+1); - for (var i=changeObj.from.line; i -1 ? "braceRangeFinder" : "tagRangeFinder"],null,"+","-",true)(thisCM, i); } // Update HTML edited files live @@ -252,7 +252,10 @@ function createNewCMInstance(num) { ); window['cM'+num].on("gutterClick", function(thisCM, line, gutter, clickEvent) { - ["JavaScript","CoffeeScript","PHP","Python","Ruby"].indexOf(top.ICEcoder.caretLocType) > -1 + var filepath = top.ICEcoder.openFiles[top.ICEcoder.selectedTab-1]; + var filename = filepath.substr(filepath.lastIndexOf("/")+1); + var fileExt = filename.substr(filename.lastIndexOf(".")+1); + ["coffee","css","js","less","php","py","rb","ruby"].indexOf(fileExt) > -1 ? codeFoldBrace(window['cM'+num], line) : codeFoldTag(window['cM'+num], line); } );