efl_ui_image : Avoid integral division

Summary:
Assigning a result of integral division to a double type variable
is not useful for division calculation.

Test Plan: N/A

Reviewers: Hermet, YOhoho

Reviewed By: YOhoho

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D11344
This commit is contained in:
junsu choi 2020-02-14 16:26:52 +09:00
parent 3ce052d9ec
commit 2ba77c0a33
2 changed files with 2 additions and 2 deletions

View File

@ -1860,7 +1860,7 @@ _efl_ui_image_efl_player_playback_progress_get(const Eo *obj EINA_UNUSED, Efl_Ui
if (sd->edje)
efl_player_playback_progress_get(sd->img);
else if (sd->frame_count > 1)
return sd->cur_frame / (sd->frame_count - 1);
return (double)sd->cur_frame / ((double)sd->frame_count - 1.0);
return 0.0;
}

View File

@ -3153,7 +3153,7 @@ _efl_ui_image_zoomable_efl_player_playback_progress_get(const Eo *obj EINA_UNUSE
if (sd->edje)
efl_player_playback_progress_get(sd->edje);
else if (sd->frame_count > 1)
return sd->cur_frame / (sd->frame_count - 1);
return (double)sd->cur_frame / ((double)sd->frame_count - 1.0);
return 0.0;
}