]> git.ipfire.org Git - thirdparty/plymouth.git/commitdiff
two-step: Replace ConsoleViewerPreserveBackground with ConsoleLogBackgroundColor
authornerdopolis <bluescreen_avenger@verizon.net>
Wed, 7 Aug 2024 20:21:24 +0000 (16:21 -0400)
committernerdopolis <bluescreen_avenger@verizon.net>
Wed, 7 Aug 2024 20:21:24 +0000 (16:21 -0400)
src/plugins/splash/two-step/plugin.c
themes/spinfinity/spinfinity.plymouth.in

index 29fb93b75ca36e3d308b294c5343f3be7e9f0a8b..61f136c2478f239ce1a3faf8a7c785a823c860d2 100644 (file)
@@ -201,7 +201,7 @@ struct _ply_boot_splash_plugin
         uint32_t                            should_show_console_messages : 1;
         ply_buffer_t                       *boot_buffer;
         uint32_t                            console_text_color;
-        uint32_t                            console_viewer_preserve_background;
+        uint32_t                            console_background_color;
 };
 
 ply_boot_splash_plugin_interface_t *ply_boot_splash_plugin_get_interface (void);
@@ -1290,8 +1290,10 @@ create_plugin (ply_key_file_t *key_file)
                                        "ConsoleLogTextColor",
                                        PLY_CONSOLE_VIEWER_LOG_TEXT_COLOR);
 
-        plugin->console_viewer_preserve_background =
-                ply_key_file_get_bool (key_file, "two-step", "ConsoleViewerPreserveBackground");
+        plugin->console_background_color =
+                ply_key_file_get_long (key_file, "two-step",
+                                       "ConsoleLogBackgroundColor",
+                                       0x00000000);
 
         plugin->transition_duration =
                 ply_key_file_get_double (key_file, "two-step",
@@ -1620,7 +1622,7 @@ draw_background (view_t             *view,
             using_fw_background && plugin->dialog_clears_firmware_background)
                 use_black_background = true;
 
-        if (plugin->should_show_console_messages && plugin->console_viewer_preserve_background == false) {
+        if (plugin->should_show_console_messages && plugin->console_background_color == 0x00000000) {
                 use_black_background = true;
         }
 
@@ -1636,8 +1638,10 @@ draw_background (view_t             *view,
                 ply_pixel_buffer_fill_with_hex_color (pixel_buffer, &area,
                                                       plugin->background_start_color);
 
-        if (plugin->should_show_console_messages)
+        if (plugin->should_show_console_messages && use_black_background == false) {
+                ply_pixel_buffer_fill_with_hex_color (pixel_buffer, &area, plugin->console_background_color);
                 return;
+        }
 
         if (plugin->watermark_image != NULL) {
                 uint32_t *data;
index 8f2eb8fa81a0c573850d9d3924d39a58edd52262..b9b7f4d8112399dd9382e417b8ed92c3c6d0f2ae 100644 (file)
@@ -5,7 +5,7 @@ ModuleName=two-step
 
 [two-step]
 ScaleBackgroundImage=false
-ConsoleViewerPreserveBackground=false
+ConsoleLogBackgroundColor=0x00000000
 ImageDir=@PLYMOUTH_THEME_PATH@/spinfinity
 BackgroundStartColor=0x0073b3
 BackgroundEndColor=0x00457e