changeset 1816:d0dda44136a0

Initial code to make sure the background of notebooks on OS/2 draws even if there are no pages in the notebook. Was hoping to get it to draw the outline at least, but this is better than a bleed through undrawn area.
author bsmith@81767d24-ef19-dc11-ae90-00e081727c95
date Sun, 14 Oct 2012 22:43:09 +0000
parents 6ae40234d531
children e827394a7f20
files os2/dw.c
diffstat 1 files changed, 11 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/os2/dw.c	Tue Oct 09 05:05:29 2012 +0000
+++ b/os2/dw.c	Sun Oct 14 22:43:09 2012 +0000
@@ -4287,6 +4287,17 @@
 
    switch(msg)
    {
+   case WM_PAINT:
+      if(!WinSendMsg(hwnd, BKM_QUERYPAGECOUNT, 0, (MPARAM)BKA_END))
+      {
+         HPS hpsPaint;
+         RECTL rclPaint;
+
+         hpsPaint = WinBeginPaint(hwnd, 0, &rclPaint);
+         WinFillRect(hpsPaint, &rclPaint, CLR_PALEGRAY);
+         WinEndPaint(hpsPaint);
+      }
+      break;
    case WM_CHAR:
       if(SHORT1FROMMP(mp2) == '\t')
       {