Open vinit2209 opened 10 years ago
when i set private final String sort_order = "DESC "; // ASC or DESC
Below method is not working properly. item numbers are not getting saved correctly.
public void persistChanges() { Cursor c = getCursor(); c.moveToPosition(-1); while (c.moveToNext()) { int listPos = getListPosition(c.getPosition()); if (listPos == REMOVED) { mDbHelper .deleteItemRecord(c.getInt(c.getColumnIndex("_id"))); } else if (listPos != c.getPosition()) { mDbHelper.updateItemPosition( c.getInt(c.getColumnIndex("_id")), listPos); } } }
plz correct me if i am wrong
thnks vinit
when i set private final String sort_order = "DESC "; // ASC or DESC
Below method is not working properly. item numbers are not getting saved correctly.
public void persistChanges() { Cursor c = getCursor(); c.moveToPosition(-1); while (c.moveToNext()) { int listPos = getListPosition(c.getPosition()); if (listPos == REMOVED) { mDbHelper .deleteItemRecord(c.getInt(c.getColumnIndex("_id"))); } else if (listPos != c.getPosition()) { mDbHelper.updateItemPosition( c.getInt(c.getColumnIndex("_id")), listPos); } } }
plz correct me if i am wrong
thnks vinit