[MPlayer-cvslog] CVS: main/libvo vo_macosx.m, 1.35, 1.36 vo_quartz.c, 1.58, 1.59
Nicolas Plourde CVS
syncmail at mplayerhq.hu
Sat Apr 8 18:16:51 CEST 2006
CVS change done by Nicolas Plourde CVS
Update of /cvsroot/mplayer/main/libvo
In directory mail:/var2/tmp/cvs-serv6857/libvo
Modified Files:
vo_macosx.m vo_quartz.c
Log Message:
Replace deprecated function
Index: vo_macosx.m
===================================================================
RCS file: /cvsroot/mplayer/main/libvo/vo_macosx.m,v
retrieving revision 1.35
retrieving revision 1.36
diff -u -r1.35 -r1.36
--- vo_macosx.m 4 Mar 2006 12:37:44 -0000 1.35
+++ vo_macosx.m 8 Apr 2006 16:16:48 -0000 1.36
@@ -167,7 +167,7 @@
//connnect to mplayerosx
mplayerosxProxy=[NSConnection rootProxyForConnectionWithRegisteredName:@"mplayerosx" host:nil];
- [mplayerosxProxy startWithWidth: image_width withHeight: image_height withBytes: image_bytes withAspect:movie_aspect];
+ [mplayerosxProxy startWithWidth: image_width withHeight: image_height withBytes: image_bytes withAspect:(int)(movie_aspect*100)];
}
return 0;
}
@@ -249,7 +249,7 @@
}
SetSystemUIMode( kUIModeNormal, 0);
- ShowCursor();
+ CGDisplayShowCursor(kCGDirectMainDisplay);
[autoreleasepool release];
}
@@ -708,16 +708,12 @@
//auto hide mouse cursor and futur on-screen control?
if(isFullscreen && !mouseHide && !isRootwin)
{
- DateTimeRec d;
- unsigned long curTime;
- static unsigned long lastTime = 0;
+ int curTime = TickCount()/60;
+ static int lastTime = 0;
- GetTime(&d);
- DateToSeconds( &d, &curTime);
-
if( ((curTime - lastTime) >= 5) || (lastTime == 0) )
{
- HideCursor();
+ CGDisplayHideCursor(kCGDirectMainDisplay);
mouseHide = YES;
lastTime = curTime;
}
@@ -725,14 +721,10 @@
//update activity every 30 seconds to prevent
//screensaver from starting up.
- DateTimeRec d;
- unsigned long curTime;
- static unsigned long lastTime = 0;
-
- GetTime(&d);
- DateToSeconds( &d, &curTime);
-
- if( ( (curTime - lastTime) >= 30) || (lastTime == 0))
+ int curTime = TickCount()/60;
+ static int lastTime = 0;
+
+ if( ((curTime - lastTime) >= 30) || (lastTime == 0) )
{
UpdateSystemActivity(UsrActivity);
lastTime = curTime;
@@ -782,7 +774,7 @@
if(!isRootwin)
{
SetSystemUIMode( kUIModeAllHidden, kUIOptionAutoShowMenuBar);
- HideCursor();
+ CGDisplayHideCursor(kCGDirectMainDisplay);
mouseHide = YES;
}
@@ -803,7 +795,7 @@
SetSystemUIMode( kUIModeNormal, 0);
isFullscreen = 0;
- ShowCursor();
+ CGDisplayShowCursor(kCGDirectMainDisplay);
mouseHide = NO;
//revert window to previous setting
@@ -946,7 +938,7 @@
{
if(isFullscreen && !isRootwin)
{
- ShowCursor();
+ CGDisplayShowCursor(kCGDirectMainDisplay);
mouseHide = NO;
}
}
Index: vo_quartz.c
===================================================================
RCS file: /cvsroot/mplayer/main/libvo/vo_quartz.c,v
retrieving revision 1.58
retrieving revision 1.59
diff -u -r1.58 -r1.59
--- vo_quartz.c 7 Feb 2006 01:36:32 -0000 1.58
+++ vo_quartz.c 8 Apr 2006 16:16:48 -0000 1.59
@@ -282,7 +282,7 @@
{
if(vo_quartz_fs)
{
- ShowCursor();
+ CGDisplayShowCursor(kCGDirectMainDisplay);
mouseHide = FALSE;
}
}
@@ -967,16 +967,12 @@
//auto hide mouse cursor and futur on-screen control?
if(vo_quartz_fs && !mouseHide)
{
- DateTimeRec d;
- unsigned long curTime;
- static unsigned long lastTime = 0;
+ int curTime = TickCount()/60;
+ static int lastTime = 0;
- GetTime(&d);
- DateToSeconds( &d, &curTime);
-
if( ((curTime - lastTime) >= 5) || (lastTime == 0) )
{
- HideCursor();
+ CGDisplayHideCursor(kCGDirectMainDisplay);
mouseHide = TRUE;
lastTime = curTime;
}
@@ -984,14 +980,10 @@
//update activity every 30 seconds to prevent
//screensaver from starting up.
- DateTimeRec d;
- unsigned long curTime;
- static unsigned long lastTime = 0;
-
- GetTime(&d);
- DateToSeconds( &d, &curTime);
-
- if( ( (curTime - lastTime) >= 30) || (lastTime == 0))
+ int curTime = TickCount()/60;
+ static int lastTime = 0;
+
+ if( ((curTime/ - lastTime) >= 5) || (lastTime == 0) )
{
UpdateSystemActivity(UsrActivity);
lastTime = curTime;
@@ -1359,7 +1351,7 @@
if(device_id == 0)
{
SetSystemUIMode( kUIModeAllHidden, kUIOptionAutoShowMenuBar);
- HideCursor();
+ CGDisplayHideCursor(kCGDirectMainDisplay);
mouseHide = TRUE;
}
@@ -1407,7 +1399,7 @@
SetSystemUIMode( kUIModeNormal, NULL);
//show mouse cursor
- ShowCursor();
+ CGDisplayShowCursor(kCGDirectMainDisplay);
mouseHide = FALSE;
//revert window to previous setting
More information about the MPlayer-cvslog
mailing list