85
85
settings.set_string("rss-url", rssEntry.get_text ());
89
var refreshLabel = new Gtk.Label (_("Refresh Interval") + " :");
90
container.attach(refreshLabel, 0, 1, 1, 1);
91
refreshLabel.set_alignment (1, 0);
94
var scale = new Gtk.Scale.with_range (Gtk.Orientation.HORIZONTAL, 0, 3600000, 60000);
95
scale.set_draw_value (false);
96
scale.add_mark (300000, Gtk.PositionType.BOTTOM, _("5 min"));
97
scale.add_mark (1200000, Gtk.PositionType.BOTTOM, _("20 min"));
98
scale.add_mark (2400000, Gtk.PositionType.BOTTOM, _("40 min"));
99
scale.add_mark (3600000, Gtk.PositionType.BOTTOM, _("1 hour"));
101
scale.set_value (update_interval);
103
scale.value_changed.connect (() => {
104
settings.set_int("update-interval", (int) scale.get_value() );
107
container.attach(scale, 1, 1, 2, 1);
110
var resetButton = new Gtk.Button.with_label ( _("Reset") );
111
container.attach(resetButton, 2, 2, 1, 1);
112
resetButton.clicked.connect(() => {
113
settings.reset ("rss-url");
114
settings.reset ("update-interval");
115
rss_url = settings.get_string("rss-url");
116
update_interval = settings.get_int("update-interval");
117
rssEntry.set_text (rss_url);
118
scale.set_value (update_interval);