diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2012-06-05 13:12:04 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2012-06-05 13:12:04 (GMT) |
commit | 0f3a2fcdd9d1f4c2d5659ae50ce1a5cba322f62c (patch) | |
tree | e941d8cac470415eab1469160234f7ec7dd217a9 /macosx | |
parent | fad48a7b6368bdb719b8b5cdc77f19ee4b089ee6 (diff) | |
parent | e35d614587b25a1a03ededdf2d04bcbfca86be70 (diff) | |
download | tk-0f3a2fcdd9d1f4c2d5659ae50ce1a5cba322f62c.zip tk-0f3a2fcdd9d1f4c2d5659ae50ce1a5cba322f62c.tar.gz tk-0f3a2fcdd9d1f4c2d5659ae50ce1a5cba322f62c.tar.bz2 |
merge core-8-4-branchbug_3508771
Diffstat (limited to 'macosx')
-rw-r--r-- | macosx/tkMacOSXClipboard.c | 8 | ||||
-rw-r--r-- | macosx/tkMacOSXColor.c | 6 | ||||
-rw-r--r-- | macosx/tkMacOSXDraw.c | 19 | ||||
-rw-r--r-- | macosx/tkMacOSXKeyboard.c | 3 | ||||
-rw-r--r-- | macosx/tkMacOSXXStubs.c | 6 |
5 files changed, 22 insertions, 20 deletions
diff --git a/macosx/tkMacOSXClipboard.c b/macosx/tkMacOSXClipboard.c index b561244..ae56383 100644 --- a/macosx/tkMacOSXClipboard.c +++ b/macosx/tkMacOSXClipboard.c @@ -161,7 +161,7 @@ TkSelGetSelection( *---------------------------------------------------------------------- */ -void +int XSetSelectionOwner( Display *display, /* X Display. */ Atom selection, /* What selection to own. */ @@ -185,11 +185,11 @@ XSetSelectionOwner( */ dispPtr = TkGetMainInfoList()->winPtr->dispPtr; - if (dispPtr->clipboardActive) { - return; + if (!dispPtr->clipboardActive) { + ClearCurrentScrap(); } - ClearCurrentScrap(); } + return Success; } /* diff --git a/macosx/tkMacOSXColor.c b/macosx/tkMacOSXColor.c index 9520a77..22686a3 100644 --- a/macosx/tkMacOSXColor.c +++ b/macosx/tkMacOSXColor.c @@ -713,14 +713,15 @@ XCreateColormap( return index++; } -void +int XFreeColormap( Display* display, /* Display. */ Colormap colormap) /* Colormap. */ { + return Success; } -void +int XFreeColors( Display* display, /* Display. */ Colormap colormap, /* Colormap. */ @@ -733,4 +734,5 @@ XFreeColors( * needs to be done to release colors as there really is * no colormap in the Tk sense. */ + return Success; } diff --git a/macosx/tkMacOSXDraw.c b/macosx/tkMacOSXDraw.c index 6805f28..5c36967 100644 --- a/macosx/tkMacOSXDraw.c +++ b/macosx/tkMacOSXDraw.c @@ -340,7 +340,7 @@ end: *---------------------------------------------------------------------- */ -void +int TkPutImage( unsigned long *colors, /* Unused on Macintosh. */ int ncolors, /* Unused on Macintosh. */ @@ -360,7 +360,7 @@ TkPutImage( display->request++; if (!TkMacOSXSetupDrawingContext(d, gc, 0, &dc)) { - return; + return BadDrawable; } if (dc.context) { TkMacOSXDbgMsg("Ignored CG drawing of XImage"); @@ -532,6 +532,7 @@ TkPutImage( } } TkMacOSXRestoreDrawingContext(&dc); + return Success; } /* @@ -564,16 +565,12 @@ XDrawLines( int i, lw = gc->line_width; if (npoints < 2) { - /* - * TODO: generate BadValue error. - */ - - return 0; + return BadValue; } display->request++; if (!TkMacOSXSetupDrawingContext(d, gc, tkMacOSXUseCGDrawing, &dc)) { - return 0; + return BadDrawable; } if (dc.context) { double prevx, prevy; @@ -614,7 +611,7 @@ XDrawLines( } } TkMacOSXRestoreDrawingContext(&dc); - return 1; + return Success; } /* @@ -918,7 +915,7 @@ XFillRectangles( display->request++; if (!TkMacOSXSetupDrawingContext(d, gc, tkMacOSXUseCGDrawing, &dc)) { - return 0; + return BadDrawable; } if (dc.context) { CGRect rect; @@ -945,7 +942,7 @@ XFillRectangles( } } TkMacOSXRestoreDrawingContext(&dc); - return 1; + return Success; } /* diff --git a/macosx/tkMacOSXKeyboard.c b/macosx/tkMacOSXKeyboard.c index b1e60bb..6bf3643 100644 --- a/macosx/tkMacOSXKeyboard.c +++ b/macosx/tkMacOSXKeyboard.c @@ -394,7 +394,7 @@ XGetModifierMapping( *---------------------------------------------------------------------- */ -void +int XFreeModifiermap( XModifierKeymap *modmap) { @@ -402,6 +402,7 @@ XFreeModifiermap( ckfree((char *) modmap->modifiermap); } ckfree((char *) modmap); + return Success; } /* diff --git a/macosx/tkMacOSXXStubs.c b/macosx/tkMacOSXXStubs.c index 8bf57fa..4845454 100644 --- a/macosx/tkMacOSXXStubs.c +++ b/macosx/tkMacOSXXStubs.c @@ -464,12 +464,13 @@ XSelectInput( Debugger(); } -void +int XBell( Display* display, int percent) { SysBeep(percent); + return Success; } #if 0 @@ -549,7 +550,7 @@ XDrawPoints( } */ -void +int XWarpPointer( Display* display, Window src_w, @@ -561,6 +562,7 @@ XWarpPointer( int dest_x, int dest_y) { + return Success; } void |