From: Daniel Date: Fri, 2 Apr 2021 14:16:57 +0000 (-0400) Subject: checking and unchecking subtask done X-Git-Url: https://git.danieliu.xyz/?a=commitdiff_plain;h=2b4885a41163276393cd0fa6eff11e86c613294d;p=taskasaur.git checking and unchecking subtask done --- diff --git a/taskasaur.c b/taskasaur.c index d091e55..3d787e6 100644 --- a/taskasaur.c +++ b/taskasaur.c @@ -202,6 +202,10 @@ popup_handleinput(BoardMenu* boardmenu, int ch) break; case BINDING_TOGGLE_DONE: + { + SubTask* curitem_data = (SubTask*)get_menuitem_userdata(get_menu_item(popupmenu_menu, get_selected_item(popupmenu_menu))); + curitem_data->done = (curitem_data->done == SubTaskState_todo) ? SubTaskState_done : SubTaskState_todo; + } break;