redoundo: fix Undo's indiscriminate red alert.

Summary:
if grammatically incorrect EDC file is opened, then
Undo causes error caution (with red alert) even though
there is no Undo action.

Test Plan:
1. Make incorrect EDC file. (e.g. Write "aaaa" in EDC file incorrectly)
2. Save the wrong EDC file.
3. Newly open the wrong EDC file.
4. press Undo button and it causes error caution.

Reviewers: Hermet, Jaehyun_Cho

Reviewed By: Jaehyun_Cho

Differential Revision: https://phab.enlightenment.org/D4118
This commit is contained in:
Bowon Ryu 2016-06-30 21:50:42 +09:00 committed by Jaehyun Cho
parent f0623301d9
commit f4cf6703bb
1 changed files with 2 additions and 2 deletions

View File

@ -193,8 +193,8 @@ redoundo_undo(redoundo_data *rd, Eina_Bool *changed)
if (!rd->last_diff)
{
edit_save(rd->ed, build_edc_path_get());
build_edc();
Eina_Bool saved = edit_save(rd->ed, build_edc_path_get());
if (saved) build_edc();
return 0;
}