Commit 5ba518fb authored by Canek Peláez's avatar Canek Peláez
Browse files

Media: Return 0.0 completion when it hasn't started.

parent fb416152
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -35,7 +35,7 @@ namespace MLM {
        /**
         * Whether the media is working.
         */
        public bool working { get; protected set; }
        public bool working { public get; protected set; }

        /**
         * Initializes the media.
@@ -70,9 +70,9 @@ namespace MLM {
            position = -1;

            if (!pipe.query_duration(Gst.Format.TIME, out duration))
                return -1;
                return 0.0;
            if (!pipe.query_position(Gst.Format.TIME, out position))
                return -1;
                return 0.0;

            return (double)position/duration;
        }