Mercurial > mplayer.hg
annotate gui/win32/gui.h @ 23123:21e29d5932c5
header / declarations cleanup, also fixes broken compilation.
author | vayne |
---|---|
date | Thu, 26 Apr 2007 17:30:20 +0000 |
parents | 52488bb09d90 |
children | f15bce7943b9 |
rev | line source |
---|---|
23077 | 1 /* |
23079 | 2 * MPlayer GUI for Win32 |
3 * Copyright (C) 2003 Sascha Sommer <saschasommer@freenet.de> | |
4 * Copyright (C) 2006 Erik Augustson <erik_27can@yahoo.com> | |
5 * Copyright (C) 2006 Gianluigi Tiesi <sherpya@netfarm.it> | |
6 * | |
7 * This file is part of MPlayer. | |
8 * | |
9 * MPlayer is free software; you can redistribute it and/or modify | |
10 * it under the terms of the GNU General Public License as published by | |
11 * the Free Software Foundation; either version 2 of the License, or | |
12 * (at your option) any later version. | |
13 * | |
14 * MPlayer is distributed in the hope that it will be useful, | |
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
17 * GNU General Public License for more details. | |
18 * | |
19 * You should have received a copy of the GNU General Public License | |
20 * along with MPlayer; if not, write to the Free Software | |
21 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA | |
22 */ | |
23077 | 23 |
24 #ifndef _GUI_H | |
25 #define _GUI_H | |
23091
52488bb09d90
Consistently use quotes instead of angled brackets in #include
diego
parents:
23079
diff
changeset
|
26 #include "config.h" |
23123
21e29d5932c5
header / declarations cleanup, also fixes broken compilation.
vayne
parents:
23091
diff
changeset
|
27 #include "mplayer.h" |
23091
52488bb09d90
Consistently use quotes instead of angled brackets in #include
diego
parents:
23079
diff
changeset
|
28 #include "playtree.h" |
52488bb09d90
Consistently use quotes instead of angled brackets in #include
diego
parents:
23079
diff
changeset
|
29 #include "m_config.h" |
23077 | 30 #include "skinload.h" |
31 #include "playlist.h" | |
32 | |
33 extern char *skinName; | |
34 extern float sub_aspect; | |
35 extern play_tree_t* playtree; | |
36 extern m_config_t* mconfig; | |
37 | |
38 extern NOTIFYICONDATA nid; | |
39 | |
40 typedef struct window_priv_t window_priv_t; | |
41 struct window_priv_t | |
42 { | |
43 HWND hwnd; | |
44 image img; | |
45 image *background; | |
46 HBITMAP bitmap; | |
47 int type; | |
48 }; | |
49 | |
50 typedef struct gui_t gui_t; | |
51 struct gui_t | |
52 { | |
53 /* screenproperties */ | |
54 int screenw, screenh, screenbpp; | |
55 /* window related stuff */ | |
56 char *classname; | |
57 HICON icon; | |
58 unsigned int window_priv_count; | |
59 window_priv_t **window_priv; | |
60 | |
61 HWND mainwindow; | |
62 HWND subwindow; | |
63 | |
64 /* for event handling */ | |
65 widget *activewidget; | |
66 | |
67 int mousewx, mousewy; /* mousepos inside widget */ | |
68 int mousex, mousey; | |
69 | |
70 HMENU menu; | |
71 HMENU diskmenu; | |
72 HMENU traymenu; | |
73 HMENU trayplaymenu; | |
74 HMENU trayplaybackmenu; | |
75 HMENU submenu; | |
76 HMENU subtitlemenu; | |
77 HMENU aspectmenu; | |
78 HMENU dvdmenu; | |
79 HMENU playlistmenu; | |
80 | |
81 int skinbrowserwindow; | |
82 int playlistwindow; | |
83 int aboutwindow; | |
84 | |
85 skin_t *skin; | |
86 playlist_t *playlist; | |
87 | |
88 void (*startplay)(gui_t *gui); | |
89 void (*updatedisplay)(gui_t *gui, HWND hwnd); | |
90 void (*playercontrol)(int event); /* userdefine call back function */ | |
91 void (*uninit)(gui_t *gui); | |
92 }; | |
93 | |
94 #define wsShowWindow 8 | |
95 #define wsHideWindow 16 | |
96 #define wsShowFrame 1 | |
97 #define wsMovable 2 | |
98 #define wsSizeable 4 | |
99 | |
100 extern gui_t *create_gui(char *skindir, char *skinName, void (*playercontrol)(int event)); | |
101 extern int destroy_window(gui_t *gui); | |
102 extern int create_window(gui_t *gui, char *skindir); | |
103 extern int create_subwindow(gui_t *gui, char *skindir); | |
104 extern int parse_filename(char *file, play_tree_t *playtree, m_config_t *mconfig, int clear); | |
105 extern void capitalize(char *filename); | |
106 extern int import_playtree_playlist_into_gui(play_tree_t *my_playtree, m_config_t *config); | |
107 | |
108 /* Dialogs */ | |
109 extern void display_playlistwindow(gui_t *gui); | |
110 extern void update_playlistwindow(void); | |
111 extern int display_openfilewindow(gui_t *gui, int add); | |
112 extern void display_openurlwindow(gui_t *gui, int add); | |
113 extern void display_skinbrowser(gui_t *gui); | |
114 extern void display_chapterselwindow(gui_t *gui); | |
115 extern void display_eqwindow(gui_t *gui); | |
116 extern void display_prefswindow(gui_t *gui); | |
117 extern void display_opensubtitlewindow(gui_t *gui); | |
118 | |
119 #endif |