aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorThierry Vignaud <thierry.vignaud@gmail.com>2013-11-20 06:29:29 +0100
committerThierry Vignaud <thierry.vignaud@gmail.com>2013-11-20 06:31:42 +0100
commitc68733b0f98deb7723b61f01e4ca84d87e463569 (patch)
tree5dc609cb67216f04caaf1f168b9cc441a27b1ad6 /src
parent7ab12b88799eea07b8460c37329b3d46b5fcf826 (diff)
downloadnet_monitor-c68733b0f98deb7723b61f01e4ca84d87e463569.tar
net_monitor-c68733b0f98deb7723b61f01e4ca84d87e463569.tar.gz
net_monitor-c68733b0f98deb7723b61f01e4ca84d87e463569.tar.bz2
net_monitor-c68733b0f98deb7723b61f01e4ca84d87e463569.tar.xz
net_monitor-c68733b0f98deb7723b61f01e4ca84d87e463569.zip
fix RadioButtons
Diffstat (limited to 'src')
-rwxr-xr-xsrc/net_monitor19
1 files changed, 12 insertions, 7 deletions
diff --git a/src/net_monitor b/src/net_monitor
index 14cce77..9ab770b 100755
--- a/src/net_monitor
+++ b/src/net_monitor
@@ -2,6 +2,7 @@
from gi.repository import GObject
from gi.repository import Gdk
+from gi.repository import GdkPixbuf
from gi.repository import Gtk
from gi.repository import Pango
@@ -517,25 +518,29 @@ class MonitorGui:
vbox = Gtk.VBox()
frame.add(vbox)
# summary
- button = Gtk.RadioButton(None, _("Summary"))
- button.connect('toggled', self.update_stat_iface, (iface, graph_vnstat, "summary"))
- vbox.pack_start(button, False, False, 0)
+ first_button = Gtk.RadioButton(None, _("Summary"))
+ first_button.connect('toggled', self.update_stat_iface, (iface, graph_vnstat, "summary"))
+ vbox.pack_start(first_button, False, False, 0)
# summary
- button = Gtk.RadioButton(button, _("Hourly traffic"))
+ button = Gtk.RadioButton(None, _("Hourly traffic"))
button.connect('toggled', self.update_stat_iface, (iface, graph_vnstat, "hourly"))
vbox.pack_start(button, False, False, 0)
+ button.join_group(first_button)
# summary
- button = Gtk.RadioButton(button, _("Daily traffic"))
+ button = Gtk.RadioButton(None, _("Daily traffic"))
button.connect('toggled', self.update_stat_iface, (iface, graph_vnstat, "daily"))
vbox.pack_start(button, False, False, 0)
+ button.join_group(first_button)
# summary
- button = Gtk.RadioButton(button, _("Monthly traffic"))
+ button = Gtk.RadioButton(None, _("Monthly traffic"))
button.connect('toggled', self.update_stat_iface, (iface, graph_vnstat, "monthly"))
vbox.pack_start(button, False, False, 0)
+ button.join_group(first_button)
# summary
- button = Gtk.RadioButton(button, _("Top 10 traffic days"))
+ button = Gtk.RadioButton(None, _("Top 10 traffic days"))
button.connect('toggled', self.update_stat_iface, (iface, graph_vnstat, "top"))
vbox.pack_start(button, False, False, 0)
+ button.join_group(first_button)
else:
label = Gtk.Label(label=_("Network accounting was not enabled on interface %s.\nPlease enable network accounting on the interface in order to view traffic statistics and restart your network connection to start collecting traffic statistics."))
stats_vbox.add(label)