diff options
author | wolfsuit <wolfsuit> | 2002-10-03 06:24:54 (GMT) |
---|---|---|
committer | wolfsuit <wolfsuit> | 2002-10-03 06:24:54 (GMT) |
commit | 2634c4cb6b3b10aae8263e7dc02a98cb56a12cfe (patch) | |
tree | 2b12019e8bb0743ca1f7ac6c3fe6978006f0d4ec /macosx | |
parent | 14db34d9c98eb1b58b4c5a7d951d3c338a8b2eb7 (diff) | |
download | tk-2634c4cb6b3b10aae8263e7dc02a98cb56a12cfe.zip tk-2634c4cb6b3b10aae8263e7dc02a98cb56a12cfe.tar.gz tk-2634c4cb6b3b10aae8263e7dc02a98cb56a12cfe.tar.bz2 |
2002-10-02 Jim Ingham <jingham@apple.com>
* macosx/tkMacOSXScrlbr.c (TkpDisplayScrollbar): Put the Tk scrollbar
pointer into the control reference data for the Mac scrollbar, so we
can get it out again in the ScrollbarActionProc.
Diffstat (limited to 'macosx')
-rw-r--r-- | macosx/tkMacOSXScrlbr.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/macosx/tkMacOSXScrlbr.c b/macosx/tkMacOSXScrlbr.c index 0b22c3e..432aa1e 100644 --- a/macosx/tkMacOSXScrlbr.c +++ b/macosx/tkMacOSXScrlbr.c @@ -11,7 +11,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tkMacOSXScrlbr.c,v 1.3 2002/09/22 07:46:53 wolfsuit Exp $ + * RCS: @(#) $Id: tkMacOSXScrlbr.c,v 1.4 2002/10/03 06:24:54 wolfsuit Exp $ */ #include "tkScrollbar.h" @@ -252,15 +252,12 @@ TkpDisplayScrollbar( procID = kControlScrollBarLiveProc; windowRef = GetWindowFromPort(destPort); - CreateScrollBarControl (windowRef, &r, initialValue, + CreateScrollBarControl(windowRef, &r, initialValue, minValue, maxValue, maxValue - minValue, true, NULL, &(macScrollPtr->sbHandle)); + SetControlReference(macScrollPtr->sbHandle, (SInt32) scrollPtr); - /* macScrollPtr->sbHandle = NewControl(windowRef, &r, "\p", - false, initialValue,minValue,maxValue, - procID, (SInt32) scrollPtr); */ - /* * If we are foremost then make us active. */ @@ -366,8 +363,8 @@ TkpComputeScrollbarGeometry( if (fieldLength < 0) { fieldLength = 0; } - scrollPtr->sliderFirst = fieldLength*scrollPtr->firstFraction; - scrollPtr->sliderLast = fieldLength*scrollPtr->lastFraction; + scrollPtr->sliderFirst = fieldLength * scrollPtr->firstFraction; + scrollPtr->sliderLast = fieldLength * scrollPtr->lastFraction; /* * Adjust the slider so that some piece of it is always |