summaryrefslogtreecommitdiff
path: root/modules/pref-labels.php
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2009-01-26 17:01:46 +0100
committerAndrew Dolgov <[email protected]>2009-01-26 17:01:46 +0100
commitaec9df485dda2b694cc18b9e3a5877379f910541 (patch)
tree32744e22a00c1abcee2a97dfe7127d91719d7860 /modules/pref-labels.php
parentb8776a07f1c125955a9e8ad1ca13097411568fbd (diff)
colored labels UI improvements
Diffstat (limited to 'modules/pref-labels.php')
-rw-r--r--modules/pref-labels.php27
1 files changed, 19 insertions, 8 deletions
diff --git a/modules/pref-labels.php b/modules/pref-labels.php
index 162592625..66753df9a 100644
--- a/modules/pref-labels.php
+++ b/modules/pref-labels.php
@@ -14,6 +14,18 @@
AND owner_uid = " . $_SESSION["uid"]);
}
+ return;
+ }
+
+ if ($subop == "color-reset") {
+ $ids = split(',', db_escape_string($_REQUEST["ids"]));
+
+ foreach ($ids as $id) {
+ db_query($link, "UPDATE ttrss_labels2 SET
+ fg_color = '', bg_color = '' WHERE id = '$id'
+ AND owner_uid = " . $_SESSION["uid"]);
+ }
+
}
if ($subop == "save") {
@@ -192,8 +204,8 @@
$fg_color = $line["fg_color"];
$bg_color = $line["bg_color"];
- if (!$fg_color) $fg_color = "black";
- if (!$bg_color) $bg_color = "transparent";
+ if (!$fg_color) $fg_color = "";
+ if (!$bg_color) $bg_color = "";
print "<td width='5%' align='center'><input
onclick='toggleSelectPrefRow(this, \"label\");'
@@ -201,15 +213,14 @@
$id = $line['id'];
-/* print "<td width='30' align='center'>
- <div class='labelColorIndicator'
+ print "<td>";
+
+ print "<div class='labelColorIndicator' id='LICID-$id'
style='color : $fg_color; background-color : $bg_color'
- onclick=\"colorPicker(this, '$id', '$fg_color', '$bg_color')\">z</div>";
+ onclick=\"colorPicker(this, '$id', '$fg_color', '$bg_color')\">&alpha;</div>&nbsp;";
- print "</td>"; */
- print "<td><span class='prefsLabelEntry'
- style='color : $fg_color; background-color : $bg_color'
+ print "<span class='prefsLabelEntry'
id=\"LILT-".$line["id"]."\">" . $line["caption"] .
"</span>";