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

Commit 4eb7a983 authored by Basavapatna Dattaguru's avatar Basavapatna Dattaguru
Browse files

VideoEditor: Fixes Issue ID:3448077

Updated with review comments. checks width & height

Change-Id: I79bd28862f511e7653e7e7a63c88772834ee6559
parent c53349f6
Loading
Loading
Loading
Loading
+7 −0
Original line number Original line Diff line number Diff line
@@ -53,6 +53,13 @@ public class EffectKenBurns extends Effect {
                         Rect endRect, long startTimeMs, long durationMs) {
                         Rect endRect, long startTimeMs, long durationMs) {
        super(mediaItem, effectId, startTimeMs, durationMs);
        super(mediaItem, effectId, startTimeMs, durationMs);


        if ( (startRect.width() <= 0) || (startRect.height() <= 0) ) {
            throw new IllegalArgumentException("Invalid Start rectangle");
        }
        if ( (endRect.width() <= 0) || (endRect.height() <= 0) ) {
            throw new IllegalArgumentException("Invalid End rectangle");
        }

        mStartRect = startRect;
        mStartRect = startRect;
        mEndRect = endRect;
        mEndRect = endRect;
    }
    }