source: smplayer/trunk/src/basegui.h@ 188

Last change on this file since 188 was 188, checked in by Silvan Scherrer, 8 years ago

SMPlayer: update trunk to version 17.1.0

  • Property svn:eol-style set to LF
File size: 21.4 KB
Line 
1/* smplayer, GUI front-end for mplayer.
2 Copyright (C) 2006-2017 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 BASEGUI_H
20#define BASEGUI_H
21
22#include <QMainWindow>
23#include <QNetworkProxy>
24#include "mediadata.h"
25#include "mediasettings.h"
26#include "preferences.h"
27#include "core.h"
28#include "config.h"
29#include "guiconfig.h"
30
31#if defined(AVOID_SCREENSAVER) && !defined(Q_OS_OS2)
32#include <windows.h>
33#endif
34
35#ifdef MOUSE_GESTURES
36 #define MG_DELAYED_SEEK
37#endif
38
39//#define SHARE_MENU
40//#define DETECT_MINIMIZE_WORKAROUND
41
42#if !defined(Q_OS_WIN) && QT_VERSION >= 0x050000 && QT_VERSION < 0x050501
43#define NUMPAD_WORKAROUND
44#endif
45
46class QWidget;
47class QMenu;
48class LogWindow;
49class InfoWindow;
50class MplayerWindow;
51
52class QLabel;
53class FilePropertiesDialog;
54class VideoEqualizer;
55class AudioEqualizer;
56class Playlist;
57#ifdef FIND_SUBTITLES
58class FindSubtitlesWindow;
59#endif
60
61#ifdef VIDEOPREVIEW
62class VideoPreview;
63#endif
64
65class MyAction;
66class MyActionGroup;
67class PreferencesDialog;
68class Favorites;
69class TVList;
70class UpdateChecker;
71
72#ifdef SHARE_WIDGET
73class ShareWidget;
74#endif
75
76#ifndef SHARE_WIDGET
77#define DONATE_REMINDER
78#endif
79
80class BaseGui : public QMainWindow
81{
82 Q_OBJECT
83
84public:
85 BaseGui( QWidget* parent = 0, Qt::WindowFlags flags = 0 );
86 ~BaseGui();
87
88 /* Return true if the window shouldn't show on startup */
89 virtual bool startHidden() { return false; };
90
91 //! Execute all actions in \a actions. The actions should be
92 //! separated by spaces. Checkable actions could have a parameter:
93 //! true or false.
94 void runActions(QString actions);
95
96 //! Execute all the actions after the video has started to play
97 void runActionsLater(QString actions) { pending_actions_to_run = actions; };
98
99#ifdef LOG_SMPLAYER
100 //! Saves the line from the smplayer output
101 void recordSmplayerLog(QString line);
102#endif
103
104 Core * getCore() { return core; };
105 Playlist * getPlaylist() { return playlist; };
106
107public slots:
108 virtual void open(QString file); // Generic open, autodetect type.
109 virtual void openFile();
110 virtual void openFile(QString file);
111 virtual void openFiles(QStringList files);
112 virtual void openFavorite(QString file);
113 virtual void openURL();
114 virtual void openURL(QString url);
115 virtual void openVCD();
116 virtual void openAudioCD();
117 virtual void openDVD();
118 virtual void openDVDFromFolder();
119 virtual void openDVDFromFolder(QString directory);
120#ifdef BLURAY_SUPPORT
121 void openBluRay();
122 void openBluRayFromFolder();
123 void openBluRayFromFolder(QString directory);
124#endif
125 virtual void openDirectory();
126 virtual void openDirectory(QString directory);
127
128 virtual void helpFirstSteps();
129 virtual void helpFAQ();
130 virtual void helpCLOptions();
131 virtual void helpCheckUpdates();
132 virtual void helpDonate();
133#ifndef SHARE_ACTIONS
134 void showHelpDonateDialog(bool * accepted = 0);
135#endif
136 virtual void helpShowConfig();
137 virtual void helpAbout();
138
139#ifdef SHARE_MENU
140 virtual void shareSMPlayer();
141#endif
142
143 virtual void loadSub();
144 virtual void loadAudioFile(); // Load external audio file
145
146 void setInitialSubtitle(const QString & subtitle_file);
147
148#ifdef FIND_SUBTITLES
149 virtual void showFindSubtitlesDialog();
150 virtual void openUploadSubtitlesPage(); //turbos
151#endif
152
153#ifdef VIDEOPREVIEW
154 virtual void showVideoPreviewDialog();
155#endif
156
157#ifdef YOUTUBE_SUPPORT
158 virtual void showTubeBrowser();
159#endif
160
161 virtual void showPlaylist();
162 virtual void showPlaylist(bool b);
163 virtual void showVideoEqualizer();
164 virtual void showVideoEqualizer(bool b);
165 virtual void showAudioEqualizer();
166 virtual void showAudioEqualizer(bool b);
167#ifdef LOG_MPLAYER
168 virtual void showMplayerLog();
169#endif
170#ifdef LOG_SMPLAYER
171 virtual void showLog();
172#endif
173 virtual void showPreferencesDialog();
174 virtual void showFilePropertiesDialog();
175
176 virtual void showGotoDialog();
177 virtual void showSubDelayDialog();
178 virtual void showAudioDelayDialog();
179 virtual void showStereo3dDialog();
180#ifdef BOOKMARKS
181 virtual void showAddBookmarkDialog();
182 virtual void showBookmarkDialog();
183#endif
184
185 virtual void exitFullscreen();
186 virtual void toggleFullscreen();
187 virtual void toggleFullscreen(bool);
188
189 virtual void toggleCompactMode();
190 virtual void toggleCompactMode(bool);
191
192 void setStayOnTop(bool b);
193 virtual void changeStayOnTop(int);
194 virtual void checkStayOnTop(Core::State);
195 void toggleStayOnTop();
196
197 void setForceCloseOnFinish(int n) { arg_close_on_finish = n; };
198 int forceCloseOnFinish() { return arg_close_on_finish; };
199
200 void setForceStartInFullscreen(int n) { arg_start_in_fullscreen = n; };
201 int forceStartInFullscreen() { return arg_start_in_fullscreen; };
202
203
204protected slots:
205 virtual void closeWindow();
206
207 virtual void setJumpTexts();
208
209 // Replace for setCaption (in Qt 4 it's not virtual)
210 virtual void setWindowCaption(const QString & title);
211
212 //virtual void openRecent(int item);
213 virtual void openRecent();
214 virtual void enterFullscreenOnPlay();
215 virtual void exitFullscreenOnStop();
216 virtual void exitFullscreenIfNeeded();
217 virtual void playlistHasFinished();
218 virtual void addToPlaylistCurrentFile();
219
220 virtual void displayState(Core::State state);
221 virtual void displayMessage(QString message, int time);
222 virtual void displayMessage(QString message);
223 virtual void gotCurrentTime(double);
224
225 virtual void initializeMenus();
226 virtual void updateWidgets();
227 virtual void updateVideoEqualizer();
228 virtual void updateAudioEqualizer();
229 virtual void setDefaultValuesFromVideoEqualizer();
230 virtual void changeVideoEqualizerBySoftware(bool b);
231
232 virtual void newMediaLoaded();
233 virtual void updateMediaInfo();
234
235 void gotNoFileToPlay();
236
237 void checkPendingActionsToRun();
238
239#if REPORT_OLD_MPLAYER
240 void checkMplayerVersion();
241 void displayWarningAboutOldMplayer();
242#endif
243
244#ifdef CHECK_UPGRADED
245 void checkIfUpgraded();
246#endif
247
248#ifdef DONATE_REMINDER
249 void checkReminder();
250#endif
251
252#ifdef YOUTUBE_SUPPORT
253 void YTNoSslSupport();
254 void YTNoSignature(const QString &);
255 #ifdef YT_USE_YTSIG
256 void YTUpdateScript();
257 #endif
258#endif
259 void gotForbidden();
260
261#if AUTODISABLE_ACTIONS
262 virtual void enableActionsOnPlaying();
263 virtual void disableActionsOnStop();
264#endif
265 virtual void togglePlayAction(Core::State);
266
267 void changeSizeFactor(int factor);
268 void toggleDoubleSize();
269 void resizeMainWindow(int w, int h);
270 void resizeWindow(int w, int h);
271 virtual void hidePanel();
272 void centerWindow();
273
274 /* virtual void playlistVisibilityChanged(); */
275
276 virtual void displayGotoTime(int);
277 //! You can call this slot to jump to the specified percentage in the video, while dragging the slider.
278 virtual void goToPosOnDragging(int);
279
280 virtual void showPopupMenu();
281 virtual void showPopupMenu( QPoint p );
282 /*
283 virtual void mouseReleaseEvent( QMouseEvent * e );
284 virtual void mouseDoubleClickEvent( QMouseEvent * e );
285 */
286
287 virtual void leftClickFunction();
288 virtual void rightClickFunction();
289 virtual void doubleClickFunction();
290 virtual void middleClickFunction();
291 virtual void xbutton1ClickFunction();
292 virtual void xbutton2ClickFunction();
293 virtual void processFunction(QString function);
294
295 virtual void dragEnterEvent( QDragEnterEvent * ) ;
296 virtual void dropEvent ( QDropEvent * );
297
298 virtual void applyNewPreferences();
299 virtual void applyFileProperties();
300
301 virtual void clearRecentsList();
302
303 virtual void loadActions();
304 virtual void saveActions();
305
306 virtual void processMouseMovedDiff(QPoint diff);
307 virtual void moveWindowDiff(QPoint diff);
308#ifdef MG_DELAYED_SEEK
309 virtual void delayedSeek();
310#endif
311
312 // Single instance stuff
313#ifdef SINGLE_INSTANCE
314 void handleMessageFromOtherInstances(const QString& message);
315#endif
316
317 //! Called when core can't parse the mplayer version and there's no
318 //! version supplied by the user
319 void askForMplayerVersion(QString);
320
321 void showExitCodeFromMplayer(int exit_code);
322 void showErrorFromMplayer(QProcess::ProcessError);
323
324 // stylesheet
325#if ALLOW_CHANGE_STYLESHEET
326 virtual QString loadQss(QString filename);
327 virtual void changeStyleSheet(QString style);
328#endif
329
330 void applyStyles();
331
332 virtual void setTabletMode(bool);
333
334#if defined(Q_OS_WIN) || defined(Q_OS_OS2)
335 #ifdef Q_OS_WIN
336 void checkSystemTabletMode();
337 void systemTabletModeChanged(bool);
338 #endif
339
340 #ifdef AVOID_SCREENSAVER
341 void clear_just_stopped();
342 #endif
343#endif
344
345#ifdef LOG_MPLAYER
346 //! Clears the mplayer log
347 void clearMplayerLog();
348
349 //! Saves the line from the mplayer output
350 void recordMplayerLog(QString line);
351
352 //! Saves the mplayer log to a file every time a file is loaded
353 void autosaveMplayerLog();
354#endif
355
356signals:
357 void frameChanged(int);
358 void ABMarkersChanged(int secs_a, int secs_b);
359 void videoInfoChanged(int width, int height, double fps);
360 void timeChanged(QString time_ready_to_print);
361 void timeChanged(double current_time);
362
363 /*
364 void wheelUp();
365 void wheelDown();
366 */
367 /*
368 void doubleClicked();
369 void leftClicked();
370 void middleClicked();
371 */
372
373 //! Sent when the user wants to close the main window
374 void quitSolicited();
375
376 //! Sent when another instance requested to play a file
377 void openFileRequested();
378
379#ifdef GUI_CHANGE_ON_RUNTIME
380 void guiChanged(QString gui);
381#endif
382
383 void preferencesChanged();
384 void tabletModeChanged(bool new_mode);
385
386protected:
387 virtual void retranslateStrings();
388 virtual void changeEvent(QEvent * event);
389#ifndef DETECT_MINIMIZE_WORKAROUND
390 virtual void hideEvent( QHideEvent * );
391 virtual void showEvent( QShowEvent * );
392#else
393 virtual bool event(QEvent * e);
394 bool was_minimized;
395#endif
396
397#ifdef Q_OS_WIN
398 virtual bool winEvent ( MSG * m, long * result );
399 #if QT_VERSION >= 0x050000
400 virtual bool nativeEvent(const QByteArray &eventType, void * message, long * result);
401 #endif
402#endif
403
404#ifdef NUMPAD_WORKAROUND
405 void keyPressEvent(QKeyEvent *event);
406#endif
407
408 virtual void aboutToEnterFullscreen();
409 virtual void aboutToExitFullscreen();
410 virtual void aboutToEnterCompactMode();
411 virtual void aboutToExitCompactMode();
412
413protected:
414 void createCore();
415 void createMplayerWindow();
416 void createVideoEqualizer();
417 void createAudioEqualizer();
418 void createPlaylist();
419 void createPanel();
420 void createPreferencesDialog();
421 void createFilePropertiesDialog();
422 void setDataToFileProperties();
423
424 void createActions();
425#if AUTODISABLE_ACTIONS
426 void setActionsEnabled(bool);
427#endif
428 void createMenus();
429 virtual void populateMainMenu();
430#ifdef BOOKMARKS
431 void updateBookmarks();
432#endif
433 void updateRecents();
434 void configureDiscDevices();
435 void setupNetworkProxy();
436 /* virtual void closeEvent( QCloseEvent * e ); */
437
438protected:
439 /* virtual void wheelEvent( QWheelEvent * e ) ; */
440
441protected:
442 QWidget * panel;
443
444 // Menu File
445 MyAction * openFileAct;
446 MyAction * openDirectoryAct;
447 MyAction * openPlaylistAct;
448 MyAction * openVCDAct;
449 MyAction * openAudioCDAct;
450 MyAction * openDVDAct;
451 MyAction * openDVDFolderAct;
452#ifdef BLURAY_SUPPORT
453 MyAction * openBluRayAct;
454 MyAction * openBluRayFolderAct;
455#endif
456 MyAction * openURLAct;
457 MyAction * exitAct;
458 MyAction * clearRecentsAct;
459
460 // Menu Play
461 MyAction * playAct;
462 MyAction * playOrPauseAct;
463 MyAction * pauseAct;
464 MyAction * pauseAndStepAct;
465 MyAction * stopAct;
466 MyAction * frameStepAct;
467 MyAction * frameBackStepAct;
468 MyAction * rewind1Act;
469 MyAction * rewind2Act;
470 MyAction * rewind3Act;
471 MyAction * forward1Act;
472 MyAction * forward2Act;
473 MyAction * forward3Act;
474 MyAction * repeatAct;
475 MyAction * setAMarkerAct;
476 MyAction * setBMarkerAct;
477 MyAction * clearABMarkersAct;
478 MyAction * gotoAct;
479
480 // Menu Speed
481 MyAction * normalSpeedAct;
482 MyAction * halveSpeedAct;
483 MyAction * doubleSpeedAct;
484 MyAction * decSpeed10Act;
485 MyAction * incSpeed10Act;
486 MyAction * decSpeed4Act;
487 MyAction * incSpeed4Act;
488 MyAction * decSpeed1Act;
489 MyAction * incSpeed1Act;
490
491 // Menu Video
492 MyAction * fullscreenAct;
493 MyAction * compactAct;
494 MyAction * videoEqualizerAct;
495 MyAction * screenshotAct;
496 MyAction * screenshotsAct;
497#ifdef CAPTURE_STREAM
498 MyAction * capturingAct;
499#endif
500#ifdef VIDEOPREVIEW
501 MyAction * videoPreviewAct;
502#endif
503 MyAction * flipAct;
504 MyAction * mirrorAct;
505 MyAction * stereo3dAct;
506 MyAction * postProcessingAct;
507 MyAction * phaseAct;
508 MyAction * deblockAct;
509 MyAction * deringAct;
510 MyAction * gradfunAct;
511 MyAction * addNoiseAct;
512 MyAction * addLetterboxAct;
513 MyAction * upscaleAct;
514
515 // Menu Audio
516 MyAction * audioEqualizerAct;
517 MyAction * muteAct;
518 MyAction * decVolumeAct;
519 MyAction * incVolumeAct;
520 MyAction * decAudioDelayAct;
521 MyAction * incAudioDelayAct;
522 MyAction * audioDelayAct; // Ask for delay
523 MyAction * extrastereoAct;
524#ifdef MPLAYER_SUPPORT
525 MyAction * karaokeAct;
526#endif
527 MyAction * volnormAct;
528 MyAction * loadAudioAct;
529 MyAction * unloadAudioAct;
530
531 // Menu Subtitles
532 MyAction * loadSubsAct;
533 MyAction * unloadSubsAct;
534 MyAction * decSubDelayAct;
535 MyAction * incSubDelayAct;
536 MyAction * subDelayAct; // Ask for delay
537 MyAction * decSubPosAct;
538 MyAction * incSubPosAct;
539 MyAction * incSubStepAct;
540 MyAction * decSubStepAct;
541 MyAction * incSubScaleAct;
542 MyAction * decSubScaleAct;
543#ifdef MPV_SUPPORT
544 MyAction * seekNextSubAct;
545 MyAction * seekPrevSubAct;
546#endif
547 MyAction * useCustomSubStyleAct;
548 MyAction * useForcedSubsOnlyAct;
549 MyAction * subVisibilityAct;
550#ifdef FIND_SUBTITLES
551 MyAction * showFindSubtitlesDialogAct;
552 MyAction * openUploadSubtitlesPageAct;//turbos
553#endif
554
555 // Menu Options
556 MyAction * showPlaylistAct;
557 MyAction * showPropertiesAct;
558 MyAction * showPreferencesAct;
559#ifdef YOUTUBE_SUPPORT
560 MyAction * showTubeBrowserAct;
561#endif
562#ifdef LOG_MPLAYER
563 MyAction * showLogMplayerAct;
564#endif
565#ifdef LOG_SMPLAYER
566 MyAction * showLogSmplayerAct;
567#endif
568 MyAction * tabletModeAct;
569
570 // Menu Help
571 MyAction * showFirstStepsAct;
572 MyAction * showFAQAct;
573 MyAction * showCLOptionsAct; // Command line options
574 MyAction * showCheckUpdatesAct;
575#if defined(YOUTUBE_SUPPORT) && defined(YT_USE_YTSIG)
576 MyAction * updateYTAct;
577#endif
578 MyAction * showConfigAct;
579 MyAction * donateAct;
580 MyAction * aboutThisAct;
581
582#ifdef SHARE_MENU
583 MyAction * facebookAct;
584 MyAction * twitterAct;
585 MyAction * gmailAct;
586 MyAction * hotmailAct;
587 MyAction * yahooAct;
588#endif
589
590 // OSD
591 MyAction * incOSDScaleAct;
592 MyAction * decOSDScaleAct;
593
594 // Playlist
595 MyAction * playPrevAct;
596 MyAction * playNextAct;
597
598 // Actions not in menus
599#if !USE_MULTIPLE_SHORTCUTS
600 MyAction * decVolume2Act;
601 MyAction * incVolume2Act;
602#endif
603 MyAction * exitFullscreenAct;
604 MyAction * nextOSDAct;
605 MyAction * decContrastAct;
606 MyAction * incContrastAct;
607 MyAction * decBrightnessAct;
608 MyAction * incBrightnessAct;
609 MyAction * decHueAct;
610 MyAction * incHueAct;
611 MyAction * decSaturationAct;
612 MyAction * incSaturationAct;
613 MyAction * decGammaAct;
614 MyAction * incGammaAct;
615 MyAction * nextVideoAct;
616 MyAction * nextAudioAct;
617 MyAction * nextSubtitleAct;
618 MyAction * nextChapterAct;
619 MyAction * prevChapterAct;
620 MyAction * doubleSizeAct;
621 MyAction * resetVideoEqualizerAct;
622 MyAction * resetAudioEqualizerAct;
623 MyAction * showContextMenuAct;
624 MyAction * nextAspectAct;
625 MyAction * nextWheelFunctionAct;
626
627 MyAction * showFilenameAct;
628 MyAction * showTimeAct;
629 MyAction * toggleDeinterlaceAct;
630
631 // Moving and zoom
632 MyAction * moveUpAct;
633 MyAction * moveDownAct;
634 MyAction * moveLeftAct;
635 MyAction * moveRightAct;
636 MyAction * incZoomAct;
637 MyAction * decZoomAct;
638 MyAction * resetZoomAct;
639 MyAction * autoZoomAct;
640 MyAction * autoZoom169Act;
641 MyAction * autoZoom235Act;
642
643
644 // OSD Action Group
645 MyActionGroup * osdGroup;
646 MyAction * osdNoneAct;
647 MyAction * osdSeekAct;
648 MyAction * osdTimerAct;
649 MyAction * osdTotalAct;
650
651 // Denoise Action Group
652 MyActionGroup * denoiseGroup;
653 MyAction * denoiseNoneAct;
654 MyAction * denoiseNormalAct;
655 MyAction * denoiseSoftAct;
656
657 // Blur-sharpen group
658 MyActionGroup * unsharpGroup;
659 MyAction * unsharpNoneAct;
660 MyAction * blurAct;
661 MyAction * sharpenAct;
662
663 // Window Size Action Group
664 MyActionGroup * sizeGroup;
665 MyAction * size50;
666 MyAction * size75;
667 MyAction * size100;
668 MyAction * size125;
669 MyAction * size150;
670 MyAction * size175;
671 MyAction * size200;
672 MyAction * size300;
673 MyAction * size400;
674
675 // Deinterlace Action Group
676 MyActionGroup * deinterlaceGroup;
677 MyAction * deinterlaceNoneAct;
678 MyAction * deinterlaceL5Act;
679 MyAction * deinterlaceYadif0Act;
680 MyAction * deinterlaceYadif1Act;
681 MyAction * deinterlaceLBAct;
682 MyAction * deinterlaceKernAct;
683
684 // Aspect Action Group
685 MyActionGroup * aspectGroup;
686 MyAction * aspectDetectAct;
687 MyAction * aspectNoneAct;
688 MyAction * aspect11Act; // 1:1
689 MyAction * aspect32Act; // 3:2
690 MyAction * aspect43Act; // 4:3
691 MyAction * aspect118Act; // 11:8
692 MyAction * aspect54Act; // 5:4
693 MyAction * aspect149Act; // 14:9
694 MyAction * aspect1410Act; // 14:10
695 MyAction * aspect169Act; // 16:9
696 MyAction * aspect1610Act; // 16:10
697 MyAction * aspect235Act; // 2.35:1
698
699 // Rotate Group
700 MyActionGroup * rotateGroup;
701 MyAction * rotateNoneAct;
702 MyAction * rotateClockwiseFlipAct;
703 MyAction * rotateClockwiseAct;
704 MyAction * rotateCounterclockwiseAct;
705 MyAction * rotateCounterclockwiseFlipAct;
706
707 // Menu StayOnTop
708 MyActionGroup * onTopActionGroup;
709 MyAction * onTopAlwaysAct;
710 MyAction * onTopNeverAct;
711 MyAction * onTopWhilePlayingAct;
712 MyAction * toggleStayOnTopAct;
713
714#if USE_ADAPTER
715 // Screen Group
716 MyActionGroup * screenGroup;
717 MyAction * screenDefaultAct;
718#endif
719
720 // Closed Captions Group
721 MyActionGroup * ccGroup;
722 MyAction * ccNoneAct;
723 MyAction * ccChannel1Act;
724 MyAction * ccChannel2Act;
725 MyAction * ccChannel3Act;
726 MyAction * ccChannel4Act;
727
728 // External sub fps Group
729 MyActionGroup * subFPSGroup;
730 MyAction * subFPSNoneAct;
731 /* MyAction * subFPS23Act; */
732 MyAction * subFPS23976Act;
733 MyAction * subFPS24Act;
734 MyAction * subFPS25Act;
735 MyAction * subFPS29970Act;
736 MyAction * subFPS30Act;
737
738 // Audio Channels Action Group
739 MyActionGroup * channelsGroup;
740 /* MyAction * channelsDefaultAct; */
741 MyAction * channelsStereoAct;
742 MyAction * channelsSurroundAct;
743 MyAction * channelsFull51Act;
744 MyAction * channelsFull61Act;
745 MyAction * channelsFull71Act;
746
747 // Stereo Mode Action Group
748 MyActionGroup * stereoGroup;
749 MyAction * stereoAct;
750 MyAction * leftChannelAct;
751 MyAction * rightChannelAct;
752 MyAction * monoAct;
753 MyAction * reverseAct;
754
755 // Other groups
756#if PROGRAM_SWITCH
757 MyActionGroup * programTrackGroup;
758#endif
759 MyActionGroup * videoTrackGroup;
760 MyActionGroup * audioTrackGroup;
761 MyActionGroup * subtitleTrackGroup;
762#ifdef MPV_SUPPORT
763 MyActionGroup * secondarySubtitleTrackGroup;
764#endif
765 MyActionGroup * titleGroup;
766 MyActionGroup * chapterGroup;
767 MyActionGroup * angleGroup;
768#ifdef BOOKMARKS
769 MyActionGroup * bookmarkGroup;
770 MyAction * addBookmarkAct;
771 MyAction * editBookmarksAct;
772
773 MyAction * prevBookmarkAct;
774 MyAction * nextBookmarkAct;
775#endif
776
777#if DVDNAV_SUPPORT
778 MyAction * dvdnavUpAct;
779 MyAction * dvdnavDownAct;
780 MyAction * dvdnavLeftAct;
781 MyAction * dvdnavRightAct;
782 MyAction * dvdnavMenuAct;
783 MyAction * dvdnavSelectAct;
784 MyAction * dvdnavPrevAct;
785 MyAction * dvdnavMouseAct;
786#endif
787
788 // MENUS
789 QMenu *openMenu;
790 QMenu *playMenu;
791 QMenu *videoMenu;
792 QMenu *audioMenu;
793 QMenu *subtitlesMenu;
794 QMenu *browseMenu;
795 QMenu *viewMenu;
796 QMenu *optionsMenu;
797 QMenu *helpMenu;
798
799 QMenu * disc_menu;
800 QMenu * subtitles_track_menu;
801#ifdef MPV_SUPPORT
802 QMenu * secondary_subtitles_track_menu;
803#endif
804#if PROGRAM_SWITCH
805 QMenu * programtrack_menu;
806#endif
807 QMenu * videotrack_menu;
808 QMenu * audiotrack_menu;
809 QMenu * titles_menu;
810 QMenu * chapters_menu;
811 QMenu * angles_menu;
812#ifdef BOOKMARKS
813 QMenu * bookmark_menu;
814#endif
815 QMenu * aspect_menu;
816 QMenu * osd_menu;
817 QMenu * deinterlace_menu;
818 QMenu * denoise_menu;
819 QMenu * unsharp_menu;
820 QMenu * videosize_menu;
821 QMenu * audiochannels_menu;
822 QMenu * stereomode_menu;
823
824 QMenu * speed_menu;
825 QMenu * ab_menu; // A-B menu
826 QMenu * videofilter_menu;
827 QMenu * audiofilter_menu;
828#if defined(LOG_MPLAYER) || defined(LOG_SMPLAYER)
829 //QMenu * logs_menu;
830#endif
831 QMenu * zoom_menu;
832 QMenu * rotate_menu;
833 QMenu * ontop_menu;
834#if USE_ADAPTER
835 QMenu * screen_menu;
836#endif
837 QMenu * closed_captions_menu;
838 QMenu * subfps_menu;
839
840#ifdef SHARE_MENU
841 QMenu * share_menu;
842#endif
843
844 QMenu * popup;
845 QMenu * recentfiles_menu;
846 QMenu * access_menu;
847
848#ifdef LOG_MPLAYER
849 LogWindow * mplayer_log_window;
850#endif
851#ifdef LOG_SMPLAYER
852 LogWindow * smplayer_log_window;
853#endif
854 InfoWindow * clhelp_window;
855
856 PreferencesDialog *pref_dialog;
857 FilePropertiesDialog *file_dialog;
858 Playlist * playlist;
859 VideoEqualizer * video_equalizer;
860 AudioEqualizer * audio_equalizer;
861#ifdef FIND_SUBTITLES
862 FindSubtitlesWindow * find_subs_dialog;
863#endif
864#ifdef VIDEOPREVIEW
865 VideoPreview * video_preview;
866#endif
867
868 Core * core;
869 MplayerWindow *mplayerwindow;
870
871 Favorites * favorites;
872
873#ifdef TV_SUPPORT
874 TVList * tvlist;
875 TVList * radiolist;
876#endif
877
878#ifdef UPDATE_CHECKER
879 UpdateChecker * update_checker;
880#endif
881
882#ifdef SHARE_WIDGET
883 ShareWidget * sharewidget;
884#endif
885
886 QStringList actions_list;
887
888 QString pending_actions_to_run;
889
890 // Force settings from command line
891 int arg_close_on_finish; // -1 = not set, 1 = true, 0 = false
892 int arg_start_in_fullscreen; // -1 = not set, 1 = true, 0 = false
893
894#ifdef MG_DELAYED_SEEK
895 QTimer * delayed_seek_timer;
896 int delayed_seek_value;
897#endif
898
899private:
900 QString default_style;
901
902 // Variables to restore pos and size of the window
903 // when exiting from fullscreen mode.
904 QPoint win_pos;
905 QSize win_size;
906 bool was_maximized;
907
908#ifdef AVOID_SCREENSAVER
909 bool just_stopped;
910#endif
911
912#ifdef LOG_MPLAYER
913 QString mplayer_log;
914#endif
915#ifdef LOG_SMPLAYER
916 QString smplayer_log;
917#endif
918
919 bool ignore_show_hide_events;
920};
921
922#endif
923
Note: See TracBrowser for help on using the repository browser.