# HG changeset patch # User nplourde # Date 1098358580 0 # Node ID 43ecd6a73ec07113ffd9ee50621be3bc94aa8e43 # Parent 4896e688aa31c0f01fb317fc981c2dcf0538198e move variable declaration at beginning of block diff -r 4896e688aa31 -r 43ecd6a73ec0 libvo/vo_quartz.c --- a/libvo/vo_quartz.c Thu Oct 21 11:34:25 2004 +0000 +++ b/libvo/vo_quartz.c Thu Oct 21 11:36:20 2004 +0000 @@ -250,9 +250,11 @@ case kEventMouseDown: { EventMouseButton button; + short part; + GetEventParameter(event, kEventParamMouseButton, typeMouseButton, 0, sizeof(EventMouseButton), 0, &button); - short part = FindWindow(mousePos,&tmpWin); + part = FindWindow(mousePos,&tmpWin); if(part == inMenuBar) { @@ -276,9 +278,11 @@ case kEventMouseWheelMoved: { int wheel; + short part; + GetEventParameter(event, kEventParamMouseWheelDelta, typeSInt32, 0, sizeof(int), 0, &wheel); - short part = FindWindow(mousePos,&tmpWin); + part = FindWindow(mousePos,&tmpWin); if(part == inContent) { @@ -301,13 +305,13 @@ static OSStatus MainWindowCommandHandler(EventHandlerCallRef nextHandler, EventRef event, void *userData) { OSStatus result = noErr; + UInt32_t d_width; + UInt32_t d_height; UInt32 class = GetEventClass (event); UInt32 kind = GetEventKind (event); result = CallNextEventHandler(nextHandler, event); - uint32_t d_width; - uint32_t d_height; aspect(&d_width,&d_height,A_NOZOOM); if(class == kEventClassCommand) @@ -462,10 +466,11 @@ WindowAttributes windowAttrs; GDHandle deviceHdl; OSErr qterr; - + int i; + //Get Main device info/////////////////////////////////////////////////// - int i; - + + deviceHdl = GetMainDevice(); for(i=0; i