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

Side by Side Diff: third_party/WebKit/Source/core/html/shadow/MediaControls.cpp

Issue 2222163005: Updating media controls to give fullscreen button highest priority (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed comment Created 4 years, 4 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 | « third_party/WebKit/LayoutTests/media/video-controls-fullscreen.js ('k') | no next file » | 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 671 matching lines...) Expand 10 before | Expand all | Expand 10 after
682 // Hide all controls that don't fit, and show the ones that do. 682 // Hide all controls that don't fit, and show the ones that do.
683 // This might be better suited for a layout, but since JS media controls 683 // This might be better suited for a layout, but since JS media controls
684 // won't benefit from that anwyay, we just do it here like JS will. 684 // won't benefit from that anwyay, we just do it here like JS will.
685 685
686 if (!RuntimeEnabledFeatures::newMediaPlaybackUiEnabled()) 686 if (!RuntimeEnabledFeatures::newMediaPlaybackUiEnabled())
687 return; 687 return;
688 688
689 // Controls that we'll hide / show, in order of decreasing priority. 689 // Controls that we'll hide / show, in order of decreasing priority.
690 MediaControlElement* elements[] = { 690 MediaControlElement* elements[] = {
691 // Exclude m_playButton; we handle it specially. 691 // Exclude m_playButton; we handle it specially.
692 m_fullScreenButton.get(),
692 m_toggleClosedCaptionsButton.get(), 693 m_toggleClosedCaptionsButton.get(),
693 m_fullScreenButton.get(),
694 m_timeline.get(), 694 m_timeline.get(),
695 m_currentTimeDisplay.get(), 695 m_currentTimeDisplay.get(),
696 m_volumeSlider.get(), 696 m_volumeSlider.get(),
697 m_castButton.get(), 697 m_castButton.get(),
698 m_muteButton.get(), 698 m_muteButton.get(),
699 m_durationDisplay.get(), 699 m_durationDisplay.get(),
700 }; 700 };
701 701
702 int usedWidth = 0; 702 int usedWidth = 0;
703 703
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
799 visitor->trace(m_fullScreenButton); 799 visitor->trace(m_fullScreenButton);
800 visitor->trace(m_durationDisplay); 800 visitor->trace(m_durationDisplay);
801 visitor->trace(m_enclosure); 801 visitor->trace(m_enclosure);
802 visitor->trace(m_textTrackList); 802 visitor->trace(m_textTrackList);
803 visitor->trace(m_castButton); 803 visitor->trace(m_castButton);
804 visitor->trace(m_overlayCastButton); 804 visitor->trace(m_overlayCastButton);
805 HTMLDivElement::trace(visitor); 805 HTMLDivElement::trace(visitor);
806 } 806 }
807 807
808 } // namespace blink 808 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/media/video-controls-fullscreen.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698