summaryrefslogtreecommitdiffstats
path: root/macosx/tkMacOSXScale.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2020-08-26 07:39:41 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2020-08-26 07:39:41 (GMT)
commit219216c26fe5f38d29a865b7df2a5f816d20fffa (patch)
tree335e3e75ab1ecb713d53f7086c056f8b66b5f51a /macosx/tkMacOSXScale.c
parent4cb9d608b9e906a7ff8a3a67df94551dd0ce79ff (diff)
downloadtk-219216c26fe5f38d29a865b7df2a5f816d20fffa.zip
tk-219216c26fe5f38d29a865b7df2a5f816d20fffa.tar.gz
tk-219216c26fe5f38d29a865b7df2a5f816d20fffa.tar.bz2
Put back a dummy Tk_MacOSXTkOwnsCursor(), just because it's in the public stub table. Can be removed fully in Tk 8.7.
More simplifications
Diffstat (limited to 'macosx/tkMacOSXScale.c')
-rw-r--r--macosx/tkMacOSXScale.c28
1 files changed, 0 insertions, 28 deletions
diff --git a/macosx/tkMacOSXScale.c b/macosx/tkMacOSXScale.c
index 80b1bda..28b192d 100644
--- a/macosx/tkMacOSXScale.c
+++ b/macosx/tkMacOSXScale.c
@@ -149,8 +149,6 @@ TkpDisplayScale(
MacScale *macScalePtr = clientData;
Rect r;
WindowRef windowRef;
- CGrafPtr destPort, savePort;
- Boolean portChanged;
MacDrawable *macDraw;
SInt32 initialValue, minValue, maxValue;
UInt16 numTicks;
@@ -216,9 +214,7 @@ TkpDisplayScale(
*/
macDraw = (MacDrawable *) Tk_WindowId(tkwin);
- destPort = TkMacOSXGetDrawablePort(Tk_WindowId(tkwin));
windowRef = TkMacOSXDrawableWindow(Tk_WindowId(tkwin));
- portChanged = QDSwapPort(destPort, &savePort);
/*
* Create Macintosh control.
@@ -292,9 +288,6 @@ TkpDisplayScale(
HiliteControl(macScalePtr->scaleHandle, 0);
Draw1Control(macScalePtr->scaleHandle);
- if (portChanged) {
- QDSwapPort(savePort, NULL);
- }
done:
scalePtr->flags &= ~REDRAW_ALL;
}
@@ -326,14 +319,10 @@ TkpScaleElement(
ControlPartCode part;
Point where;
Rect bounds;
- CGrafPtr destPort, savePort;
- Boolean portChanged;
#ifdef TK_MAC_DEBUG_SCALE
TkMacOSXDbgMsg("TkpScaleElement");
#endif
- destPort = TkMacOSXGetDrawablePort(Tk_WindowId(scalePtr->tkwin));
- portChanged = QDSwapPort(destPort, &savePort);
/*
* All of the calculations in this procedure mirror those in
@@ -345,10 +334,6 @@ TkpScaleElement(
where.v = y + bounds.top;
part = TestControl(macScalePtr->scaleHandle, where);
- if (portChanged) {
- QDSwapPort(savePort, NULL);
- }
-
#ifdef TK_MAC_DEBUG_SCALE
fprintf (stderr,"ScalePart %d, pos ( %d %d )\n", part, where.h, where.v );
#endif
@@ -400,8 +385,6 @@ MacScaleEventProc(
Point where;
Rect bounds;
int part;
- CGrafPtr destPort, savePort;
- Boolean portChanged;
#ifdef TK_MAC_DEBUG_SCALE
fprintf(stderr,"MacScaleEventProc\n" );
@@ -413,13 +396,6 @@ MacScaleEventProc(
* control was hit and act accordingly.
*/
- destPort = TkMacOSXGetDrawablePort(Tk_WindowId(macScalePtr->info.tkwin));
- portChanged = QDSwapPort(destPort, &savePort);
-
- TkMacOSXWinBounds((TkWindow *) macScalePtr->info.tkwin, &bounds);
- where.h = eventPtr->xbutton.x + bounds.left;
- where.v = eventPtr->xbutton.y + bounds.top;
-#ifdef TK_MAC_DEBUG_SCALE
TkMacOSXDbgMsg("calling TestControl");
#endif
part = TestControl(macScalePtr->scaleHandle, where);
@@ -445,10 +421,6 @@ MacScaleEventProc(
*/
TkGenerateButtonEventForXPointer(Tk_WindowId(macScalePtr->info.tkwin));
-
- if (portChanged) {
- QDSwapPort(savePort, NULL);
- }
}
/*