popup: enable to set last_button_number to 0

Summary:
If last added button is removed, any statements to set last_button_number in for loop doesn't be executed.
So last button number has previous value, not 0.
Because of that, action area is not removed, but that area has zero height, so it doesn't be shown.

@fix

Reviewers: herb, jpeg, cedric, singh.amitesh, raster

Reviewed By: jpeg

Subscribers: woohyun

Differential Revision: https://phab.enlightenment.org/D4870
This commit is contained in:
JinYong Park 2017-05-12 14:57:01 +09:00 committed by Jean-Philippe Andre
parent 226c1cff82
commit 9df3685884
1 changed files with 2 additions and 0 deletions

View File

@ -613,6 +613,8 @@ _button_remove(Evas_Object *obj,
ELM_SAFE_FREE(sd->buttons[pos], free);
sd->last_button_number = 0;
for (i = ELM_POPUP_ACTION_BUTTON_MAX - 1; i >= 0; i--)
{
if (sd->buttons[i])