summaryrefslogtreecommitdiffstats
path: root/media/player/view.h
diff options
context:
space:
mode:
authorfbarchard@chromium.org <fbarchard@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-05 18:31:35 +0000
committerfbarchard@chromium.org <fbarchard@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-05 18:31:35 +0000
commit2f31e009401121b71f03cc233aa2e6b360697fdb (patch)
treece91dedea61036dcbd758089125f69eef95805b1 /media/player/view.h
parent28c47ee963812e92e2eb921ed1778f5db74041bc (diff)
downloadchromium_src-2f31e009401121b71f03cc233aa2e6b360697fdb.zip
chromium_src-2f31e009401121b71f03cc233aa2e6b360697fdb.tar.gz
chromium_src-2f31e009401121b71f03cc233aa2e6b360697fdb.tar.bz2
Media Player mainfrm.h
This module contains all event handling for menus in the Media Player. The implementation is WTL (Windows Template Library) based. The main menu is: File Edit View Play Options Help File opens/closes movies and has print features. Edit has copy/paste features. View has spatial controls, such as scaling, and tool and status bars and a properties dialogue box. Play has temporal controls, such as play speed and pause. Options controls details such as Audio and Video on/off. Help is just an about box. Right clicking brings up a context menu with edit and view items. A tool bar exposes the most common menu items as buttons. Hotkeys (accelerators) are mapped to most menu items. A .RC file is used to edit the menus using the resource editor in visual studio. Dialogue boxes are each handled by a different .h. ie props.h for properties. Mainfrm.h does some minor dialogue boxes directly, such as the file selector and alert boxes for errors. Review URL: http://codereview.chromium.org/99087 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15311 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'media/player/view.h')
-rw-r--r--media/player/view.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/media/player/view.h b/media/player/view.h
index 6d36c92..4c72512 100644
--- a/media/player/view.h
+++ b/media/player/view.h
@@ -27,6 +27,7 @@
#include "media/base/filters.h"
#include "media/base/yuv_convert.h"
#include "media/base/yuv_scale.h"
+#include "media/player/movie.h"
#include "media/player/wtl_renderer.h"
#ifdef TESTING
@@ -40,10 +41,6 @@ static inline double GetTime() {
}
#endif
-extern bool g_enableswscaler;
-extern bool g_enabledraw;
-extern bool g_enabledump_yuv_file;
-
class WtlVideoWindow : public CScrollWindowImpl<WtlVideoWindow> {
public:
DECLARE_WND_CLASS_EX(NULL, 0, -1)
@@ -182,7 +179,8 @@ class WtlVideoWindow : public CScrollWindowImpl<WtlVideoWindow> {
}
// Append each frame to end of file.
- if (g_enabledump_yuv_file) {
+ bool enable_dump_yuv_file = media::Movie::get()->GetDumpYuvFileEnable();
+ if (enable_dump_yuv_file) {
DumpYUV(frame_in);
}
@@ -191,8 +189,10 @@ class WtlVideoWindow : public CScrollWindowImpl<WtlVideoWindow> {
double yuvtimestart = GetTime(); // Start timer.
#endif
- if (g_enabledraw) {
- if (g_enableswscaler) {
+ bool enable_draw = media::Movie::get()->GetDrawEnable();
+ if (enable_draw) {
+ bool enable_swscaler = media::Movie::get()->GetSwscalerEnable();
+ if (enable_swscaler) {
uint8* data_out[3];
int stride_out[3];
data_out[0] = movie_dib_bits;