From 430fa7f7449b8a99aa93c88d4fdaeb03942b5ce0 Mon Sep 17 00:00:00 2001 From: Fabian Keil Date: Thu, 24 May 2012 14:59:41 +0000 Subject: [PATCH] Merge two log_error() calls in OnLogCommand() --- w32log.c | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/w32log.c b/w32log.c index d688c588..8eecdbfb 100644 --- a/w32log.c +++ b/w32log.c @@ -1,4 +1,4 @@ -const char w32log_rcs[] = "$Id: w32log.c,v 1.41 2012/03/09 16:23:50 fabiankeil Exp $"; +const char w32log_rcs[] = "$Id: w32log.c,v 1.42 2012/05/24 14:59:25 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/w32log.c,v $ @@ -947,14 +947,8 @@ void OnLogCommand(int nCommand) /* by haroon - change toggle to its opposite value */ case ID_TOGGLE_ENABLED: global_toggle_state = !global_toggle_state; - if (global_toggle_state) - { - log_error(LOG_LEVEL_INFO, "Now toggled ON."); - } - else - { - log_error(LOG_LEVEL_INFO, "Now toggled OFF."); - } + log_error(LOG_LEVEL_INFO, + "Now toggled %s", global_toggle_state ? "ON" : "OFF"); SetIdleIcon(); break; #endif /* def FEATURE_TOGGLE */ -- 2.39.2