Diff for /np2/win9x/toolwin.cpp between versions 1.8 and 1.9

version 1.8, 2003/10/30 16:54:04 version 1.9, 2003/10/30 18:09:06
Line 492  static void tooldrawbutton(HWND hWnd, HD Line 492  static void tooldrawbutton(HWND hWnd, HD
         POINT   pt;          POINT   pt;
         HWND    sub;          HWND    sub;
         RECT    rect;          RECT    rect;
         int             cx;  
         int             cy;  
         HDC             hmdc;          HDC             hmdc;
         HBRUSH  hbrush;          RECT    btn;
   
         idc -= IDC_BASE;          idc -= IDC_BASE;
         if (idc >= IDC_MAXITEMS) {          if (idc >= IDC_MAXITEMS) {
Line 506  static void tooldrawbutton(HWND hWnd, HD Line 504  static void tooldrawbutton(HWND hWnd, HD
         ClientToScreen(hWnd, &pt);          ClientToScreen(hWnd, &pt);
         sub = toolwin.sub[idc];          sub = toolwin.sub[idc];
         GetWindowRect(sub, &rect);          GetWindowRect(sub, &rect);
         cx = rect.right - rect.left;          btn.left = 0;
         cy = rect.bottom - rect.top;          btn.top = 0;
           btn.right = rect.right - rect.left;
           btn.bottom = rect.bottom - rect.top;
         if (toolwin.hbmp) {          if (toolwin.hbmp) {
                 hmdc = CreateCompatibleDC(hdc);                  hmdc = CreateCompatibleDC(hdc);
                 SelectObject(hmdc, toolwin.hbmp);                  SelectObject(hmdc, toolwin.hbmp);
                 BitBlt(hdc, 0, 0, cx, cy,                  BitBlt(hdc, 0, 0, btn.right, btn.bottom,
                                         hmdc, rect.left - pt.x, rect.top - pt.y, SRCCOPY);                                          hmdc, rect.left - pt.x, rect.top - pt.y, SRCCOPY);
                 DeleteDC(hmdc);                  DeleteDC(hmdc);
                 if (GetFocus() == sub) {                  if (GetFocus() == sub) {
                         hbrush = (HBRUSH)SelectObject(hdc, GetStockObject(WHITE_BRUSH));                          DrawFocusRect(hdc, &btn);
                         PatBlt(hdc, 0, 0, cx, 1, PATINVERT);  
                         PatBlt(hdc, 0, 0, 1, cy, PATINVERT);  
                         PatBlt(hdc, cx - 1, 0, cx, cy, PATINVERT);  
                         PatBlt(hdc, 0, cy - 1, cx, cy, PATINVERT);  
                         SelectObject(hdc, hbrush);  
                 }                  }
         }          }
 }  }
Line 825  static LRESULT CALLBACK twproc(HWND hWnd Line 820  static LRESULT CALLBACK twproc(HWND hWnd
   
                                 case IDC_BASE + IDC_TOOLRESET:                                  case IDC_BASE + IDC_TOOLRESET:
                                         SendMessage(hWndMain, WM_COMMAND, IDM_RESET, 0);                                          SendMessage(hWndMain, WM_COMMAND, IDM_RESET, 0);
                                           SetForegroundWindow(hWndMain);
                                         break;                                          break;
   
                                 case IDC_BASE + IDC_TOOLPOWER:                                  case IDC_BASE + IDC_TOOLPOWER:

Removed from v.1.8  
changed lines
  Added in v.1.9


RetroPC.NET-CVS <cvs@retropc.net>