From cd71385e98ea6bddf88591c0ce14ebf85ba8e02e Mon Sep 17 00:00:00 2001 From: mattpass Date: Thu, 2 Jul 2020 19:37:45 +0100 Subject: [PATCH] Improve item coloring according to state --- classes/File.php | 8 ++------ index.php | 2 +- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/classes/File.php b/classes/File.php index 565fc3e..e9114af 100644 --- a/classes/File.php +++ b/classes/File.php @@ -87,13 +87,9 @@ class File $doNext = ""; // Reload file manager, rename tab & remove old file highlighting if it was a new file if (isset($_POST['newFileName']) && "" != $_POST['newFileName']) { - $doNext .= 'ICEcoder.selectedFiles=[]; ICEcoder.updateFileManagerList(\'add\', \'' . $fileLoc . '\', \'' . $fileName . '\', false, false, false, \'file\');'; + $doNext .= 'ICEcoder.selectedFiles=[];'; + $doNext .= 'ICEcoder.updateFileManagerList(\'add\', \'' . $fileLoc . '\', \'' . $fileName . '\', false, false, false, \'file\');'; $doNext .= 'ICEcoder.renameTab(ICEcoder.selectedTab, \'' . $fileLoc . "/" . $fileName . '\');'; - if (!strpos($_REQUEST['file'], "[NEW]")) { - // We're saving as a new file, so unhighlight the old name in the file manager if visible - $doNext .= "fileLink = ICEcoder.filesFrame.contentWindow.document.getElementById('" . str_replace("/", "|", $fileLoc) . "|". basename($_REQUEST['file']). "');"; - $doNext .= "if (fileLink) {fileLink.style.backgroundColor = ICEcoder.tabBGnormal; fileLink.style.color = ICEcoder.tabFGnormalFile};"; - } } return $doNext; diff --git a/index.php b/index.php index e5fd304..b55daf5 100644 --- a/index.php +++ b/index.php @@ -314,7 +314,7 @@ if (true === $havePrettier && true === file_exists(dirname(__FILE__) . "/plugins '; + echo '
'; } ?>
+