comparison libvo/vo_directx.c @ 33585:1f6ff1848bd3

Remove left-over code from icon/cursor handling that is now done by w32_common.c
author reimar
date Sun, 19 Jun 2011 18:43:07 +0000
parents deedeb235cac
children ae9746a552dd
comparison
equal deleted inserted replaced
33584:deedeb235cac 33585:1f6ff1848bd3
66 static HINSTANCE hddraw_dll; //handle to ddraw.dll 66 static HINSTANCE hddraw_dll; //handle to ddraw.dll
67 static RECT rd; //rect of our stretched image 67 static RECT rd; //rect of our stretched image
68 static RECT rs; //rect of our source image 68 static RECT rs; //rect of our source image
69 static HBRUSH colorbrush = NULL; // Handle to colorkey brush 69 static HBRUSH colorbrush = NULL; // Handle to colorkey brush
70 static HBRUSH blackbrush = NULL; // Handle to black brush 70 static HBRUSH blackbrush = NULL; // Handle to black brush
71 static HICON mplayericon = NULL; // Handle to mplayer icon
72 static HCURSOR mplayercursor = NULL; // Handle to mplayer cursor
73 static uint32_t image_width, image_height; //image width and height 71 static uint32_t image_width, image_height; //image width and height
74 static uint32_t d_image_width, d_image_height; //image width and height zoomed 72 static uint32_t d_image_width, d_image_height; //image width and height zoomed
75 static uint8_t *image=NULL; //image data 73 static uint8_t *image=NULL; //image data
76 static void* tmp_image = NULL; 74 static void* tmp_image = NULL;
77 static uint32_t image_format=0; //image format 75 static uint32_t image_format=0; //image format
354 if (g_lpddsPrimary != NULL) g_lpddsPrimary->lpVtbl->Release(g_lpddsPrimary); 352 if (g_lpddsPrimary != NULL) g_lpddsPrimary->lpVtbl->Release(g_lpddsPrimary);
355 g_lpddsPrimary = NULL; 353 g_lpddsPrimary = NULL;
356 mp_msg(MSGT_VO, MSGL_DBG3,"<vo_directx><INFO>primary released\n"); 354 mp_msg(MSGT_VO, MSGL_DBG3,"<vo_directx><INFO>primary released\n");
357 UnregisterClass(WNDCLASSNAME_WINDOWED, GetModuleHandle(NULL)); 355 UnregisterClass(WNDCLASSNAME_WINDOWED, GetModuleHandle(NULL));
358 UnregisterClass(WNDCLASSNAME_FULLSCREEN, GetModuleHandle(NULL)); 356 UnregisterClass(WNDCLASSNAME_FULLSCREEN, GetModuleHandle(NULL));
359 if (mplayericon) DestroyIcon(mplayericon);
360 mplayericon = NULL;
361 if (mplayercursor) DestroyCursor(mplayercursor);
362 mplayercursor = NULL;
363 if (colorbrush) DeleteObject(colorbrush); 357 if (colorbrush) DeleteObject(colorbrush);
364 colorbrush = NULL; 358 colorbrush = NULL;
365 mp_msg(MSGT_VO, MSGL_DBG3,"<vo_directx><INFO>GDI resources deleted\n"); 359 mp_msg(MSGT_VO, MSGL_DBG3,"<vo_directx><INFO>GDI resources deleted\n");
366 if (g_lpdd != NULL){ 360 if (g_lpdd != NULL){
367 if(vidmode)g_lpdd->lpVtbl->RestoreDisplayMode(g_lpdd); 361 if(vidmode)g_lpdd->lpVtbl->RestoreDisplayMode(g_lpdd);
835 { 829 {
836 mp_msg(MSGT_VO,MSGL_V,"<vo_directx><INFO>disabled overlay\n"); 830 mp_msg(MSGT_VO,MSGL_V,"<vo_directx><INFO>disabled overlay\n");
837 nooverlay = 1; 831 nooverlay = 1;
838 } 832 }
839 } 833 }
840 /*load icon from the main app*/
841 if(GetModuleFileName(NULL,exedir,MAX_PATH))
842 {
843 mplayericon = ExtractIcon( hInstance, exedir, 0 );
844 }
845 if(!mplayericon)mplayericon=LoadIcon(NULL,IDI_APPLICATION);
846 mplayercursor = LoadCursor(NULL, IDC_ARROW);
847 monitor_rect.right=GetSystemMetrics(SM_CXSCREEN); 834 monitor_rect.right=GetSystemMetrics(SM_CXSCREEN);
848 monitor_rect.bottom=GetSystemMetrics(SM_CYSCREEN); 835 monitor_rect.bottom=GetSystemMetrics(SM_CYSCREEN);
849 836
850 windowcolor = vo_colorkey; 837 windowcolor = vo_colorkey;
851 colorbrush = CreateSolidBrush(windowcolor); 838 colorbrush = CreateSolidBrush(windowcolor);