Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(406)

Side by Side Diff: Source/core/html/shadow/MediaControls.h

Issue 212173002: Media controls should fade out after a while regardless of mouse position (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: "Patchset 3" Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | Source/core/html/shadow/MediaControls.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011, 2012 Apple Inc. All rights reserved. 2 * Copyright (C) 2011, 2012 Apple Inc. All rights reserved.
3 * Copyright (C) 2011, 2012 Google Inc. All rights reserved. 3 * Copyright (C) 2011, 2012 Google Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 private: 69 private:
70 explicit MediaControls(HTMLMediaElement&); 70 explicit MediaControls(HTMLMediaElement&);
71 71
72 bool initializeControls(); 72 bool initializeControls();
73 73
74 void makeOpaque(); 74 void makeOpaque();
75 void makeTransparent(); 75 void makeTransparent();
76 76
77 void updatePlayState(); 77 void updatePlayState();
78 78
79 bool shouldHideFullscreenControls(); 79 bool shouldHideMediaControls();
80 void hideFullscreenControlsTimerFired(Timer<MediaControls>*); 80 void hideMediaControlsTimerFired(Timer<MediaControls>*);
81 void startHideFullscreenControlsTimer(); 81 void startHideMediaControlsTimer();
82 void stopHideFullscreenControlsTimer(); 82 void stopHideMediaControlsTimer();
83 83
84 void createTextTrackDisplay(); 84 void createTextTrackDisplay();
85 void showTextTrackDisplay(); 85 void showTextTrackDisplay();
86 void hideTextTrackDisplay(); 86 void hideTextTrackDisplay();
87 87
88 // Node 88 // Node
89 virtual bool isMediaControls() const OVERRIDE { return true; } 89 virtual bool isMediaControls() const OVERRIDE { return true; }
90 virtual bool willRespondToMouseMoveEvents() OVERRIDE { return true; } 90 virtual bool willRespondToMouseMoveEvents() OVERRIDE { return true; }
91 virtual void defaultEventHandler(Event*) OVERRIDE; 91 virtual void defaultEventHandler(Event*) OVERRIDE;
92 bool containsRelatedTarget(Event*); 92 bool containsRelatedTarget(Event*);
(...skipping 15 matching lines...) Expand all
108 MediaControlPlayButtonElement* m_playButton; 108 MediaControlPlayButtonElement* m_playButton;
109 MediaControlCurrentTimeDisplayElement* m_currentTimeDisplay; 109 MediaControlCurrentTimeDisplayElement* m_currentTimeDisplay;
110 MediaControlTimelineElement* m_timeline; 110 MediaControlTimelineElement* m_timeline;
111 MediaControlMuteButtonElement* m_muteButton; 111 MediaControlMuteButtonElement* m_muteButton;
112 MediaControlVolumeSliderElement* m_volumeSlider; 112 MediaControlVolumeSliderElement* m_volumeSlider;
113 MediaControlToggleClosedCaptionsButtonElement* m_toggleClosedCaptionsButton; 113 MediaControlToggleClosedCaptionsButtonElement* m_toggleClosedCaptionsButton;
114 MediaControlFullscreenButtonElement* m_fullScreenButton; 114 MediaControlFullscreenButtonElement* m_fullScreenButton;
115 MediaControlTimeRemainingDisplayElement* m_durationDisplay; 115 MediaControlTimeRemainingDisplayElement* m_durationDisplay;
116 MediaControlPanelEnclosureElement* m_enclosure; 116 MediaControlPanelEnclosureElement* m_enclosure;
117 117
118 Timer<MediaControls> m_hideFullscreenControlsTimer; 118 Timer<MediaControls> m_hideMediaControlsTimer;
119 bool m_isFullscreen : 1;
120 bool m_isMouseOverControls : 1; 119 bool m_isMouseOverControls : 1;
121 bool m_isPausedForScrubbing : 1; 120 bool m_isPausedForScrubbing : 1;
122 }; 121 };
123 122
124 DEFINE_ELEMENT_TYPE_CASTS(MediaControls, isMediaControls()); 123 DEFINE_ELEMENT_TYPE_CASTS(MediaControls, isMediaControls());
125 124
126 } 125 }
127 126
128 #endif 127 #endif
OLDNEW
« no previous file with comments | « no previous file | Source/core/html/shadow/MediaControls.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698