[Goodies-dev] [Bug 10385] New: Jumping panel resize at 1 GHz
bugzilla-daemon at xfce.org
bugzilla-daemon at xfce.org
Thu Oct 3 16:30:27 CEST 2013
https://bugzilla.xfce.org/show_bug.cgi?id=10385
Bug ID: 10385
Summary: Jumping panel resize at 1 GHz
Classification: Panel Plugins
Product: Xfce4-cpufreq-plugin
Version: unspecified
Hardware: All
OS: Linux
Status: NEW
Severity: enhancement
Priority: Medium
Component: General
Assignee: goodies-dev at xfce.org
Reporter: nick at linicks.net
QA Contact: frivoal at xfce.org
I noticed that if CPU(s) freq. are dropped to 1Ghz, the icon tray just
displays:
[1 GHz]
but then on activity, governor pushes up Hz, so we get this:
[1.67 GHz]
OK, all well and good. But what this does is just make the panel keep
resizing:
[ ]
[ ]
[ ]
[ ]
etc.
So, looking at the code (panel-plugins/xfce4-cpufreq-utils.c)
if ((freq % div) == 0 || div == 1000)
readable_freq = g_strdup_printf ("%d.2f %s", (freq/div),
freq_unit);
else
readable_freq = g_strdup_printf ("%3.2f %s",
((gfloat)freq/div), freq_unit);
g_free (freq_unit);
return readable_freq;
}
... isn't needed. Just:
readable_freq = g_strdup_printf ("%3.2f %s", ((gfloat)freq/div), freq_unit);
... which now gives:
[1.00 GHz]
[1.66 GHz]
[1.33 GHz]
[1.00 GHz]
and no 'panel' jumping resize.
Nick
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the Goodies-dev
mailing list