OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/chromeos/media/media_player.h" | 5 #include "chrome/browser/chromeos/media/media_player.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "base/memory/singleton.h" | 9 #include "base/memory/singleton.h" |
10 #include "base/memory/weak_ptr.h" | 10 #include "base/memory/weak_ptr.h" |
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
170 pending_playback_request_ = false; | 170 pending_playback_request_ = false; |
171 return result; | 171 return result; |
172 } | 172 } |
173 | 173 |
174 void MediaPlayer::SetPlaybackRequest() { | 174 void MediaPlayer::SetPlaybackRequest() { |
175 pending_playback_request_ = true; | 175 pending_playback_request_ = true; |
176 } | 176 } |
177 | 177 |
178 void MediaPlayer::ToggleFullscreen() { | 178 void MediaPlayer::ToggleFullscreen() { |
179 if (mediaplayer_browser_) { | 179 if (mediaplayer_browser_) { |
180 mediaplayer_browser_->ToggleFullscreenMode(); | 180 mediaplayer_browser_->ToggleFullscreenMode(false); |
181 } | 181 } |
182 } | 182 } |
183 | 183 |
184 void MediaPlayer::PopupPlaylist(Browser* creator) { | 184 void MediaPlayer::PopupPlaylist(Browser* creator) { |
185 if (playlist_browser_) | 185 if (playlist_browser_) |
186 return; // Already opened. | 186 return; // Already opened. |
187 | 187 |
188 Profile* profile = BrowserList::GetLastActive()->profile(); | 188 Profile* profile = BrowserList::GetLastActive()->profile(); |
189 playlist_browser_ = Browser::CreateForApp(Browser::TYPE_PANEL, | 189 playlist_browser_ = Browser::CreateForApp(Browser::TYPE_PANEL, |
190 kMediaPlayerAppName, | 190 kMediaPlayerAppName, |
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
294 | 294 |
295 MediaPlayer::MediaPlayer() | 295 MediaPlayer::MediaPlayer() |
296 : current_position_(0), | 296 : current_position_(0), |
297 pending_playback_request_(false), | 297 pending_playback_request_(false), |
298 playlist_browser_(NULL), | 298 playlist_browser_(NULL), |
299 mediaplayer_browser_(NULL) { | 299 mediaplayer_browser_(NULL) { |
300 for (size_t i = 0; i < arraysize(supported_mime_type_list); ++i) { | 300 for (size_t i = 0; i < arraysize(supported_mime_type_list); ++i) { |
301 supported_mime_types_.insert(supported_mime_type_list[i]); | 301 supported_mime_types_.insert(supported_mime_type_list[i]); |
302 } | 302 } |
303 }; | 303 }; |
OLD | NEW |