Skip to content

Commit

Permalink
Fixing a bug where the TODO state is not saved
Browse files Browse the repository at this point in the history
  • Loading branch information
wizmer committed Sep 11, 2016
1 parent 90518df commit d61a773
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,8 @@ public OrgFile(String filename, ContentResolver resolver) throws OrgFileNotFound

/**
* Edit the org file on disk to incorporate new modifications
*
* @param node
* @param node: Any node from the file
* @param context: context
*/
static public void updateFile(OrgNode node, Context context) {
ContentResolver resolver = context.getContentResolver();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
import android.view.View;
import android.widget.Button;

import com.matburt.mobileorg.OrgData.OrgFile;
import com.matburt.mobileorg.OrgData.OrgNode;
import com.matburt.mobileorg.OrgData.OrgProviderUtils;
import com.matburt.mobileorg.R;
Expand Down Expand Up @@ -48,6 +49,8 @@ public void onClick(DialogInterface dialog,
if(which == 0) selectedTodo = "";
node.todo = selectedTodo;
setupTodoButton(context,node,button, false);
node.write(context);
OrgFile.updateFile(node, context);
}
});
builder.create().show();
Expand Down

0 comments on commit d61a773

Please sign in to comment.