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

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

Issue 2773113002: Fix an issue when media controls never hide after certain tap sequence (Closed)
Patch Set: Created 3 years, 9 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 | 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 695 matching lines...) Expand 10 before | Expand all | Expand 10 after
706 return; 706 return;
707 707
708 if (!containsRelatedTarget(event)) { 708 if (!containsRelatedTarget(event)) {
709 if (!mediaElement().paused()) { 709 if (!mediaElement().paused()) {
710 if (!isVisible()) { 710 if (!isVisible()) {
711 makeOpaque(); 711 makeOpaque();
712 // When the panel switches from invisible to visible, we need to mark 712 // When the panel switches from invisible to visible, we need to mark
713 // the event handled to avoid buttons below the tap to be activated. 713 // the event handled to avoid buttons below the tap to be activated.
714 event->setDefaultHandled(); 714 event->setDefaultHandled();
715 } 715 }
716 if (shouldHideMediaControls(IgnoreWaitForTimer)) { 716 // TODO(zqzhang): temporary workaround to fix an issue on Android where
717 // the controls panel is always hovered after certain tap sequence.
718 if (shouldHideMediaControls(IgnoreWaitForTimer | IgnoreControlsHover |
719 IgnoreVideoHover)) {
717 m_keepShowingUntilTimerFires = true; 720 m_keepShowingUntilTimerFires = true;
718 startHideMediaControlsTimer(); 721 startHideMediaControlsTimer();
719 } 722 }
720 } 723 }
721 } 724 }
722 725
723 return; 726 return;
724 } 727 }
725 728
726 if (event->type() == EventTypeNames::mouseover) { 729 if (event->type() == EventTypeNames::mouseover) {
(...skipping 373 matching lines...) Expand 10 before | Expand all | Expand 10 after
1100 visitor->trace(m_overflowList); 1103 visitor->trace(m_overflowList);
1101 visitor->trace(m_castButton); 1104 visitor->trace(m_castButton);
1102 visitor->trace(m_overlayCastButton); 1105 visitor->trace(m_overlayCastButton);
1103 visitor->trace(m_mediaEventListener); 1106 visitor->trace(m_mediaEventListener);
1104 visitor->trace(m_windowEventListener); 1107 visitor->trace(m_windowEventListener);
1105 visitor->trace(m_orientationLockDelegate); 1108 visitor->trace(m_orientationLockDelegate);
1106 HTMLDivElement::trace(visitor); 1109 HTMLDivElement::trace(visitor);
1107 } 1110 }
1108 1111
1109 } // namespace blink 1112 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698