From 1619b4656c1e7810e06ff12af087bc04d2e47a5c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?P=C5=99emysl=20Janouch?= Date: Mon, 23 Nov 2015 01:47:27 +0100 Subject: Replace --save with --no-save The former has shown to be confusing to users, and is rarely desired. --- sensei-raw-ctl.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) (limited to 'sensei-raw-ctl.c') diff --git a/sensei-raw-ctl.c b/sensei-raw-ctl.c index f6c3caf..47c8719 100644 --- a/sensei-raw-ctl.c +++ b/sensei-raw-ctl.c @@ -302,14 +302,14 @@ sensei_display_config (const struct sensei_config *config) struct options { - unsigned show_config : 1; - unsigned save_to_rom : 1; - unsigned set_pulsation : 1; - unsigned set_mode : 1; - unsigned set_intensity : 1; - unsigned set_polling : 1; - unsigned set_cpi_off : 1; - unsigned set_cpi_on : 1; + unsigned show_config : 1; + unsigned do_not_save_to_rom : 1; + unsigned set_pulsation : 1; + unsigned set_mode : 1; + unsigned set_intensity : 1; + unsigned set_polling : 1; + unsigned set_cpi_off : 1; + unsigned set_cpi_on : 1; }; static void @@ -329,7 +329,7 @@ show_usage (const char *program_name) " (steady, slow, medium, fast, trigger)\n"); printf (" --intensity X Set the backlight intensity" " (off, low, medium, high)\n"); - printf (" --save Save the current configuration to ROM\n"); + printf (" --no-save Do not save changes in configuration to ROM\n"); printf ("\n"); } @@ -369,7 +369,7 @@ parse_options (int argc, char *argv[], { "help", no_argument, 0, 'h' }, { "version", no_argument, 0, 'V' }, { "show", no_argument, 0, 's' }, - { "save", no_argument, 0, 'S' }, + { "no-save", no_argument, 0, 'S' }, { "mode", required_argument, 0, 'm' }, { "polling", required_argument, 0, 'p' }, { "cpi-on", required_argument, 0, 'c' }, @@ -400,7 +400,7 @@ parse_options (int argc, char *argv[], options->show_config = true; break; case 'S': - options->save_to_rom = true; + options->do_not_save_to_rom = true; break; case 'm': if (!strcasecmp (optarg, "legacy")) @@ -518,7 +518,7 @@ apply_options (libusb_device_handle *device, if ((result = sensei_set_cpi (device, new_config->cpi_on, true))) return result; - if (options->save_to_rom) + if (options->do_not_save_to_rom == false) if ((result = sensei_save_to_rom (device))) return result; -- cgit v1.2.3