]> git.wh0rd.org Git - tt-rss.git/commitdiff
pref-prefs: show default update interval as a dropdown
authorAndrew Dolgov <fox@bah.org.ru>
Wed, 20 Jan 2010 10:20:20 +0000 (13:20 +0300)
committerAndrew Dolgov <fox@bah.org.ru>
Wed, 20 Jan 2010 10:20:20 +0000 (13:20 +0300)
backend.php
modules/pref-prefs.php

index 7757931f3e38ccd75bc3ec58899fa24345fa548f..b9b60a5425f9dc478f3e9164c060a81a3ab0b81b 100644 (file)
                1440 => __("Daily"),
                10080 => __("Weekly"));
 
+       $update_intervals_nodefault = array(
+               -1  => __("Disable updates"),
+               15  => __("Each 15 minutes"),
+               30  => __("Each 30 minutes"),
+               60  => __("Hourly"),
+               240 => __("Each 4 hours"),
+               720 => __("Each 12 hours"),
+               1440 => __("Daily"),
+               10080 => __("Weekly"));
+
        $update_methods = array(
                0   => __("Default"),
                1   => __("Magpie"),
index 9b58cdbb49200cf4b60caba54ac077054318d5bd..da5ae60bf41cff18be450fbe3fc17d84b23aae64 100644 (file)
 
                                print "<td class=\"prefValue\">";
 
-                               if ($type_name == "bool") {
+                               if ($pref_name == "DEFAULT_UPDATE_INTERVAL") {
+
+                                       global $update_intervals_nodefault;
+
+                                       print_select_hash($pref_name, $value, $update_intervals_nodefault);
+
+                               } else if ($type_name == "bool") {
 //                                     print_select($pref_name, $value, array("true", "false"));
 
                                        if ($value == "true") {