Skip running animation if option is silent 04/245704/1
authorlokilee73 <changjoo.lee@samsung.com>
Tue, 13 Oct 2020 07:02:06 +0000 (16:02 +0900)
committerHyotaek Shim <hyotaek.shim@samsung.com>
Wed, 14 Oct 2020 11:07:08 +0000 (11:07 +0000)
Change-Id: Iaccd10955d02a129ad352b0a13192ed47042ffa9
Signed-off-by: lokilee73 <changjoo.lee@samsung.com>
(cherry picked from commit ca9d81149e324e49efc033810b25ce787f7c4c00)

conf/power.conf
src/power/power-handler.c

index e99b94d..7a753c2 100644 (file)
@@ -3,3 +3,4 @@ Option=recovery
 Option=download
 Option=wdownload
 Option=debug
+Option=silent
index 0a672c7..342868e 100644 (file)
@@ -502,7 +502,11 @@ static int power_execute_pid(const char *typename, const char *option)
        system_shutdown_send_system_event();
        poweroff_send_broadcast(poweroff_opt.type);
 
-       poweroff_start_animation();
+       /* Skip running animation if option is silent */
+       if (poweroff_opt.option != NULL && !strcmp(poweroff_opt.option, "silent"))
+               _D("Skip running poweroff animation.");
+       else
+               poweroff_start_animation();
 
        /* Spare time for AddPowerOffWait requests */
        g_timeout_add_seconds(1, poweroff_start_timers, NULL);