summaryrefslogtreecommitdiffstats
path: root/shemov.h
blob: 13ec741e394dd5265092e69a5c0fd84ca3076071 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
/*
  This program 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.
*/

#ifndef SHEMOV_H
#define SHEMOV_H

#include <QMainWindow>
#include <QVariant>

class QTabWidget;
class QLabel;
class QActionGroup;
class NewMovieWizard;
class PicturesWidget;
class SmTreeModel;
class SmTreeView;
class NewPicsDialog;
class ArchiveView;
class ArchiveBrowser;
class SearchDialog;
class RandomTab;
class FSWidget;
class MovieWidget;

class SheMov : public QMainWindow {
	Q_OBJECT
	public:
		SheMov(QWidget *parent = 0, Qt::WindowFlags flags = 0);
        enum TabNum { FileManager = 0, Movies = 1, Pictures = 2, ArchiveBrowserTab = 3, RandomDisp = 4 };
		virtual ~SheMov() {}

	protected:
		virtual void closeEvent(QCloseEvent *event);

	private slots:
        void updateSelectedCount(int count);
		void statusbarMessage(const QString &message);
		void configure();
		void tabChanged(int newTab);
		void setFsFree();
		void aboutShemov();
		void showStatistics();
		void setSize(qint64 size);
        void setDuration(qint64 dur, bool maybeMore);
		void checkConsistency();
		void toggleHover(QObject *object);
        void analyzeActors();
        void analyzeGenres();
        void analyzeSeries();
        void analyzeParts();

	signals:
		void configChanged();

	private:
		void createStatusbar();
		void createMenus();
		void createOpenWithMenuFS();
		void writeSettings();
        void readSettings();
        void createPalette();

		//Statusbar Items
        QLabel *mSelectedDuration;
		QLabel *mSelectedItems;
		QLabel *mSelectedSize;
		QLabel *mFsFree;

		//Actions
        QAction *mQuitA;
		QAction *mConfigA;
		QAction *mAboutShemovA;
		QAction *mAboutQtA;
		QAction *mStatisticsA;
		QAction *mConsistencyA;

        //DB analyze actions
        QAction *mAnalyzeActorsA;
        QAction *mAnalyzeGenresA;
        QAction *mAnalyzeSeriesA;
        QAction *mAnalyzePartsA;

		//widgets + dialogs
		QTabWidget *mTab;
        SearchDialog *mSearchDialog;
        PicturesWidget *mPicWidget;
        ArchiveBrowser *mArchiveBrowser;
        RandomTab *mRandomTab;
        FSWidget* mFileWidget; //rename me!
        MovieWidget *mMovieWidget;
};
#endif