]> git.pld-linux.org Git - packages/xfce4-diskperf-plugin.git/commitdiff
- fix 1842 bug (http://bugzilla.xfce.org/show_bug.cgi?id=1842)
authorMarcin Banasiak <marcin.banasiak@gmail.com>
Tue, 14 Nov 2006 16:54:27 +0000 (16:54 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    xfce4-diskperf-plugin-bug1842.patch -> 1.1

xfce4-diskperf-plugin-bug1842.patch [new file with mode: 0644]

diff --git a/xfce4-diskperf-plugin-bug1842.patch b/xfce4-diskperf-plugin-bug1842.patch
new file mode 100644 (file)
index 0000000..5968d97
--- /dev/null
@@ -0,0 +1,53 @@
+diff -Nur xfce4-diskperf-plugin-2.0/panel-plugin/main.c xfce4-diskperf-plugin-2.0.new/panel-plugin/main.c
+--- xfce4-diskperf-plugin-2.0/panel-plugin/main.c      2005-10-11 22:18:15.000000000 +0300
++++ xfce4-diskperf-plugin-2.0.new/panel-plugin/main.c  2006-10-07 10:15:34.000000000 +0300
+@@ -141,6 +141,8 @@
+       /**************************************************************/
++static int timerNeedsUpdate = 0;
++
+ static int DisplayPerf (struct diskperf_t *p_poPlugin)
+  /* Get the last disk perfomance data, compute the statistics and update
+     the panel-docked monitor bars */
+@@ -273,6 +275,12 @@
+     DisplayPerf (poPlugin);
++    if (timerNeedsUpdate) {
++        g_source_remove (poPlugin->iTimerId);
++        poPlugin->iTimerId = 0;
++        timerNeedsUpdate = 0;
++    }
++
+     if (!poPlugin->iTimerId)
+         poPlugin->iTimerId = g_timeout_add (poConf->iPeriod_ms,
+                                           (GSourceFunc) SetTimer, poPlugin);
+@@ -773,6 +781,7 @@
+     struct param_t *poConf = &(poPlugin->oConf.oParam);
+     float           r;
++    timerNeedsUpdate = 1;
+     TRACE ("SetPeriod()\n");
+     r = gtk_spin_button_get_value (GTK_SPIN_BUTTON (p_wSc));
+     poConf->iPeriod_ms = (r * 1000) + 0.5;    /* rounded */
+@@ -1096,8 +1105,6 @@
+ {
+     diskperf_t *diskperf = diskperf_create_control (plugin);
+-    diskperf_read_config (plugin, diskperf);
+-
+     g_signal_connect (plugin, "free-data", G_CALLBACK (diskperf_free), 
+                       diskperf);
+@@ -1120,7 +1127,9 @@
+     gtk_container_add (GTK_CONTAINER (plugin), diskperf->oMonitor.wEventBox);
+     CreateMonitorBars (diskperf, xfce_panel_plugin_get_orientation (plugin));
+-    
++
++    diskperf_read_config (plugin, diskperf);
++    DevPerfInit();
+     SetTimer (diskperf);
+ }
This page took 0.064539 seconds and 4 git commands to generate.