2008-04-22 09:33:39 +00:00
|
|
|
/*
|
|
|
|
* This file is part of MPlayer.
|
|
|
|
*
|
|
|
|
* MPlayer is free software; you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation; either version 2 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* MPlayer is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License along
|
|
|
|
* with MPlayer; if not, write to the Free Software Foundation, Inc.,
|
|
|
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
|
|
|
*/
|
|
|
|
|
2008-02-22 09:09:46 +00:00
|
|
|
#ifndef MPLAYER_GUI_APP_H
|
|
|
|
#define MPLAYER_GUI_APP_H
|
2001-08-25 21:04:29 +00:00
|
|
|
|
2002-11-02 20:10:18 +00:00
|
|
|
#include "bitmap.h"
|
2001-08-25 21:04:29 +00:00
|
|
|
#include "wm/ws.h"
|
|
|
|
#include "wm/wskeys.h"
|
2002-11-02 16:09:05 +00:00
|
|
|
|
|
|
|
// --- User events ------
|
|
|
|
|
|
|
|
#define evNone 0
|
|
|
|
#define evPlay 1
|
|
|
|
#define evStop 2
|
|
|
|
#define evPause 3
|
|
|
|
#define evPrev 6
|
|
|
|
#define evNext 7
|
|
|
|
#define evLoad 8
|
|
|
|
#define evEqualizer 9
|
|
|
|
#define evPlayList 10
|
|
|
|
#define evIconify 11
|
|
|
|
#define evAbout 12
|
|
|
|
#define evLoadPlay 13
|
|
|
|
#define evPreferences 14
|
|
|
|
#define evSkinBrowser 15
|
|
|
|
#define evPlaySwitchToPause 16
|
|
|
|
#define evPauseSwitchToPlay 17
|
|
|
|
|
|
|
|
#define evBackward10sec 18
|
|
|
|
#define evForward10sec 19
|
|
|
|
#define evBackward1min 20
|
|
|
|
#define evForward1min 21
|
|
|
|
#define evBackward10min 22
|
|
|
|
#define evForward10min 23
|
|
|
|
|
2005-01-25 12:44:38 +00:00
|
|
|
#define evHalfSize 301
|
2002-11-02 16:09:05 +00:00
|
|
|
#define evNormalSize 24
|
|
|
|
#define evDoubleSize 25
|
|
|
|
#define evFullScreen 26
|
|
|
|
|
|
|
|
#define evSetMoviePosition 27
|
|
|
|
#define evSetVolume 28
|
|
|
|
#define evSetBalance 29
|
|
|
|
#define evMute 30
|
|
|
|
|
|
|
|
#define evIncVolume 31
|
|
|
|
#define evDecVolume 32
|
|
|
|
#define evIncAudioBufDelay 33
|
|
|
|
#define evDecAudioBufDelay 34
|
|
|
|
#define evIncBalance 35
|
|
|
|
#define evDecBalance 36
|
|
|
|
|
|
|
|
#define evHelp 37
|
|
|
|
|
|
|
|
#define evLoadSubtitle 38
|
|
|
|
#define evDropSubtitle 43
|
|
|
|
#define evPlayDVD 39
|
|
|
|
#define evPlayVCD 40
|
|
|
|
#define evPlayNetwork 41
|
|
|
|
#define evLoadAudioFile 42
|
|
|
|
#define evSetAspect 44
|
2002-11-29 00:58:25 +00:00
|
|
|
#define evSetAudio 45
|
2002-12-11 01:21:12 +00:00
|
|
|
#define evSetVideo 46
|
2006-04-16 16:58:36 +00:00
|
|
|
#define evSetSubtitle 47
|
|
|
|
// 48 ...
|
2002-11-02 16:09:05 +00:00
|
|
|
|
|
|
|
#define evExit 1000
|
|
|
|
|
|
|
|
// --- General events ---
|
|
|
|
|
|
|
|
#define evFileLoaded 5000
|
|
|
|
#define evHideMouseCursor 5001
|
|
|
|
#define evMessageBox 5002
|
|
|
|
#define evGeneralTimer 5003
|
|
|
|
#define evGtkIsOk 5004
|
|
|
|
#define evShowPopUpMenu 5005
|
|
|
|
#define evHidePopUpMenu 5006
|
|
|
|
#define evSetDVDAudio 5007
|
|
|
|
#define evSetDVDSubtitle 5008
|
|
|
|
#define evSetDVDTitle 5009
|
|
|
|
#define evSetDVDChapter 5010
|
|
|
|
#define evSubtitleLoaded 5011
|
|
|
|
#define evSetVCDTrack 5012
|
|
|
|
#define evSetURL 5013
|
|
|
|
|
|
|
|
#define evFName 7000
|
|
|
|
#define evMovieTime 7001
|
|
|
|
#define evRedraw 7002
|
|
|
|
#define evHideWindow 7003
|
|
|
|
#define evShowWindow 7004
|
|
|
|
#define evFirstLoad 7005
|
|
|
|
|
|
|
|
// ----------------------
|
|
|
|
|
|
|
|
typedef struct
|
|
|
|
{
|
|
|
|
int msg;
|
2006-07-16 01:40:24 +00:00
|
|
|
const char * name;
|
2002-11-02 16:09:05 +00:00
|
|
|
} evName;
|
|
|
|
|
2001-08-25 21:04:29 +00:00
|
|
|
#define itNULL 0
|
|
|
|
#define itButton 101 // button
|
|
|
|
#define itHPotmeter 102 // horizontal potmeter
|
|
|
|
#define itVPotmeter 103 // vertical potmeter
|
|
|
|
#define itSLabel 104 // static label
|
|
|
|
#define itDLabel 105 // dynamic label
|
|
|
|
#define itBase 106
|
|
|
|
#define itPotmeter 107
|
|
|
|
#define itFont 108
|
|
|
|
// ---
|
|
|
|
#define btnPressed 0
|
|
|
|
#define btnReleased 1
|
|
|
|
#define btnDisabled 2
|
|
|
|
// ---
|
|
|
|
typedef struct
|
|
|
|
{
|
|
|
|
int type;
|
|
|
|
// ---
|
|
|
|
int x,y;
|
|
|
|
int width,height;
|
|
|
|
// ---
|
|
|
|
int px,py,psx,psy;
|
|
|
|
// ---
|
|
|
|
int msg,msg2;
|
2002-11-27 23:11:49 +00:00
|
|
|
int pressed,tmp;
|
2001-08-25 21:04:29 +00:00
|
|
|
int key,key2;
|
|
|
|
int phases;
|
|
|
|
float value;
|
|
|
|
txSample Bitmap;
|
|
|
|
txSample Mask;
|
|
|
|
// ---
|
|
|
|
int fontid;
|
|
|
|
int align;
|
|
|
|
char * label;
|
|
|
|
// ---
|
|
|
|
int event;
|
2003-01-17 22:39:43 +00:00
|
|
|
// ---
|
|
|
|
int R,G,B;
|
2001-08-25 21:04:29 +00:00
|
|
|
} wItem;
|
|
|
|
|
|
|
|
typedef struct
|
|
|
|
{
|
|
|
|
wItem main;
|
|
|
|
wsTWindow mainWindow;
|
2001-11-12 12:26:09 +00:00
|
|
|
int mainDecoration;
|
2001-08-25 21:04:29 +00:00
|
|
|
|
|
|
|
wItem sub;
|
|
|
|
wsTWindow subWindow;
|
2003-01-13 23:38:49 +00:00
|
|
|
|
|
|
|
wItem bar;
|
|
|
|
wsTWindow barWindow;
|
|
|
|
int barIsPresent;
|
2003-01-17 22:39:43 +00:00
|
|
|
|
2001-08-25 21:04:29 +00:00
|
|
|
wItem menuBase;
|
|
|
|
wItem menuSelected;
|
|
|
|
wsTWindow menuWindow;
|
2003-01-13 23:38:49 +00:00
|
|
|
int menuIsPresent;
|
2001-08-25 21:04:29 +00:00
|
|
|
|
|
|
|
// ---
|
|
|
|
int NumberOfItems;
|
|
|
|
wItem Items[256];
|
|
|
|
// ---
|
|
|
|
int NumberOfMenuItems;
|
2003-01-17 22:39:43 +00:00
|
|
|
wItem MenuItems[64];
|
|
|
|
// ---
|
|
|
|
int NumberOfBarItems;
|
2003-03-20 12:42:16 +00:00
|
|
|
wItem barItems[256];
|
2001-08-25 21:04:29 +00:00
|
|
|
} listItems;
|
|
|
|
|
|
|
|
extern listItems appMPlayer;
|
|
|
|
|
|
|
|
extern char * skinDirInHome;
|
2006-03-27 11:39:27 +00:00
|
|
|
extern char * skinDirInHome_obsolete;
|
2001-08-25 21:04:29 +00:00
|
|
|
extern char * skinMPlayerDir;
|
2006-03-27 11:39:27 +00:00
|
|
|
extern char * skinMPlayerDir_obsolete;
|
2001-09-07 21:04:14 +00:00
|
|
|
extern char * skinName;
|
2001-08-25 21:04:29 +00:00
|
|
|
|
2008-12-03 23:01:03 +00:00
|
|
|
void appInitStruct( listItems * item );
|
|
|
|
void appClearItem( wItem * item );
|
|
|
|
void appCopy( listItems * item1, listItems * item2 );
|
|
|
|
int appFindMessage( unsigned char * str );
|
|
|
|
int appFindKey( unsigned char * name );
|
|
|
|
|
|
|
|
void btnModify( int event, float state );
|
|
|
|
float btnGetValue( int event );
|
|
|
|
void btnSet( int event, int set );
|
2002-11-25 17:33:30 +00:00
|
|
|
|
2008-02-22 09:09:46 +00:00
|
|
|
#endif /* MPLAYER_GUI_APP_H */
|