pull up r19964 from trunk
authorTom Yu <tlyu@mit.edu>
Mon, 1 Oct 2007 22:23:09 +0000 (22:23 +0000)
committerTom Yu <tlyu@mit.edu>
Mon, 1 Oct 2007 22:23:09 +0000 (22:23 +0000)
 r19964@cathode-dark-space:  jaltman | 2007-09-21 19:22:56 -0400
 ticket: new
 subject: NIM: APP: BUG: restore HideWatermark functionality
 component: windows

 Restore the HideWatermark functionality that was accidently
 removed from ui/credwnd.c

ticket: 5759
version_fixed: 1.6.3

git-svn-id: svn://anonsvn.mit.edu/krb5/branches/krb5-1-6@20042 dc483132-0cff-0310-8789-dd5450dbe970

src/windows/identity/ui/credwnd.c

index 9e4daa10aa286b20cef43976847456e5fa5d5483..960a83424fe00f0db538ba225eb0c0f93e4760d3 100644 (file)
@@ -50,6 +50,8 @@ static void
 cw_select_row(khui_credwnd_tbl * tbl, int row, WPARAM wParam);
 
 
+khm_int32   bHideWatermarks = 0;
+
 void
 khm_set_cw_element_font(wchar_t * name, LOGFONT * pfont) {
     khm_handle csp_cw = NULL;
@@ -507,6 +509,8 @@ cw_load_view(khui_credwnd_tbl * tbl, wchar_t * view, HWND hwnd) {
                                  &hc_cw)))
         return;
 
+    khc_read_int32(hc_cw, L"HideWatermarks", &bHideWatermarks);
+
     if(KHM_FAILED(khc_open_space(hc_cw, L"Views", KHM_PERM_READ, &hc_vs)))
         goto _exit;
 
@@ -2392,7 +2396,8 @@ cw_erase_rect(HDC hdc,
         rlogo.right = r_wnd->right;
         rlogo.top = r_wnd->bottom - tbl->kbm_logo_shade.cy;
         rlogo.bottom = r_wnd->bottom;
-        rie = IntersectRect(&ri, r_erase, &rlogo);
+        if (bHideWatermarks)    {rie = FALSE;}
+        else                    {rie = IntersectRect(&ri, r_erase, &rlogo);}
     } else {
         ZeroMemory(&rlogo, sizeof(rlogo));
         ZeroMemory(&ri, sizeof(ri));