summaryrefslogtreecommitdiffstats
path: root/libvo
diff options
context:
space:
mode:
authornplourde <nplourde@b3059339-0415-0410-9bf9-f77b7e298cf2>2004-10-21 11:36:20 +0000
committernplourde <nplourde@b3059339-0415-0410-9bf9-f77b7e298cf2>2004-10-21 11:36:20 +0000
commit159928a38a3fc65427a1336b2c73aa3f78a82aa7 (patch)
treea476c8df61dee51dc9adb6ff3a541c2214002b08 /libvo
parent5cda6fffa5b197e026301435ec38a7cb28cdb6f5 (diff)
downloadmpv-159928a38a3fc65427a1336b2c73aa3f78a82aa7.tar.bz2
mpv-159928a38a3fc65427a1336b2c73aa3f78a82aa7.tar.xz
move variable declaration at beginning of block
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@13720 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libvo')
-rw-r--r--libvo/vo_quartz.c19
1 files changed, 12 insertions, 7 deletions
diff --git a/libvo/vo_quartz.c b/libvo/vo_quartz.c
index 01e16ef565..dcb3dbb17f 100644
--- a/libvo/vo_quartz.c
+++ b/libvo/vo_quartz.c
@@ -250,9 +250,11 @@ static OSStatus MainWindowEventHandler(EventHandlerCallRef nextHandler, EventRef
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 @@ static OSStatus MainWindowEventHandler(EventHandlerCallRef nextHandler, EventRef
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 MainWindowEventHandler(EventHandlerCallRef nextHandler, EventRef
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 @@ static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, uint32
WindowAttributes windowAttrs;
GDHandle deviceHdl;
OSErr qterr;
-
- //Get Main device info///////////////////////////////////////////////////
int i;
-
+
+ //Get Main device info///////////////////////////////////////////////////
+
+
deviceHdl = GetMainDevice();
for(i=0; i<device_id; i++)