source: smplayer/trunk/src/prefgeneral.h@ 124

Last change on this file since 124 was 124, checked in by Silvan Scherrer, 14 years ago

SMPlayer: 0.7.1 trunk update

  • Property svn:eol-style set to LF
File size: 4.6 KB
Line 
1/* smplayer, GUI front-end for mplayer.
2 Copyright (C) 2006-2012 Ricardo Villalba <[email protected]>
3
4 This program is free software; you can redistribute it and/or modify
5 it under the terms of the GNU General Public License as published by
6 the Free Software Foundation; either version 2 of the License, or
7 (at your option) any later version.
8
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 GNU General Public License for more details.
13
14 You should have received a copy of the GNU General Public License
15 along with this program; if not, write to the Free Software
16 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17*/
18
19#ifndef _PREFGENERAL_H_
20#define _PREFGENERAL_H_
21
22#include "ui_prefgeneral.h"
23#include "prefwidget.h"
24#include "inforeader.h"
25#include "deviceinfo.h"
26#include "preferences.h"
27
28#ifdef Q_OS_WIN
29#define USE_DSOUND_DEVICES 1
30#else
31#define USE_ALSA_DEVICES 1
32#define USE_XV_ADAPTORS 1
33#endif
34
35#ifdef Q_OS_OS2
36#define MPLAYER_KAI_VERSION 30994
37#endif
38
39class PrefGeneral : public PrefWidget, public Ui::PrefGeneral
40{
41 Q_OBJECT
42
43public:
44 PrefGeneral( QWidget * parent = 0, Qt::WindowFlags f = 0 );
45 ~PrefGeneral();
46
47 // Return the name of the section
48 virtual QString sectionName();
49 // Return the icon of the section
50 virtual QPixmap sectionIcon();
51
52 // Pass data to the dialog
53 void setData(Preferences * pref);
54
55 // Apply changes
56 void getData(Preferences * pref);
57
58 bool fileSettingsMethodChanged() { return filesettings_method_changed; };
59
60protected:
61 virtual void createHelp();
62
63 // Tab General
64 void setMplayerPath( QString path );
65 QString mplayerPath();
66
67 void setUseScreenshots(bool b);
68 bool useScreenshots();
69
70 void setScreenshotDir( QString path );
71 QString screenshotDir();
72
73 void setVO( QString vo_driver );
74 QString VO();
75
76 void setAO( QString ao_driver );
77 QString AO();
78
79 void setRememberSettings(bool b);
80 bool rememberSettings();
81
82 void setRememberTimePos(bool b);
83 bool rememberTimePos();
84
85 void setFileSettingsMethod(QString method);
86 QString fileSettingsMethod();
87
88 void setAudioLang(QString lang);
89 QString audioLang();
90
91 void setSubtitleLang(QString lang);
92 QString subtitleLang();
93
94 void setAudioTrack(int track);
95 int audioTrack();
96
97 void setSubtitleTrack(int track);
98 int subtitleTrack();
99
100 void setCloseOnFinish(bool b);
101 bool closeOnFinish();
102
103 void setPauseWhenHidden(bool b);
104 bool pauseWhenHidden();
105
106 // Tab video and audio
107 void setEq2(bool b);
108 bool eq2();
109
110 void setStartInFullscreen(bool b);
111 bool startInFullscreen();
112
113#if defined(Q_OS_WIN) || defined(Q_OS_OS2)
114 void setAvoidScreensaver(bool b);
115 bool avoidScreensaver();
116
117 void setTurnScreensaverOff(bool b);
118 bool turnScreensaverOff();
119#else
120 void setDisableScreensaver(bool b);
121 bool disableScreensaver();
122#endif
123
124 void setBlackbordersOnFullscreen(bool b);
125 bool blackbordersOnFullscreen();
126
127 void setAutoq(int n);
128 int autoq();
129
130 void setGlobalVolume(bool b);
131 bool globalVolume();
132
133 void setAutoSyncFactor(int factor);
134 int autoSyncFactor();
135
136 void setAutoSyncActivated(bool b);
137 bool autoSyncActivated();
138
139 void setMc(double value);
140 double mc();
141
142 void setMcActivated(bool b);
143 bool mcActivated();