Sfoglia il codice sorgente

Device Logs - Edit: Ace Editor icon change, remove old icon files.

fusionate 1 anno fa
parent
commit
75c3f54b01

+ 12 - 28
device_log_edit.php

@@ -256,27 +256,12 @@
 	echo "</script>\n";
 	echo "</script>\n";
 
 
 	echo "<style>\n";
 	echo "<style>\n";
-
-	echo "	img.control {\n";
-	echo "		cursor: pointer;\n";
-	echo "		width: auto;\n";
-	echo "		height: 23px;\n";
-	echo "		border: none;\n";
-	echo "		opacity: 0.5;\n";
-	echo "		}\n";
-
-	echo "	img.control:hover {\n";
-	echo "		opacity: 1.0;\n";
-	echo "		}\n";
-
 	echo "	div#editor {\n";
 	echo "	div#editor {\n";
-	//echo "	box-shadow: 0 3px 10px #333;\n";
 	echo "		text-align: left;\n";
 	echo "		text-align: left;\n";
 	echo "		width: 100%;\n";
 	echo "		width: 100%;\n";
 	echo "		height: 600px;\n";
 	echo "		height: 600px;\n";
 	echo "		font-size: 12px;\n";
 	echo "		font-size: 12px;\n";
 	echo "		}\n";
 	echo "		}\n";
-
 	echo "</style>\n";
 	echo "</style>\n";
 
 
 //show the content
 //show the content
@@ -294,7 +279,7 @@
 	}
 	}
 	echo button::create(['type'=>'submit','label'=>$text['button-save'],'icon'=>$_SESSION['theme']['button_icon_save'],'id'=>'btn_save','name'=>'action','value'=>'save']);
 	echo button::create(['type'=>'submit','label'=>$text['button-save'],'icon'=>$_SESSION['theme']['button_icon_save'],'id'=>'btn_save','name'=>'action','value'=>'save']);
 	echo "	</div>\n";
 	echo "	</div>\n";
-	echo "	<div style='clear: both;'>".$text['description-device_logs']."</div>\n";
+	echo "	<div style='clear: both; text-align: left;'>".$text['description-device_logs']."</div>\n";
 	echo "</div>\n";
 	echo "</div>\n";
 	if ($action == 'update' && permission_exists('device_log_delete')) {
 	if ($action == 'update' && permission_exists('device_log_delete')) {
 		echo modal::create(['id'=>'modal-delete','type'=>'delete','actions'=>button::create(['type'=>'submit','label'=>$text['button-continue'],'icon'=>'check','id'=>'btn_delete','style'=>'float: right; margin-left: 15px;','collapse'=>'never','name'=>'action','value'=>'delete','onclick'=>"modal_close();"])]);
 		echo modal::create(['id'=>'modal-delete','type'=>'delete','actions'=>button::create(['type'=>'submit','label'=>$text['button-continue'],'icon'=>'check','id'=>'btn_delete','style'=>'float: right; margin-left: 15px;','collapse'=>'never','name'=>'action','value'=>'delete','onclick'=>"modal_close();"])]);
@@ -302,7 +287,6 @@
 
 
 	echo "<table width='100%'  border='0' cellpadding='0' cellspacing='0'>\n";
 	echo "<table width='100%'  border='0' cellpadding='0' cellspacing='0'>\n";
 
 
-
 	echo "<tr>\n";
 	echo "<tr>\n";
 	echo "<td class='vncell' valign='top' align='left' nowrap='nowrap'>\n";
 	echo "<td class='vncell' valign='top' align='left' nowrap='nowrap'>\n";
 	echo "	".$text['label-device_uuid']."\n";
 	echo "	".$text['label-device_uuid']."\n";
@@ -444,12 +428,12 @@
 	echo "	<div id='editor'></div>\n";
 	echo "	<div id='editor'></div>\n";
 	echo "	<table cellpadding='0' cellspacing='0' border='0' style='float: right; padding-top: 5px;'>\n";
 	echo "	<table cellpadding='0' cellspacing='0' border='0' style='float: right; padding-top: 5px;'>\n";
 	echo "		<tr>\n";
 	echo "		<tr>\n";
-	echo "			<td valign='middle' style='padding-left: 6px;'><img src='resources/images/icon_numbering.png' title='Toggle Line Numbers' class='control' onclick=\"toggle_option('numbering');\"></td>\n";
-	echo "			<td valign='middle' style='padding-left: 6px;'><img src='resources/images/icon_invisibles.png' title='Toggle Invisibles' class='control' onclick=\"toggle_option('invisibles');\"></td>\n";
-	echo "			<td valign='middle' style='padding-left: 6px;'><img src='resources/images/icon_indenting.png' title='Toggle Indent Guides' class='control' onclick=\"toggle_option('indenting');\"></td>\n";
-	echo "			<td valign='middle' style='padding-left: 6px;'><img src='resources/images/icon_replace.png' title='Show Find/Replace [Ctrl+H]' class='control' onclick=\"editor.execCommand('replace');\"></td>\n";
-	echo "			<td valign='middle' style='padding-left: 6px;'><img src='resources/images/icon_goto.png' title='Show Go To Line' class='control' onclick=\"editor.execCommand('gotoline');\"></td>\n";
-	echo "			<td valign='middle' style='padding-left: 4px;'>\n";
+	echo "			<td valign='middle' style='padding-left: 6px;'><i class='fas fa-list-ul fa-lg ace_control' title=\"".$text['label-toggle_line_numbers']."\" onclick=\"toggle_option('numbering');\"></i></td>\n";
+	echo "			<td valign='middle' style='padding-left: 6px;'><i class='fas fa-eye-slash fa-lg ace_control' title=\"".$text['label-toggle_invisibles']."\" onclick=\"toggle_option('invisibles');\"></i></td>\n";
+	echo "			<td valign='middle' style='padding-left: 6px;'><i class='fas fa-indent fa-lg ace_control' title=\"".$text['label-toggle_indent_guides']."\" onclick=\"toggle_option('indenting');\"></i></td>\n";
+	echo "			<td valign='middle' style='padding-left: 6px;'><i class='fas fa-search fa-lg ace_control' title=\"".$text['label-find_replace']."\" onclick=\"editor.execCommand('replace');\"></i></td>\n";
+	echo "			<td valign='middle' style='padding-left: 6px;'><i class='fas fa-chevron-down fa-lg ace_control' title=\"".$text['label-go_to_line']."\" onclick=\"editor.execCommand('gotoline');\"></i></td>\n";
+	echo "			<td valign='middle' style='padding-left: 15px;'>\n";
 	echo "				<select id='size' class='formfld' onchange=\"document.getElementById('editor').style.fontSize = this.options[this.selectedIndex].value; focus_editor();\">\n";
 	echo "				<select id='size' class='formfld' onchange=\"document.getElementById('editor').style.fontSize = this.options[this.selectedIndex].value; focus_editor();\">\n";
 	$sizes = explode(',','9px,10px,11px,12px,14px,16px,18px,20px');
 	$sizes = explode(',','9px,10px,11px,12px,14px,16px,18px,20px');
 	if (!in_array($setting_size, $sizes)) {
 	if (!in_array($setting_size, $sizes)) {
@@ -463,7 +447,6 @@
 	echo "				</select>\n";
 	echo "				</select>\n";
 	echo "			</td>\n";
 	echo "			</td>\n";
 	echo "			<td valign='middle' style='padding-left: 4px; padding-right: 0px;'>\n";
 	echo "			<td valign='middle' style='padding-left: 4px; padding-right: 0px;'>\n";
-	echo "				<select id='theme' class='formfld' onchange=\"editor.setTheme('ace/theme/' + this.options[this.selectedIndex].value); focus_editor();\">\n";
 	$themes['Light']['chrome']= 'Chrome';
 	$themes['Light']['chrome']= 'Chrome';
 	$themes['Light']['clouds']= 'Clouds';
 	$themes['Light']['clouds']= 'Clouds';
 	$themes['Light']['crimson_editor']= 'Crimson Editor';
 	$themes['Light']['crimson_editor']= 'Crimson Editor';
@@ -498,13 +481,14 @@
 	$themes['Dark']['tomorrow_night_eighties']= 'Tomorrow Night 80s';
 	$themes['Dark']['tomorrow_night_eighties']= 'Tomorrow Night 80s';
 	$themes['Dark']['twilight']= 'Twilight';
 	$themes['Dark']['twilight']= 'Twilight';
 	$themes['Dark']['vibrant_ink']= 'Vibrant Ink';
 	$themes['Dark']['vibrant_ink']= 'Vibrant Ink';
+	echo "				<select id='theme' class='formfld' onchange=\"editor.setTheme('ace/theme/' + this.options[this.selectedIndex].value); focus_editor();\">\n";
 	foreach ($themes as $optgroup => $theme) {
 	foreach ($themes as $optgroup => $theme) {
-		echo "<optgroup label='".$optgroup."'>\n";
+		echo "				<optgroup label='".$optgroup."'>\n";
 		foreach ($theme as $value => $label) {
 		foreach ($theme as $value => $label) {
 			$selected = strtolower($label) == strtolower($setting_theme) ? 'selected' : null;
 			$selected = strtolower($label) == strtolower($setting_theme) ? 'selected' : null;
-			echo "<option value='".$value."' ".$selected.">".escape($label)."</option>\n";
+			echo "				<option value='".$value."' ".$selected.">".escape($label)."</option>\n";
 		}
 		}
-		echo "</optgroup>\n";
+		echo "				</optgroup>\n";
 	}
 	}
 
 
 	echo "				</select>\n";
 	echo "				</select>\n";
@@ -562,4 +546,4 @@
 //include the footer
 //include the footer
 	require_once "resources/footer.php";
 	require_once "resources/footer.php";
 
 
-?>
+?>

BIN
resources/images/icon_goto.png


BIN
resources/images/icon_indenting.png


BIN
resources/images/icon_invisibles.png


BIN
resources/images/icon_numbering.png


BIN
resources/images/icon_replace.png