[112] | 1 | /* smplayer, GUI front-end for mplayer.
|
---|
[188] | 2 | Copyright (C) 2006-2017 Ricardo Villalba <rvm@users.sourceforge.net>
|
---|
[112] | 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 |
|
---|
[176] | 20 | #ifndef PREFERENCES_H
|
---|
| 21 | #define PREFERENCES_H
|
---|
[112] | 22 |
|
---|
| 23 | /* Global settings */
|
---|
| 24 |
|
---|
| 25 | #include <QString>
|
---|
| 26 | #include <QStringList>
|
---|
| 27 | #include <QSize>
|
---|
| 28 | #include "config.h"
|
---|
| 29 | #include "audioequalizerlist.h"
|
---|
| 30 | #include "assstyles.h"
|
---|
| 31 |
|
---|
[156] | 32 | #ifdef UPDATE_CHECKER
|
---|
[176] | 33 | #include "updatecheckerdata.h"
|
---|
[156] | 34 | #endif
|
---|
| 35 |
|
---|
[112] | 36 | class Recents;
|
---|
| 37 | class URLHistory;
|
---|
| 38 | class Filters;
|
---|
| 39 |
|
---|
| 40 | class Preferences {
|
---|
| 41 |
|
---|
| 42 | public:
|
---|
| 43 | enum OSD { None = 0, Seek = 1, SeekTimer = 2, SeekTimerTotal = 3 };
|
---|
| 44 | enum OnTop { NeverOnTop = 0, AlwaysOnTop = 1, WhilePlayingOnTop = 2 };
|
---|
| 45 | enum Resize { Never = 0, Always = 1, Afterload = 2 };
|
---|
| 46 | enum Priority { Realtime = 0, High = 1, AboveNormal = 2, Normal = 3,
|
---|
| 47 | BelowNormal = 4, Idle = 5 };
|
---|
| 48 | enum WheelFunction { DoNothing = 1, Seeking = 2, Volume = 4, Zoom = 8,
|
---|
| 49 | ChangeSpeed = 16 };
|
---|
[176] | 50 | enum DragFunction { DragDisabled = 0, MoveWindow = 1, Gestures = 2 };
|
---|
[112] | 51 | enum OptionState { Detect = -1, Disabled = 0, Enabled = 1 };
|
---|
| 52 | enum H264LoopFilter { LoopDisabled = 0, LoopEnabled = 1, LoopDisabledOnHD = 2 };
|
---|
[165] | 53 | enum AutoAddToPlaylistFilter { NoFiles = 0, VideoFiles = 1, AudioFiles = 2, MultimediaFiles = 3, ConsecutiveFiles = 4 };
|
---|
[176] | 54 | enum Streaming { NoStreaming = 0, StreamingAuto = 1, StreamingYT = 2, StreamingYTDL = 3 };
|
---|
[112] | 55 |
|
---|
| 56 | Q_DECLARE_FLAGS(WheelFunctions, WheelFunction);
|
---|
| 57 |
|
---|
| 58 | Preferences();
|
---|
| 59 | virtual ~Preferences();
|
---|
| 60 |
|
---|
| 61 | virtual void reset();
|
---|
| 62 |
|
---|
| 63 | void save();
|
---|
| 64 | void load();
|
---|
| 65 |
|
---|
| 66 | double monitor_aspect_double();
|
---|
[124] | 67 | void setupScreenshotFolder();
|
---|
[112] | 68 |
|
---|
| 69 |
|
---|
| 70 |
|
---|
| 71 | /* *******
|
---|
| 72 | General
|
---|
| 73 | ******* */
|
---|
| 74 |
|
---|
[135] | 75 | int config_version;
|
---|
| 76 |
|
---|
[112] | 77 | QString mplayer_bin;
|
---|
| 78 | QString vo; // video output
|
---|
| 79 | QString ao; // audio output
|
---|
| 80 |
|
---|
| 81 | bool use_screenshot;
|
---|
[176] | 82 | #ifdef MPV_SUPPORT
|
---|
| 83 | QString screenshot_template;
|
---|
| 84 | QString screenshot_format;
|
---|
| 85 | #endif
|
---|
[112] | 86 | QString screenshot_directory;
|
---|
[176] | 87 | #ifdef CAPTURE_STREAM
|
---|
| 88 | QString capture_directory;
|
---|
| 89 | #endif
|
---|
[112] | 90 |
|
---|
[181] | 91 | // Possibility to remember all media settings
|
---|
| 92 | bool remember_media_settings;
|
---|
| 93 | bool remember_time_pos;
|
---|
| 94 | bool remember_stream_settings;
|
---|
[112] | 95 |
|
---|
| 96 | QString audio_lang; // Preferred audio language
|
---|
| 97 | QString subtitle_lang; // Preferred subtitle language
|
---|
| 98 |
|
---|
| 99 | // Video
|
---|
| 100 | bool use_direct_rendering;
|
---|
| 101 | bool use_double_buffer;
|
---|
| 102 | bool use_soft_video_eq;
|
---|
| 103 | bool use_slices;
|
---|
| 104 | int autoq; //!< Postprocessing quality
|
---|
[188] | 105 |
|
---|
| 106 | #ifdef ADD_BLACKBORDERS_FS
|
---|
[112] | 107 | bool add_blackborders_on_fullscreen;
|
---|
[188] | 108 | #endif
|
---|
[112] | 109 |
|
---|
[182] | 110 | #if defined(Q_OS_WIN) || defined(Q_OS_OS2)
|
---|
[165] | 111 | #ifdef SCREENSAVER_OFF
|
---|
[112] | 112 | bool turn_screensaver_off;
|
---|
[165] | 113 | #endif
|
---|
| 114 | #ifdef AVOID_SCREENSAVER
|
---|
[112] | 115 | bool avoid_screensaver;
|
---|
[165] | 116 | #endif
|
---|
[112] | 117 | #else
|
---|
| 118 | bool disable_screensaver;
|
---|
| 119 | #endif
|
---|
| 120 |
|
---|
| 121 | #ifndef Q_OS_WIN
|
---|
[119] | 122 | struct VDPAU_settings {
|
---|
| 123 | bool ffh264vdpau;
|
---|
| 124 | bool ffmpeg12vdpau;
|
---|
| 125 | bool ffwmv3vdpau;
|
---|
| 126 | bool ffvc1vdpau;
|
---|
| 127 | bool ffodivxvdpau;
|
---|
| 128 | bool disable_video_filters;
|
---|
| 129 | } vdpau;
|
---|
[112] | 130 | #endif
|
---|
| 131 |
|
---|
| 132 | // Audio
|
---|
| 133 | bool use_soft_vol;
|
---|
| 134 | int softvol_max;
|
---|
| 135 | OptionState use_scaletempo;
|
---|
| 136 | bool use_hwac3; // -afm hwac3
|
---|
| 137 | bool use_audio_equalizer;
|
---|
| 138 |
|
---|
| 139 | // Global volume options
|
---|
| 140 | bool global_volume;
|
---|
| 141 | int volume;
|
---|
| 142 | bool mute;
|
---|
| 143 |
|
---|
[165] | 144 | // Global equalizer
|
---|
| 145 | bool global_audio_equalizer;
|
---|
| 146 | AudioEqualizerList audio_equalizer;
|
---|
| 147 |
|
---|
[112] | 148 | bool autosync;
|
---|
| 149 | int autosync_factor;
|
---|
| 150 |
|
---|
| 151 | // For the -mc option
|
---|
| 152 | bool use_mc;
|
---|
| 153 | double mc_value;
|
---|
| 154 |
|
---|
[165] | 155 | // When playing a mp4 file, it will use a m4a file for audio if a there's a file with same name but extension m4a
|
---|
| 156 | bool autoload_m4a;
|
---|
| 157 | int min_step; //<! Step to increase of decrease the controls for color, contrast, brightness and so on
|
---|
| 158 |
|
---|
[112] | 159 | // Misc
|
---|
| 160 | int osd;
|
---|
[176] | 161 | double osd_scale; // mpv
|
---|
| 162 | double subfont_osd_scale; // mplayer
|
---|
[112] | 163 | int osd_delay; //<! Delay in ms to show the OSD.
|
---|
| 164 |
|
---|
| 165 | QString file_settings_method; //!< Method to be used for saving file settings
|
---|
| 166 |
|
---|
[181] | 167 | bool tablet_mode;
|
---|
| 168 | #ifdef Q_OS_WIN
|
---|
| 169 | QString tablet_mode_change_answer;
|
---|
| 170 | #endif
|
---|
[112] | 171 |
|
---|
| 172 | /* ***************
|
---|
| 173 | Drives (CD/DVD)
|
---|
| 174 | *************** */
|
---|
| 175 |
|
---|
| 176 | QString dvd_device;
|
---|
| 177 | QString cdrom_device;
|
---|
[165] | 178 | #ifdef BLURAY_SUPPORT
|
---|
| 179 | QString bluray_device;
|
---|
| 180 | #endif
|
---|
[112] | 181 |
|
---|
| 182 | #ifdef Q_OS_WIN
|
---|
| 183 | bool enable_audiocd_on_windows;
|
---|
| 184 | #endif
|
---|
| 185 |
|
---|
| 186 | int vcd_initial_title;
|
---|
| 187 |
|
---|
| 188 | #if DVDNAV_SUPPORT
|
---|
| 189 | bool use_dvdnav; //!< Opens DVDs using dvdnav: instead of dvd:
|
---|
| 190 | #endif
|
---|
| 191 |
|
---|
| 192 |
|
---|
| 193 | /* ***********
|
---|
| 194 | Performance
|
---|
| 195 | *********** */
|
---|
| 196 |
|
---|
[181] | 197 | #ifdef Q_OS_WIN
|
---|
[112] | 198 | int priority;
|
---|
[181] | 199 | #endif
|
---|
[112] | 200 | bool frame_drop;
|
---|
| 201 | bool hard_frame_drop;
|
---|
| 202 | bool coreavc;
|
---|
| 203 | H264LoopFilter h264_skip_loop_filter;
|
---|
| 204 | int HD_height; //!< An HD is a video which height is equal or greater than this.
|
---|
| 205 |
|
---|
[176] | 206 | #ifdef OBSOLETE_FAST_AUDIO_CHANGE
|
---|
[112] | 207 | OptionState fast_audio_change; // If activated, not restart mplayer
|
---|
[176] | 208 | #endif
|
---|
| 209 |
|
---|
[112] | 210 | #if !SMART_DVD_CHAPTERS
|
---|
| 211 | bool fast_chapter_change;
|
---|
| 212 | #endif
|
---|
| 213 |
|
---|
| 214 | int threads; //!< number of threads to use for decoding (-lavdopts threads <1-8>)
|
---|
[176] | 215 | QString hwdec; //!< hardware video decoding (mpv only)
|
---|
[112] | 216 |
|
---|
[181] | 217 | bool cache_auto;
|
---|
[112] | 218 | int cache_for_files;
|
---|
| 219 | int cache_for_streams;
|
---|
| 220 | int cache_for_dvds;
|
---|
| 221 | int cache_for_vcds;
|
---|
| 222 | int cache_for_audiocds;
|
---|
[181] | 223 | #ifdef TV_SUPPORT
|
---|
[112] | 224 | int cache_for_tv;
|
---|
[181] | 225 | #endif
|
---|
[112] | 226 |
|
---|
| 227 |
|
---|
| 228 | /* *********
|
---|
| 229 | Subtitles
|
---|
| 230 | ********* */
|
---|
| 231 |
|
---|
| 232 | QString subcp; // -subcp
|
---|
| 233 | bool use_enca;
|
---|
| 234 | QString enca_lang;
|
---|
| 235 | int subfuzziness;
|
---|
| 236 | bool autoload_sub;
|
---|
| 237 |
|
---|
| 238 | bool use_ass_subtitles;
|
---|
[176] | 239 | bool enable_ass_styles;
|
---|
[112] | 240 | int ass_line_spacing;
|
---|
| 241 |
|
---|
| 242 | bool use_forced_subs_only;
|
---|
| 243 |
|
---|
| 244 | bool sub_visibility;
|
---|
| 245 |
|
---|
| 246 | bool subtitles_on_screenshots;
|
---|
| 247 |
|
---|
| 248 | OptionState change_sub_scale_should_restart;
|
---|
| 249 |
|
---|
| 250 | //! If true, loading an external subtitle will be done
|
---|
| 251 | //! by using the sub_load slave command. Otherwise
|
---|
| 252 | //! mplayer will be restarted.
|
---|
| 253 | bool fast_load_sub;
|
---|
| 254 |
|
---|
| 255 | // ASS styles
|
---|
| 256 | AssStyles ass_styles;
|
---|
| 257 | bool force_ass_styles; // Use ass styles even for ass files
|
---|
| 258 | QString user_forced_ass_style; //!< Specifies a style defined by the user to be used with -ass-force-style
|
---|
| 259 |
|
---|
| 260 | //! If false, options requiring freetype won't be used
|
---|
| 261 | bool freetype_support;
|
---|
[176] | 262 | #ifdef FONTS_HACK
|
---|
[165] | 263 | bool use_windowsfontdir;
|
---|
| 264 | #endif
|
---|
[112] | 265 |
|
---|
| 266 |
|
---|
| 267 | /* ********
|
---|
| 268 | Advanced
|
---|
| 269 | ******** */
|
---|
| 270 |
|
---|
| 271 | #if USE_ADAPTER
|
---|
| 272 | int adapter; //Screen for overlay. If -1 it won't be used.
|
---|
| 273 | #endif
|
---|
| 274 |
|
---|
| 275 | #if USE_COLORKEY
|
---|
| 276 | unsigned int color_key;
|
---|
| 277 | #endif
|
---|
| 278 |
|
---|
| 279 | bool use_mplayer_window;
|
---|
| 280 |
|
---|
| 281 | QString monitor_aspect;
|
---|
| 282 |
|
---|
| 283 | bool use_idx; //!< Use -idx
|
---|
[165] | 284 | bool use_lavf_demuxer;
|
---|
[112] | 285 |
|
---|
| 286 | // Let the user pass options to mplayer
|
---|
| 287 | QString mplayer_additional_options;
|
---|
| 288 | QString mplayer_additional_video_filters;
|
---|
| 289 | QString mplayer_additional_audio_filters;
|
---|
| 290 |
|
---|
| 291 | // Logs
|
---|
[128] | 292 | #ifdef LOG_MPLAYER
|
---|
[112] | 293 | bool log_mplayer;
|
---|
[128] | 294 | bool verbose_log;
|
---|
| 295 | bool autosave_mplayer_log;
|
---|
| 296 | QString mplayer_log_saveto;
|
---|
| 297 | #endif
|
---|
| 298 | #ifdef LOG_SMPLAYER
|
---|
[112] | 299 | bool log_smplayer;
|
---|
| 300 | QString log_filter;
|
---|
| 301 | bool save_smplayer_log;
|
---|
[128] | 302 | #endif
|
---|
[112] | 303 |
|
---|
| 304 | #if REPAINT_BACKGROUND_OPTION
|
---|
| 305 | //! If true, mplayerlayer erases its background
|
---|
| 306 | bool repaint_video_background;
|
---|
| 307 | #endif
|
---|
| 308 |
|
---|
| 309 | //! If true it will autoload edl files with the same name of the file
|
---|
| 310 | //! to play
|
---|
| 311 | bool use_edl_files;
|
---|
| 312 |
|
---|
[176] | 313 | #ifdef MPLAYER_SUPPORT
|
---|
| 314 | //! If true it will pass to mplayer the -playlist option
|
---|
| 315 | bool use_playlist_option;
|
---|
| 316 | #endif
|
---|
| 317 |
|
---|
[112] | 318 | //! Preferred connection method: ipv4 or ipv6
|
---|
| 319 | bool prefer_ipv4;
|
---|
| 320 |
|
---|
| 321 | //! Windows only. If true, smplayer will pass short filenames to mplayer.
|
---|
| 322 | //! To workaround a bug in mplayer.
|
---|
| 323 | bool use_short_pathnames;
|
---|
| 324 |
|
---|
| 325 | //! If false, -brightness, -contrast and so on, won't be passed to
|
---|
| 326 | //! mplayer. It seems that some graphic cards don't support those options.
|
---|
| 327 | bool change_video_equalizer_on_startup;
|
---|
| 328 |
|
---|
| 329 | //! If true, smplayer will use the prefix pausing_keep_force to keep
|
---|
| 330 | //! the pause on slave commands. This experimental prefix was added
|
---|
| 331 | //! in mplayer svn r27665.
|
---|
| 332 | bool use_pausing_keep_force;
|
---|
| 333 |
|
---|
| 334 | OptionState use_correct_pts; //!< Pass -correct-pts to mplayer
|
---|
| 335 |
|
---|
| 336 | QString actions_to_run; //!< List of actions to run every time a video loads.
|
---|
| 337 |
|
---|
[119] | 338 | //! Show file tag in window title
|
---|
| 339 | bool show_tag_in_window_title;
|
---|
[112] | 340 |
|
---|
[139] | 341 | int time_to_kill_mplayer;
|
---|
[119] | 342 |
|
---|
[176] | 343 | #ifdef MPRIS2
|
---|
| 344 | bool use_mpris2;
|
---|
| 345 | #endif
|
---|
[139] | 346 |
|
---|
[188] | 347 | #ifdef MPV_SUPPORT
|
---|
| 348 | QString mpv_osd_media_info;
|
---|
| 349 | #endif
|
---|
| 350 | #ifdef MPLAYER_SUPPORT
|
---|
| 351 | QString mplayer_osd_media_info;
|
---|
| 352 | #endif
|
---|
[176] | 353 |
|
---|
[188] | 354 |
|
---|
[112] | 355 | /* *********
|
---|
| 356 | GUI stuff
|
---|
| 357 | ********* */
|
---|
| 358 |
|
---|
| 359 | bool fullscreen;
|
---|
| 360 | bool start_in_fullscreen;
|
---|
| 361 | bool compact_mode;
|
---|
| 362 | OnTop stay_on_top;
|
---|
| 363 | int size_factor;
|
---|
| 364 |
|
---|
| 365 | int resize_method; //!< Mainwindow resize method
|
---|
| 366 |
|
---|
| 367 | #if STYLE_SWITCHING
|
---|
| 368 | QString style; //!< SMPlayer look
|
---|
| 369 | #endif
|
---|
| 370 |
|
---|
[176] | 371 | bool center_window; //!< Center the main window when playback starts
|
---|
| 372 | bool center_window_if_outside; //!< Center the main window after an autoresize if it's outside of the screen
|
---|
[142] | 373 |
|
---|
[181] | 374 | #ifdef GLOBALSHORTCUTS
|
---|
| 375 | bool use_global_shortcuts;
|
---|
| 376 | #endif
|
---|
| 377 |
|
---|
[112] | 378 | // Function of mouse buttons:
|
---|
| 379 | QString mouse_left_click_function;
|
---|
| 380 | QString mouse_right_click_function;
|
---|
| 381 | QString mouse_double_click_function;
|
---|
| 382 | QString mouse_middle_click_function;
|
---|
| 383 | QString mouse_xbutton1_click_function;
|
---|
| 384 | QString mouse_xbutton2_click_function;
|
---|
| 385 | int wheel_function;
|
---|
| 386 |
|
---|
[165] | 387 | WheelFunctions wheel_function_cycle;
|
---|
[112] | 388 | bool wheel_function_seeking_reverse;
|
---|
| 389 |
|
---|
[176] | 390 | int drag_function;
|
---|
| 391 |
|
---|
[112] | 392 | // Configurable seeking
|
---|
| 393 | int seeking1; // By default 10s
|
---|
| 394 | int seeking2; // By default 1m
|
---|
| 395 | int seeking3; // By default 10m
|
---|
| 396 | int seeking4; // For mouse wheel, by default 30s
|
---|
| 397 |
|
---|
| 398 | bool update_while_seeking;
|
---|
| 399 | #if ENABLE_DELAYED_DRAGGING
|
---|
| 400 | int time_slider_drag_delay;
|
---|
| 401 | #endif
|
---|
| 402 | #if SEEKBAR_RESOLUTION
|
---|
| 403 | //! If true, seeking will be done using a
|
---|
| 404 | //! percentage (with fractions) instead of time.
|
---|
| 405 | bool relative_seeking;
|
---|
| 406 | #endif
|
---|
[176] | 407 | bool precise_seeking; //! Enable precise_seeking (only available with mpv)
|
---|
[112] | 408 |
|
---|
[142] | 409 | bool reset_stop; //! Pressing the stop button resets the position
|
---|
| 410 |
|
---|
[165] | 411 | //! If true, the left click in the video is delayed some ms
|
---|
| 412 | //! to check if the user double clicked
|
---|
| 413 | bool delay_left_click;
|
---|
| 414 |
|
---|
[112] | 415 | QString language;
|
---|
| 416 | QString iconset;
|
---|
| 417 |
|
---|
| 418 | //! Number of times to show the balloon remembering that the program
|
---|
| 419 | //! is still running in the system tray.
|
---|
| 420 | int balloon_count;
|
---|
| 421 |
|
---|
| 422 | //! If true, the position of the main window will be saved before
|
---|
| 423 | //! entering in fullscreen and will restore when going back to
|
---|
| 424 | //! window mode.
|
---|
| 425 | bool restore_pos_after_fullscreen;
|
---|
| 426 |
|
---|
| 427 | bool save_window_size_on_exit;
|
---|
| 428 |
|
---|
| 429 | //! Close the main window when a file or playlist finish
|
---|
| 430 | bool close_on_finish;
|
---|
| 431 |
|
---|
[170] | 432 | #ifdef AUTO_SHUTDOWN_PC
|
---|
| 433 | bool auto_shutdown_pc;
|
---|
| 434 | #endif
|
---|
| 435 |
|
---|
[112] | 436 | QString default_font;
|
---|
| 437 |
|
---|
| 438 | //!< Pause the current file when the main window is not visible
|
---|
| 439 | bool pause_when_hidden;
|
---|
| 440 |
|
---|
| 441 | //!< Allow frre movement of the video window
|
---|
| 442 | bool allow_video_movement;
|
---|
| 443 |
|
---|
| 444 | QString gui; //!< The name of the GUI to use
|
---|
| 445 |
|
---|
| 446 | #if USE_MINIMUMSIZE
|
---|
| 447 | int gui_minimum_width;
|
---|
| 448 | #endif
|
---|
| 449 | QSize default_size; // Default size of the main window
|
---|
| 450 |
|
---|
| 451 | #if ALLOW_TO_HIDE_VIDEO_WINDOW_ON_AUDIO_FILES
|
---|
| 452 | bool hide_video_window_on_audio_files;
|
---|
| 453 | #endif
|
---|
| 454 |
|
---|
| 455 | bool report_mplayer_crashes;
|
---|
| 456 |
|
---|
| 457 | #if REPORT_OLD_MPLAYER
|
---|
| 458 | bool reported_mplayer_is_old;
|
---|
| 459 | #endif
|
---|
| 460 |
|
---|
| 461 | bool auto_add_to_playlist; //!< Add files to open to playlist
|
---|
[165] | 462 | AutoAddToPlaylistFilter media_to_add_to_playlist;
|
---|
[112] | 463 |
|
---|
[135] | 464 | #if LOGO_ANIMATION
|
---|
| 465 | bool animated_logo;
|
---|
| 466 | #endif
|
---|
[112] | 467 |
|
---|
[135] | 468 |
|
---|
[112] | 469 | /* ********
|
---|
| 470 | TV (dvb)
|
---|
| 471 | ******** */
|
---|
[181] | 472 | #ifdef TV_SUPPORT
|
---|
[112] | 473 | bool check_channels_conf_on_startup;
|
---|
| 474 | int initial_tv_deinterlace;
|
---|
| 475 | QString last_dvb_channel;
|
---|
| 476 | QString last_tv_channel;
|
---|
[181] | 477 | #endif
|
---|
[112] | 478 |
|
---|
[176] | 479 |
|
---|
| 480 | /* ********
|
---|
| 481 | Network
|
---|
| 482 | ******** */
|
---|
| 483 |
|
---|
| 484 | // Streaming
|
---|
| 485 | int streaming_type;
|
---|
| 486 | #ifdef YOUTUBE_SUPPORT
|
---|
| 487 | int yt_quality;
|
---|
| 488 | QString yt_user_agent;
|
---|
| 489 | bool yt_use_https_main;
|
---|
| 490 | bool yt_use_https_vi;
|
---|
| 491 | #endif
|
---|
| 492 |
|
---|
| 493 | // Proxy
|
---|
| 494 | bool use_proxy;
|
---|
| 495 | int proxy_type;
|
---|
| 496 | QString proxy_host;
|
---|
| 497 | int proxy_port;
|
---|
| 498 | QString proxy_username;
|
---|
| 499 | QString proxy_password;
|
---|
| 500 |
|
---|
| 501 |
|
---|
[112] | 502 | /* ***********
|
---|
| 503 | Directories
|
---|
| 504 | *********** */
|
---|
| 505 |
|
---|
| 506 | QString latest_dir; //!< Directory of the latest file loaded
|
---|
| 507 | QString last_dvd_directory;
|
---|
[135] | 508 | bool save_dirs; // Save or not the latest dirs
|
---|
[112] | 509 |
|
---|
| 510 | /* **************
|
---|
| 511 | Initial values
|
---|
| 512 | ************** */
|
---|
| 513 |
|
---|
| 514 | double initial_sub_scale;
|
---|
| 515 | double initial_sub_scale_ass;
|
---|
| 516 | int initial_volume;
|
---|
| 517 | int initial_contrast;
|
---|
| 518 | int initial_brightness;
|
---|
| 519 | int initial_hue;
|
---|
| 520 | int initial_saturation;
|
---|
| 521 | int initial_gamma;
|
---|
| 522 |
|
---|
| 523 | AudioEqualizerList initial_audio_equalizer;
|
---|
| 524 |
|
---|
| 525 | //! Default value for zoom (1.0 = no zoom)
|
---|
| 526 | double initial_zoom_factor;
|
---|
| 527 |
|
---|
| 528 | //! Default value for position of subtitles on screen
|
---|
| 529 | //! 100 = 100% at the bottom
|
---|
| 530 | int initial_sub_pos;
|
---|
| 531 |
|
---|
[188] | 532 | #ifdef INITIAL_BLACKBORDERS
|
---|
| 533 | bool initial_blackborders;
|
---|
| 534 | #endif
|
---|
| 535 |
|
---|
[112] | 536 | bool initial_postprocessing; //!< global postprocessing filter
|
---|
| 537 | bool initial_volnorm;
|
---|
| 538 |
|
---|
| 539 | int initial_deinterlace;
|
---|
| 540 |
|
---|
| 541 | int initial_audio_channels;
|
---|
| 542 | int initial_stereo_mode;
|
---|
| 543 |
|
---|
| 544 | int initial_audio_track;
|
---|
| 545 | int initial_subtitle_track;
|
---|
| 546 |
|
---|
| 547 |
|
---|
| 548 | /* ************
|
---|
| 549 | MPlayer info
|
---|
| 550 | ************ */
|
---|
| 551 |
|
---|
| 552 | int mplayer_detected_version; //!< Latest version of mplayer parsed
|
---|
| 553 |
|
---|
| 554 | //! Version of mplayer supplied by the user which will be used if
|
---|
| 555 | //! the version can't be parsed from mplayer output
|
---|
| 556 | int mplayer_user_supplied_version;
|
---|
| 557 |
|
---|
[176] | 558 | #ifdef MPLAYER2_SUPPORT
|
---|
[124] | 559 | bool mplayer_is_mplayer2; //! True if the detected version is mplayer2
|
---|
| 560 | QString mplayer2_detected_version;
|
---|
[176] | 561 | #endif
|
---|
[112] | 562 |
|
---|
[124] | 563 |
|
---|
[112] | 564 | /* *********
|
---|
| 565 | Instances
|
---|
| 566 | ********* */
|
---|
[128] | 567 | #ifdef SINGLE_INSTANCE
|
---|
[112] | 568 | bool use_single_instance;
|
---|
[128] | 569 | #endif
|
---|
[112] | 570 |
|
---|
| 571 |
|
---|
| 572 | /* ****************
|
---|
| 573 | Floating control
|
---|
| 574 | **************** */
|
---|
| 575 |
|
---|
| 576 | int floating_control_margin;
|
---|
| 577 | int floating_control_width;
|
---|
| 578 | bool floating_control_animated;
|
---|
| 579 | bool floating_display_in_compact_mode;
|
---|
[165] | 580 | int floating_activation_area;
|
---|
| 581 | int floating_hide_delay;
|
---|
[112] | 582 |
|
---|
| 583 |
|
---|
| 584 | /* *******
|
---|
| 585 | History
|
---|
| 586 | ******* */
|
---|
| 587 |
|
---|
| 588 | Recents * history_recents;
|
---|
| 589 | URLHistory * history_urls;
|
---|
| 590 |
|
---|
| 591 |
|
---|
| 592 | /* *******
|
---|
| 593 | Filters
|
---|
| 594 | ******* */
|
---|
| 595 | Filters * filters;
|
---|
[139] | 596 |
|
---|
| 597 |
|
---|
| 598 | /* *********
|
---|
| 599 | SMPlayer info
|
---|
| 600 | ********* */
|
---|
| 601 |
|
---|
[156] | 602 | #ifdef CHECK_UPGRADED
|
---|
| 603 | QString smplayer_stable_version;
|
---|
| 604 | bool check_if_upgraded;
|
---|
| 605 | #endif
|
---|
[139] | 606 | #ifdef FONTCACHE_DIALOG
|
---|
| 607 | QString smplayer_version;
|
---|
| 608 | #endif
|
---|
| 609 |
|
---|
[156] | 610 |
|
---|
| 611 | /* *********
|
---|
| 612 | Update
|
---|
| 613 | ********* */
|
---|
| 614 |
|
---|
| 615 | #ifdef UPDATE_CHECKER
|
---|
| 616 | UpdateCheckerData update_checker_data;
|
---|
| 617 | #endif
|
---|
[112] | 618 | };
|
---|
[139] | 619 |
|
---|
[112] | 620 | Q_DECLARE_OPERATORS_FOR_FLAGS(Preferences::WheelFunctions)
|
---|
| 621 |
|
---|
| 622 | #endif
|
---|