summaryrefslogtreecommitdiffstats
path: root/macosx/tkMacOSXMouseEvent.c
diff options
context:
space:
mode:
Diffstat (limited to 'macosx/tkMacOSXMouseEvent.c')
-rw-r--r--macosx/tkMacOSXMouseEvent.c22
1 files changed, 10 insertions, 12 deletions
diff --git a/macosx/tkMacOSXMouseEvent.c b/macosx/tkMacOSXMouseEvent.c
index 0fc3473..b43e51d 100644
--- a/macosx/tkMacOSXMouseEvent.c
+++ b/macosx/tkMacOSXMouseEvent.c
@@ -54,7 +54,7 @@
* software in accordance with the terms specified in this
* license.
*
- * RCS: @(#) $Id: tkMacOSXMouseEvent.c,v 1.25 2006/09/10 17:06:32 das Exp $
+ * RCS: @(#) $Id: tkMacOSXMouseEvent.c,v 1.26 2007/04/13 14:51:18 dkf Exp $
*/
#include "tkMacOSXInt.h"
@@ -234,11 +234,8 @@ TkMacOSXProcessMouseEvent(TkMacOSXEvent *eventPtr, MacEventStatus * statusPtr)
status = GetEventParameter(eventPtr->eventRef,
kEventParamMouseWheelDelta, typeLongInteger, NULL,
sizeof(long), NULL, &medPtr->delta);
- if (status != noErr ) {
-#ifdef TK_MAC_DEBUG
- fprintf (stderr,
- "Failed to retrieve mouse wheel delta, %d\n", (int) status);
-#endif
+ if (status != noErr) {
+ ERR_MSG("Failed to retrieve mouse wheel delta, %d", (int) status);
statusPtr->err = 1;
return false;
} else {
@@ -533,21 +530,22 @@ GeneratePollingEvents(MouseEventData * medPtr)
*/
static void
-BringWindowForward(WindowRef wRef, Boolean isFrontProcess)
+BringWindowForward(
+ WindowRef wRef,
+ Boolean isFrontProcess)
{
if (!isFrontProcess) {
ProcessSerialNumber ourPsn = {0, kCurrentProcess};
OSStatus status = SetFrontProcess(&ourPsn);
if (status != noErr) {
-#ifdef TK_MAC_DEBUG
- fprintf(stderr,"SetFrontProcess failed, %d\n", (int) status);
-#endif
+ ERR_MSG("SetFrontProcess failed, %d", (int) status);
}
}
-
+
if (!TkpIsWindowFloating(wRef)) {
- if (IsValidWindowPtr(wRef))
+ if (IsValidWindowPtr(wRef)) {
SelectWindow(wRef);
+ }
}
}