source: smplayer/trunk/src/prefinterface.h@ 167

Last change on this file since 167 was 165, checked in by Silvan Scherrer, 11 years ago

SMPlayer: update trunk to latest 0.8.7

  • Property svn:eol-style set to LF
File size: 3.4 KB
Line 
1/* smplayer, GUI front-end for mplayer.
2 Copyright (C) 2006-2014 Ricardo Villalba <rvm@users.sourceforge.net>
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 _PREFINTERFACE_H_
20#define _PREFINTERFACE_H_
21
22#include "ui_prefinterface.h"
23#include "prefwidget.h"
24#include "config.h"
25
26class Preferences;
27
28class PrefInterface : public PrefWidget, public Ui::PrefInterface
29{
30 Q_OBJECT
31
32public:
33 PrefInterface( QWidget * parent = 0, Qt::WindowFlags f = 0 );
34 ~PrefInterface();
35
36 virtual QString sectionName();
37 virtual QPixmap sectionIcon();
38
39 // Pass data to the dialog
40 void setData(Preferences * pref);
41
42 // Apply changes
43 void getData(Preferences * pref);
44
45 bool languageChanged() { return language_changed; };
46 bool iconsetChanged() { return iconset_changed; };
47 bool guiChanged() { return gui_changed; }
48 bool styleChanged() { return style_changed; };
49 bool recentsChanged() { return recents_changed; };
50 bool urlMaxChanged() { return url_max_changed; };
51
52protected:
53 virtual void createHelp();
54 void createLanguageCombo();
55
56 void setLanguage(QString lang);
57 QString language();
58
59 void setIconSet(QString set);
60 QString iconSet();
61
62 void setResizeMethod(int v);
63 int resizeMethod();
64
65 void setSaveSize(bool b);
66 bool saveSize();
67
68 void setGUI(QString gui_name);
69 QString GUI();
70
71 void setStyle(QString style);
72 QString style();
73
74#ifdef SINGLE_INSTANCE
75 void setUseSingleInstance(bool b);
76 bool useSingleInstance();
77#endif
78
79 void setSeeking1(int n);
80 int seeking1();
81
82 void setSeeking2(int n);
83 int seeking2();
84
85 void setSeeking3(int n);
86 int seeking3();
87
88 void setSeeking4(int n);
89 int seeking4();
90
91 void setUpdateWhileDragging(bool);
92 bool updateWhileDragging();
93
94#ifdef SEEKBAR_RESOLUTION
95 void setRelativeSeeking(bool);
96#endif
97 bool relativeSeeking();
98
99 void setPreciseSeeking(bool);
100 bool preciseSeeking();
101
102 void setDefaultFont(QString font_desc);
103 QString defaultFont();
104
105 void setHideVideoOnAudioFiles(bool b);
106 bool hideVideoOnAudioFiles();
107
108 // Floating tab
109 void setFloatingAnimated(bool b);
110 bool floatingAnimated();
111
112 void setFloatingWidth(int percentage);
113 int floatingWidth();
114
115 void setFloatingMargin(int pixels);
116 int floatingMargin();
117
118 void setDisplayFloatingInCompactMode(bool b);
119 bool displayFloatingInCompactMode();
120
121 // Privacy tab
122 void setRecentsMaxItems(int n);
123 int recentsMaxItems();
124
125 void setURLMaxItems(int n);
126 int urlMaxItems();
127
128 void setRememberDirs(bool b);
129 bool rememberDirs();
130
131protected slots:
132 void on_changeFontButton_clicked();
133#ifdef SINGLE_INSTANCE
134 void changeInstanceImages();
135#endif
136#ifdef SKINS
137 void GUIChanged(int index);
138#endif
139
140protected:
141 virtual void retranslateStrings();
142
143private:
144 bool language_changed;
145 bool iconset_changed;
146 bool gui_changed;
147 bool style_changed;
148 bool recents_changed;
149 bool url_max_changed;
150
151#ifdef SKINS
152 int n_skins;
153#endif
154};
155
156#endif
Note: See TracBrowser for help on using the repository browser.