summaryrefslogtreecommitdiffstats
path: root/Gui/win32/dialogs.c
diff options
context:
space:
mode:
authorvayne <vayne@b3059339-0415-0410-9bf9-f77b7e298cf2>2006-09-06 17:44:41 +0000
committervayne <vayne@b3059339-0415-0410-9bf9-f77b7e298cf2>2006-09-06 17:44:41 +0000
commit9ff3217bb0711df9a7b8aa9c1f59e7f944bc4707 (patch)
tree46816d423d9cf16c92870e41d658307d3cd2cc83 /Gui/win32/dialogs.c
parent5a420940adb6b059f1da629437c31a1774a53515 (diff)
downloadmpv-9ff3217bb0711df9a7b8aa9c1f59e7f944bc4707.tar.bz2
mpv-9ff3217bb0711df9a7b8aa9c1f59e7f944bc4707.tar.xz
ISO C90 warnings fixes
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@19724 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'Gui/win32/dialogs.c')
-rw-r--r--Gui/win32/dialogs.c29
1 files changed, 15 insertions, 14 deletions
diff --git a/Gui/win32/dialogs.c b/Gui/win32/dialogs.c
index 59f45a5fc0..8a977a3b13 100644
--- a/Gui/win32/dialogs.c
+++ b/Gui/win32/dialogs.c
@@ -374,11 +374,12 @@ LRESULT CALLBACK SubUrlWndProc(HWND hwnd, UINT iMsg, WPARAM wParam, LPARAM lPara
void display_openurlwindow(gui_t *gui, int add)
{
- if(add) addurl = 1;
HWND hWnd;
HINSTANCE hInstance = GetModuleHandle(NULL);
WNDCLASS wc;
int x, y;
+
+ if(add) addurl = 1;
if(FindWindow(NULL, "MPlayer - Open URL...")) return;
wc.style = CS_HREDRAW | CS_VREDRAW;
wc.lpfnWndProc = OpenUrlWndProc;
@@ -632,16 +633,16 @@ void update_playlistwindow(void)
void display_playlistwindow(gui_t *gui)
{
HWND hWnd = FindWindow(NULL, "MPlayer Playlist");
+ HINSTANCE hInstance = GetModuleHandle(NULL);
+ WNDCLASS wc;
+ int x, y;
+
if (hWnd)
{
SendMessage(hWnd, WM_CLOSE, 0, 0);
return;
}
- HINSTANCE hInstance = GetModuleHandle(NULL);
- WNDCLASS wc;
- int x, y;
-
wc.style = CS_HREDRAW | CS_VREDRAW;
wc.lpfnWndProc = PlayListWndProc;
wc.cbClsExtra = 0;
@@ -683,6 +684,9 @@ static LRESULT CALLBACK SkinBrowserWndProc(HWND hwnd, UINT iMsg, WPARAM wParam,
{
case WM_CREATE:
{
+ HANDLE skinHandle = INVALID_HANDLE_VALUE;
+ WIN32_FIND_DATA finddata;
+
listbox = CreateWindow("listbox", NULL,
WS_CHILD | WS_VISIBLE | LBS_NOTIFY | LBS_NOINTEGRALHEIGHT |
LBS_DISABLENOSCROLL | WS_VSCROLL | WS_TABSTOP,
@@ -695,9 +699,6 @@ static LRESULT CALLBACK SkinBrowserWndProc(HWND hwnd, UINT iMsg, WPARAM wParam,
/* This opens the skins directory, lists the directory names, and adds them to the listbox */
sprintf(skinspath, "%s/*.", get_path("skins"));
- HANDLE skinHandle = INVALID_HANDLE_VALUE;
- WIN32_FIND_DATA finddata;
-
skinHandle = FindFirstFile(skinspath, &finddata);
if (skinHandle != INVALID_HANDLE_VALUE)
{
@@ -753,16 +754,16 @@ static LRESULT CALLBACK SkinBrowserWndProc(HWND hwnd, UINT iMsg, WPARAM wParam,
void display_skinbrowser(gui_t* gui)
{
HWND hWnd = FindWindow(NULL, "Skin Browser");
+ HINSTANCE hInstance = GetModuleHandle(NULL);
+ WNDCLASS wc;
+ int x, y;
+
if (hWnd)
{
SendMessage(hWnd, WM_CLOSE, 0, 0);
return;
}
- HINSTANCE hInstance = GetModuleHandle(NULL);
- WNDCLASS wc;
- int x, y;
-
wc.style = CS_HREDRAW | CS_VREDRAW;
wc.lpfnWndProc = SkinBrowserWndProc;
wc.cbClsExtra = 0;
@@ -1106,12 +1107,12 @@ static LRESULT CALLBACK EqWndProc(HWND hwnd, UINT iMsg, WPARAM wParam, LPARAM lP
void display_eqwindow(gui_t *gui)
{
- if(!guiIntfStruct.sh_video) return;
-
HWND hWnd;
HINSTANCE hInstance = GetModuleHandle(NULL);
WNDCLASS wc;
int x, y;
+
+ if(!guiIntfStruct.sh_video) return;
if(FindWindow(NULL, "MPlayer - Equalizer")) return;
wc.style = CS_HREDRAW | CS_VREDRAW;
wc.lpfnWndProc = EqWndProc;