Mercurial > mplayer.hg
annotate gui/win32/gui.h @ 24818:1e1d16ef51c8
synced with r24841
author | Gabrov |
---|---|
date | Wed, 24 Oct 2007 09:22:28 +0000 |
parents | 3f0d00abc073 |
children | 3baf6a2283da |
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 |
23689
3f0d00abc073
Do not use leading underscores in multiple inclusion guards, they are reserved.
diego
parents:
23685
diff
changeset
|
24 #ifndef GUI_GUI_H |
3f0d00abc073
Do not use leading underscores in multiple inclusion guards, they are reserved.
diego
parents:
23685
diff
changeset
|
25 #define GUI_GUI_H |
3f0d00abc073
Do not use leading underscores in multiple inclusion guards, they are reserved.
diego
parents:
23685
diff
changeset
|
26 |
23091
52488bb09d90
Consistently use quotes instead of angled brackets in #include
diego
parents:
23079
diff
changeset
|
27 #include "config.h" |
23123
21e29d5932c5
header / declarations cleanup, also fixes broken compilation.
vayne
parents:
23091
diff
changeset
|
28 #include "mplayer.h" |
23091
52488bb09d90
Consistently use quotes instead of angled brackets in #include
diego
parents:
23079
diff
changeset
|
29 #include "playtree.h" |
52488bb09d90
Consistently use quotes instead of angled brackets in #include
diego
parents:
23079
diff
changeset
|
30 #include "m_config.h" |
23077 | 31 #include "skinload.h" |
32 #include "playlist.h" | |
33 | |
34 extern char *skinName; | |
35 extern float sub_aspect; | |
36 extern play_tree_t* playtree; | |
37 extern m_config_t* mconfig; | |
38 | |
39 extern NOTIFYICONDATA nid; | |
40 | |
41 typedef struct window_priv_t window_priv_t; | |
42 struct window_priv_t | |
43 { | |
44 HWND hwnd; | |
45 image img; | |
46 image *background; | |
47 HBITMAP bitmap; | |
48 int type; | |
49 }; | |
50 | |
51 typedef struct gui_t gui_t; | |
52 struct gui_t | |
53 { | |
54 /* screenproperties */ | |
55 int screenw, screenh, screenbpp; | |
56 /* window related stuff */ | |
57 char *classname; | |
58 HICON icon; | |
59 unsigned int window_priv_count; | |
60 window_priv_t **window_priv; | |
61 | |
62 HWND mainwindow; | |
63 HWND subwindow; | |
64 | |
65 /* for event handling */ | |
66 widget *activewidget; | |
67 | |
68 int mousewx, mousewy; /* mousepos inside widget */ | |
69 int mousex, mousey; | |
70 | |
71 HMENU menu; | |
72 HMENU diskmenu; | |
73 HMENU traymenu; | |
74 HMENU trayplaymenu; | |
75 HMENU trayplaybackmenu; | |
76 HMENU submenu; | |
77 HMENU subtitlemenu; | |
78 HMENU aspectmenu; | |
79 HMENU dvdmenu; | |
80 HMENU playlistmenu; | |
81 | |
82 int skinbrowserwindow; | |
83 int playlistwindow; | |
84 int aboutwindow; | |
85 | |
86 skin_t *skin; | |
87 playlist_t *playlist; | |
88 | |
89 void (*startplay)(gui_t *gui); | |
90 void (*updatedisplay)(gui_t *gui, HWND hwnd); | |
91 void (*playercontrol)(int event); /* userdefine call back function */ | |
92 void (*uninit)(gui_t *gui); | |
93 }; | |
94 | |
95 #define wsShowWindow 8 | |
96 #define wsHideWindow 16 | |
97 #define wsShowFrame 1 | |
98 #define wsMovable 2 | |
99 #define wsSizeable 4 | |
100 | |
101 extern gui_t *create_gui(char *skindir, char *skinName, void (*playercontrol)(int event)); | |
102 extern int destroy_window(gui_t *gui); | |
103 extern int create_window(gui_t *gui, char *skindir); | |
104 extern int create_subwindow(gui_t *gui, char *skindir); | |
105 extern int parse_filename(char *file, play_tree_t *playtree, m_config_t *mconfig, int clear); | |
106 extern void capitalize(char *filename); | |
107 extern int import_playtree_playlist_into_gui(play_tree_t *my_playtree, m_config_t *config); | |
108 | |
109 /* Dialogs */ | |
110 extern void display_playlistwindow(gui_t *gui); | |
111 extern void update_playlistwindow(void); | |
112 extern int display_openfilewindow(gui_t *gui, int add); | |
113 extern void display_openurlwindow(gui_t *gui, int add); | |
114 extern void display_skinbrowser(gui_t *gui); | |
115 extern void display_chapterselwindow(gui_t *gui); | |
116 extern void display_eqwindow(gui_t *gui); | |
117 extern void display_prefswindow(gui_t *gui); | |
118 extern void display_opensubtitlewindow(gui_t *gui); | |
119 | |
120 #endif |