93 void setRecordDither(const QString& s) { record_dither = s; } |
91 void setRecordDither(const QString& s) { record_dither = s; } |
94 void setRecordRate(int fps); |
92 void setRecordRate(int fps); |
95 void setRecordFile(const QString&); |
93 void setRecordFile(const QString&); |
96 void setRecordArgs(const QStringList&); |
94 void setRecordArgs(const QStringList&); |
97 void setRecording(bool on); |
95 void setRecording(bool on); |
98 bool isRecording() const { return recordTimer.isRunning(); } |
96 bool isRecording() const { return recordTimer.isActive(); } |
99 void setAutoRecord(int from, int to); |
97 void setAutoRecord(int from, int to); |
100 void setDeviceKeys(bool); |
98 void setDeviceKeys(bool); |
101 void setNetworkCacheSize(int size); |
99 void setNetworkCacheSize(int size); |
102 void addLibraryPath(const QString& lib); |
100 void addLibraryPath(const QString& lib); |
103 void addPluginPath(const QString& plugin); |
101 void addPluginPath(const QString& plugin); |
104 void setUseGL(bool use); |
102 void setUseGL(bool use); |
105 void setUseNativeFileBrowser(bool); |
103 void setUseNativeFileBrowser(bool); |
106 void updateSizeHints(); |
|
107 void setSizeToView(bool sizeToView); |
104 void setSizeToView(bool sizeToView); |
108 |
|
109 QMenuBar *menuBar() const; |
|
110 |
105 |
111 QDeclarativeView *view() const; |
106 QDeclarativeView *view() const; |
112 LoggerWidget *warningsWidget() const; |
107 LoggerWidget *warningsWidget() const; |
113 |
108 |
114 void enableExperimentalGestures(); |
109 void enableExperimentalGestures(); |
122 void toggleRecording(); |
117 void toggleRecording(); |
123 void toggleRecordingWithSelection(); |
118 void toggleRecordingWithSelection(); |
124 void ffmpegFinished(int code); |
119 void ffmpegFinished(int code); |
125 void showProxySettings (); |
120 void showProxySettings (); |
126 void proxySettingsChanged (); |
121 void proxySettingsChanged (); |
127 void toggleOrientation(); |
122 void rotateOrientation(); |
128 void statusChanged(); |
123 void statusChanged(); |
129 void setSlowMode(bool); |
124 void setSlowMode(bool); |
130 void launch(const QString &); |
125 void launch(const QString &); |
131 |
126 |
132 protected: |
127 protected: |
133 virtual void keyPressEvent(QKeyEvent *); |
128 virtual void keyPressEvent(QKeyEvent *); |
134 virtual bool event(QEvent *); |
129 virtual bool event(QEvent *); |
135 void createMenu(QMenuBar *menu, QMenu *flatmenu); |
130 void createMenu(); |
136 |
131 |
137 private slots: |
132 private slots: |
|
133 void appAboutToQuit(); |
|
134 |
138 void autoStartRecording(); |
135 void autoStartRecording(); |
139 void autoStopRecording(); |
136 void autoStopRecording(); |
140 void recordFrame(); |
137 void recordFrame(); |
141 void chooseRecordingOptions(); |
138 void chooseRecordingOptions(); |
142 void pickRecordingFile(); |
139 void pickRecordingFile(); |
143 void setPortrait(); |
|
144 void setLandscape(); |
|
145 void startNetwork(); |
|
146 void toggleFullScreen(); |
140 void toggleFullScreen(); |
|
141 void changeOrientation(QAction*); |
147 void orientationChanged(); |
142 void orientationChanged(); |
148 |
143 |
149 void showWarnings(bool show); |
144 void showWarnings(bool show); |
150 void warningsWidgetOpened(); |
145 void warningsWidgetOpened(); |
151 void warningsWidgetClosed(); |
146 void warningsWidgetClosed(); |
152 |
147 |
153 private: |
148 private: |
|
149 void updateSizeHints(bool initial = false); |
|
150 |
154 QString getVideoFileName(); |
151 QString getVideoFileName(); |
155 int menuBarHeight() const; |
|
156 |
152 |
157 LoggerWidget *loggerWindow; |
153 LoggerWidget *loggerWindow; |
158 QDeclarativeView *canvas; |
154 QDeclarativeView *canvas; |
159 QSize initialSize; |
155 QSize initialSize; |
160 QString currentFileOrUrl; |
156 QString currentFileOrUrl; |
161 QDeclarativeTimer recordTimer; |
157 QTimer recordTimer; |
162 QString frame_fmt; |
158 QString frame_fmt; |
163 QImage frame; |
159 QImage frame; |
164 QList<QImage*> frames; |
160 QList<QImage*> frames; |
165 QProcess* frame_stream; |
161 QProcess* frame_stream; |
166 QDeclarativeTimer autoStartTimer; |
162 QTimer autoStartTimer; |
167 QDeclarativeTimer autoStopTimer; |
163 QTimer autoStopTimer; |
168 QString record_dither; |
164 QString record_dither; |
169 QString record_file; |
165 QString record_file; |
170 QSize record_outsize; |
166 QSize record_outsize; |
171 QStringList record_args; |
167 QStringList record_args; |
172 int record_rate; |
168 int record_rate; |
173 int record_autotime; |
169 int record_autotime; |
174 bool devicemode; |
170 bool devicemode; |
175 QAction *recordAction; |
171 QAction *recordAction; |
176 QString currentSkin; |
172 QString currentSkin; |
177 bool scaleSkin; |
173 bool scaleSkin; |
178 mutable QMenuBar *mb; |
|
179 RecordingDialog *recdlg; |
174 RecordingDialog *recdlg; |
180 |
175 |
181 void senseImageMagick(); |
176 void senseImageMagick(); |
182 void senseFfmpeg(); |
177 void senseFfmpeg(); |
183 QWidget *ffmpegHelpWindow; |
178 QWidget *ffmpegHelpWindow; |
184 bool ffmpegAvailable; |
179 bool ffmpegAvailable; |
185 bool convertAvailable; |
180 bool convertAvailable; |
186 |
181 |
187 QAction *portraitOrientation; |
182 QActionGroup *orientation; |
188 QAction *landscapeOrientation; |
|
189 |
|
190 QAction *showWarningsWindow; |
183 QAction *showWarningsWindow; |
191 |
184 |
192 QString m_script; |
185 QString m_script; |
193 ScriptOptions m_scriptOptions; |
186 ScriptOptions m_scriptOptions; |
194 QDeclarativeTester *tester; |
187 QDeclarativeTester *tester; |