From 25b5af50c2d57ed5143fb5eaa6e2fe7067e7a5e9 Mon Sep 17 00:00:00 2001 From: Matt Pass Date: Sun, 17 Jun 2012 16:17:31 +0100 Subject: [PATCH] tabWidth changable & Zip It! on Demand useNewSettings now takes a tabWidth param This changes the width of all open documents in CM instance New function to call Zip It! plugin on demand with target (This means you can zip anything up from the file manager menu) --- lib/coder.js | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/lib/coder.js b/lib/coder.js index 7d5ce8d..e04b106 100644 --- a/lib/coder.js +++ b/lib/coder.js @@ -1479,7 +1479,7 @@ var ICEcoder = { }, // Update the settings used when we make a change to them - useNewSettings: function(themeURL,tabsIndent,codeAssist,lockedNav,visibleTabs,refreshFM) { + useNewSettings: function(themeURL,tabsIndent,codeAssist,lockedNav,visibleTabs,tabWidth,refreshFM) { var styleNode, strCSS, cMCSS; // Add new stylesheet for selected theme @@ -1510,6 +1510,14 @@ var ICEcoder = { cMCSS = ICEcoder.content.contentWindow.document; visibleTabs ? cMCSS.styleSheets[2][strCSS][5].style['content'] = '"\\21e5"' : cMCSS.styleSheets[2][strCSS][5].style['content'] = '" "'; + top.tabWidth = tabWidth; + for (i=0;i -1 ? screenIcon.src = "images/restored-screen.gif" : screenIcon.src = "images/full-screen.gif"; + }, + + // Pass target file/folder to Zip It! + zipIt: function(tgt) { + tgt=tgt.replace(top.fullPath+"/","").replace(/\//g,"|"); + top.ICEcoder.filesFrame.contentWindow.frames['fileControl'].location.href="plugins/zip-it/index.php?zip="+tgt; } }; \ No newline at end of file