Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 23cc716c authored by James Dong's avatar James Dong
Browse files

Change the signature of method addTextSource() in AwesomePlayer

o avoid a unnecessary copy constructor call

Change-Id: Ib598bbe42d42a835549e2d29502c6f196f859874
parent 9c81154d
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1360,7 +1360,7 @@ void AwesomePlayer::setAudioSource(sp<MediaSource> source) {
    mAudioTrack = source;
}

void AwesomePlayer::addTextSource(sp<MediaSource> source) {
void AwesomePlayer::addTextSource(const sp<MediaSource>& source) {
    Mutex::Autolock autoLock(mTimedTextLock);
    CHECK(source != NULL);

+1 −1
Original line number Diff line number Diff line
@@ -258,7 +258,7 @@ private:
    void setVideoSource(sp<MediaSource> source);
    status_t initVideoDecoder(uint32_t flags = 0);

    void addTextSource(sp<MediaSource> source);
    void addTextSource(const sp<MediaSource>& source);

    void onStreamDone();