diff options
author | Ray Strode <halfline@gmail.com> | 2022-11-29 15:15:30 +0000 |
---|---|---|
committer | Ray Strode <halfline@gmail.com> | 2022-11-29 15:15:30 +0000 |
commit | a3a63e3e30df206c7706c5011b447dac39a28ed2 (patch) | |
tree | 60ad38478827c3e9e19e39deadfd82145e01ded4 | |
parent | 6b28bb622917ed3e640714b64ecdc121385913fa (diff) | |
parent | 48881ba2ef3d25fd27fd150d4d5957d4df9868e0 (diff) |
Merge branch 'hide-text-early' into 'main'
src: Hide console text when splash is requested
See merge request plymouth/plymouth!205
-rw-r--r-- | src/libply-splash-core/ply-terminal.c | 2 | ||||
-rw-r--r-- | src/main.c | 12 |
2 files changed, 10 insertions, 4 deletions
diff --git a/src/libply-splash-core/ply-terminal.c b/src/libply-splash-core/ply-terminal.c index eee23c74..1a57c6ad 100644 --- a/src/libply-splash-core/ply-terminal.c +++ b/src/libply-splash-core/ply-terminal.c @@ -323,6 +323,8 @@ ply_terminal_write (ply_terminal_t *terminal, assert (terminal != NULL); assert (format != NULL); + ply_terminal_set_mode (terminal, PLY_TERMINAL_MODE_TEXT); + string = NULL; va_start (args, format); size = vasprintf (&string, format, args); @@ -984,6 +984,14 @@ on_show_splash (state_t *state) if (!state->is_attached && state->should_be_attached && has_displays) attach_to_running_session (state); + if (state->local_console_terminal != NULL) + ply_terminal_set_mode (state->local_console_terminal, PLY_TERMINAL_MODE_GRAPHICS); + +#ifdef PLY_ENABLE_SYSTEMD_INTEGRATION + if (state->is_attached) + tell_systemd_to_print_details (state); +#endif + if (has_displays) { ply_trace ("at least one display already available, so loading splash"); show_splash (state); @@ -1412,10 +1420,6 @@ on_quit (state_t *state, state->quit_trigger = quit_trigger; state->should_retain_splash = retain_splash; -#ifdef PLY_ENABLE_SYSTEMD_INTEGRATION - tell_systemd_to_stop_printing_details (state); -#endif - ply_trace ("closing log"); if (state->session != NULL) ply_terminal_session_close_log (state->session); |