[Xfce4-commits] <xfce4-cpugraph-plugin:master> Improve the migration from the previous release

Florian Rivoal noreply at xfce.org
Mon May 31 13:26:02 CEST 2010


Updating branch refs/heads/master
         to cf07dff98ef98e6c9d9be1c0a3b6f9eaa5626ed9 (commit)
       from 209f7f249badfbafb2a40308c08ee4f383fa1651 (commit)

commit cf07dff98ef98e6c9d9be1c0a3b6f9eaa5626ed9
Author: Florian Rivoal <frivoal at gmail.com>
Date:   Sun May 30 19:37:58 2010 +0900

    Improve the migration from the previous release
    
    In the previous release (0.4.0), the associated command was neither
    launched in a terminal nor using startup notifications. Now, depending
    on whether xfce4-taskmanager is present in the system, one of these
    settings will be turned on by default when creating a new cpugraph, or
    when running this version of cpugraph for the first time on a system
    that has a setting file for 0.4.0.
    
    The default command of 0.4.0 was "xterm -e top". Running this with
    either startup notification or in a terminal is not appropriate.
    
    The name of the entry in the rc file used to save the associated command
    is now different from the one used in 0.4.0. This means that the old
    setting, if it exists, will be ignored, and cpugraph will use the new
    default setting. For people who had kept the old default, people who had
    changed it to xfce4-taskmanager, or who had changed it to run top in
    their favorite terminal, this is likely to be the best thing to do, and
    I suspect that these cases cover most people.
    
    People who had set a different custom command will need to set it again,
    but depending on what their actual command is, they probably would have
    need to tweak it anyway, because of the new "Startup notification" and
    "Run in terminal" options.

 panel-plugin/settings.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/panel-plugin/settings.c b/panel-plugin/settings.c
index d2e3de6..4759f81 100644
--- a/panel-plugin/settings.c
+++ b/panel-plugin/settings.c
@@ -72,7 +72,7 @@ void read_settings( XfcePanelPlugin * plugin, CPUGraph * base )
 			mode = xfce_rc_read_int_entry( rc, "Mode", mode );
 			color_mode = xfce_rc_read_int_entry( rc, "ColorMode", color_mode );
 			frame = xfce_rc_read_int_entry( rc, "Frame", frame );
-			associated_command = xfce_rc_read_entry( rc, "AssociateCommand", associated_command );
+			associated_command = xfce_rc_read_entry( rc, "Command", associated_command );
 			in_terminal = xfce_rc_read_int_entry( rc, "InTerminal", in_terminal );
 			startup_notification = xfce_rc_read_int_entry( rc, "StartupNotification", startup_notification );
 			border = xfce_rc_read_int_entry( rc, "Border", border );
@@ -130,7 +130,7 @@ void write_settings( XfcePanelPlugin *plugin, CPUGraph *base )
 	xfce_rc_write_int_entry( rc, "Frame", base->has_frame );
 	xfce_rc_write_int_entry( rc, "Border", base->has_border );
 	xfce_rc_write_int_entry( rc, "Bars", base->has_bars );
-	xfce_rc_write_entry( rc, "AssociateCommand", base->command ? base->command : "" );
+	xfce_rc_write_entry( rc, "Command", base->command ? base->command : "" );
 	xfce_rc_write_int_entry( rc, "InTerminal", base->in_terminal );
 	xfce_rc_write_int_entry( rc, "StartupNotification", base->startup_notification );
 	xfce_rc_write_int_entry( rc, "ColorMode", base->color_mode );



More information about the Xfce4-commits mailing list