summaryrefslogtreecommitdiffstats
path: root/macosx/tkMacOSXScrlbr.c
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2015-02-12 12:51:10 (GMT)
committerdgp <dgp@users.sourceforge.net>2015-02-12 12:51:10 (GMT)
commit6dbbfe9f269314838207f70fd26de9a7d5394039 (patch)
tree587344f98f1985de320c58734134f3eee93b87f8 /macosx/tkMacOSXScrlbr.c
parent7d13b808151fa7b1fff9754f24f5f32739f5950b (diff)
downloadtk-6dbbfe9f269314838207f70fd26de9a7d5394039.zip
tk-6dbbfe9f269314838207f70fd26de9a7d5394039.tar.gz
tk-6dbbfe9f269314838207f70fd26de9a7d5394039.tar.bz2
Silence some compiler warnings
Diffstat (limited to 'macosx/tkMacOSXScrlbr.c')
-rw-r--r--macosx/tkMacOSXScrlbr.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/macosx/tkMacOSXScrlbr.c b/macosx/tkMacOSXScrlbr.c
index a9d8469..efa0f38 100644
--- a/macosx/tkMacOSXScrlbr.c
+++ b/macosx/tkMacOSXScrlbr.c
@@ -102,12 +102,10 @@ TkpCreateScrollbar(
Tk_Window tkwin)
{
- static int initialized = 0;
- MacScrollbar *scrollPtr = ckalloc(sizeof(MacScrollbar));
+ MacScrollbar *scrollPtr = (MacScrollbar *)ckalloc(sizeof(MacScrollbar));
scrollPtr->troughGC = None;
scrollPtr->copyGC = None;
- TkWindow *winPtr = (TkWindow *)tkwin;
Tk_CreateEventHandler(tkwin,ExposureMask|StructureNotifyMask|FocusChangeMask|ButtonPressMask|VisibilityChangeMask, ScrollbarEventProc, scrollPtr);
@@ -144,7 +142,6 @@ TkpDisplayScrollbar(
return;
}
- MacScrollbar *macScrollPtr = clientData;
TkWindow *winPtr = (TkWindow *) tkwin;
MacDrawable *macWin = (MacDrawable *) winPtr->window;
TkMacOSXDrawingContext dc;
@@ -220,7 +217,7 @@ TkpComputeScrollbarGeometry(
* changed. */
{
- int width, height, variant, fieldLength;
+ int variant, fieldLength;
if (scrollPtr->highlightWidth < 0) {
scrollPtr->highlightWidth = 0;
@@ -432,7 +429,7 @@ UpdateControlValues(
MacDrawable *macWin = (MacDrawable *) Tk_WindowId(scrollPtr->tkwin);
double dViewSize;
HIRect contrlRect;
- int variant, active;
+ int variant;
short width, height;
NSView *view = TkMacOSXDrawableView(macWin);
@@ -511,8 +508,8 @@ ScrollbarPress(TkScrollbar *scrollPtr, XEvent *eventPtr)
if (eventPtr->type == ButtonPress) {
UpdateControlValues(scrollPtr);
- return TCL_OK;
}
+ return TCL_OK;
}