Tk Source Code

Check-in [50e0c049]
Login

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

Overview
Comment:3567812 3567779 Repaired regressions in 3546073 fix. Stopped test event leakage in winWm-9.2.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 50e0c049b213060b5192947c81ae8cded172aae9
User & Date: dgp 2012-09-15 00:33:30
References
2012-09-30
20:21 Ticket [3567812f] clipboard clear segfaults status still Open with 4 other changes artifact: a1543f9a user: ferrieux
Context
2012-09-15
11:17
typo check-in: 23538b2e user: dgp tags: trunk
00:33
3567812 3567779 Repaired regressions in 3546073 fix. Stopped test event leakage in winWm-9.2. check-in: 50e0c049 user: dgp tags: trunk
2012-09-13
20:49
[Bug 3567453]: Clip regions must be cleared with XSetClipMask and not TkSetRegion on X11. check-in: 39af9760 user: dkf tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to generic/tkClipboard.c.

648
649
650
651
652
653
654



655
656
657
658
659
660
661
     * Create the window used for clipboard ownership and selection retrieval,
     * and set up an event handler for it.
     */

    dispPtr->clipWindow = (Tk_Window) TkAllocWindow(dispPtr,
	DefaultScreen(dispPtr->display), NULL);
    Tcl_Preserve(dispPtr->clipWindow);



    atts.override_redirect = True;
    Tk_ChangeWindowAttributes(dispPtr->clipWindow, CWOverrideRedirect, &atts);
    Tk_MakeWindowExist(dispPtr->clipWindow);

    if (dispPtr->multipleAtom == None) {
	/*
	 * Need to invoke selection initialization to make sure that atoms we







>
>
>







648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
     * Create the window used for clipboard ownership and selection retrieval,
     * and set up an event handler for it.
     */

    dispPtr->clipWindow = (Tk_Window) TkAllocWindow(dispPtr,
	DefaultScreen(dispPtr->display), NULL);
    Tcl_Preserve(dispPtr->clipWindow);
    ((TkWindow *) dispPtr->clipWindow)->flags |=
	    TK_TOP_HIERARCHY|TK_TOP_LEVEL|TK_HAS_WRAPPER|TK_WIN_MANAGED;
    TkWmNewWindow((TkWindow *) dispPtr->clipWindow);
    atts.override_redirect = True;
    Tk_ChangeWindowAttributes(dispPtr->clipWindow, CWOverrideRedirect, &atts);
    Tk_MakeWindowExist(dispPtr->clipWindow);

    if (dispPtr->multipleAtom == None) {
	/*
	 * Need to invoke selection initialization to make sure that atoms we

Changes to tests/winWm.test.

537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552


553
554
555
556
557

558

559
560
561
562
563
564
565
566
567
568
569
    toplevel .t
    set winwm92 {}
    frame .t.f -background blue -height 200 -width 200
    frame .t.f.x -background red -height 100 -width 100
} -body {
    pack .t.f.x
    pack .t.f
    set aid [after 1000 {set ::winwm92 timeout}]
    after 100 {
        wm manage .t.f
        wm iconify .t
        after 100 {
            wm forget .t.f
            wm deiconify .t
            after 100 {
                pack .t.f


                after 100 {set ::winwm92 [expr {[winfo rooty .t.f.x] == 0 ? "failed" : "ok"}]}
            }
        }
    }
    vwait ::winwm92

    after cancel $aid

    set winwm92
} -cleanup {
    destroy .t.f.x .t.f .t
    unset -nocomplain winwm92 aid
} -result ok

destroy .t

# cleanup
cleanupTests
return







|
<


|


|

>
>
|
|
|
|

>
|
>



|







537
538
539
540
541
542
543
544

545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
    toplevel .t
    set winwm92 {}
    frame .t.f -background blue -height 200 -width 200
    frame .t.f.x -background red -height 100 -width 100
} -body {
    pack .t.f.x
    pack .t.f
    lappend aid [after 2000 {set ::winwm92 timeout}] [after 100 {

        wm manage .t.f
        wm iconify .t
        lappend aid [after 100 {
            wm forget .t.f
            wm deiconify .t
            lappend aid [after 100 {
                pack .t.f
                lappend aid [after 100 {
		    set ::winwm92 [expr {
			    [winfo rooty .t.f.x] == 0 ? "failed" : "ok"}]}]
            }]
        }]
    }]
    vwait ::winwm92
    foreach id $aid {
	after cancel $id
    }
    set winwm92
} -cleanup {
    destroy .t.f.x .t.f .t
    unset -nocomplain winwm92 aid id
} -result ok

destroy .t

# cleanup
cleanupTests
return

Changes to unix/tkUnixSend.c.

1356
1357
1358
1359
1360
1361
1362



1363
1364
1365
1366
1367
1368
1369
     * Create the window used for communication, and set up an event handler
     * for it.
     */

    dispPtr->commTkwin = (Tk_Window) TkAllocWindow(dispPtr,
    	DefaultScreen(dispPtr->display), NULL);
    Tcl_Preserve(dispPtr->commTkwin);



    atts.override_redirect = True;
    Tk_ChangeWindowAttributes(dispPtr->commTkwin,
	    CWOverrideRedirect, &atts);
    Tk_CreateEventHandler(dispPtr->commTkwin, PropertyChangeMask,
	    SendEventProc, dispPtr);
    Tk_MakeWindowExist(dispPtr->commTkwin);








>
>
>







1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
     * Create the window used for communication, and set up an event handler
     * for it.
     */

    dispPtr->commTkwin = (Tk_Window) TkAllocWindow(dispPtr,
    	DefaultScreen(dispPtr->display), NULL);
    Tcl_Preserve(dispPtr->commTkwin);
    ((TkWindow *) dispPtr->commTkwin)->flags |=
	    TK_TOP_HIERARCHY|TK_TOP_LEVEL|TK_HAS_WRAPPER|TK_WIN_MANAGED;
    TkWmNewWindow((TkWindow *) dispPtr->commTkWin);
    atts.override_redirect = True;
    Tk_ChangeWindowAttributes(dispPtr->commTkwin,
	    CWOverrideRedirect, &atts);
    Tk_CreateEventHandler(dispPtr->commTkwin, PropertyChangeMask,
	    SendEventProc, dispPtr);
    Tk_MakeWindowExist(dispPtr->commTkwin);