summaryrefslogtreecommitdiffstats
path: root/macosx/tkMacOSXDebug.c
diff options
context:
space:
mode:
Diffstat (limited to 'macosx/tkMacOSXDebug.c')
-rw-r--r--macosx/tkMacOSXDebug.c54
1 files changed, 30 insertions, 24 deletions
diff --git a/macosx/tkMacOSXDebug.c b/macosx/tkMacOSXDebug.c
index 6c2d2f4..9997886 100644
--- a/macosx/tkMacOSXDebug.c
+++ b/macosx/tkMacOSXDebug.c
@@ -50,7 +50,7 @@
* software in accordance with the terms specified in this
* license.
*
- * RCS: @(#) $Id: tkMacOSXDebug.c,v 1.5 2005/09/10 14:53:20 das Exp $
+ * RCS: @(#) $Id: tkMacOSXDebug.c,v 1.6 2005/11/27 02:36:14 das Exp $
*/
#include "tkMacOSXDebug.h"
@@ -230,7 +230,7 @@ static MyEventNameList eventNameList [] = {
};
-MyEventName classicEventNames [] = {
+static MyEventName classicEventNames [] = {
{ nullEvent,"nullEvent" },
{ mouseDown,"mouseDown" },
{ mouseUp,"mouseUp" },
@@ -245,7 +245,7 @@ MyEventName classicEventNames [] = {
{ 0, NULL }
};
-char *
+MODULE_SCOPE char *
CarbonEventToAscii(EventRef eventRef, char * buf)
{
EventClass eventClass;
@@ -289,7 +289,8 @@ CarbonEventToAscii(EventRef eventRef, char * buf)
return iBuf;
}
-char * CarbonEventKindToAscii(EventRef eventRef, char * buf )
+MODULE_SCOPE char *
+CarbonEventKindToAscii(EventRef eventRef, char * buf )
{
EventClass eventClass;
EventKind eventKind;
@@ -324,7 +325,8 @@ char * CarbonEventKindToAscii(EventRef eventRef, char * buf )
return buf;
}
-char * ClassicEventToAscii(EventRecord * eventPtr, char * buf )
+MODULE_SCOPE char *
+ClassicEventToAscii(EventRecord * eventPtr, char * buf )
{
MyEventName * names = NULL;
int found = 0;
@@ -353,27 +355,31 @@ char * ClassicEventToAscii(EventRecord * eventPtr, char * buf )
}
-void printPoint(char * tag, Point * p )
+MODULE_SCOPE void
+printPoint(char * tag, Point * p )
{
fprintf(stderr,"%s %4d %4d\n",
tag,p->h,p->v );
}
-void printRect(char * tag, Rect * r )
+MODULE_SCOPE void
+printRect(char * tag, Rect * r )
{
fprintf(stderr,"%s %4d %4d %4d %4d (%dx%d)\n",
tag, r->left, r->top, r->right, r->bottom,
r->right - r->left + 1, r->bottom - r->top + 1);
}
-void printRegion(char * tag, RgnHandle rgn )
+MODULE_SCOPE void
+printRegion(char * tag, RgnHandle rgn )
{
Rect r;
GetRegionBounds(rgn,&r);
printRect(tag,&r);
}
-void printWindowTitle(char * tag, WindowRef window )
+MODULE_SCOPE void
+printWindowTitle(char * tag, WindowRef window )
{
Str255 title;
GetWTitle(window,title);
@@ -386,7 +392,7 @@ typedef struct {
char * name;
} MsgName;
-MsgName msgNames [] = {
+static MsgName msgNames [] = {
{ kMenuDrawMsg, "Draw"},
{ kMenuSizeMsg, "Size"},
{ kMenuPopUpMsg, "PopUp"},
@@ -400,8 +406,7 @@ MsgName msgNames [] = {
{ -1, NULL }
};
-
-char *
+MODULE_SCOPE char *
TkMacOSXMenuMessageToAscii(int msg, char * s)
{
MsgName * msgNamePtr;
@@ -417,20 +422,21 @@ TkMacOSXMenuMessageToAscii(int msg, char * s)
return s;
}
+static MsgName trackingNames [] = {
+ { kMouseTrackingMousePressed , "MousePressed " },
+ { kMouseTrackingMouseReleased , "MouseReleased " },
+ { kMouseTrackingMouseExited , "MouseExited " },
+ { kMouseTrackingMouseEntered , "MouseEntered " },
+ { kMouseTrackingMouseMoved , "MouseMoved " },
+ { kMouseTrackingKeyModifiersChanged, "KeyModifiersChanged" },
+ { kMouseTrackingUserCancelled , "UserCancelled " },
+ { kMouseTrackingTimedOut , "TimedOut " },
+ { -1, NULL }
+};
-char * MouseTrackingResultToAscii(MouseTrackingResult r, char * buf)
+MODULE_SCOPE char *
+MouseTrackingResultToAscii(MouseTrackingResult r, char * buf)
{
- MsgName trackingNames [] = {
- { kMouseTrackingMousePressed , "MousePressed " },
- { kMouseTrackingMouseReleased , "MouseReleased " },
- { kMouseTrackingMouseExited , "MouseExited " },
- { kMouseTrackingMouseEntered , "MouseEntered " },
- { kMouseTrackingMouseMoved , "MouseMoved " },
- { kMouseTrackingKeyModifiersChanged, "KeyModifiersChanged" },
- { kMouseTrackingUserCancelled , "UserCancelled " },
- { kMouseTrackingTimedOut , "TimedOut " },
- { -1, NULL }
- };
MsgName * namePtr;
for (namePtr = trackingNames; namePtr->name; namePtr++) {
if (namePtr->msg == r) {