Mercurial > mplayer.hg
comparison gui/win32/gui.c @ 33640:0ce6ffda0dfe
Cast handle to menu in AppendMenu() to UINT_PTR.
This makes the call compatible with both
32-bit and 64-bit versions of Windows.
Patch by Stephen Sheldon, sfsheldo gmail com.
author | ib |
---|---|
date | Sun, 26 Jun 2011 12:11:09 +0000 |
parents | dbca6aa18b50 |
children | 16286ee1fc71 |
comparison
equal
deleted
inserted
replaced
33639:6776826e72a9 | 33640:0ce6ffda0dfe |
---|---|
1142 static void create_menu(gui_t *gui) | 1142 static void create_menu(gui_t *gui) |
1143 { | 1143 { |
1144 gui->diskmenu = CreatePopupMenu(); | 1144 gui->diskmenu = CreatePopupMenu(); |
1145 gui->menu=CreatePopupMenu(); | 1145 gui->menu=CreatePopupMenu(); |
1146 gui->trayplaymenu = CreatePopupMenu(); | 1146 gui->trayplaymenu = CreatePopupMenu(); |
1147 AppendMenu(gui->menu, MF_STRING | MF_POPUP, (UINT) gui->trayplaymenu, "Open..."); | 1147 AppendMenu(gui->menu, MF_STRING | MF_POPUP, (UINT_PTR) gui->trayplaymenu, "Open..."); |
1148 AppendMenu(gui->trayplaymenu, MF_STRING, IDFILE_OPEN, "File..."); | 1148 AppendMenu(gui->trayplaymenu, MF_STRING, IDFILE_OPEN, "File..."); |
1149 AppendMenu(gui->trayplaymenu, MF_STRING, IDURL_OPEN, "Url..."); | 1149 AppendMenu(gui->trayplaymenu, MF_STRING, IDURL_OPEN, "Url..."); |
1150 AppendMenu(gui->trayplaymenu, MF_STRING, IDDIR_OPEN, "Directory..."); | 1150 AppendMenu(gui->trayplaymenu, MF_STRING, IDDIR_OPEN, "Directory..."); |
1151 AppendMenu(gui->menu, MF_SEPARATOR, 0, 0); | 1151 AppendMenu(gui->menu, MF_SEPARATOR, 0, 0); |
1152 AppendMenu(gui->menu, MF_STRING | MF_POPUP, (UINT) gui->diskmenu, "Play &CD/DVD/VCD/SVCD"); | 1152 AppendMenu(gui->menu, MF_STRING | MF_POPUP, (UINT_PTR) gui->diskmenu, "Play &CD/DVD/VCD/SVCD"); |
1153 AppendMenu(gui->menu, MF_SEPARATOR, 0, 0); | 1153 AppendMenu(gui->menu, MF_SEPARATOR, 0, 0); |
1154 AppendMenu(gui->menu, MF_STRING, IDSUBTITLE_OPEN, "Open Subtitle"); | 1154 AppendMenu(gui->menu, MF_STRING, IDSUBTITLE_OPEN, "Open Subtitle"); |
1155 AppendMenu(gui->menu, MF_STRING, ID_SKINBROWSER, "Skin Browser"); | 1155 AppendMenu(gui->menu, MF_STRING, ID_SKINBROWSER, "Skin Browser"); |
1156 AppendMenu(gui->menu, MF_SEPARATOR, 0, 0); | 1156 AppendMenu(gui->menu, MF_SEPARATOR, 0, 0); |
1157 AppendMenu(gui->menu, MF_STRING, ID_PREFS, "Preferences"); | 1157 AppendMenu(gui->menu, MF_STRING, ID_PREFS, "Preferences"); |
1163 | 1163 |
1164 static void create_traymenu(gui_t *gui) | 1164 static void create_traymenu(gui_t *gui) |
1165 { | 1165 { |
1166 gui->traymenu = CreatePopupMenu(); | 1166 gui->traymenu = CreatePopupMenu(); |
1167 gui->trayplaybackmenu = CreatePopupMenu(); | 1167 gui->trayplaybackmenu = CreatePopupMenu(); |
1168 AppendMenu(gui->traymenu, MF_STRING | MF_POPUP, (UINT) gui->trayplaymenu, "Open..."); | 1168 AppendMenu(gui->traymenu, MF_STRING | MF_POPUP, (UINT_PTR) gui->trayplaymenu, "Open..."); |
1169 AppendMenu(gui->traymenu, MF_SEPARATOR, 0, 0); | 1169 AppendMenu(gui->traymenu, MF_SEPARATOR, 0, 0); |
1170 AppendMenu(gui->traymenu, MF_STRING | MF_POPUP, (UINT) gui->trayplaybackmenu, "Playback"); | 1170 AppendMenu(gui->traymenu, MF_STRING | MF_POPUP, (UINT_PTR) gui->trayplaybackmenu, "Playback"); |
1171 AppendMenu(gui->trayplaybackmenu, MF_STRING, ID_SEEKB, "Seek Backwards"); | 1171 AppendMenu(gui->trayplaybackmenu, MF_STRING, ID_SEEKB, "Seek Backwards"); |
1172 AppendMenu(gui->trayplaybackmenu, MF_STRING, ID_PTRACK, "Previous Track"); | 1172 AppendMenu(gui->trayplaybackmenu, MF_STRING, ID_PTRACK, "Previous Track"); |
1173 AppendMenu(gui->trayplaybackmenu, MF_STRING, ID_PLAY, "Play/Pause"); | 1173 AppendMenu(gui->trayplaybackmenu, MF_STRING, ID_PLAY, "Play/Pause"); |
1174 AppendMenu(gui->trayplaybackmenu, MF_STRING, ID_STOP, "Stop"); | 1174 AppendMenu(gui->trayplaybackmenu, MF_STRING, ID_STOP, "Stop"); |
1175 AppendMenu(gui->trayplaybackmenu, MF_STRING, ID_NTRACK, "Next Track"); | 1175 AppendMenu(gui->trayplaybackmenu, MF_STRING, ID_NTRACK, "Next Track"); |
1193 { | 1193 { |
1194 gui->submenu = CreatePopupMenu(); | 1194 gui->submenu = CreatePopupMenu(); |
1195 gui->dvdmenu = CreatePopupMenu(); | 1195 gui->dvdmenu = CreatePopupMenu(); |
1196 gui->aspectmenu = CreatePopupMenu(); | 1196 gui->aspectmenu = CreatePopupMenu(); |
1197 gui->subtitlemenu = CreatePopupMenu(); | 1197 gui->subtitlemenu = CreatePopupMenu(); |
1198 AppendMenu(gui->submenu, MF_STRING | MF_POPUP, (UINT) gui->trayplaymenu, "Open..."); | 1198 AppendMenu(gui->submenu, MF_STRING | MF_POPUP, (UINT_PTR) gui->trayplaymenu, "Open..."); |
1199 AppendMenu(gui->submenu, MF_SEPARATOR, 0, 0); | 1199 AppendMenu(gui->submenu, MF_SEPARATOR, 0, 0); |
1200 AppendMenu(gui->submenu, MF_STRING, ID_SEEKB, "Seek Backwards"); | 1200 AppendMenu(gui->submenu, MF_STRING, ID_SEEKB, "Seek Backwards"); |
1201 AppendMenu(gui->submenu, MF_STRING, ID_PTRACK, "Previous Track"); | 1201 AppendMenu(gui->submenu, MF_STRING, ID_PTRACK, "Previous Track"); |
1202 AppendMenu(gui->submenu, MF_STRING, ID_PLAY, "Play/Pause"); | 1202 AppendMenu(gui->submenu, MF_STRING, ID_PLAY, "Play/Pause"); |
1203 AppendMenu(gui->submenu, MF_STRING, ID_STOP, "Stop"); | 1203 AppendMenu(gui->submenu, MF_STRING, ID_STOP, "Stop"); |
1205 AppendMenu(gui->submenu, MF_STRING, ID_SEEKF, "Seek Forwards"); | 1205 AppendMenu(gui->submenu, MF_STRING, ID_SEEKF, "Seek Forwards"); |
1206 AppendMenu(gui->submenu, MF_SEPARATOR, 0, 0); | 1206 AppendMenu(gui->submenu, MF_SEPARATOR, 0, 0); |
1207 AppendMenu(gui->submenu, MF_STRING, ID_FULLSCREEN, "Toggle Fullscreen"); | 1207 AppendMenu(gui->submenu, MF_STRING, ID_FULLSCREEN, "Toggle Fullscreen"); |
1208 AppendMenu(gui->submenu, MF_STRING, ID_MUTE, "Toggle Mute"); | 1208 AppendMenu(gui->submenu, MF_STRING, ID_MUTE, "Toggle Mute"); |
1209 AppendMenu(gui->submenu, MF_SEPARATOR, 0, 0); | 1209 AppendMenu(gui->submenu, MF_SEPARATOR, 0, 0); |
1210 AppendMenu(gui->submenu, MF_STRING | MF_POPUP, (UINT) gui->aspectmenu, "Aspect Ratio"); | 1210 AppendMenu(gui->submenu, MF_STRING | MF_POPUP, (UINT_PTR) gui->aspectmenu, "Aspect Ratio"); |
1211 AppendMenu(gui->submenu, MF_STRING | MF_POPUP, (UINT) gui->subtitlemenu, "Subtitle Options"); | 1211 AppendMenu(gui->submenu, MF_STRING | MF_POPUP, (UINT_PTR) gui->subtitlemenu, "Subtitle Options"); |
1212 AppendMenu(gui->submenu, MF_STRING | MF_POPUP, (UINT) gui->dvdmenu, "DVD Options"); | 1212 AppendMenu(gui->submenu, MF_STRING | MF_POPUP, (UINT_PTR) gui->dvdmenu, "DVD Options"); |
1213 #ifdef CONFIG_DVDREAD | 1213 #ifdef CONFIG_DVDREAD |
1214 AppendMenu(gui->dvdmenu, MF_STRING | MF_GRAYED, ID_CHAPTERSEL, "Select Title/Chapter..."); | 1214 AppendMenu(gui->dvdmenu, MF_STRING | MF_GRAYED, ID_CHAPTERSEL, "Select Title/Chapter..."); |
1215 #endif | 1215 #endif |
1216 AppendMenu(gui->subtitlemenu, MF_STRING, IDSUB_TOGGLE, "Subtitle Visibility On/Off"); | 1216 AppendMenu(gui->subtitlemenu, MF_STRING, IDSUB_TOGGLE, "Subtitle Visibility On/Off"); |
1217 AppendMenu(gui->subtitlemenu, MF_STRING, IDSUB_CYCLE, "Cycle Subtitle Languages"); | 1217 AppendMenu(gui->subtitlemenu, MF_STRING, IDSUB_CYCLE, "Cycle Subtitle Languages"); |