| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc. All rights | 2 * Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc. All rights |
| 3 * reserved. | 3 * 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 1010 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1021 << "), nothing to load"; | 1021 << "), nothing to load"; |
| 1022 return; | 1022 return; |
| 1023 } | 1023 } |
| 1024 | 1024 |
| 1025 // 7 - Set the media element's networkState to NETWORK_LOADING. | 1025 // 7 - Set the media element's networkState to NETWORK_LOADING. |
| 1026 SetNetworkState(kNetworkLoading); | 1026 SetNetworkState(kNetworkLoading); |
| 1027 | 1027 |
| 1028 // 8 - Queue a task to fire a simple event named loadstart at the media | 1028 // 8 - Queue a task to fire a simple event named loadstart at the media |
| 1029 // element. | 1029 // element. |
| 1030 ScheduleEvent(EventTypeNames::loadstart); | 1030 ScheduleEvent(EventTypeNames::loadstart); |
| 1031 autoplay_policy_->OnLoadStarted(); |
| 1031 | 1032 |
| 1032 // 9 - Run the appropriate steps... | 1033 // 9 - Run the appropriate steps... |
| 1033 switch (mode) { | 1034 switch (mode) { |
| 1034 case kObject: | 1035 case kObject: |
| 1035 LoadSourceFromObject(); | 1036 LoadSourceFromObject(); |
| 1036 BLINK_MEDIA_LOG << "selectMediaResource(" << (void*)this | 1037 BLINK_MEDIA_LOG << "selectMediaResource(" << (void*)this |
| 1037 << ", using 'srcObject' attribute"; | 1038 << ", using 'srcObject' attribute"; |
| 1038 break; | 1039 break; |
| 1039 case kAttribute: | 1040 case kAttribute: |
| 1040 LoadSourceFromAttribute(); | 1041 LoadSourceFromAttribute(); |
| (...skipping 3050 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4091 kMostlyFillViewportBecomeStableSeconds, BLINK_FROM_HERE); | 4092 kMostlyFillViewportBecomeStableSeconds, BLINK_FROM_HERE); |
| 4092 } | 4093 } |
| 4093 | 4094 |
| 4094 void HTMLMediaElement::ViewportFillDebouncerTimerFired(TimerBase*) { | 4095 void HTMLMediaElement::ViewportFillDebouncerTimerFired(TimerBase*) { |
| 4095 mostly_filling_viewport_ = true; | 4096 mostly_filling_viewport_ = true; |
| 4096 if (web_media_player_) | 4097 if (web_media_player_) |
| 4097 web_media_player_->BecameDominantVisibleContent(mostly_filling_viewport_); | 4098 web_media_player_->BecameDominantVisibleContent(mostly_filling_viewport_); |
| 4098 } | 4099 } |
| 4099 | 4100 |
| 4100 } // namespace blink | 4101 } // namespace blink |
| OLD | NEW |