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

Side by Side Diff: content/renderer/media/android/webmediaplayer_android.cc

Issue 1747593002: Change the type for byte counts to size_t in WebMediaPlayer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Made changes in the unittests Created 4 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "content/renderer/media/android/webmediaplayer_android.h" 5 #include "content/renderer/media/android/webmediaplayer_android.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <limits> 9 #include <limits>
10 10
(...skipping 768 matching lines...) Expand 10 before | Expand all | Expand 10 after
779 return 0; 779 return 0;
780 } 780 }
781 781
782 unsigned WebMediaPlayerAndroid::droppedFrameCount() const { 782 unsigned WebMediaPlayerAndroid::droppedFrameCount() const {
783 if (media_source_delegate_) 783 if (media_source_delegate_)
784 return media_source_delegate_->DroppedFrameCount(); 784 return media_source_delegate_->DroppedFrameCount();
785 NOTIMPLEMENTED(); 785 NOTIMPLEMENTED();
786 return 0; 786 return 0;
787 } 787 }
788 788
789 unsigned WebMediaPlayerAndroid::audioDecodedByteCount() const { 789 size_t WebMediaPlayerAndroid::audioDecodedByteCount() const {
790 if (media_source_delegate_) 790 if (media_source_delegate_)
791 return media_source_delegate_->AudioDecodedByteCount(); 791 return media_source_delegate_->AudioDecodedByteCount();
792 NOTIMPLEMENTED(); 792 NOTIMPLEMENTED();
793 return 0; 793 return 0;
794 } 794 }
795 795
796 unsigned WebMediaPlayerAndroid::videoDecodedByteCount() const { 796 size_t WebMediaPlayerAndroid::videoDecodedByteCount() const {
797 if (media_source_delegate_) 797 if (media_source_delegate_)
798 return media_source_delegate_->VideoDecodedByteCount(); 798 return media_source_delegate_->VideoDecodedByteCount();
799 NOTIMPLEMENTED(); 799 NOTIMPLEMENTED();
800 return 0; 800 return 0;
801 } 801 }
802 802
803 void WebMediaPlayerAndroid::OnMediaMetadataChanged( 803 void WebMediaPlayerAndroid::OnMediaMetadataChanged(
804 base::TimeDelta duration, int width, int height, bool success) { 804 base::TimeDelta duration, int width, int height, bool success) {
805 DCHECK(main_thread_checker_.CalledOnValidThread()); 805 DCHECK(main_thread_checker_.CalledOnValidThread());
806 bool need_to_signal_duration_changed = false; 806 bool need_to_signal_duration_changed = false;
(...skipping 850 matching lines...) Expand 10 before | Expand all | Expand 10 after
1657 result = PREDICTION_RESULT_PATH_BASED_WAS_BETTER; 1657 result = PREDICTION_RESULT_PATH_BASED_WAS_BETTER;
1658 } else if (is_hls_url == is_hls) { 1658 } else if (is_hls_url == is_hls) {
1659 result = PREDICTION_RESULT_URL_BASED_WAS_BETTER; 1659 result = PREDICTION_RESULT_URL_BASED_WAS_BETTER;
1660 } 1660 }
1661 UMA_HISTOGRAM_ENUMERATION( 1661 UMA_HISTOGRAM_ENUMERATION(
1662 "Media.Android.IsHttpLiveStreamingMediaPredictionResult", 1662 "Media.Android.IsHttpLiveStreamingMediaPredictionResult",
1663 result, PREDICTION_RESULT_MAX); 1663 result, PREDICTION_RESULT_MAX);
1664 } 1664 }
1665 1665
1666 } // namespace content 1666 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698