| OLD | NEW |
| 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 574 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 585 | 585 |
| 586 if (!shouldHideMediaControls(behaviorFlags)) | 586 if (!shouldHideMediaControls(behaviorFlags)) |
| 587 return; | 587 return; |
| 588 | 588 |
| 589 makeTransparent(); | 589 makeTransparent(); |
| 590 m_overlayCastButton->setIsWanted(false); | 590 m_overlayCastButton->setIsWanted(false); |
| 591 } | 591 } |
| 592 | 592 |
| 593 void MediaControls::startHideMediaControlsTimer() | 593 void MediaControls::startHideMediaControlsTimer() |
| 594 { | 594 { |
| 595 m_hideMediaControlsTimer.startOneShot(timeWithoutMouseMovementBeforeHidingMe
diaControls, FROM_HERE); | 595 m_hideMediaControlsTimer.startOneShot(timeWithoutMouseMovementBeforeHidingMe
diaControls, BLINK_FROM_HERE); |
| 596 } | 596 } |
| 597 | 597 |
| 598 void MediaControls::stopHideMediaControlsTimer() | 598 void MediaControls::stopHideMediaControlsTimer() |
| 599 { | 599 { |
| 600 m_hideMediaControlsTimer.stop(); | 600 m_hideMediaControlsTimer.stop(); |
| 601 } | 601 } |
| 602 | 602 |
| 603 void MediaControls::resetHideMediaControlsTimer() | 603 void MediaControls::resetHideMediaControlsTimer() |
| 604 { | 604 { |
| 605 stopHideMediaControlsTimer(); | 605 stopHideMediaControlsTimer(); |
| (...skipping 25 matching lines...) Expand all Loading... |
| 631 if (!RuntimeEnabledFeatures::newMediaPlaybackUiEnabled()) | 631 if (!RuntimeEnabledFeatures::newMediaPlaybackUiEnabled()) |
| 632 return; | 632 return; |
| 633 | 633 |
| 634 m_panelWidth = panelWidth; | 634 m_panelWidth = panelWidth; |
| 635 | 635 |
| 636 // Adjust for effective zoom. | 636 // Adjust for effective zoom. |
| 637 if (!m_panel->layoutObject() || !m_panel->layoutObject()->style()) | 637 if (!m_panel->layoutObject() || !m_panel->layoutObject()->style()) |
| 638 return; | 638 return; |
| 639 m_panelWidth = ceil(m_panelWidth / m_panel->layoutObject()->style()->effecti
veZoom()); | 639 m_panelWidth = ceil(m_panelWidth / m_panel->layoutObject()->style()->effecti
veZoom()); |
| 640 | 640 |
| 641 m_panelWidthChangedTimer.startOneShot(0, FROM_HERE); | 641 m_panelWidthChangedTimer.startOneShot(0, BLINK_FROM_HERE); |
| 642 } | 642 } |
| 643 | 643 |
| 644 void MediaControls::panelWidthChangedTimerFired(Timer<MediaControls>*) | 644 void MediaControls::panelWidthChangedTimerFired(Timer<MediaControls>*) |
| 645 { | 645 { |
| 646 computeWhichControlsFit(); | 646 computeWhichControlsFit(); |
| 647 } | 647 } |
| 648 | 648 |
| 649 void MediaControls::computeWhichControlsFit() | 649 void MediaControls::computeWhichControlsFit() |
| 650 { | 650 { |
| 651 // Hide all controls that don't fit, and show the ones that do. | 651 // Hide all controls that don't fit, and show the ones that do. |
| (...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 723 visitor->trace(m_toggleClosedCaptionsButton); | 723 visitor->trace(m_toggleClosedCaptionsButton); |
| 724 visitor->trace(m_fullScreenButton); | 724 visitor->trace(m_fullScreenButton); |
| 725 visitor->trace(m_durationDisplay); | 725 visitor->trace(m_durationDisplay); |
| 726 visitor->trace(m_enclosure); | 726 visitor->trace(m_enclosure); |
| 727 visitor->trace(m_castButton); | 727 visitor->trace(m_castButton); |
| 728 visitor->trace(m_overlayCastButton); | 728 visitor->trace(m_overlayCastButton); |
| 729 HTMLDivElement::trace(visitor); | 729 HTMLDivElement::trace(visitor); |
| 730 } | 730 } |
| 731 | 731 |
| 732 } | 732 } |
| OLD | NEW |