Tk Source Code

Check-in [aaa5dd4e]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:proposed fix for [bug 3512824]: Tk and dual/multihead on windows
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | bug-3512824
Files: files | file ages | folders
SHA1: aaa5dd4efa78d14deff7d22a9eadc405ea3da916
User & Date: jan.nijtmans 2012-04-02 08:42:19
Context
2012-04-12
21:22
merge trunk check-in: ae0bf774 user: jan.nijtmans tags: bug-3512824
2012-04-02
08:42
proposed fix for [bug 3512824]: Tk and dual/multihead on windows check-in: aaa5dd4e user: jan.nijtmans tags: bug-3512824
2012-03-26
12:35
fix for scoping of buf (introduced with fix for [Bug 2809525]) check-in: e8d270f5 user: jan.nijtmans tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to win/tkWinWm.c.

7817
7818
7819
7820
7821
7822
7823
7824
7825
7826
7827
7828
7829
7830
7831
7832
		 * toplevel that receives the message.
		 */

		TkWinDisplayChanged(Tk_Display(winPtr));
	    } else {
		HDC dc = GetDC(NULL);

		screen->width = LOWORD(lParam);		/* horizontal res */
		screen->height = HIWORD(lParam);	/* vertical res */
		screen->mwidth = MulDiv(screen->width, 254,
			GetDeviceCaps(dc, LOGPIXELSX) * 10);
		screen->mheight = MulDiv(screen->height, 254,
			GetDeviceCaps(dc, LOGPIXELSY) * 10);
		ReleaseDC(NULL, dc);
	    }
	    if (Tk_Depth(winPtr) != (int) wParam) {







|
|







7817
7818
7819
7820
7821
7822
7823
7824
7825
7826
7827
7828
7829
7830
7831
7832
		 * toplevel that receives the message.
		 */

		TkWinDisplayChanged(Tk_Display(winPtr));
	    } else {
		HDC dc = GetDC(NULL);

		screen->width = GetSystemMetrics(SM_CXVIRTUALSCREEN);		/* horizontal res */
		screen->height = GetSystemMetrics(SM_CYVIRTUALSCREEN);	/* vertical res */
		screen->mwidth = MulDiv(screen->width, 254,
			GetDeviceCaps(dc, LOGPIXELSX) * 10);
		screen->mheight = MulDiv(screen->height, 254,
			GetDeviceCaps(dc, LOGPIXELSY) * 10);
		ReleaseDC(NULL, dc);
	    }
	    if (Tk_Depth(winPtr) != (int) wParam) {

Changes to win/tkWinX.c.

448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463

    if (display == NULL || display->screens == NULL) {
	return;
    }
    screen = display->screens;

    dc = GetDC(NULL);
    screen->width = GetDeviceCaps(dc, HORZRES);
    screen->height = GetDeviceCaps(dc, VERTRES);
    screen->mwidth = MulDiv(screen->width, 254,
	    GetDeviceCaps(dc, LOGPIXELSX) * 10);
    screen->mheight = MulDiv(screen->height, 254,
	    GetDeviceCaps(dc, LOGPIXELSY) * 10);

    /*
     * On windows, when creating a color bitmap, need two pieces of







|
|







448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463

    if (display == NULL || display->screens == NULL) {
	return;
    }
    screen = display->screens;

    dc = GetDC(NULL);
    screen->width = GetSystemMetrics(SM_CXVIRTUALSCREEN);;
    screen->height = GetSystemMetrics(SM_CYVIRTUALSCREEN);
    screen->mwidth = MulDiv(screen->width, 254,
	    GetDeviceCaps(dc, LOGPIXELSX) * 10);
    screen->mheight = MulDiv(screen->height, 254,
	    GetDeviceCaps(dc, LOGPIXELSY) * 10);

    /*
     * On windows, when creating a color bitmap, need two pieces of