summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher3/Utilities.java
diff options
context:
space:
mode:
authorSunny Goyal <sunnygoyal@google.com>2015-06-18 03:06:30 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2015-06-18 03:06:30 +0000
commit27f03251ea8b563dc385094e8d03f9fc1dc9390d (patch)
tree46efd5f64b2eb9b4447d84e23b90a6531ba78dc3 /src/com/android/launcher3/Utilities.java
parentdad45a7026868832404ecfb722407c685c0e8a13 (diff)
parentb1622cc30f2fd9b579cb918083e063685950df92 (diff)
downloadandroid_packages_apps_Trebuchet-27f03251ea8b563dc385094e8d03f9fc1dc9390d.tar.gz
android_packages_apps_Trebuchet-27f03251ea8b563dc385094e8d03f9fc1dc9390d.tar.bz2
android_packages_apps_Trebuchet-27f03251ea8b563dc385094e8d03f9fc1dc9390d.zip
Merge "Deleting empty folders based on DB state" into ub-launcher3-burnaby
Diffstat (limited to 'src/com/android/launcher3/Utilities.java')
-rw-r--r--src/com/android/launcher3/Utilities.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/com/android/launcher3/Utilities.java b/src/com/android/launcher3/Utilities.java
index 2d8a1b1cf..3b06c2093 100644
--- a/src/com/android/launcher3/Utilities.java
+++ b/src/com/android/launcher3/Utilities.java
@@ -54,12 +54,14 @@ import android.util.SparseArray;
import android.util.TypedValue;
import android.view.View;
import android.widget.Toast;
+
import junit.framework.Assert;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.util.ArrayList;
import java.util.Comparator;
+import java.util.Locale;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
@@ -677,4 +679,8 @@ public final class Utilities {
return (int) Math.round(TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_SP,
size, metrics));
}
+
+ public static String createDbSelectionQuery(String columnName, Iterable<?> values) {
+ return String.format(Locale.ENGLISH, "%s IN (%s)", columnName, TextUtils.join(", ", values));
+ }
}