• Home
  • Raw
  • Download

Lines Matching refs:c

354         private int copyFromCursor(SQLiteDatabase db, Cursor c) {  in copyFromCursor()  argument
355 final int idIndex = c.getColumnIndexOrThrow(LauncherSettings.Favorites._ID); in copyFromCursor()
356 final int intentIndex = c.getColumnIndexOrThrow(LauncherSettings.Favorites.INTENT); in copyFromCursor()
357 final int titleIndex = c.getColumnIndexOrThrow(LauncherSettings.Favorites.TITLE); in copyFromCursor()
358 final int iconTypeIndex = c.getColumnIndexOrThrow(LauncherSettings.Favorites.ICON_TYPE); in copyFromCursor()
359 final int iconIndex = c.getColumnIndexOrThrow(LauncherSettings.Favorites.ICON); in copyFromCursor()
360 … final int iconPackageIndex = c.getColumnIndexOrThrow(LauncherSettings.Favorites.ICON_PACKAGE); in copyFromCursor()
361 … final int iconResourceIndex = c.getColumnIndexOrThrow(LauncherSettings.Favorites.ICON_RESOURCE); in copyFromCursor()
362 … final int containerIndex = c.getColumnIndexOrThrow(LauncherSettings.Favorites.CONTAINER); in copyFromCursor()
363 final int itemTypeIndex = c.getColumnIndexOrThrow(LauncherSettings.Favorites.ITEM_TYPE); in copyFromCursor()
364 final int screenIndex = c.getColumnIndexOrThrow(LauncherSettings.Favorites.SCREEN); in copyFromCursor()
365 final int cellXIndex = c.getColumnIndexOrThrow(LauncherSettings.Favorites.CELLX); in copyFromCursor()
366 final int cellYIndex = c.getColumnIndexOrThrow(LauncherSettings.Favorites.CELLY); in copyFromCursor()
367 final int uriIndex = c.getColumnIndexOrThrow(LauncherSettings.Favorites.URI); in copyFromCursor()
368 … final int displayModeIndex = c.getColumnIndexOrThrow(LauncherSettings.Favorites.DISPLAY_MODE); in copyFromCursor()
370 ContentValues[] rows = new ContentValues[c.getCount()]; in copyFromCursor()
372 while (c.moveToNext()) { in copyFromCursor()
373 ContentValues values = new ContentValues(c.getColumnCount()); in copyFromCursor()
374 values.put(LauncherSettings.Favorites._ID, c.getLong(idIndex)); in copyFromCursor()
375 values.put(LauncherSettings.Favorites.INTENT, c.getString(intentIndex)); in copyFromCursor()
376 values.put(LauncherSettings.Favorites.TITLE, c.getString(titleIndex)); in copyFromCursor()
377 values.put(LauncherSettings.Favorites.ICON_TYPE, c.getInt(iconTypeIndex)); in copyFromCursor()
378 values.put(LauncherSettings.Favorites.ICON, c.getBlob(iconIndex)); in copyFromCursor()
379 values.put(LauncherSettings.Favorites.ICON_PACKAGE, c.getString(iconPackageIndex)); in copyFromCursor()
380 … values.put(LauncherSettings.Favorites.ICON_RESOURCE, c.getString(iconResourceIndex)); in copyFromCursor()
381 values.put(LauncherSettings.Favorites.CONTAINER, c.getInt(containerIndex)); in copyFromCursor()
382 values.put(LauncherSettings.Favorites.ITEM_TYPE, c.getInt(itemTypeIndex)); in copyFromCursor()
384 values.put(LauncherSettings.Favorites.SCREEN, c.getInt(screenIndex)); in copyFromCursor()
385 values.put(LauncherSettings.Favorites.CELLX, c.getInt(cellXIndex)); in copyFromCursor()
386 values.put(LauncherSettings.Favorites.CELLY, c.getInt(cellYIndex)); in copyFromCursor()
387 values.put(LauncherSettings.Favorites.URI, c.getString(uriIndex)); in copyFromCursor()
388 values.put(LauncherSettings.Favorites.DISPLAY_MODE, c.getInt(displayModeIndex)); in copyFromCursor()
517 Cursor c = null; in updateContactsShortcuts() local
522 c = db.query(TABLE_FAVORITES, in updateContactsShortcuts()
525 if (c == null) return false; in updateContactsShortcuts()
527 if (LOGD) Log.d(TAG, "found upgrade cursor count=" + c.getCount()); in updateContactsShortcuts()
529 final int idIndex = c.getColumnIndex(Favorites._ID); in updateContactsShortcuts()
530 final int intentIndex = c.getColumnIndex(Favorites.INTENT); in updateContactsShortcuts()
532 while (c.moveToNext()) { in updateContactsShortcuts()
533 long favoriteId = c.getLong(idIndex); in updateContactsShortcuts()
534 final String intentUri = c.getString(intentIndex); in updateContactsShortcuts()
585 if (c != null) { in updateContactsShortcuts()
586 c.close(); in updateContactsShortcuts()
597 Cursor c = null; in normalizeIcons() local
604 c = db.rawQuery("SELECT _id, icon FROM favorites WHERE iconType=" + in normalizeIcons()
607 final int idIndex = c.getColumnIndexOrThrow(Favorites._ID); in normalizeIcons()
608 final int iconIndex = c.getColumnIndexOrThrow(Favorites.ICON); in normalizeIcons()
610 while (c.moveToNext()) { in normalizeIcons()
611 long id = c.getLong(idIndex); in normalizeIcons()
612 byte[] data = c.getBlob(iconIndex); in normalizeIcons()
643 if (c != null) { in normalizeIcons()
644 c.close(); in normalizeIcons()
663 Cursor c = db.rawQuery("SELECT MAX(_id) FROM favorites", null); in initializeMaxId() local
668 if (c != null && c.moveToNext()) { in initializeMaxId()
669 id = c.getLong(maxIdIndex); in initializeMaxId()
671 if (c != null) { in initializeMaxId()
672 c.close(); in initializeMaxId()
696 Cursor c = null; in convertWidgets() local
701 c = db.query(TABLE_FAVORITES, new String[] { Favorites._ID, Favorites.ITEM_TYPE }, in convertWidgets()
704 if (LOGD) Log.d(TAG, "found upgrade cursor count=" + c.getCount()); in convertWidgets()
707 while (c != null && c.moveToNext()) { in convertWidgets()
708 long favoriteId = c.getLong(0); in convertWidgets()
709 int favoriteType = c.getInt(1); in convertWidgets()
760 if (c != null) { in convertWidgets()
761 c.close(); in convertWidgets()