[PATCH 5/5] server: Add the popup_attr member to the console screen_buffer struct

Hugh McMaster hugh.mcmaster at outlook.com
Sun Aug 7 22:09:14 CDT 2016


Signed-off-by: Hugh McMaster <hugh.mcmaster at outlook.com>
---
 server/console.c    | 6 +++++-
 server/protocol.def | 6 ++++--
 2 files changed, 9 insertions(+), 3 deletions(-)

diff --git a/server/console.c b/server/console.c
index 413db75..56f7cd3 100644
--- a/server/console.c
+++ b/server/console.c
@@ -146,7 +146,8 @@ struct screen_buffer
     int                   max_width;     /* size (w-h) of the window given font size */
     int                   max_height;
     char_info_t          *data;          /* the data for each cell - a width x height matrix */
-    unsigned short        attr;          /* default attribute for screen buffer */
+    unsigned short        attr;          /* default fill attributes (screen colors) */
+    unsigned short        popup_attr;    /* pop-up color attributes */
     unsigned int          color_map[16]; /* console ColorTable */
     rectangle_t           win;           /* current visible window on the screen buffer *
 					  * as seen in wineconsole */
@@ -420,6 +421,7 @@ static struct screen_buffer *create_console_output( struct console_input *consol
     screen_buffer->cursor_x       = 0;
     screen_buffer->cursor_y       = 0;
     screen_buffer->attr           = 0x0F;
+    screen_buffer->popup_attr     = 0xF5;
     screen_buffer->win.left       = 0;
     screen_buffer->win.right      = screen_buffer->max_width - 1;
     screen_buffer->win.top        = 0;
@@ -998,6 +1000,7 @@ static int set_console_output_info( struct screen_buffer *screen_buffer,
     if (req->mask & SET_CONSOLE_OUTPUT_INFO_ATTR)
     {
 	screen_buffer->attr = req->attr;
+        screen_buffer->popup_attr = req->popup_attr;
     }
     if (req->mask & SET_CONSOLE_OUTPUT_INFO_DISPLAY_WINDOW)
     {
@@ -1684,6 +1687,7 @@ DECL_HANDLER(get_console_output_info)
         reply->width          = screen_buffer->width;
         reply->height         = screen_buffer->height;
         reply->attr           = screen_buffer->attr;
+        reply->popup_attr     = screen_buffer->popup_attr;
         reply->win_left       = screen_buffer->win.left;
         reply->win_top        = screen_buffer->win.top;
         reply->win_right      = screen_buffer->win.right;
diff --git a/server/protocol.def b/server/protocol.def
index 3a96a92..484d8bf 100644
--- a/server/protocol.def
+++ b/server/protocol.def
@@ -1528,7 +1528,8 @@ struct console_renderer_event
     short int    cursor_y;
     short int    width;         /* width of the screen buffer */
     short int    height;        /* height of the screen buffer */
-    short int    attr;          /* default attribute */
+    short int    attr;          /* default fill attributes (screen colors) */
+    short int    popup_attr;    /* pop-up color attributes */
     short int    win_left;      /* window actually displayed by renderer */
     short int    win_top;       /* the rect area is expressed within the */
     short int    win_right;     /* boundaries of the screen buffer */
@@ -1557,7 +1558,8 @@ struct console_renderer_event
     short int    cursor_y;
     short int    width;         /* width of the screen buffer */
     short int    height;        /* height of the screen buffer */
-    short int    attr;          /* default attribute */
+    short int    attr;          /* default fill attributes (screen colors) */
+    short int    popup_attr;    /* pop-up color attributes */
     short int    win_left;      /* window actually displayed by renderer */
     short int    win_top;       /* the rect area is expressed within the */
     short int    win_right;     /* boundaries of the screen buffer */
-- 
2.7.4




More information about the wine-patches mailing list