Advertisement
Guest User

Untitled

a guest
Sep 22nd, 2014
184
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. public void checkItem(ToDoItem item) {
  2.         if (mClient == null) {
  3.             return;
  4.         }
  5.  
  6.         // Ustawienie flagi 'completed' i aktualizacja tabeli
  7.         item.setComplete(true);
  8.        
  9.         mToDoTable.update(item, new TableOperationCallback<ToDoItem>() {
  10.  
  11.             public void onCompleted(ToDoItem entity, Exception exception, ServiceFilterResponse response) {
  12.                 if (exception == null) {
  13.                     if (entity.isComplete()) {
  14.                         mAdapter.remove(entity);
  15.                     }
  16.                 } else {
  17.                     createAndShowDialog(exception, "Error");
  18.                 }
  19.             }
  20.  
  21.         });
  22.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement