Merge "Remove debug logging."
diff --git a/api/current.txt b/api/current.txt
index d40832c..80952e3 100644
--- a/api/current.txt
+++ b/api/current.txt
@@ -2821,6 +2821,7 @@
method public void recreate();
method public void registerForContextMenu(android.view.View);
method public final deprecated void removeDialog(int);
+ method public void reportFullyDrawn();
method public final boolean requestWindowFeature(int);
method public final void runOnUiThread(java.lang.Runnable);
method public void setContentView(int);
@@ -33379,6 +33380,7 @@
method public static int getType(char);
method public static int getType(int);
method public static char highSurrogate(int);
+ method public static boolean isAlphabetic(int);
method public static boolean isBmpCodePoint(int);
method public static boolean isDefined(char);
method public static boolean isDefined(int);
@@ -33389,6 +33391,7 @@
method public static boolean isISOControl(int);
method public static boolean isIdentifierIgnorable(char);
method public static boolean isIdentifierIgnorable(int);
+ method public static boolean isIdeographic(int);
method public static boolean isJavaIdentifierPart(char);
method public static boolean isJavaIdentifierPart(int);
method public static boolean isJavaIdentifierStart(char);
@@ -33515,48 +33518,84 @@
method public static java.lang.Character.UnicodeBlock of(char);
method public static java.lang.Character.UnicodeBlock of(int);
field public static final java.lang.Character.UnicodeBlock AEGEAN_NUMBERS;
+ field public static final java.lang.Character.UnicodeBlock ALCHEMICAL_SYMBOLS;
field public static final java.lang.Character.UnicodeBlock ALPHABETIC_PRESENTATION_FORMS;
+ field public static final java.lang.Character.UnicodeBlock ANCIENT_GREEK_MUSICAL_NOTATION;
+ field public static final java.lang.Character.UnicodeBlock ANCIENT_GREEK_NUMBERS;
+ field public static final java.lang.Character.UnicodeBlock ANCIENT_SYMBOLS;
field public static final java.lang.Character.UnicodeBlock ARABIC;
field public static final java.lang.Character.UnicodeBlock ARABIC_PRESENTATION_FORMS_A;
field public static final java.lang.Character.UnicodeBlock ARABIC_PRESENTATION_FORMS_B;
+ field public static final java.lang.Character.UnicodeBlock ARABIC_SUPPLEMENT;
field public static final java.lang.Character.UnicodeBlock ARMENIAN;
field public static final java.lang.Character.UnicodeBlock ARROWS;
+ field public static final java.lang.Character.UnicodeBlock AVESTAN;
+ field public static final java.lang.Character.UnicodeBlock BALINESE;
+ field public static final java.lang.Character.UnicodeBlock BAMUM;
+ field public static final java.lang.Character.UnicodeBlock BAMUM_SUPPLEMENT;
field public static final java.lang.Character.UnicodeBlock BASIC_LATIN;
+ field public static final java.lang.Character.UnicodeBlock BATAK;
field public static final java.lang.Character.UnicodeBlock BENGALI;
field public static final java.lang.Character.UnicodeBlock BLOCK_ELEMENTS;
field public static final java.lang.Character.UnicodeBlock BOPOMOFO;
field public static final java.lang.Character.UnicodeBlock BOPOMOFO_EXTENDED;
field public static final java.lang.Character.UnicodeBlock BOX_DRAWING;
+ field public static final java.lang.Character.UnicodeBlock BRAHMI;
field public static final java.lang.Character.UnicodeBlock BRAILLE_PATTERNS;
+ field public static final java.lang.Character.UnicodeBlock BUGINESE;
field public static final java.lang.Character.UnicodeBlock BUHID;
field public static final java.lang.Character.UnicodeBlock BYZANTINE_MUSICAL_SYMBOLS;
+ field public static final java.lang.Character.UnicodeBlock CARIAN;
+ field public static final java.lang.Character.UnicodeBlock CHAM;
field public static final java.lang.Character.UnicodeBlock CHEROKEE;
field public static final java.lang.Character.UnicodeBlock CJK_COMPATIBILITY;
field public static final java.lang.Character.UnicodeBlock CJK_COMPATIBILITY_FORMS;
field public static final java.lang.Character.UnicodeBlock CJK_COMPATIBILITY_IDEOGRAPHS;
field public static final java.lang.Character.UnicodeBlock CJK_COMPATIBILITY_IDEOGRAPHS_SUPPLEMENT;
field public static final java.lang.Character.UnicodeBlock CJK_RADICALS_SUPPLEMENT;
+ field public static final java.lang.Character.UnicodeBlock CJK_STROKES;
field public static final java.lang.Character.UnicodeBlock CJK_SYMBOLS_AND_PUNCTUATION;
field public static final java.lang.Character.UnicodeBlock CJK_UNIFIED_IDEOGRAPHS;
field public static final java.lang.Character.UnicodeBlock CJK_UNIFIED_IDEOGRAPHS_EXTENSION_A;
field public static final java.lang.Character.UnicodeBlock CJK_UNIFIED_IDEOGRAPHS_EXTENSION_B;
+ field public static final java.lang.Character.UnicodeBlock CJK_UNIFIED_IDEOGRAPHS_EXTENSION_C;
+ field public static final java.lang.Character.UnicodeBlock CJK_UNIFIED_IDEOGRAPHS_EXTENSION_D;
field public static final java.lang.Character.UnicodeBlock COMBINING_DIACRITICAL_MARKS;
+ field public static final java.lang.Character.UnicodeBlock COMBINING_DIACRITICAL_MARKS_SUPPLEMENT;
field public static final java.lang.Character.UnicodeBlock COMBINING_HALF_MARKS;
field public static final java.lang.Character.UnicodeBlock COMBINING_MARKS_FOR_SYMBOLS;
+ field public static final java.lang.Character.UnicodeBlock COMMON_INDIC_NUMBER_FORMS;
field public static final java.lang.Character.UnicodeBlock CONTROL_PICTURES;
+ field public static final java.lang.Character.UnicodeBlock COPTIC;
+ field public static final java.lang.Character.UnicodeBlock COUNTING_ROD_NUMERALS;
+ field public static final java.lang.Character.UnicodeBlock CUNEIFORM;
+ field public static final java.lang.Character.UnicodeBlock CUNEIFORM_NUMBERS_AND_PUNCTUATION;
field public static final java.lang.Character.UnicodeBlock CURRENCY_SYMBOLS;
field public static final java.lang.Character.UnicodeBlock CYPRIOT_SYLLABARY;
field public static final java.lang.Character.UnicodeBlock CYRILLIC;
+ field public static final java.lang.Character.UnicodeBlock CYRILLIC_EXTENDED_A;
+ field public static final java.lang.Character.UnicodeBlock CYRILLIC_EXTENDED_B;
field public static final java.lang.Character.UnicodeBlock CYRILLIC_SUPPLEMENTARY;
field public static final java.lang.Character.UnicodeBlock DESERET;
field public static final java.lang.Character.UnicodeBlock DEVANAGARI;
+ field public static final java.lang.Character.UnicodeBlock DEVANAGARI_EXTENDED;
field public static final java.lang.Character.UnicodeBlock DINGBATS;
+ field public static final java.lang.Character.UnicodeBlock DOMINO_TILES;
+ field public static final java.lang.Character.UnicodeBlock EGYPTIAN_HIEROGLYPHS;
+ field public static final java.lang.Character.UnicodeBlock EMOTICONS;
field public static final java.lang.Character.UnicodeBlock ENCLOSED_ALPHANUMERICS;
+ field public static final java.lang.Character.UnicodeBlock ENCLOSED_ALPHANUMERIC_SUPPLEMENT;
field public static final java.lang.Character.UnicodeBlock ENCLOSED_CJK_LETTERS_AND_MONTHS;
+ field public static final java.lang.Character.UnicodeBlock ENCLOSED_IDEOGRAPHIC_SUPPLEMENT;
field public static final java.lang.Character.UnicodeBlock ETHIOPIC;
+ field public static final java.lang.Character.UnicodeBlock ETHIOPIC_EXTENDED;
+ field public static final java.lang.Character.UnicodeBlock ETHIOPIC_EXTENDED_A;
+ field public static final java.lang.Character.UnicodeBlock ETHIOPIC_SUPPLEMENT;
field public static final java.lang.Character.UnicodeBlock GENERAL_PUNCTUATION;
field public static final java.lang.Character.UnicodeBlock GEOMETRIC_SHAPES;
field public static final java.lang.Character.UnicodeBlock GEORGIAN;
+ field public static final java.lang.Character.UnicodeBlock GEORGIAN_SUPPLEMENT;
+ field public static final java.lang.Character.UnicodeBlock GLAGOLITIC;
field public static final java.lang.Character.UnicodeBlock GOTHIC;
field public static final java.lang.Character.UnicodeBlock GREEK;
field public static final java.lang.Character.UnicodeBlock GREEK_EXTENDED;
@@ -33565,6 +33604,8 @@
field public static final java.lang.Character.UnicodeBlock HALFWIDTH_AND_FULLWIDTH_FORMS;
field public static final java.lang.Character.UnicodeBlock HANGUL_COMPATIBILITY_JAMO;
field public static final java.lang.Character.UnicodeBlock HANGUL_JAMO;
+ field public static final java.lang.Character.UnicodeBlock HANGUL_JAMO_EXTENDED_A;
+ field public static final java.lang.Character.UnicodeBlock HANGUL_JAMO_EXTENDED_B;
field public static final java.lang.Character.UnicodeBlock HANGUL_SYLLABLES;
field public static final java.lang.Character.UnicodeBlock HANUNOO;
field public static final java.lang.Character.UnicodeBlock HEBREW;
@@ -33572,12 +33613,20 @@
field public static final java.lang.Character.UnicodeBlock HIGH_SURROGATES;
field public static final java.lang.Character.UnicodeBlock HIRAGANA;
field public static final java.lang.Character.UnicodeBlock IDEOGRAPHIC_DESCRIPTION_CHARACTERS;
+ field public static final java.lang.Character.UnicodeBlock IMPERIAL_ARAMAIC;
+ field public static final java.lang.Character.UnicodeBlock INSCRIPTIONAL_PAHLAVI;
+ field public static final java.lang.Character.UnicodeBlock INSCRIPTIONAL_PARTHIAN;
field public static final java.lang.Character.UnicodeBlock IPA_EXTENSIONS;
+ field public static final java.lang.Character.UnicodeBlock JAVANESE;
+ field public static final java.lang.Character.UnicodeBlock KAITHI;
+ field public static final java.lang.Character.UnicodeBlock KANA_SUPPLEMENT;
field public static final java.lang.Character.UnicodeBlock KANBUN;
field public static final java.lang.Character.UnicodeBlock KANGXI_RADICALS;
field public static final java.lang.Character.UnicodeBlock KANNADA;
field public static final java.lang.Character.UnicodeBlock KATAKANA;
field public static final java.lang.Character.UnicodeBlock KATAKANA_PHONETIC_EXTENSIONS;
+ field public static final java.lang.Character.UnicodeBlock KAYAH_LI;
+ field public static final java.lang.Character.UnicodeBlock KHAROSHTHI;
field public static final java.lang.Character.UnicodeBlock KHMER;
field public static final java.lang.Character.UnicodeBlock KHMER_SYMBOLS;
field public static final java.lang.Character.UnicodeBlock LAO;
@@ -33585,58 +33634,96 @@
field public static final java.lang.Character.UnicodeBlock LATIN_EXTENDED_A;
field public static final java.lang.Character.UnicodeBlock LATIN_EXTENDED_ADDITIONAL;
field public static final java.lang.Character.UnicodeBlock LATIN_EXTENDED_B;
+ field public static final java.lang.Character.UnicodeBlock LATIN_EXTENDED_C;
+ field public static final java.lang.Character.UnicodeBlock LATIN_EXTENDED_D;
+ field public static final java.lang.Character.UnicodeBlock LEPCHA;
field public static final java.lang.Character.UnicodeBlock LETTERLIKE_SYMBOLS;
field public static final java.lang.Character.UnicodeBlock LIMBU;
field public static final java.lang.Character.UnicodeBlock LINEAR_B_IDEOGRAMS;
field public static final java.lang.Character.UnicodeBlock LINEAR_B_SYLLABARY;
+ field public static final java.lang.Character.UnicodeBlock LISU;
field public static final java.lang.Character.UnicodeBlock LOW_SURROGATES;
+ field public static final java.lang.Character.UnicodeBlock LYCIAN;
+ field public static final java.lang.Character.UnicodeBlock LYDIAN;
+ field public static final java.lang.Character.UnicodeBlock MAHJONG_TILES;
field public static final java.lang.Character.UnicodeBlock MALAYALAM;
+ field public static final java.lang.Character.UnicodeBlock MANDAIC;
field public static final java.lang.Character.UnicodeBlock MATHEMATICAL_ALPHANUMERIC_SYMBOLS;
field public static final java.lang.Character.UnicodeBlock MATHEMATICAL_OPERATORS;
+ field public static final java.lang.Character.UnicodeBlock MEETEI_MAYEK;
field public static final java.lang.Character.UnicodeBlock MISCELLANEOUS_MATHEMATICAL_SYMBOLS_A;
field public static final java.lang.Character.UnicodeBlock MISCELLANEOUS_MATHEMATICAL_SYMBOLS_B;
field public static final java.lang.Character.UnicodeBlock MISCELLANEOUS_SYMBOLS;
field public static final java.lang.Character.UnicodeBlock MISCELLANEOUS_SYMBOLS_AND_ARROWS;
+ field public static final java.lang.Character.UnicodeBlock MISCELLANEOUS_SYMBOLS_AND_PICTOGRAPHS;
field public static final java.lang.Character.UnicodeBlock MISCELLANEOUS_TECHNICAL;
+ field public static final java.lang.Character.UnicodeBlock MODIFIER_TONE_LETTERS;
field public static final java.lang.Character.UnicodeBlock MONGOLIAN;
field public static final java.lang.Character.UnicodeBlock MUSICAL_SYMBOLS;
field public static final java.lang.Character.UnicodeBlock MYANMAR;
+ field public static final java.lang.Character.UnicodeBlock MYANMAR_EXTENDED_A;
+ field public static final java.lang.Character.UnicodeBlock NEW_TAI_LUE;
+ field public static final java.lang.Character.UnicodeBlock NKO;
field public static final java.lang.Character.UnicodeBlock NUMBER_FORMS;
field public static final java.lang.Character.UnicodeBlock OGHAM;
field public static final java.lang.Character.UnicodeBlock OLD_ITALIC;
+ field public static final java.lang.Character.UnicodeBlock OLD_PERSIAN;
+ field public static final java.lang.Character.UnicodeBlock OLD_SOUTH_ARABIAN;
+ field public static final java.lang.Character.UnicodeBlock OLD_TURKIC;
+ field public static final java.lang.Character.UnicodeBlock OL_CHIKI;
field public static final java.lang.Character.UnicodeBlock OPTICAL_CHARACTER_RECOGNITION;
field public static final java.lang.Character.UnicodeBlock ORIYA;
field public static final java.lang.Character.UnicodeBlock OSMANYA;
+ field public static final java.lang.Character.UnicodeBlock PHAGS_PA;
+ field public static final java.lang.Character.UnicodeBlock PHAISTOS_DISC;
+ field public static final java.lang.Character.UnicodeBlock PHOENICIAN;
field public static final java.lang.Character.UnicodeBlock PHONETIC_EXTENSIONS;
+ field public static final java.lang.Character.UnicodeBlock PHONETIC_EXTENSIONS_SUPPLEMENT;
+ field public static final java.lang.Character.UnicodeBlock PLAYING_CARDS;
field public static final java.lang.Character.UnicodeBlock PRIVATE_USE_AREA;
+ field public static final java.lang.Character.UnicodeBlock REJANG;
+ field public static final java.lang.Character.UnicodeBlock RUMI_NUMERAL_SYMBOLS;
field public static final java.lang.Character.UnicodeBlock RUNIC;
+ field public static final java.lang.Character.UnicodeBlock SAMARITAN;
+ field public static final java.lang.Character.UnicodeBlock SAURASHTRA;
field public static final java.lang.Character.UnicodeBlock SHAVIAN;
field public static final java.lang.Character.UnicodeBlock SINHALA;
field public static final java.lang.Character.UnicodeBlock SMALL_FORM_VARIANTS;
field public static final java.lang.Character.UnicodeBlock SPACING_MODIFIER_LETTERS;
field public static final java.lang.Character.UnicodeBlock SPECIALS;
+ field public static final java.lang.Character.UnicodeBlock SUNDANESE;
field public static final java.lang.Character.UnicodeBlock SUPERSCRIPTS_AND_SUBSCRIPTS;
field public static final java.lang.Character.UnicodeBlock SUPPLEMENTAL_ARROWS_A;
field public static final java.lang.Character.UnicodeBlock SUPPLEMENTAL_ARROWS_B;
field public static final java.lang.Character.UnicodeBlock SUPPLEMENTAL_MATHEMATICAL_OPERATORS;
+ field public static final java.lang.Character.UnicodeBlock SUPPLEMENTAL_PUNCTUATION;
field public static final java.lang.Character.UnicodeBlock SUPPLEMENTARY_PRIVATE_USE_AREA_A;
field public static final java.lang.Character.UnicodeBlock SUPPLEMENTARY_PRIVATE_USE_AREA_B;
field public static final deprecated java.lang.Character.UnicodeBlock SURROGATES_AREA;
+ field public static final java.lang.Character.UnicodeBlock SYLOTI_NAGRI;
field public static final java.lang.Character.UnicodeBlock SYRIAC;
field public static final java.lang.Character.UnicodeBlock TAGALOG;
field public static final java.lang.Character.UnicodeBlock TAGBANWA;
field public static final java.lang.Character.UnicodeBlock TAGS;
field public static final java.lang.Character.UnicodeBlock TAI_LE;
+ field public static final java.lang.Character.UnicodeBlock TAI_THAM;
+ field public static final java.lang.Character.UnicodeBlock TAI_VIET;
field public static final java.lang.Character.UnicodeBlock TAI_XUAN_JING_SYMBOLS;
field public static final java.lang.Character.UnicodeBlock TAMIL;
field public static final java.lang.Character.UnicodeBlock TELUGU;
field public static final java.lang.Character.UnicodeBlock THAANA;
field public static final java.lang.Character.UnicodeBlock THAI;
field public static final java.lang.Character.UnicodeBlock TIBETAN;
+ field public static final java.lang.Character.UnicodeBlock TIFINAGH;
+ field public static final java.lang.Character.UnicodeBlock TRANSPORT_AND_MAP_SYMBOLS;
field public static final java.lang.Character.UnicodeBlock UGARITIC;
field public static final java.lang.Character.UnicodeBlock UNIFIED_CANADIAN_ABORIGINAL_SYLLABICS;
+ field public static final java.lang.Character.UnicodeBlock UNIFIED_CANADIAN_ABORIGINAL_SYLLABICS_EXTENDED;
+ field public static final java.lang.Character.UnicodeBlock VAI;
field public static final java.lang.Character.UnicodeBlock VARIATION_SELECTORS;
field public static final java.lang.Character.UnicodeBlock VARIATION_SELECTORS_SUPPLEMENT;
+ field public static final java.lang.Character.UnicodeBlock VEDIC_EXTENSIONS;
+ field public static final java.lang.Character.UnicodeBlock VERTICAL_FORMS;
field public static final java.lang.Character.UnicodeBlock YIJING_HEXAGRAM_SYMBOLS;
field public static final java.lang.Character.UnicodeBlock YI_RADICALS;
field public static final java.lang.Character.UnicodeBlock YI_SYLLABLES;
diff --git a/core/java/android/app/Activity.java b/core/java/android/app/Activity.java
index e87d805..d1efd0d1 100644
--- a/core/java/android/app/Activity.java
+++ b/core/java/android/app/Activity.java
@@ -686,6 +686,7 @@
boolean mFinished;
boolean mStartedActivity;
private boolean mDestroyed;
+ private boolean mDoReportFullyDrawn = true;
/** true if the activity is going through a transient pause */
/*package*/ boolean mTemporaryPause = false;
/** true if the activity is being destroyed in order to recreate it with a new configuration */
@@ -1449,6 +1450,27 @@
}
/**
+ * Report to the system that your app is now fully drawn. This is only used
+ * to help instrument app launch times, so that the app can report when it is
+ * fully in a usable state; without this, all the system can determine is when
+ * its window is first drawn and displayed. To participate in app launch time
+ * measurement, you should always call this method after first launch (when
+ * {@link #onCreate(android.os.Bundle)} is called) at the point where you have
+ * entirely drawn your UI and populated with all of the significant data. You
+ * can safely call this method any time after first launch as well, in which case
+ * it will simply be ignored.
+ */
+ public void reportFullyDrawn() {
+ if (mDoReportFullyDrawn) {
+ mDoReportFullyDrawn = false;
+ try {
+ ActivityManagerNative.getDefault().reportActivityFullyDrawn(mToken);
+ } catch (RemoteException e) {
+ }
+ }
+ }
+
+ /**
* Called by the system when the device configuration changes while your
* activity is running. Note that this will <em>only</em> be called if
* you have selected configurations you would like to handle with the
@@ -5252,6 +5274,7 @@
}
final void performPause() {
+ mDoReportFullyDrawn = false;
mFragments.dispatchPause();
mCalled = false;
onPause();
@@ -5271,6 +5294,7 @@
}
final void performStop() {
+ mDoReportFullyDrawn = false;
if (mLoadersStarted) {
mLoadersStarted = false;
if (mLoaderManager != null) {
diff --git a/core/java/android/app/ActivityManagerNative.java b/core/java/android/app/ActivityManagerNative.java
index b966d6d..a23611ec 100644
--- a/core/java/android/app/ActivityManagerNative.java
+++ b/core/java/android/app/ActivityManagerNative.java
@@ -1949,6 +1949,14 @@
return true;
}
+ case REPORT_ACTIVITY_FULLY_DRAWN_TRANSACTION: {
+ data.enforceInterface(IActivityManager.descriptor);
+ IBinder token = data.readStrongBinder();
+ reportActivityFullyDrawn(token);
+ reply.writeNoException();
+ return true;
+ }
+
}
return super.onTransact(code, data, reply, flags);
@@ -4463,5 +4471,16 @@
reply.recycle();
}
+ public void reportActivityFullyDrawn(IBinder token) throws RemoteException {
+ Parcel data = Parcel.obtain();
+ Parcel reply = Parcel.obtain();
+ data.writeInterfaceToken(IActivityManager.descriptor);
+ data.writeStrongBinder(token);
+ mRemote.transact(REPORT_ACTIVITY_FULLY_DRAWN_TRANSACTION, data, reply, 0);
+ reply.readException();
+ data.recycle();
+ reply.recycle();
+ }
+
private IBinder mRemote;
}
diff --git a/core/java/android/app/IActivityManager.java b/core/java/android/app/IActivityManager.java
index 39f4cfa..3793c73 100644
--- a/core/java/android/app/IActivityManager.java
+++ b/core/java/android/app/IActivityManager.java
@@ -392,6 +392,8 @@
public void hang(IBinder who, boolean allowRestart) throws RemoteException;
+ public void reportActivityFullyDrawn(IBinder token) throws RemoteException;
+
/*
* Private non-Binder interfaces
*/
@@ -669,4 +671,5 @@
int SET_FOCUSED_STACK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+171;
int GET_STACK_BOX_INFO_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+172;
int CONVERT_TO_OPAQUE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+173;
+ int REPORT_ACTIVITY_FULLY_DRAWN_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+174;
}
diff --git a/core/java/android/inputmethodservice/IInputMethodWrapper.java b/core/java/android/inputmethodservice/IInputMethodWrapper.java
index 9306373..06d8e4a 100644
--- a/core/java/android/inputmethodservice/IInputMethodWrapper.java
+++ b/core/java/android/inputmethodservice/IInputMethodWrapper.java
@@ -279,6 +279,10 @@
try {
InputMethodSession ls = ((IInputMethodSessionWrapper)
session).getInternalInputMethodSession();
+ if (ls == null) {
+ Log.w(TAG, "Session is already finished: " + session);
+ return;
+ }
mCaller.executeOrSendMessage(mCaller.obtainMessageIO(
DO_SET_SESSION_ENABLED, enabled ? 1 : 0, ls));
} catch (ClassCastException e) {
@@ -291,6 +295,10 @@
try {
InputMethodSession ls = ((IInputMethodSessionWrapper)
session).getInternalInputMethodSession();
+ if (ls == null) {
+ Log.w(TAG, "Session is already finished: " + session);
+ return;
+ }
mCaller.executeOrSendMessage(mCaller.obtainMessageO(DO_REVOKE_SESSION, ls));
} catch (ClassCastException e) {
Log.w(TAG, "Incoming session not of correct type: " + session, e);
diff --git a/core/java/android/net/ConnectivityManager.java b/core/java/android/net/ConnectivityManager.java
index ffcc297..04ab0a5 100644
--- a/core/java/android/net/ConnectivityManager.java
+++ b/core/java/android/net/ConnectivityManager.java
@@ -25,6 +25,7 @@
import android.os.Build.VERSION_CODES;
import android.os.Messenger;
import android.os.RemoteException;
+import android.os.ResultReceiver;
import android.provider.Settings;
import java.net.InetAddress;
@@ -1309,4 +1310,67 @@
} catch (RemoteException e) {
}
}
+
+ /**
+ * The ResultReceiver resultCode for checkMobileProvisioning (CMP_RESULT_CODE)
+ */
+
+ /**
+ * No connection was possible to the network.
+ * {@hide}
+ */
+ public static final int CMP_RESULT_CODE_NO_CONNECTION = 0;
+
+ /**
+ * A connection was made to the internet, all is well.
+ * {@hide}
+ */
+ public static final int CMP_RESULT_CODE_CONNECTABLE = 1;
+
+ /**
+ * A connection was made but there was a redirection, we appear to be in walled garden.
+ * This is an indication of a warm sim on a mobile network.
+ * {@hide}
+ */
+ public static final int CMP_RESULT_CODE_REDIRECTED = 2;
+
+ /**
+ * A connection was made but no dns server was available to resolve a name to address.
+ * This is an indication of a warm sim on a mobile network.
+ *
+ * {@hide}
+ */
+ public static final int CMP_RESULT_CODE_NO_DNS = 3;
+
+ /**
+ * A connection was made but could not open a TCP connection.
+ * This is an indication of a warm sim on a mobile network.
+ * {@hide}
+ */
+ public static final int CMP_RESULT_CODE_NO_TCP_CONNECTION = 4;
+
+ /**
+ * Check mobile provisioning. The resultCode passed to
+ * onReceiveResult will be one of the CMP_RESULT_CODE_xxxx values above.
+ * This may take a minute or more to complete.
+ *
+ * @param sendNotificaiton, when true a notification will be sent to user.
+ * @param suggestedTimeOutMs, timeout in milliseconds
+ * @param resultReceiver needs to be supplied to receive the result
+ *
+ * @return time out that will be used, maybe less that suggestedTimeOutMs
+ * -1 if an error.
+ *
+ * {@hide}
+ */
+ public int checkMobileProvisioning(boolean sendNotification, int suggestedTimeOutMs,
+ ResultReceiver resultReceiver) {
+ int timeOutMs = -1;
+ try {
+ timeOutMs = mService.checkMobileProvisioning(sendNotification, suggestedTimeOutMs,
+ resultReceiver);
+ } catch (RemoteException e) {
+ }
+ return timeOutMs;
+ }
}
diff --git a/core/java/android/net/IConnectivityManager.aidl b/core/java/android/net/IConnectivityManager.aidl
index e5d6e51..3dbe078 100644
--- a/core/java/android/net/IConnectivityManager.aidl
+++ b/core/java/android/net/IConnectivityManager.aidl
@@ -24,6 +24,7 @@
import android.os.IBinder;
import android.os.Messenger;
import android.os.ParcelFileDescriptor;
+import android.os.ResultReceiver;
import com.android.internal.net.LegacyVpnInfo;
import com.android.internal.net.VpnConfig;
@@ -131,4 +132,6 @@
void supplyMessenger(int networkType, in Messenger messenger);
int findConnectionTypeForIface(in String iface);
+
+ int checkMobileProvisioning(boolean sendNotification, int suggestedTimeOutMs, in ResultReceiver resultReceiver);
}
diff --git a/core/java/android/net/MobileDataStateTracker.java b/core/java/android/net/MobileDataStateTracker.java
index e85dbcd..5a1daed 100644
--- a/core/java/android/net/MobileDataStateTracker.java
+++ b/core/java/android/net/MobileDataStateTracker.java
@@ -494,6 +494,19 @@
}
/**
+ * Eanble/disable FailFast
+ *
+ * @param enabled is DctConstants.ENABLED/DISABLED
+ */
+ public void setEnableFailFastMobileData(int enabled) {
+ if (DBG) log("setEnableFailFastMobileData(enabled=" + enabled + ")");
+ final AsyncChannel channel = mDataConnectionTrackerAc;
+ if (channel != null) {
+ channel.sendMessage(DctConstants.CMD_SET_ENABLE_FAIL_FAST_MOBILE_DATA, enabled);
+ }
+ }
+
+ /**
* carrier dependency is met/unmet
* @param met
*/
diff --git a/core/java/android/widget/ProgressBar.java b/core/java/android/widget/ProgressBar.java
index 5392a96..65a2d4d 100644
--- a/core/java/android/widget/ProgressBar.java
+++ b/core/java/android/widget/ProgressBar.java
@@ -959,11 +959,9 @@
if (!mInDrawing) {
if (verifyDrawable(dr)) {
final Rect dirty = dr.getBounds();
- final int scrollX = mScrollX + mPaddingLeft;
- final int scrollY = mScrollY + mPaddingTop;
- invalidate(dirty.left + scrollX, dirty.top + scrollY,
- dirty.right + scrollX, dirty.bottom + scrollY);
+ invalidate(dirty.left + mScrollX, dirty.top + mScrollY,
+ dirty.right + mScrollX, dirty.bottom + mScrollY);
} else {
super.invalidateDrawable(dr);
}
diff --git a/core/jni/Android.mk b/core/jni/Android.mk
index 0a694c7..20e5011 100644
--- a/core/jni/Android.mk
+++ b/core/jni/Android.mk
@@ -194,6 +194,7 @@
libnetutils \
libui \
libgui \
+ libinput \
libcamera_client \
libskia \
libsqlite \
diff --git a/core/jni/android_app_NativeActivity.cpp b/core/jni/android_app_NativeActivity.cpp
index 9fc01e1..f768ce8 100644
--- a/core/jni/android_app_NativeActivity.cpp
+++ b/core/jni/android_app_NativeActivity.cpp
@@ -25,7 +25,7 @@
#include <android_runtime/android_util_AssetManager.h>
#include <android_runtime/android_view_Surface.h>
#include <android_runtime/AndroidRuntime.h>
-#include <androidfw/InputTransport.h>
+#include <input/InputTransport.h>
#include <gui/Surface.h>
diff --git a/core/jni/android_view_InputChannel.cpp b/core/jni/android_view_InputChannel.cpp
index 9fa9fe4..ce475e0 100644
--- a/core/jni/android_view_InputChannel.cpp
+++ b/core/jni/android_view_InputChannel.cpp
@@ -21,7 +21,7 @@
#include <android_runtime/AndroidRuntime.h>
#include <binder/Parcel.h>
#include <utils/Log.h>
-#include <androidfw/InputTransport.h>
+#include <input/InputTransport.h>
#include "android_view_InputChannel.h"
#include "android_os_Parcel.h"
#include "android_util_Binder.h"
diff --git a/core/jni/android_view_InputChannel.h b/core/jni/android_view_InputChannel.h
index 0967021..2ba2dc0 100644
--- a/core/jni/android_view_InputChannel.h
+++ b/core/jni/android_view_InputChannel.h
@@ -19,7 +19,7 @@
#include "jni.h"
-#include <androidfw/InputTransport.h>
+#include <input/InputTransport.h>
namespace android {
diff --git a/core/jni/android_view_InputDevice.cpp b/core/jni/android_view_InputDevice.cpp
index e3a54a8..8ef5d0b 100644
--- a/core/jni/android_view_InputDevice.cpp
+++ b/core/jni/android_view_InputDevice.cpp
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-#include <androidfw/Input.h>
+#include <input/Input.h>
#include <android_runtime/AndroidRuntime.h>
#include <nativehelper/jni.h>
diff --git a/core/jni/android_view_InputDevice.h b/core/jni/android_view_InputDevice.h
index 78651ba..ac38eb1 100644
--- a/core/jni/android_view_InputDevice.h
+++ b/core/jni/android_view_InputDevice.h
@@ -19,7 +19,7 @@
#include "jni.h"
-#include <androidfw/InputDevice.h>
+#include <input/InputDevice.h>
namespace android {
diff --git a/core/jni/android_view_InputEventReceiver.cpp b/core/jni/android_view_InputEventReceiver.cpp
index 8e1e04a..b254de7 100644
--- a/core/jni/android_view_InputEventReceiver.cpp
+++ b/core/jni/android_view_InputEventReceiver.cpp
@@ -29,7 +29,7 @@
#include <utils/Looper.h>
#include <utils/Vector.h>
#include <utils/threads.h>
-#include <androidfw/InputTransport.h>
+#include <input/InputTransport.h>
#include "android_os_MessageQueue.h"
#include "android_view_InputChannel.h"
#include "android_view_KeyEvent.h"
diff --git a/core/jni/android_view_InputEventSender.cpp b/core/jni/android_view_InputEventSender.cpp
index b46eb4b..e4b65a1 100644
--- a/core/jni/android_view_InputEventSender.cpp
+++ b/core/jni/android_view_InputEventSender.cpp
@@ -29,7 +29,7 @@
#include <utils/Looper.h>
#include <utils/threads.h>
#include <utils/KeyedVector.h>
-#include <androidfw/InputTransport.h>
+#include <input/InputTransport.h>
#include "android_os_MessageQueue.h"
#include "android_view_InputChannel.h"
#include "android_view_KeyEvent.h"
diff --git a/core/jni/android_view_InputQueue.cpp b/core/jni/android_view_InputQueue.cpp
index ec56afa..7532c9d 100644
--- a/core/jni/android_view_InputQueue.cpp
+++ b/core/jni/android_view_InputQueue.cpp
@@ -23,7 +23,7 @@
#include <android/input.h>
#include <android_runtime/AndroidRuntime.h>
#include <android_runtime/android_view_InputQueue.h>
-#include <androidfw/Input.h>
+#include <input/Input.h>
#include <utils/Looper.h>
#include <utils/TypeHelpers.h>
#include <ScopedLocalRef.h>
diff --git a/core/jni/android_view_KeyCharacterMap.cpp b/core/jni/android_view_KeyCharacterMap.cpp
index 3e56a89..ffe2dea 100644
--- a/core/jni/android_view_KeyCharacterMap.cpp
+++ b/core/jni/android_view_KeyCharacterMap.cpp
@@ -16,8 +16,8 @@
#include <android_runtime/AndroidRuntime.h>
-#include <androidfw/KeyCharacterMap.h>
-#include <androidfw/Input.h>
+#include <input/KeyCharacterMap.h>
+#include <input/Input.h>
#include <binder/Parcel.h>
#include <nativehelper/jni.h>
diff --git a/core/jni/android_view_KeyCharacterMap.h b/core/jni/android_view_KeyCharacterMap.h
index 04024f6..e8465c2 100644
--- a/core/jni/android_view_KeyCharacterMap.h
+++ b/core/jni/android_view_KeyCharacterMap.h
@@ -19,7 +19,7 @@
#include "jni.h"
-#include <androidfw/KeyCharacterMap.h>
+#include <input/KeyCharacterMap.h>
namespace android {
diff --git a/core/jni/android_view_KeyEvent.cpp b/core/jni/android_view_KeyEvent.cpp
index 36a98f9..17a0677 100644
--- a/core/jni/android_view_KeyEvent.cpp
+++ b/core/jni/android_view_KeyEvent.cpp
@@ -20,7 +20,7 @@
#include <android_runtime/AndroidRuntime.h>
#include <utils/Log.h>
-#include <androidfw/Input.h>
+#include <input/Input.h>
#include "android_view_KeyEvent.h"
namespace android {
diff --git a/core/jni/android_view_MotionEvent.cpp b/core/jni/android_view_MotionEvent.cpp
index e69fb74..73c0683 100644
--- a/core/jni/android_view_MotionEvent.cpp
+++ b/core/jni/android_view_MotionEvent.cpp
@@ -20,7 +20,7 @@
#include <android_runtime/AndroidRuntime.h>
#include <utils/Log.h>
-#include <androidfw/Input.h>
+#include <input/Input.h>
#include "android_os_Parcel.h"
#include "android_view_MotionEvent.h"
#include "android_util_Binder.h"
diff --git a/core/jni/android_view_VelocityTracker.cpp b/core/jni/android_view_VelocityTracker.cpp
index c2fa3be..90ba2ba 100644
--- a/core/jni/android_view_VelocityTracker.cpp
+++ b/core/jni/android_view_VelocityTracker.cpp
@@ -20,8 +20,8 @@
#include <android_runtime/AndroidRuntime.h>
#include <utils/Log.h>
-#include <androidfw/Input.h>
-#include <androidfw/VelocityTracker.h>
+#include <input/Input.h>
+#include <input/VelocityTracker.h>
#include "android_view_MotionEvent.h"
#include <ScopedUtfChars.h>
diff --git a/core/res/res/values-af/strings.xml b/core/res/res/values-af/strings.xml
index c0c71f9..06a5e67 100644
--- a/core/res/res/values-af/strings.xml
+++ b/core/res/res/values-af/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Laat die program toe om take na die voorgrond of agtergrond te skuif. Die program kan dit moontlik sonder jou insette doen."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"stop lopende programme"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Laat die program toe om take te verwyder en hul programme te dood. Kwaadwillige programme kan die gedrag van ander programme ontwrig."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"begin enige aktiwiteit"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Laat die program toe om \'n aktiwiteit te begin, ongeag toestemming-beskerming of uitgevoerde status."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"stel skermversoenbaarheid"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Verkeerde patroon"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Verkeerde wagwoord"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Verkeerde PIN"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Probeer weer oor <xliff:g id="NUMBER">%d</xliff:g> sekondes."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Probeer weer oor <xliff:g id="NUMBER">%1$d</xliff:g> sekondes."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Teken jou patroon"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Voer SIM-PIN in"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Voer PIN in"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-am/strings.xml b/core/res/res/values-am/strings.xml
index 51fb415..8c0da87 100644
--- a/core/res/res/values-am/strings.xml
+++ b/core/res/res/values-am/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"መተግበሪያው ተግባሮችን ወደ ቅድመ ገጹ እና ወደ ዳራው እንዲያንቀሳቅስ ይፈቅድለታል። መተግበሪያው ይህንን ያላንተ ግብዓት ሊያደርግ ይችላል።"</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"የአሂድ ትግበራዎች አቁም"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"ተግባሮችን ለማስወገድ እና መተግበሪያዎቻቸውን ለመግደል ለመተግበሪያ ይፈቅዳል። ጎጂ የሆኑ መተግበሪያዎች የሌሎችን መተግበሪያዎችን ባህሪ ሊያውኩ ይችላሉ።"</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"ማንኛውም እንቅስቃሴ ጀምር"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"መተግበሪያው ማንኛውም እንቅስቃሴ፣ የፍቃድ ጥበቃም ሆነ ወደ ውጭ የተላከበት ሁኔታ ሳይታይ፣ እንዲጀምር ይፈቅድለታል።"</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"የማያ ገጽ ተኳኋኝነት መድብ"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"የተሳሳተ ስርዓተ ጥለት"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"የተሳሳተ ይለፍ ቃል"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"የተሳሳተ ፒን"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"በ<xliff:g id="NUMBER">%d</xliff:g> ሰከንዶች ውስጥ እንደገና ይሞክሩ።"</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"በ<xliff:g id="NUMBER">%1$d</xliff:g> ሰከንዶች ውስጥ እንደገና ይሞክሩ።"</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"ስርዓተ ጥለትዎን ይሳሉ"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"የሲም ፒን ያስገቡ"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"ፒን ያስገቡ"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-ar/strings.xml b/core/res/res/values-ar/strings.xml
index 18fd4c9..1820689 100644
--- a/core/res/res/values-ar/strings.xml
+++ b/core/res/res/values-ar/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"للسماح للتطبيق بنقل المهام إلى المقدمة والخلفية. وقد يجري التطبيق ذلك بدون إذنك."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"إيقاف التطبيقات التي قيد التشغيل"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"للسماح للتطبيق بإزالة المهام وإنهاء تطبيقاتها. قد تعطل التطبيقات الضارة عمل التطبيقات الأخرى."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"بدء أي نشاط"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"للسماح للتطبيق ببدء أي نشاط، بغض النظر عن حماية الإذن أو حالة التصدير."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"تعيين توافق الشاشة"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"نقش خاطئ"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"كلمة مرور خاطئة"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"رقم تعريف شخصي خاطئ"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"حاول مرة أخرى خلال <xliff:g id="NUMBER">%d</xliff:g> ثانية."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"حاول مرة أخرى خلال <xliff:g id="NUMBER">%1$d</xliff:g> ثانية."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"ارسم نقشك"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"أدخل رقم التعريف الشخصي لبطاقة SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"أدخل رقم التعريف الشخصي"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-be/strings.xml b/core/res/res/values-be/strings.xml
index 9d87725..becac6c 100644
--- a/core/res/res/values-be/strings.xml
+++ b/core/res/res/values-be/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Дазваляе прыкладанню перамяшчаць заданні на пярэдні план і ў фон. Шкоднасныя прыкладанні могуць прымусова рабіць сябе асноўнымі без вашага ведама."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"спыніць запушчаныя прыкладанні"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Дазваляе прыкладанням выдаляць заданні і спыняць прыкладанні, якія іх выкарыстоўваюць. Шкоднасныя прыкладаннi могуць перашкодзiць працы іншых прыкладанняў."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"пачынаць любы працэс"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Дазваляе прыкладанню пачынаць любы працэс, незалежна ад абароны дазволам ці стану экспарту."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"усталяваць сумяшчальнасць экранаў"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1468,7 +1473,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Няправільна ключ"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Няправiльны пароль"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Няправільны PIN-код"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Паўтарыце спробу праз <xliff:g id="NUMBER">%d</xliff:g> с."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Паўтарыце спробу праз <xliff:g id="NUMBER">%1$d</xliff:g> с."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Намалюйце ключ"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Увядзіце PIN-код SIM-карты"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Увядзіце PIN-код"</string>
@@ -1589,4 +1594,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-bg/strings.xml b/core/res/res/values-bg/strings.xml
index d1b4737..a4fa7f0 100644
--- a/core/res/res/values-bg/strings.xml
+++ b/core/res/res/values-bg/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Разрешава на приложението да прехвърля задачи на преден и на заден план. То може да направи това без вашето потвърждение."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"спиране на изпълняваните приложения"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Разрешава на приложението да премахва задачи и да прекратява приложенията им. Злонамерените приложения могат да нарушат поведението на други приложения."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"започване на дейности"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Разрешава на приложението да започва дейности независимо от защитата на базата на разрешения или състоянието при експортиране."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"задаване на съвместимост на екрана"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Грешна фигура"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Грешна парола"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Грешен ПИН код"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Опитайте отново след <xliff:g id="NUMBER">%d</xliff:g> секунди."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Опитайте отново след <xliff:g id="NUMBER">%1$d</xliff:g> секунди."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Начертайте фигурата си"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Въведете ПИН кода за SIM картата"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Въведете ПИН код"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-ca/strings.xml b/core/res/res/values-ca/strings.xml
index 40db5d2..05965b3 100644
--- a/core/res/res/values-ca/strings.xml
+++ b/core/res/res/values-ca/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Permet que l\'aplicació desplaci tasques en primer o segon pla. L\'aplicació pot fer-ho sense que tu ho indiquis."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"atura les aplicacions que s\'estan executant"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Permet que l\'aplicació elimini tasques i finalitzi les seves aplicacions. Les aplicacions malicioses poden alterar el comportament d\'altres aplicacions."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"iniciar qualsevol activitat"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Permet que l\'aplicació iniciï qualsevol activitat, amb independència de la protecció del permís o de l\'estat exportat."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"definició de la compatibilitat de pantalla"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Patró incorrecte"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Contrasenya incorrecta"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"PIN incorrecte"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Torna-ho a provar d\'aquí a <xliff:g id="NUMBER">%d</xliff:g> segons."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Torna-ho a provar d\'aquí a <xliff:g id="NUMBER">%1$d</xliff:g> segons."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Dibuixa el patró"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Introdueix el PIN de la SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Introdueix el PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-cs/strings.xml b/core/res/res/values-cs/strings.xml
index 33a68bd..9f3a090 100644
--- a/core/res/res/values-cs/strings.xml
+++ b/core/res/res/values-cs/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Umožňuje aplikaci přesunout úlohy na popředí nebo pozadí. Aplikace tak může činit bez vašeho zásahu."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"zastavení činnosti aplikací"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Umožňuje aplikaci odstranit úlohy a ukončit jejich aplikace. Škodlivé aplikace mohou narušit chování ostatních aplikací."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"zahájení libovolné činnosti"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Umožňuje aplikaci zahájit libovolnou aktivitu bez ohledu na ochranu pomocí oprávnění či exportovaný stav."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"nastavit kompatibilitu obrazovky"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Nesprávné gesto"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Nesprávné heslo"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Nesprávný kód PIN"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Zkuste to znovu za <xliff:g id="NUMBER">%d</xliff:g> s."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Zkuste to znovu za <xliff:g id="NUMBER">%1$d</xliff:g> s."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Nakreslete gesto"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Zadejte kód PIN SIM karty"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Zadejte kód PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-da/strings.xml b/core/res/res/values-da/strings.xml
index aacf74ad..80e14c8 100644
--- a/core/res/res/values-da/strings.xml
+++ b/core/res/res/values-da/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Tillader, at appen kan flytte opgaver til forgrunden og baggrunden. Appen kan gøre dette uden din bekræftelse."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"stoppe kørsel af apps"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Tillader, at en app kan fjerne opgaver og lukke deres apps. Ondsindede apps kan forstyrre adfærden for andre apps."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"starte en aktivitet"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Tillader, at appen starter en hvilken som helst aktivitet, uanset tilladelsesbeskyttelse eller eksporteret tilstand."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"indstil skærmens kompatibilitet"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Forkert mønster"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Forkert adgangskode"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Forkert pinkode"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Prøv igen om <xliff:g id="NUMBER">%d</xliff:g> sekunder."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Prøv igen om <xliff:g id="NUMBER">%1$d</xliff:g> sekunder."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Tegn dit mønster"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Indtast pinkode til SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Indtast pinkode"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-de/strings.xml b/core/res/res/values-de/strings.xml
index a35a41a..be81e63 100644
--- a/core/res/res/values-de/strings.xml
+++ b/core/res/res/values-de/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Ermöglicht der App, Aufgaben in den Vorder- und Hintergrund zu verschieben, ohne dass dazu ein Eingreifen Ihrerseits notwendig ist."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"Aktive Apps beenden"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Ermöglicht der App, Aufgaben zu entfernen und die entsprechenden Apps zu beenden. Schädliche Apps können das Verhalten anderer Apps stören."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"Beliebige Aktivität starten"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Ermöglicht der App, ungeachtet der Berechtigungen oder des Exportstatus beliebige Aktivitäten zu starten"</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"Bildschirmkompatibilität festlegen"</string>
@@ -435,9 +439,9 @@
<string name="permlab_readCallLog" msgid="3478133184624102739">"Anrufliste lesen"</string>
<string name="permdesc_readCallLog" product="tablet" msgid="3700645184870760285">"Ermöglicht der App, die Anrufliste Ihres Tablets zu lesen, einschließlich der Daten über ein- und ausgehende Anrufe. Die Berechtigung erlaubt Apps, Ihre Anruflistendaten zu speichern, und schädliche Apps können diese Daten ohne Ihr Wissen weiterleiten."</string>
<string name="permdesc_readCallLog" product="default" msgid="5777725796813217244">"Ermöglicht der App, die Anrufliste Ihres Telefons zu lesen, einschließlich der Daten über ein- und ausgehende Anrufe. Die Berechtigung erlaubt Apps, Ihre Anruflistendaten zu speichern, und schädliche Apps können diese Daten ohne Ihr Wissen weiterleiten."</string>
- <string name="permlab_writeCallLog" msgid="8552045664743499354">"Anrufprotokoll bearbeiten"</string>
- <string name="permdesc_writeCallLog" product="tablet" msgid="6661806062274119245">"Ermöglicht der App, das Anrufprotokoll Ihres Tablets zu ändern, einschließlich der Daten über ein- und ausgehende Anrufe. Schädliche Apps können so Ihr Anrufprotokoll löschen oder ändern."</string>
- <string name="permdesc_writeCallLog" product="default" msgid="683941736352787842">"Ermöglicht der App, das Anrufprotokoll Ihres Telefons zu ändern, einschließlich der Daten über ein- und ausgehende Anrufe. Schädliche Apps können so Ihr Anrufprotokoll löschen oder ändern."</string>
+ <string name="permlab_writeCallLog" msgid="8552045664743499354">"Anrufliste bearbeiten"</string>
+ <string name="permdesc_writeCallLog" product="tablet" msgid="6661806062274119245">"Ermöglicht der App, die Anrufliste Ihres Tablets zu ändern, einschließlich der Daten über ein- und ausgehende Anrufe. Schädliche Apps können so Ihre Anrufliste löschen oder ändern."</string>
+ <string name="permdesc_writeCallLog" product="default" msgid="683941736352787842">"Ermöglicht der App, die Anrufliste Ihres Telefons zu ändern, einschließlich der Daten über ein- und ausgehende Anrufe. Schädliche Apps können so Ihre Anrufliste löschen oder ändern."</string>
<string name="permlab_readProfile" msgid="4701889852612716678">"Meine Kontaktkarten lesen"</string>
<string name="permdesc_readProfile" product="default" msgid="5462475151849888848">"Ermöglicht der App, auf Ihrem Gerät gespeicherte personenbezogene Profildaten zu lesen, einschließlich Ihres Namens und Ihrer Kontaktdaten. Die App kann Sie somit identifizieren und Ihre Profildaten an andere senden."</string>
<string name="permlab_writeProfile" msgid="907793628777397643">"Meine Kontaktkarten ändern"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo!"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1447,7 +1452,7 @@
<string name="default_media_route_name_hdmi" msgid="2450970399023478055">"HDMI"</string>
<string name="default_audio_route_category_name" msgid="3722811174003886946">"System"</string>
<string name="bluetooth_a2dp_audio_route_name" msgid="8575624030406771015">"Bluetooth-Audio"</string>
- <string name="wireless_display_route_description" msgid="9070346425023979651">"Kabellose Übertragung"</string>
+ <string name="wireless_display_route_description" msgid="9070346425023979651">"Kabellose Übertragung (WiDi)"</string>
<string name="media_route_chooser_grouping_done" msgid="7966438307723317169">"Fertig"</string>
<string name="media_route_button_content_description" msgid="5758553567065145276">"Medienausgabe"</string>
<string name="media_route_status_scanning" msgid="7279908761758293783">"Wird gescannt..."</string>
@@ -1459,7 +1464,7 @@
<string name="display_manager_hdmi_display_name" msgid="1555264559227470109">"HDMI-Bildschirm"</string>
<string name="display_manager_overlay_display_name" msgid="5142365982271620716">"Overlay-Nr. <xliff:g id="ID">%1$d</xliff:g>"</string>
<string name="display_manager_overlay_display_title" msgid="652124517672257172">"<xliff:g id="NAME">%1$s</xliff:g>: <xliff:g id="WIDTH">%2$d</xliff:g> x <xliff:g id="HEIGHT">%3$d</xliff:g>, <xliff:g id="DPI">%4$d</xliff:g> dpi"</string>
- <string name="wifi_display_notification_title" msgid="2223050649240326557">"WLAN-Anzeige ist aktiv."</string>
+ <string name="wifi_display_notification_title" msgid="2223050649240326557">"Kabellose Übertragung (WiDi) ist aktiviert."</string>
<string name="wifi_display_notification_message" msgid="4498802012464170685">"Dieser Bildschirm wird auf einem anderen Gerät angezeigt."</string>
<string name="wifi_display_notification_disconnect" msgid="6183754463561153372">"Verbindung trennen"</string>
<string name="kg_emergency_call_label" msgid="684946192523830531">"Notruf"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Falsches Muster"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Falsches Passwort"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Falsche PIN"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Versuchen Sie es in <xliff:g id="NUMBER">%d</xliff:g> Sekunden erneut."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Versuchen Sie es in <xliff:g id="NUMBER">%1$d</xliff:g> Sekunden erneut."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Muster zeichnen"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"SIM-PIN eingeben"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"PIN eingeben"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-el/strings.xml b/core/res/res/values-el/strings.xml
index 6592bde..961e15e 100644
--- a/core/res/res/values-el/strings.xml
+++ b/core/res/res/values-el/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Επιτρέπει στην εφαρμογή τη μετακίνηση εργασιών στο προσκήνιο και το παρασκήνιο. Η εφαρμογή μπορεί να το κάνει αυτό χωρίς να καταχωρίσετε δεδομένα εισόδου."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"διακοπή εκτέλεσης εφαρμογών"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Επιτρέπει στην εφαρμογή την κατάργηση ενεργειών και την απομάκρυνση των εφαρμογών τους. Τυχόν κακόβουλες εφαρμογές ενδέχεται να διαταράξουν τη λειτουργία άλλων εφαρμογών."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"έναρξη οποιασδήποτε δραστηριότητας"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Επιτρέπει στην εφαρμογή την έναρξη οποιασδήποτε δραστηριότητας, ανεξάρτητα από την προστασία αδειών ή την κατάσταση εξαγωγής."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"ρύθμιση συμβατότητας οθόνης"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Εσφαλμένο μοτίβο"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Εσφαλμένος κωδικός πρόσβασης"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Εσφαλμένος κωδικός PIN"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Δοκιμάστε ξανά σε <xliff:g id="NUMBER">%d</xliff:g> δευτερόλεπτα."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Δοκιμάστε ξανά σε <xliff:g id="NUMBER">%1$d</xliff:g> δευτερόλεπτα."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Σχεδιάστε το μοτίβο σας"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Εισαγωγή PIN SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Πληκτρολογήστε το PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-en-rGB/strings.xml b/core/res/res/values-en-rGB/strings.xml
index 8ad86c2..4825085 100644
--- a/core/res/res/values-en-rGB/strings.xml
+++ b/core/res/res/values-en-rGB/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Allows the app to move tasks to the foreground and background. The app may do this without your input."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"stop running apps"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Allows the app to remove tasks and kill their apps. Malicious apps may disrupt the behaviour of other apps."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"start any activity"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Allows the app to start any activity, regardless of permission protection or exported state."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"set screen compatibility"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"Net Meeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Wrong Pattern"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Wrong Password"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Wrong PIN"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Try again in <xliff:g id="NUMBER">%d</xliff:g> seconds."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Try again in <xliff:g id="NUMBER">%1$d</xliff:g> seconds."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Draw your pattern"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Enter SIM PIN"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Enter PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-es-rUS/strings.xml b/core/res/res/values-es-rUS/strings.xml
index 5756a31..615fcbe 100644
--- a/core/res/res/values-es-rUS/strings.xml
+++ b/core/res/res/values-es-rUS/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Permite que la aplicación mueva tareas a segundo o a primer plano. La aplicación puede utilizar este permiso para realizar estos movimientos sin indicártelo."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"detener las aplicaciones en ejecución"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Permite que la aplicación elimine tareas y cierre sus aplicaciones. Las aplicaciones malintencionadas pueden usar este permiso para interferir en el comportamiento de otras aplicaciones."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"Iniciar cualquier actividad"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Permite a la aplicación iniciar una actividad, sin importar si fue exportada ni si se encuentra protegida por permisos."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"Definir compatibilidad de pantalla"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Patrón incorrecto"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Contraseña incorrecta"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"PIN incorrecto"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Vuelve a intentarlo en <xliff:g id="NUMBER">%d</xliff:g> segundos."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Vuelve a intentarlo en <xliff:g id="NUMBER">%1$d</xliff:g> segundos."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Dibuja tu patrón."</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Ingresa el PIN de la tarjeta SIM."</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Ingresa el PIN."</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-es/strings.xml b/core/res/res/values-es/strings.xml
index 2c7ca39..2dbe795 100644
--- a/core/res/res/values-es/strings.xml
+++ b/core/res/res/values-es/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Permite que la aplicación mueva tareas a segundo o a primer plano. La aplicación puede utilizar este permiso para realizar estos movimientos sin que se lo indique el usuario."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"detener aplicaciones en ejecución"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Permite que la aplicación termine tareas y cierre sus aplicaciones. Las aplicaciones malintencionadas pueden usar este permiso para interferir en el comportamiento de otras aplicaciones."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"iniciar una actividad"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Permite que la aplicación inicie una actividad, independientemente de la protección de permisos o de si está exportada."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"establecer compatibilidad de pantalla"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo!"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"El patrón es incorrecto"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Contraseña incorrecta"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"PIN incorrecto"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Inténtalo de nuevo en <xliff:g id="NUMBER">%d</xliff:g> segundos."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Inténtalo de nuevo en <xliff:g id="NUMBER">%1$d</xliff:g> segundos."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Dibuja tu patrón de desbloqueo."</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Introduce el PIN de la tarjeta SIM."</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Introduce el PIN."</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-et/strings.xml b/core/res/res/values-et/strings.xml
index 5c31f97..cd3d97c 100644
--- a/core/res/res/values-et/strings.xml
+++ b/core/res/res/values-et/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Võimaldab rakendusel teisaldada ülesanded esiplaanile ja taustale. Rakendus võib seda teha teie sisendita."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"käitatud rakenduste peatamine"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Võimaldab rakendusel eemaldada ülesanded ja peatada nende rakendused. Pahatahtlikud rakendused võivad häirida teiste rakenduste käitumist."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"mis tahes toimingu alustamine"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Võimaldab rakendusel käivitada mis tahes toimingu loa kaitsest või eksporditud olekust sõltumata."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"kuva ühilduvuse seadmine"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Vale muster"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Vale parool"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Vale PIN-kood"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Proovige uuesti <xliff:g id="NUMBER">%d</xliff:g> sekundi pärast."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Proovige uuesti <xliff:g id="NUMBER">%1$d</xliff:g> sekundi pärast."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Joonistage oma muster"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Sisestage SIM-i PIN-kood"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Sisestage PIN-kood"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-fa/strings.xml b/core/res/res/values-fa/strings.xml
index c62b131..d4b1cb7 100644
--- a/core/res/res/values-fa/strings.xml
+++ b/core/res/res/values-fa/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"به برنامه اجازه میدهد تا کارها را به پیشزمینه و پسزمینه منتقل کند. برنامه ممکن است بدون دخالت شما این کار را انجام دهد."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"متوقف کردن برنامههای در حال اجرا"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"به برنامه اجازه میدهد تا کارها را حذف کند و برنامههای آنها را متوقف کند. برنامههای مخرب میتوانند در اجرای برنامههای دیگر اختلال ایجاد کنند."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"شروع هر نوع فعالیت"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"به برنامه اجازه میدهد هر فعالیتی را شروع کند بدون اینکه وضعیت صادرشده یا حفاظت با مجوز در نظر گرفته شود."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"تنظیم سازگاری با صفحهٔ نمایش"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"الگوی اشتباه"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"گذرواژه اشتباه"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"پین اشتباه"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"پس از <xliff:g id="NUMBER">%d</xliff:g> ثانیه دوباره امتحان کنید."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"پس از <xliff:g id="NUMBER">%1$d</xliff:g> ثانیه دوباره امتحان کنید."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"الگوی خود را رسم کنید"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"پین سیم کارت را وارد کنید"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"پین را وارد کنید"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-fi/strings.xml b/core/res/res/values-fi/strings.xml
index ded0f00..bded5cc 100644
--- a/core/res/res/values-fi/strings.xml
+++ b/core/res/res/values-fi/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Antaa sovelluksen siirtää tehtäviä etualalle ja taustalle. Sovellus ei tarvitse toimiin käyttäjän lupaa."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"käynnissä olevien sovellusten pysäyttäminen"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Antaa sovelluksen poistaa tehtäviä ja lopettaa niiden sovelluksia. Haitalliset sovellukset voivat häiritä muiden sovellusten toimintaa."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"käynnistä mikä tahansa toiminto"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Antaa sovelluksen käynnistää minkä tahansa toiminnon käyttölupasuojauksesta tai viennin tilasta huolimatta."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"aseta näytön yhteensopivuus"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Väärä kuvio"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Väärä salasana"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Väärä PIN-koodi"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Yritä uudelleen <xliff:g id="NUMBER">%d</xliff:g> sekunnin kuluttua."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Yritä uudelleen <xliff:g id="NUMBER">%1$d</xliff:g> sekunnin kuluttua."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Piirrä kuvio"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Anna SIM-kortin PIN-koodi"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Anna PIN-koodi"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-fr/strings.xml b/core/res/res/values-fr/strings.xml
index c162cf1..549c4ae 100644
--- a/core/res/res/values-fr/strings.xml
+++ b/core/res/res/values-fr/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Permet à l\'application de déplacer les tâches au premier plan et en arrière-plan. L\'application peut procéder à ces opérations sans votre intervention."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"arrêter les applications en cours d\'exécution"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Permet à l\'application de supprimer des tâches et de fermer les applications qui les exécutent. Des applications malveillantes peuvent exploiter cette fonctionnalité pour perturber le comportement des autres applications."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"démarrer n\'importe quelle activité"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Permet à l\'application de démarrer n\'importe quelle activité, quels que soient l\'état exporté ou le degré de protection appliqué à l\'autorisation."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"définir la compatibilité de l\'écran"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Schéma incorrect."</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Mot de passe incorrect."</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Code PIN incorrect."</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Réessayez dans <xliff:g id="NUMBER">%d</xliff:g> secondes."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Réessayez dans <xliff:g id="NUMBER">%1$d</xliff:g> secondes."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Dessinez votre schéma."</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Saisissez le code PIN de la carte SIM."</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Saisissez le code PIN."</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-hi/strings.xml b/core/res/res/values-hi/strings.xml
index 218cb89..768dbd1 100644
--- a/core/res/res/values-hi/strings.xml
+++ b/core/res/res/values-hi/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"एप्लिकेशन को कार्यों को अग्रभूमि और पृष्ठभूमि पर ले जाने देता है. एप्लिकेशन आपके इनपुट के बिना यह कर सकता है."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"चलने वाले एप्लिकेशन रोकें"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"किसी एप्लिकेशन को कार्यों को निकालने और उनके एप्लिकेशन समाप्त करने देता है. दुर्भावनापूर्ण एप्लिकेशन अन्य एप्लिकेशन का व्यवहार बाधित कर सकते हैं."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"कोई गतिविधि प्रारंभ करें"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"अनुमति सुरक्षा या निर्यात की स्थिति पर ध्यान दिए बिना, एप्लिकेशन को कोई गतिविधि प्रारंभ करने देता है."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"स्क्रीन संगतता सेट करें"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google टॉक"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"गलत प्रतिमान"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"गलत पासवर्ड"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"गलत PIN"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"<xliff:g id="NUMBER">%d</xliff:g> सेकंड में पुन: प्रयास करें."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"<xliff:g id="NUMBER">%1$d</xliff:g> सेकंड में पुन: प्रयास करें."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"अपना प्रतिमान आरेखित करें"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"सिम PIN डालें"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"PIN डालें"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-hr/strings.xml b/core/res/res/values-hr/strings.xml
index bda36de..730fb21 100644
--- a/core/res/res/values-hr/strings.xml
+++ b/core/res/res/values-hr/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Aplikaciji omogućuje premještanje zadataka u prednji plan ili pozadinu. Aplikacija to može napraviti bez vašeg naloga."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"zaustavljanje pokrenutih aplikacija"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Omogućuje aplikaciji uklanjanje zadataka i uklanjanje njihovih aplikacija. Zlonamjerne aplikacije mogu poremetiti rad drugih aplikacija."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"započni bilo kakvu aktivnost"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Omogućuje aplikaciji da započne bilo koju aktivnost, bez obzira na zaštitu pomoću dozvola ili stanje izvoza."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"postavljanje kompatibilnosti sa zaslonom"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Pogrešan obrazac"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Pogrešna zaporka"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Pogrešan PIN"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Pokušajte ponovo za <xliff:g id="NUMBER">%d</xliff:g> s."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Pokušajte ponovo za <xliff:g id="NUMBER">%1$d</xliff:g> s."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Iscrtajte svoj obrazac"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Unesite PIN za SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Unesite PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-hu/strings.xml b/core/res/res/values-hu/strings.xml
index 9efb6b3..23f8e74 100644
--- a/core/res/res/values-hu/strings.xml
+++ b/core/res/res/values-hu/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Lehetővé teszi az alkalmazás számára, hogy feladatokat helyezzen át az előtérből a háttérbe és fordítva. Az alkalmazás ezt az Ön jóváhagyása nélkül is megteheti."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"futó alkalmazások leállítása"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Lehetővé teszi, hogy az alkalmazás feladatokat távolítson el és leállítsa azok alkalmazásait. Rosszindulatú alkalmazások megzavarhatják más alkalmazások viselkedését."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"bármely tevékenység elindítása"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Lehetővé teszi az alkalmazás számára bármely tevékenység elindítását az engedélyektől és exportált állapottól függetlenül."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"Képernyő-kompatibilitás beállítása"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Csevegő"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Helytelen minta"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Helytelen jelszó"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Helytelen PIN kód"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Próbálkozzon újra <xliff:g id="NUMBER">%d</xliff:g> másodperc múlva."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Próbálkozzon újra <xliff:g id="NUMBER">%1$d</xliff:g> másodperc múlva."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Rajzolja le a mintát"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Adja meg a SIM kártya PIN kódját"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Adja meg a PIN kódot"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-in/strings.xml b/core/res/res/values-in/strings.xml
index de45c42..ee652c5 100644
--- a/core/res/res/values-in/strings.xml
+++ b/core/res/res/values-in/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Memungkinkan aplikasi memindah tugas ke latar depan dan latar belakang. Aplikasi dapat melakukannya tanpa masukan dari Anda."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"menghentikan apl yang berjalan"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Memungkinkan apl menghapus tugas dan menutup aplikasinya. Apl berbahaya dapat mengganggu perilaku apl lain."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"memulai aktivitas apa pun"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Mengizinkan aplikasi memulai aktivitas apa pun, terlepas dari perlindungan izin atau status yang diekspor."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"menyetel kompatibilitas layar"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -820,8 +825,8 @@
<string name="lockscreen_too_many_failed_attempts_dialog_message" msgid="6481623830344107222">"Anda telah <xliff:g id="NUMBER_0">%d</xliff:g> kali salah menggambar pola pembuka kunci. "\n\n"Coba lagi dalam <xliff:g id="NUMBER_1">%d</xliff:g> detik."</string>
<string name="lockscreen_too_many_failed_password_attempts_dialog_message" msgid="2725973286239344555">"Anda telah <xliff:g id="NUMBER_0">%d</xliff:g> kali salah mengetik sandi. "\n\n"Coba lagi dalam <xliff:g id="NUMBER_1">%d</xliff:g> detik."</string>
<string name="lockscreen_too_many_failed_pin_attempts_dialog_message" msgid="6216672706545696955">"Anda telah <xliff:g id="NUMBER_0">%d</xliff:g> kali salah mengetik PIN. "\n\n"Coba lagi dalam <xliff:g id="NUMBER_1">%d</xliff:g> detik."</string>
- <string name="lockscreen_failed_attempts_almost_glogin" product="tablet" msgid="9191611984625460820">"Anda telah <xliff:g id="NUMBER_0">%d</xliff:g> kali salah menggambar pola pembuka kunci. Setelah <xliff:g id="NUMBER_1">%d</xliff:g> lagi upaya gagal, Anda akan diminta membuka kunci tablet menggunakan info masuk Google."\n\n"Coba lagi dalam <xliff:g id="NUMBER_2">%d</xliff:g> detik."</string>
- <string name="lockscreen_failed_attempts_almost_glogin" product="default" msgid="2590227559763762751">"Anda telah <xliff:g id="NUMBER_0">%d</xliff:g> kali salah menggambar pola pembuka kunci. Setelah <xliff:g id="NUMBER_1">%d</xliff:g> lagi upaya gagal, Anda akan diminta membuka kunci ponsel menggunakan info masuk Google."\n\n"Coba lagi dalam <xliff:g id="NUMBER_2">%d</xliff:g> detik."</string>
+ <string name="lockscreen_failed_attempts_almost_glogin" product="tablet" msgid="9191611984625460820">"Anda telah <xliff:g id="NUMBER_0">%d</xliff:g> kali salah menggambar pola pembuka kunci. Setelah <xliff:g id="NUMBER_1">%d</xliff:g> lagi upaya gagal, Anda akan diminta membuka kunci tablet menggunakan proses masuk Google."\n\n"Coba lagi dalam <xliff:g id="NUMBER_2">%d</xliff:g> detik."</string>
+ <string name="lockscreen_failed_attempts_almost_glogin" product="default" msgid="2590227559763762751">"Anda telah <xliff:g id="NUMBER_0">%d</xliff:g> kali salah menggambar pola pembuka kunci. Setelah <xliff:g id="NUMBER_1">%d</xliff:g> lagi upaya gagal, Anda akan diminta membuka kunci ponsel menggunakan proses masuk Google."\n\n"Coba lagi dalam <xliff:g id="NUMBER_2">%d</xliff:g> detik."</string>
<string name="lockscreen_failed_attempts_almost_at_wipe" product="tablet" msgid="6128106399745755604">"Anda telah gagal mencoba membuka gembok tablet sebanyak <xliff:g id="NUMBER_0">%d</xliff:g> kali. Setelah <xliff:g id="NUMBER_1">%d</xliff:g> upaya gagal lagi, tablet akan disetel ulang ke setelan default pabrik dan semua data pengguna hilang."</string>
<string name="lockscreen_failed_attempts_almost_at_wipe" product="default" msgid="8603565142156826565">"Anda telah gagal mencoba membuka gembok ponsel sebanyak <xliff:g id="NUMBER_0">%d</xliff:g> kali. Setelah <xliff:g id="NUMBER_1">%d</xliff:g> upaya gagal lagi, ponsel akan disetel ulang ke setelan default pabrik dan semua data pengguna hilang."</string>
<string name="lockscreen_failed_attempts_now_wiping" product="tablet" msgid="280873516493934365">"Anda telah gagal mencoba membuka gembok tablet sebanyak <xliff:g id="NUMBER">%d</xliff:g> kali. Kini tablet akan disetel ulang ke setelan default pabrik."</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Pola Salah"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Sandi Salah"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"PIN Salah"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Coba lagi dalam <xliff:g id="NUMBER">%d</xliff:g> detik."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Coba lagi dalam <xliff:g id="NUMBER">%1$d</xliff:g> detik."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Gambar pola Anda"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Masukkan PIN SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Masukkan PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-it/strings.xml b/core/res/res/values-it/strings.xml
index 5861679..4059ad5 100644
--- a/core/res/res/values-it/strings.xml
+++ b/core/res/res/values-it/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Consente all\'applicazione di spostare attività in primo piano e in background. L\'applicazione potrebbe farlo senza un tuo comando."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"interruzione applicazioni in esecuzione"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Consente all\'applicazione di rimuovere le attività e terminare le loro applicazioni. Le applicazioni dannose potrebbero interferire con il comportamento di altre applicazioni."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"inizio di un\'attività"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Consente all\'applicazione di iniziare un\'attività, indipendentemente dalla protezione delle autorizzazioni o dallo stato esportato."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"impostazione compatibilità schermo"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Sequenza sbagliata"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Password sbagliata"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"PIN errato"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Riprova fra <xliff:g id="NUMBER">%d</xliff:g> secondi."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Riprova fra <xliff:g id="NUMBER">%1$d</xliff:g> secondi."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Inserisci la sequenza"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Inserisci il PIN della SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Inserisci PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-iw/strings.xml b/core/res/res/values-iw/strings.xml
index 37444e9..6168fdf 100644
--- a/core/res/res/values-iw/strings.xml
+++ b/core/res/res/values-iw/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"מאפשר ליישום להעביר משימות לחזית ולרקע. היישום עשוי לעשות זאת ללא התערבותך."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"עצירת יישומים פעילים"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"הרשאה זו מאפשרת ליישום להסיר משימות ולסגור את היישומים שבהם הן פועלות. יישומים זדוניים עלולים לשבש את פעולתם של יישומים אחרים."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"התחלת פעילות מכל סוג שהוא"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"מאפשר ליישום להתחיל בפעילות מכל סוג שהוא, ללא התחשבות בהגנת הרשאות או במצב מיוצא."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"הגדרת תאימות מסך"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"קו ביטול נעילה שגוי"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"סיסמה שגויה"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"מספר PIN שגוי"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"נסה שוב בעוד <xliff:g id="NUMBER">%d</xliff:g> שניות."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"נסה שוב בעוד <xliff:g id="NUMBER">%1$d</xliff:g> שניות."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"שרטט את קו ביטול הנעילה"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"הזן מספר PIN ל-SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"הזן מספר PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-ja/strings.xml b/core/res/res/values-ja/strings.xml
index 5fd3105..eb1556d 100644
--- a/core/res/res/values-ja/strings.xml
+++ b/core/res/res/values-ja/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"タスクをフォアグラウンドやバックグラウンドに移動することをアプリに許可します。これにより、アプリがユーザーからの入力なしでこの処理を実行する可能性があります。"</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"実行中のアプリの停止"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"タスクの削除とアプリの終了をアプリに許可します。この許可を悪意のあるアプリケーションに利用されると、他のアプリの動作が妨害される恐れがあります。"</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"すべてのアクティビティの開始"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"権限による保護やエクスポートされた状態を問わず、すべてのアクティビティを開始することをアプリに許可します。"</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"画面互換性の設定"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Googleトーク"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"パターンが正しくありません"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"パスワードが正しくありません"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"PINが正しくありません"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"<xliff:g id="NUMBER">%d</xliff:g>秒後にもう一度お試しください。"</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"<xliff:g id="NUMBER">%1$d</xliff:g>秒後にもう一度お試しください。"</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"パターンを入力"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"SIM PINを入力"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"PINを入力"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-ko/strings.xml b/core/res/res/values-ko/strings.xml
index a15e777..8cd152d 100644
--- a/core/res/res/values-ko/strings.xml
+++ b/core/res/res/values-ko/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"앱이 사용자의 입력 없이 작업을 포그라운드나 백그라운드로 이동할 수 있도록 허용합니다."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"실행 중인 앱 중지"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"애플리케이션이 작업을 삭제하거나 다른 애플리케이션을 중지시킬 수 있도록 허용합니다. 이 경우 악성 애플리케이션이 다른 애플리케이션의 동작을 멈추게 할 수 있습니다."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"원하는 활동 시작"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"권한 보호나 내보낸 상태에 관계없이 앱이 활동을 시작하도록 합니다."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"화면 호환성 설정"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google 토크"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"잘못된 패턴"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"잘못된 비밀번호"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"잘못된 PIN"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"<xliff:g id="NUMBER">%d</xliff:g>초 후에 다시 시도해 주세요."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"<xliff:g id="NUMBER">%1$d</xliff:g>초 후에 다시 시도해 주세요."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"패턴 그리기"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"SIM PIN 입력"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"PIN 입력"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-lt/strings.xml b/core/res/res/values-lt/strings.xml
index 267171c..ea10f2f 100644
--- a/core/res/res/values-lt/strings.xml
+++ b/core/res/res/values-lt/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Leidžiama programai perkelti užduotis į priekinį planą ir foną. Programa gali tai daryti be jūsų įsikišimo."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"sustabdyti vykdomas programas"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Leidžiama programai pašalinti užduotis ir panaikinti jų programas. Kenkėjiškos programos gali trikdyti kitų programų veikimą."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"pradėti bet kokią veiklą"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Programai leidžiama pradėti bet kokią veiklą, nepaisant leidimo apsaugos ar eksportuotos būsenos."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"nustatyti ekrano suderinamumo režimą"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"„Google“ pokalbiai"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"„Jabber“"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Netinkamas atrakinimo piešinys"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Netinkamas slaptažodis"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Netinkamas PIN kodas"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Bandyti dar kartą po <xliff:g id="NUMBER">%d</xliff:g> sek."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Bandyti dar kartą po <xliff:g id="NUMBER">%1$d</xliff:g> sek."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Nupieškite atrakinimo piešinį"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Įveskite SIM PIN kodą"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Įveskite PIN kodą"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-lv/strings.xml b/core/res/res/values-lv/strings.xml
index 79eb3ec..3e3ab2c 100644
--- a/core/res/res/values-lv/strings.xml
+++ b/core/res/res/values-lv/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Ļauj lietotnei pārvietot uzdevumus priekšplānā un fonā. Lietotne var to izdarīt bez jūsu apstiprinājuma."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"apturēt izmantoto lietotņu darbību"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Ļauj lietotnei noņemt uzdevumus un pārtraukt to lietotņu darbību. Ļaunprātīgas lietotnes var traucēt citu lietotņu darbību."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"jebkuras darbības sākšana"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Ļauj lietotnei sākt jebkuru darbību neatkarīgi no atļaujas aizsardzības vai eksportētā stāvokļa."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"Ekrāna saderības noteikšana"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Nepareiza kombinācija"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Nepareiza parole"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Nepareizs PIN"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Mēģiniet vēlreiz pēc <xliff:g id="NUMBER">%d</xliff:g> sekundēm."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Mēģiniet vēlreiz pēc <xliff:g id="NUMBER">%1$d</xliff:g> sekundēm."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Norādiet savu kombināciju"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Ievadiet SIM kartes PIN"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Ievadiet PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-ms/strings.xml b/core/res/res/values-ms/strings.xml
index cd27bba..9260061 100644
--- a/core/res/res/values-ms/strings.xml
+++ b/core/res/res/values-ms/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Membenarkan apl memindahkan tugasan ke latar depan dan latar belakang. Apl boleh melakukan ini tanpa input anda."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"hentikan apl yang sedang dijalankan"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Membenarkan apl untuk mengalih keluar tugasan dan melupuskan aplnya. Apl hasad boleh mengganggu tingkah laku apl lain."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"mulakan sebarang aktiviti"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Membenarkan apl untuk memulakan apa-apa aktiviti, tanpa mengira perlindungan kebenaran atau keadaan eksport."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"tetapkan keserasian skrin"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Bual Google"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Corak Salah"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Kata Laluan Salah"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"PIN salah"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Cuba lagi dalam <xliff:g id="NUMBER">%d</xliff:g> saat."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Cuba lagi dalam <xliff:g id="NUMBER">%1$d</xliff:g> saat."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Lukiskan corak anda"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Masukkan PIN SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Masukkan PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-nb/strings.xml b/core/res/res/values-nb/strings.xml
index 8bc91eda..b998377 100644
--- a/core/res/res/values-nb/strings.xml
+++ b/core/res/res/values-nb/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Lar appen flytte oppgaver til forgrunnen eller bakgrunnen. Appen kan gjøre dette uten instruksjoner fra deg."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"avslutte apper som kjører"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Lar appen fjerne oppgaver og avslutte apper. Ondsinnede apper kan forstyrre atferden til andre apper."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"igangsetting av aktiviteter"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Tillater at appen kan starte en aktivitet, uavhengig av tillatelsesbeskyttelse og eksportstatus."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"angi skjermkompatibilitet"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"OQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -870,7 +875,7 @@
<string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
<string name="granularity_label_character" msgid="7336470535385009523">"tegn"</string>
<string name="granularity_label_word" msgid="7075570328374918660">"ord"</string>
- <string name="granularity_label_link" msgid="5815508880782488267">"kobling"</string>
+ <string name="granularity_label_link" msgid="5815508880782488267">"link"</string>
<string name="granularity_label_line" msgid="5764267235026120888">"linje"</string>
<string name="hour_ampm" msgid="4584338083529355982">"<xliff:g id="HOUR">%-l</xliff:g><xliff:g id="AMPM">%P</xliff:g>"</string>
<string name="hour_cap_ampm" msgid="2083465992940444366">"<xliff:g id="HOUR">%-l</xliff:g><xliff:g id="AMPM">%p</xliff:g>"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Feil mønster"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Feil passord"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Feil PIN-kode"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Prøv på nytt om <xliff:g id="NUMBER">%d</xliff:g> sekunder."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Prøv på nytt om <xliff:g id="NUMBER">%1$d</xliff:g> sekunder."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Tegn mønsteret ditt"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Skriv inn PIN-koden for SIM-kortet"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Skriv inn PIN-koden"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-nl/strings.xml b/core/res/res/values-nl/strings.xml
index 4101c47..af72700 100644
--- a/core/res/res/values-nl/strings.xml
+++ b/core/res/res/values-nl/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Hiermee kan de app taken naar de voor- en achtergrond verplaatsen. De app kan dit doen zonder om uw bevestiging te vragen."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"actieve apps stoppen"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Hiermee kan de app taken verwijderen en apps sluiten. Schadelijke apps kunnen het gedrag van andere apps verstoren."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"elke activiteit starten"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Toestaan dat de app elke activiteit start, ongeacht rechtenbeveiliging of geëxporteerde status."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"schermcompatibiliteit instellen"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Onjuist patroon"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Onjuist wachtwoord"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Onjuiste pincode"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Probeer het over <xliff:g id="NUMBER">%d</xliff:g> seconden opnieuw."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Probeer het over <xliff:g id="NUMBER">%1$d</xliff:g> seconden opnieuw."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Teken uw patroon"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Geef de pincode van de simkaart op"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Pincode opgeven"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-pl/strings.xml b/core/res/res/values-pl/strings.xml
index 9623ab9..588df6f 100644
--- a/core/res/res/values-pl/strings.xml
+++ b/core/res/res/values-pl/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Pozwala aplikacji na przenoszenie zadań między tłem a pierwszym planem. Aplikacja może to robić bez Twojego udziału."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"zatrzymywanie uruchomionych aplikacji"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Umożliwia aplikacji usuwanie zadań i kończenie powiązanych z nimi aplikacji. Złośliwe aplikacje mogą zakłócić działanie innych aplikacji."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"rozpoczynanie dowolnej czynności"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Zezwala aplikacji na rozpoczynanie dowolnej czynności niezależnie od ochrony uprawnień lub stanu eksportu."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"ustaw zgodność ekranu"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Nieprawidłowy wzór"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Nieprawidłowe hasło"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Nieprawidłowy PIN"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Spróbuj ponownie za <xliff:g id="NUMBER">%d</xliff:g> s."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Spróbuj ponownie za <xliff:g id="NUMBER">%1$d</xliff:g> s."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Narysuj wzór"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Podaj PIN karty SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Podaj PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-pt-rPT/strings.xml b/core/res/res/values-pt-rPT/strings.xml
index b139363..4d22c52 100644
--- a/core/res/res/values-pt-rPT/strings.xml
+++ b/core/res/res/values-pt-rPT/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Permite que a aplicação mova tarefas para primeiro e segundo plano. A aplicação poderá fazê-lo sem qualquer entrada do utilizador."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"parar aplicações em execução"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Permite que a aplicação remova tarefas e elimine as respetivas aplicações. As aplicações maliciosas podem perturbar o comportamento de outras aplicações."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"iniciar qualquer atividade"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Permite que a aplicação inicie qualquer atividade, independentemente da proteção de permissão ou do estado exportado."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"definir compatibilidade de ecrã"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Sequência Incorreta"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Palavra-passe Incorreta"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"PIN Incorreto"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Tente novamente dentro de <xliff:g id="NUMBER">%d</xliff:g> segundos."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Tente novamente dentro de <xliff:g id="NUMBER">%1$d</xliff:g> segundos."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Desenhe a sua sequência"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Introduzir PIN do cartão SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Introduzir PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-pt/strings.xml b/core/res/res/values-pt/strings.xml
index 457a7a6..d9a997e 100644
--- a/core/res/res/values-pt/strings.xml
+++ b/core/res/res/values-pt/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Permite que o aplicativo mova tarefas para o primeiro plano e o plano de fundo, sem sua intervenção."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"parar os aplicativos em execução"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Permite que um aplicativo remova tarefas e elimine seus aplicativos. Aplicativos maliciosos podem interferir no comportamento de outros aplicativos."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"iniciar qualquer atividade"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Permite que o aplicativo inicie qualquer atividade, independentemente da permissão ou do estado exportado."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"definir a compatibilidade de tela"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Padrão incorreto"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Senha incorreta"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"PIN incorreto"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Tente novamente em <xliff:g id="NUMBER">%d</xliff:g> segundos."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Tente novamente em <xliff:g id="NUMBER">%1$d</xliff:g> segundos."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Desenhe seu padrão"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Digite o PIN do cartão SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Digite o PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-rm/strings.xml b/core/res/res/values-rm/strings.xml
index b124437..c5b4fd1 100644
--- a/core/res/res/values-rm/strings.xml
+++ b/core/res/res/values-rm/strings.xml
@@ -414,6 +414,10 @@
<skip />
<!-- no translation found for permdesc_removeTasks (1394714352062635493) -->
<skip />
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<!-- no translation found for permlab_startAnyActivity (2918768238045206456) -->
<skip />
<!-- no translation found for permdesc_startAnyActivity (997823695343584001) -->
@@ -1198,7 +1202,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -2529,4 +2534,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-ro/strings.xml b/core/res/res/values-ro/strings.xml
index 708b632..a058815 100644
--- a/core/res/res/values-ro/strings.xml
+++ b/core/res/res/values-ro/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Permite aplicaţiei să mute activităţile în prim-plan şi în fundal. Aplicaţia poate face acest lucru fără aportul dvs."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"oprire aplicaţii care rulează"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Permite aplicaţiei să elimine sarcini şi să închidă aplicaţiile corespunzătoare acestora. Aplicaţiile rău intenţionate pot perturba comportamentul altor aplicaţii."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"începe orice activitate"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Permite aplicaţiei să înceapă orice activitate, indiferent de protecţia permisiunii şi de starea de export."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"setaţi compatibilitatea ecranului"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Model greşit"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Parolă greşită"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Cod PIN greşit"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Încercaţi din nou peste <xliff:g id="NUMBER">%d</xliff:g> (de) secunde."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Încercaţi din nou peste <xliff:g id="NUMBER">%1$d</xliff:g> (de) secunde."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Desenaţi modelul"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Introduceţi codul PIN al cardului SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Introduceţi codul PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-ru/strings.xml b/core/res/res/values-ru/strings.xml
index 66136de..b742263 100644
--- a/core/res/res/values-ru/strings.xml
+++ b/core/res/res/values-ru/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Приложение сможет переключать активный и фоновый режимы выполнения задач без вашего ведома."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"Остановка работающих приложений"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Приложение сможет удалять задачи и собственные программы. Вредоносное ПО при этом сможет нарушать работу других приложений."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"Совершать любые действия"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Приложение сможет совершать любые действия независимо от наличия разрешений и состояния."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"Установка режима совместимости"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Неправильный графический ключ"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Неправильный пароль"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Неправильный PIN-код"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Повторите попытку через <xliff:g id="NUMBER">%d</xliff:g> сек."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Повторите попытку через <xliff:g id="NUMBER">%1$d</xliff:g> сек."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Введите графический ключ"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Введите PIN-код SIM-карты"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Введите PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-sk/strings.xml b/core/res/res/values-sk/strings.xml
index aa24702..f6a62cd 100644
--- a/core/res/res/values-sk/strings.xml
+++ b/core/res/res/values-sk/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Umožňuje aplikácii presunúť úlohy do popredia alebo do pozadia. Aplikácia tak môže urobiť bez vášho zásahu."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"zastaviť spustené aplikácie"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Umožňuje aplikácii odstrániť úlohy a ukončiť ich aplikácie. Škodlivé aplikácie môžu narušiť správanie iných aplikácií."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"spustiť ľubovoľnú aktivitu"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Umožňuje aplikácii spustiť ľubovoľnú aktivitu bez ohľadu na ochranu povolení alebo exportovaný stav."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"nastaviť kompatibilitu obrazovky"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Nesprávny vzor"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Nesprávne heslo"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Nesprávny kód PIN"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Skúste to znova o <xliff:g id="NUMBER">%d</xliff:g> s."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Skúste to znova o <xliff:g id="NUMBER">%1$d</xliff:g> s."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Nakreslite svoj vzor"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Zadajte kód PIN karty SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Zadajte kód PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-sl/strings.xml b/core/res/res/values-sl/strings.xml
index 298d0cc..ffbae22 100644
--- a/core/res/res/values-sl/strings.xml
+++ b/core/res/res/values-sl/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Aplikaciji omogoča premikanje opravil v ospredje in ozadje. Aplikacija lahko to naredi brez vašega nadzora."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"ustavitev programov, ki se izvajajo"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Programu omogoča odstranjevanje opravil in zapiranje njihovih programov. Zlonamerni programi lahko motijo delovanje drugih programov."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"zagon poljubne dejavnosti"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Omogoča aplikaciji zagon poljubne dejavnosti, ne glede na zaščito dovoljenj ali izvoženo stanje."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"nastavitev združljivosti zaslona"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Napačen vzorec"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Napačno geslo"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Napačen PIN"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Čez <xliff:g id="NUMBER">%d</xliff:g> sekund poskusite znova."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Čez <xliff:g id="NUMBER">%1$d</xliff:g> sekund poskusite znova."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Narišite vzorec"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Vnesite PIN za kartico SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Vnesite PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-sr/strings.xml b/core/res/res/values-sr/strings.xml
index a762056..7465798 100644
--- a/core/res/res/values-sr/strings.xml
+++ b/core/res/res/values-sr/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Дозвољава апликацији да премешта задатке у први план и у позадину. Апликација може да ради ово без вашег уноса."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"заустављање покренутих апликација"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Дозвољава апликацији да уклања задатке и уништава њихове апликације. Злонамерне апликације могу да поремете понашање других апликација."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"покретање било које активности"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Омогућава да апликација покрене било коју активност, без обзира на заштиту дозволе или стање извоза."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"подешавање компатибилности екрана"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Погрешан шаблон"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Погрешна лозинка"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Погрешан PIN"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Покушајте поново за <xliff:g id="NUMBER">%d</xliff:g> секунде(и)."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Покушајте поново за <xliff:g id="NUMBER">%1$d</xliff:g> секунде(и)."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Нацртајте шаблон"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Унесите PIN SIM картице"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Унесите PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-sv/strings.xml b/core/res/res/values-sv/strings.xml
index 9e4b548..5e39d66 100644
--- a/core/res/res/values-sv/strings.xml
+++ b/core/res/res/values-sv/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Tillåter att appen flyttar aktiviteter till förgrunden eller bakgrunden. Appen kan göra detta utan åtgärd från dig."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"avsluta appar som körs"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Tillåter att appen tar bort uppgifter och avslutar appar. Skadliga appar kan störa funktionen i andra appar."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"starta alla aktiviteter"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Appen tillåts starta alla aktiviteter oavsett behörighetsskydd eller exportstatus."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"ange skärmkompatibilitet"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Fel grafiskt lösenord"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Fel lösenord"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Fel PIN-kod"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Försök igen om <xliff:g id="NUMBER">%d</xliff:g> sekunder."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Försök igen om <xliff:g id="NUMBER">%1$d</xliff:g> sekunder."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Rita ditt grafiska lösenord"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Ange PIN-kod för SIM-kortet"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Ange PIN-kod"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-sw/strings.xml b/core/res/res/values-sw/strings.xml
index 2e21886..29ef9b3 100644
--- a/core/res/res/values-sw/strings.xml
+++ b/core/res/res/values-sw/strings.xml
@@ -207,7 +207,7 @@
<string name="permgrouplab_wallpaper" msgid="3850280158041175998">"Taswira"</string>
<string name="permgroupdesc_wallpaper" msgid="5630417854750540154">"Badilisha mipangilio taswira ya kifaa."</string>
<string name="permgrouplab_systemClock" msgid="406535759236612992">"Saa"</string>
- <string name="permgroupdesc_systemClock" msgid="3944359833624094992">"Badilisha muda wa kifaa au ukanda wa saa."</string>
+ <string name="permgroupdesc_systemClock" msgid="3944359833624094992">"Badilisha saa za kifaa au za eneo."</string>
<string name="permgrouplab_statusBar" msgid="2095862568113945398">"Hali Upau"</string>
<string name="permgroupdesc_statusBar" msgid="6242593432226807171">"Badilisha mipangilio ya upau wa hali ya kifaa."</string>
<string name="permgrouplab_syncSettings" msgid="3341990986147826541">"Mipangilio ya Upatanishi"</string>
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Inaruhusu programu kusongesha kazi hadi kwenye mandhari-mbele na mandari nyuma. Programu inaweza kufanya haya bila ya maingizo yako."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"Komesha programu zinazoendeshwa"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Huruhusu programu kuondoa majukumu na kuua programu zao. Programu hasidi zinaweza kutatiza tabia ya programu zingine."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"anzisha shughuli yoyote"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Huruhusu programu kuanzisha shughuli yoyote, pasi kujali ulinzi wa idhini au hali ya nje."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"weka utangamano wa skrini"</string>
@@ -549,7 +553,7 @@
<string name="permlab_setTime" msgid="2021614829591775646">"weka muda"</string>
<string name="permdesc_setTime" product="tablet" msgid="1896341438151152881">"Inaruhusu programu kubadilisha wakati wa saa ya kompyuta kibao."</string>
<string name="permdesc_setTime" product="default" msgid="1855702730738020">"Inaruhusu programu kubadilisha wakati wa saa ya simu."</string>
- <string name="permlab_setTimeZone" msgid="2945079801013077340">"weka ukanda wa saa"</string>
+ <string name="permlab_setTimeZone" msgid="2945079801013077340">"weka saa za eneo"</string>
<string name="permdesc_setTimeZone" product="tablet" msgid="1676983712315827645">"Inaruhusu programu kubadilisha majira ya saa ya kompyuta kibao."</string>
<string name="permdesc_setTimeZone" product="default" msgid="4499943488436633398">"Inaruhusu programu kubadilisha majira ya saa ya simu."</string>
<string name="permlab_accountManagerService" msgid="4829262349691386986">"tenda kama Huduma ya Meneja wa Akaunti"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Mchoro Usio sahihi"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Nenosiri Lisilo sahihi"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"PIN isiyo sahihi"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Jaribu tena baada ya sekunde <xliff:g id="NUMBER">%d</xliff:g>."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Jaribu tena baada ya sekunde <xliff:g id="NUMBER">%1$d</xliff:g>."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Chora ruwaza yako"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Ingiza PIN ya SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Ingiza PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-th/strings.xml b/core/res/res/values-th/strings.xml
index 60c22ea..9087783 100644
--- a/core/res/res/values-th/strings.xml
+++ b/core/res/res/values-th/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"อนุญาตให้แอปพลิเคชันย้ายงานไปยังส่วนหน้าและพื้นหลัง แอปพลิเคชันอาจดำเนินการโดยไม่รอคำสั่งจากคุณ"</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"หยุดแอปพลิเคชันที่ทำงานอยู่"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"อนุญาตให้แอปพลิเคชันลบงานออกและยุติแอปพลิเคชันต่างๆ ของงานนั้น แอปพลิเคชันที่เป็นอันตรายอาจทำให้แอปพลิเคชันอื่นๆ ทำงานได้ไม่ถูกต้อง"</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"เริ่มต้นกิจกรรมใดๆ"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"อนุญาตให้แอปพลิเคชันเริ่มกิจกรรม ไม่ว่าการอนุญาตหรือสถานะที่ส่งออกจะเป็นอย่างไรก็ตาม"</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"ตั้งค่าความเข้ากันได้ของหน้าจอ"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"รูปแบบไม่ถูกต้อง"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"รหัสผ่านไม่ถูกต้อง"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"PIN ไม่ถูกต้อง"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"ลองอีกครั้งในอีก <xliff:g id="NUMBER">%d</xliff:g> วินาที"</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"ลองอีกครั้งในอีก <xliff:g id="NUMBER">%1$d</xliff:g> วินาที"</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"วาดรูปแบบของคุณ"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"ป้อน PIN ของซิม"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"ป้อน PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-tl/strings.xml b/core/res/res/values-tl/strings.xml
index e1dfbad..d30fb77 100644
--- a/core/res/res/values-tl/strings.xml
+++ b/core/res/res/values-tl/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Pinapayagan ang app na maglipat ng mga gawain sa foreground at background. Maaari itong gawin ng app nang wala ng iyong input."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"ihinto ang pagpapatakbo ng apps"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Pinapayagan ang app na mag-alis ng mga gawain at i-off ang apps nito. Maaaring maantala ng nakakahamak na apps ang pagkilos ng iba pang apps."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"magsimula ng anumang aktibidad"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Binibigyang-daan ang app na magsimula ng anumang aktibidad, may proteksyon man ng pahintulot o na-export na katayuan."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"itakda ang pagkakatugma ng screen"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Maling Pattern"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Maling Password"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Maling PIN"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Subukang muli sa loob ng <xliff:g id="NUMBER">%d</xliff:g> (na) segundo."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Subukang muli sa loob ng <xliff:g id="NUMBER">%1$d</xliff:g> (na) segundo."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Iguhit ang iyong pattern"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Ilagay ang SIM PIN"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Ilagay ang PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-tr/strings.xml b/core/res/res/values-tr/strings.xml
index 419d1ca..30691d9 100644
--- a/core/res/res/values-tr/strings.xml
+++ b/core/res/res/values-tr/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Uygulamaya, görevleri ön plana ve arka plana taşıma izni verir. Uygulama bunu sizden bir giriş olmadan yapabilir."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"çalışan uygulamaları durdur"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Uygulamaya, görevleri kaldırma ve bunlara ait uygulamaları kapatma izni verir. Kötü amaçlı uygulamalar diğer uygulamaların çalışmasını bozabilir."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"herhangi bir etkinlik başlat"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Uygulamaya, izin koruma veya dışa aktarma durumu ne olursa olsun bir etkinlik başlatma izni verir."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"ekran uyumluluğunu ayarla"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Yanlış Desen"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Yanlış Şifre"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Yanlış PIN"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"<xliff:g id="NUMBER">%d</xliff:g> saniye içinde yeniden deneyin."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"<xliff:g id="NUMBER">%1$d</xliff:g> saniye içinde yeniden deneyin."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Deseninizi çizin"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"SIM PIN kodunu girin"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"PIN\'i girin"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-uk/strings.xml b/core/res/res/values-uk/strings.xml
index 047e288..db27c85 100644
--- a/core/res/res/values-uk/strings.xml
+++ b/core/res/res/values-uk/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Дозволяє програмі переміщувати завдання в активні чи фонові вікна. Програма може робити це без вашого відома."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"зупиняти запущені програми"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Дозволяє програмі видаляти завдання та примусово припиняти роботу відповідних програм. Шкідливі програми можуть переривати роботу інших програм."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"розпочинати будь-які дії"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Дозволяє програмі розпочинати будь-які дії, незалежно від захищеного дозволу або стану експорту."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"установити сумісність екрана"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Неправильний ключ"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Неправильний пароль"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Неправильний PIN-код"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Повторіть спробу через <xliff:g id="NUMBER">%d</xliff:g> с."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Повторіть спробу через <xliff:g id="NUMBER">%1$d</xliff:g> с."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Намалюйте ключ"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Введіть PIN-код SIM-карти"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Введіть PIN-код"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-vi/strings.xml b/core/res/res/values-vi/strings.xml
index 4f1f931..3002bcd 100644
--- a/core/res/res/values-vi/strings.xml
+++ b/core/res/res/values-vi/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Cho phép ứng dụng di chuyển công việc sang nền trước và nền sau. Ứng dụng có thể thực hiện việc này mà không cần bạn nhập."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"dừng các ứng dụng đang chạy"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Cho phép ứng dụng xóa công việc và loại bỏ các ứng dụng của chúng. Ứng dụng độc hại có thể làm gián đoạn hoạt động của các ứng dụng khác."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"bắt đầu mọi hoạt động"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Cho phép ứng dụng bắt đầu mọi hoạt động, bất kể tình trạng bảo vệ quyền hay trạng thái xuất."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"đặt độ tương thích màn hình"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Hình sai"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Mật khẩu sai"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"PIN sai"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Hãy thử lại sau <xliff:g id="NUMBER">%d</xliff:g> giây."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Hãy thử lại sau <xliff:g id="NUMBER">%1$d</xliff:g> giây."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Vẽ hình của bạn"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Nhập PIN của SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Nhập PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-zh-rCN/strings.xml b/core/res/res/values-zh-rCN/strings.xml
index 685e43f..52526de 100644
--- a/core/res/res/values-zh-rCN/strings.xml
+++ b/core/res/res/values-zh-rCN/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"允许该应用将任务移动到前台和后台。该应用可能不经您的命令自行执行此操作。"</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"停止正在运行的应用"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"允许该应用删除任务并终止这些任务的应用。恶意应用可以籍此影响其他应用的行为。"</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"启动任何活动"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"允许该应用启动任何活动(不考虑权限保护或导出状态)。"</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"设置屏幕兼容性"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"雅虎"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"图案错误"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"密码错误"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"PIN 有误"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"请在 <xliff:g id="NUMBER">%d</xliff:g> 秒后重试。"</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"请在 <xliff:g id="NUMBER">%1$d</xliff:g> 秒后重试。"</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"绘制您的图案"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"输入 SIM PIN"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"输入 PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-zh-rTW/strings.xml b/core/res/res/values-zh-rTW/strings.xml
index 50af84b..922a4f5 100644
--- a/core/res/res/values-zh-rTW/strings.xml
+++ b/core/res/res/values-zh-rTW/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"允許應用程式將工作移至前景或背景。應用程式可以自行處理,不待您操作。"</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"停止執行中的應用程式"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"允許應用程式移除工作並終止執行工作的應用程式。請注意,惡意應用程式可能利用此功能干擾其他應用程式的行為。"</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"啟動任何活動"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"不論權限保護或匯出狀態為何,一律允許應用程式啟動任何活動。"</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"設定螢幕相容性"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Google Talk"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"網路會議"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"圖形錯誤"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"密碼錯誤"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"PIN 錯誤"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"請在 <xliff:g id="NUMBER">%d</xliff:g> 秒後再試一次。"</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"請在 <xliff:g id="NUMBER">%1$d</xliff:g> 秒後再試一次。"</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"畫出圖形"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"輸入 SIM PIN"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"輸入 PIN"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values-zu/strings.xml b/core/res/res/values-zu/strings.xml
index 127743e..3eaf19f 100644
--- a/core/res/res/values-zu/strings.xml
+++ b/core/res/res/values-zu/strings.xml
@@ -279,6 +279,10 @@
<string name="permdesc_reorderTasks" msgid="7734217754877439351">"Ivumela uhlelo lokusebenza ukugudluza imisebenzi ngaphambili nangasemuva. Uhlelo lokusebenza lungenza lokhu ngaphandle kwakho."</string>
<string name="permlab_removeTasks" msgid="6821513401870377403">"misa izinsiza ezisebenzayo"</string>
<string name="permdesc_removeTasks" msgid="1394714352062635493">"Vumela ukuthi insiza isuse okumele kwenziwe ibulale nezinsiza zakho. Izinsiza eziwubungozi zingaphazamisa ukusebenza kwezinye izinsiza."</string>
+ <!-- no translation found for permlab_manageActivityStacks (7391191384027303065) -->
+ <skip />
+ <!-- no translation found for permdesc_manageActivityStacks (1615881933034084440) -->
+ <skip />
<string name="permlab_startAnyActivity" msgid="2918768238045206456">"qala noma imuphi umsebenzi"</string>
<string name="permdesc_startAnyActivity" msgid="997823695343584001">"Ivumela uhlelo lokusebenza ukuqala umsebenzi, ngaphandle kokuvukeleka kwemvume noma isimo sokukhishiwe."</string>
<string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"setha ukuhambelana kwesikrini"</string>
@@ -748,7 +752,8 @@
<string name="imProtocolYahoo" msgid="8271439408469021273">"i-Yahoo"</string>
<string name="imProtocolSkype" msgid="9019296744622832951">"i-Skype"</string>
<string name="imProtocolQq" msgid="8887484379494111884">"QQ"</string>
- <string name="imProtocolGoogleTalk" msgid="3808393979157698766">"Ingxoxo ye-Google"</string>
+ <!-- no translation found for imProtocolGoogleTalk (493902321140277304) -->
+ <skip />
<string name="imProtocolIcq" msgid="1574870433606517315">"i-ICQ"</string>
<string name="imProtocolJabber" msgid="2279917630875771722">"i-Jabber"</string>
<string name="imProtocolNetMeeting" msgid="8287625655986827971">"Umhlangano we-Net"</string>
@@ -1467,7 +1472,7 @@
<string name="kg_wrong_pattern" msgid="1850806070801358830">"Iphatheni engalungile"</string>
<string name="kg_wrong_password" msgid="2333281762128113157">"Iphasiwedi engalungile"</string>
<string name="kg_wrong_pin" msgid="1131306510833563801">"Iphinikhodi engalungile"</string>
- <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Zama futhi emasekhondini angu-<xliff:g id="NUMBER">%d</xliff:g>."</string>
+ <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"Zama futhi emasekhondini angu-<xliff:g id="NUMBER">%1$d</xliff:g>."</string>
<string name="kg_pattern_instructions" msgid="398978611683075868">"Dweba iphethini"</string>
<string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Faka iphinikhodi ye-SIM"</string>
<string name="kg_pin_instructions" msgid="2377242233495111557">"Faka iphinikhodi"</string>
@@ -1588,4 +1593,16 @@
<skip />
<!-- no translation found for mediaSize_na_tabloid (5775966416333578127) -->
<skip />
+ <!-- no translation found for restr_pin_create_pin (8017600000263450337) -->
+ <skip />
+ <!-- no translation found for restr_pin_enter_pin (3395953421368476103) -->
+ <skip />
+ <!-- no translation found for restr_pin_confirm_pin (2891475237150965991) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_doesnt_match (2224214190906994548) -->
+ <skip />
+ <!-- no translation found for restr_pin_error_too_short (8173982756265777792) -->
+ <skip />
+ <!-- no translation found for restr_pin_countdown:one (4835639969503729874) -->
+ <!-- no translation found for restr_pin_countdown:other (8030607343223287654) -->
</resources>
diff --git a/core/res/res/values/config.xml b/core/res/res/values/config.xml
index d844076..7076922 100644
--- a/core/res/res/values/config.xml
+++ b/core/res/res/values/config.xml
@@ -783,6 +783,15 @@
<!-- IP address of the dns server to use if nobody else suggests one -->
<string name="config_default_dns_server" translatable="false">8.8.8.8</string>
+ <!-- The default mobile provisioning url. Empty by default, maybe overridden by
+ an mcc/mnc specific config.xml -->
+ <string name="mobile_provisioning_url" translatable="false"></string>
+
+ <!-- This url is used as the default url when redirection is detected. Any
+ should work as all url's get redirected. But maybe overridden by
+ if needed. -->
+ <string name="mobile_redirected_provisioning_url" translatable="false">http://google.com</string>
+
<!-- The default character set for GsmAlphabet -->
<!-- Empty string means MBCS is not considered -->
<string name="gsm_alphabet_default_charset" translatable="false"></string>
diff --git a/core/res/res/values/symbols.xml b/core/res/res/values/symbols.xml
index 38aa2a0..b58fcfc 100755
--- a/core/res/res/values/symbols.xml
+++ b/core/res/res/values/symbols.xml
@@ -682,6 +682,8 @@
<java-symbol type="string" name="preposition_for_time" />
<java-symbol type="string" name="progress_erasing" />
<java-symbol type="string" name="progress_unmounting" />
+ <java-symbol type="string" name="mobile_provisioning_url" />
+ <java-symbol type="string" name="mobile_redirected_provisioning_url" />
<java-symbol type="string" name="reboot_safemode_confirm" />
<java-symbol type="string" name="reboot_safemode_title" />
<java-symbol type="string" name="relationTypeAssistant" />
diff --git a/docs/html/tools/help/uiautomator/Configurator.jd b/docs/html/tools/help/uiautomator/Configurator.jd
new file mode 100644
index 0000000..c898772
--- /dev/null
+++ b/docs/html/tools/help/uiautomator/Configurator.jd
@@ -0,0 +1,960 @@
+page.title=Configurator
+parent.title=uiautomator
+parent.link=index.html
+
+@jd:body
+<style>
+ h4.jd-details-title {background-color: #DEE8F1;}
+</style>
+
+<div id="api-info-block">
+<div class="api-level" style="margin:-95px 0 0;">
+Since <a href="/guide/topics/manifest/uses-sdk-element.html#ApiLevels">API level 18</a>
+</div>
+</div>
+
+<p>Allows you to set key parameters for running uiautomator tests. The new
+settings take effect immediately and can be changed any time during a test run.
+To modify parameters using <code><a href="#">Configurator</a></code>, first
+obtain an instance by calling <code><a href="#getInstance()">getInstance()</a></code>.
+As a best practice, make sure you always save the original value of any
+parameter that you are modifying. After running your tests with the modified
+parameters, make sure to also restore the original parameter values, otherwise
+this will impact other tests cases.</p>
+
+
+<h2>Summary</h2>
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+<!-- ========== METHOD SUMMARY =========== -->
+<table id="pubmethods" class="jd-sumtable"><tr><th colspan="12">Public Methods</th></tr>
+
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ long</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getActionAcknowledgmentTimeout()">getActionAcknowledgmentTimeout</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Gets the current timeout for waiting for an acknowledgment of generic
+ uiautomator actions, such as clicks, text setting, and menu presses.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+ static
+
+ <a href="#">Configurator</a></nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getInstance()">getInstance</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Retrieves a singleton instance of Configurator.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ long</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getKeyInjectionDelay()">getKeyInjectionDelay</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Gets the current delay between key presses when injecting text input.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ long</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getScrollAcknowledgmentTimeout()">getScrollAcknowledgmentTimeout</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Gets the timeout for waiting for an acknowledgement of an
+ uiautomtor scroll swipe action.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ long</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getWaitForIdleTimeout()">getWaitForIdleTimeout</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Gets the current timeout used for waiting for the user interface to go
+ into an idle state.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ long</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getWaitForSelectorTimeout()">getWaitForSelectorTimeout</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Gets the current timeout for waiting for a widget to become visible in
+ the user interface so that it can be matched by a selector.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">Configurator</a></nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#setActionAcknowledgmentTimeout(long)">setActionAcknowledgmentTimeout</a></span>(long timeout)</nobr>
+
+ <div class="jd-descrdiv">Sets the timeout for waiting for an acknowledgment of generic uiautomator
+ actions, such as clicks, text setting, and menu presses.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">Configurator</a></nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#setKeyInjectionDelay(long)">setKeyInjectionDelay</a></span>(long delay)</nobr>
+
+ <div class="jd-descrdiv">Sets a delay between key presses when injecting text input.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">Configurator</a></nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#setScrollAcknowledgmentTimeout(long)">setScrollAcknowledgmentTimeout</a></span>(long timeout)</nobr>
+
+ <div class="jd-descrdiv">Sets the timeout for waiting for an acknowledgement of an
+ uiautomtor scroll swipe action.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">Configurator</a></nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#setWaitForIdleTimeout(long)">setWaitForIdleTimeout</a></span>(long timeout)</nobr>
+
+ <div class="jd-descrdiv">Sets the timeout for waiting for the user interface to go into an idle
+ state before starting a uiautomator action.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">Configurator</a></nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#setWaitForSelectorTimeout(long)">setWaitForSelectorTimeout</a></span>(long timeout)</nobr>
+
+ <div class="jd-descrdiv">Sets the timeout for waiting for a widget to become visible in the user
+ interface so that it can be matched by a selector.</div>
+
+ </td></tr>
+
+
+
+</table>
+
+
+
+
+
+
+
+<!-- ========== METHOD SUMMARY =========== -->
+<table id="inhmethods" class="jd-sumtable"><tr><th>
+ <a href="#" class="toggle-all" onclick="return toggleAllInherited(this, null)">[Expand]</a>
+ <div style="clear:left;">Inherited Methods</div></th></tr>
+
+
+<tr class="api" >
+<td colspan="12">
+ <a href="#" onclick="return toggleInherited(this, null)" id="inherited-methods-java.lang.Object" class="jd-expando-trigger closed"
+ ><img id="inherited-methods-java.lang.Object-trigger"
+ src="../../../../../assets/images/triangle-closed.png"
+ class="jd-expando-trigger-img" /></a>
+From class
+
+ java.lang.Object
+
+<div id="inherited-methods-java.lang.Object">
+ <div id="inherited-methods-java.lang.Object-list"
+ class="jd-inheritedlinks">
+ </div>
+ <div id="inherited-methods-java.lang.Object-summary" style="display: none;">
+ <table class="jd-sumtable-expando">
+
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ Object</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">clone</span>()</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">equals</span>(Object arg0)</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">finalize</span>()</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+ final
+
+
+ Class<?></nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">getClass</span>()</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ int</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">hashCode</span>()</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+ final
+
+
+ void</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">notify</span>()</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+ final
+
+
+ void</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">notifyAll</span>()</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">toString</span>()</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+ final
+
+
+ void</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">wait</span>()</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+ final
+
+
+ void</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">wait</span>(long arg0, int arg1)</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+ final
+
+
+ void</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">wait</span>(long arg0)</nobr>
+
+ </td></tr>
+
+
+</table>
+ </div>
+</div>
+</td></tr>
+
+
+</table>
+
+
+</div><!-- jd-descr (summary) -->
+
+<!-- Details -->
+
+
+
+
+
+
+
+
+<!-- XML Attributes -->
+
+
+<!-- Enum Values -->
+
+
+<!-- Constants -->
+
+
+<!-- Fields -->
+
+
+<!-- Public ctors -->
+
+
+
+<!-- ========= CONSTRUCTOR DETAIL ======== -->
+<!-- Protected ctors -->
+
+
+
+<!-- ========= METHOD DETAIL ======== -->
+<!-- Public methdos -->
+
+<h2>Public Methods</h2>
+
+
+
+<A NAME="getActionAcknowledgmentTimeout()"></A>
+
+<div class="jd-details api apilevel-18">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ long
+ </span>
+ <span class="sympad">getActionAcknowledgmentTimeout</span>
+ <span class="normal">()</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Gets the current timeout for waiting for an acknowledgment of generic
+ uiautomator actions, such as clicks, text setting, and menu presses.
+
+ The acknowledgment is an <a href="http://developer.android.com/reference/android/view/accessibility/AccessibilityEvent.html">AccessibilityEvent</a>,
+ corresponding to an action, that lets the framework determine if the
+ action was successful. Generally, this timeout should not be modified.
+ See <code><a href="UiObject.html">UiObject</a></code></p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>current timeout in milliseconds</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+
+ </div>
+</div>
+
+
+<A NAME="getInstance()"></A>
+
+<div class="jd-details api apilevel-18">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+ static
+
+
+
+ <a href="#">Configurator</a>
+ </span>
+ <span class="sympad">getInstance</span>
+ <span class="normal">()</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Retrieves a singleton instance of Configurator.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>Configurator instance</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+
+ </div>
+</div>
+
+
+<A NAME="getKeyInjectionDelay()"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ long
+ </span>
+ <span class="sympad">getKeyInjectionDelay</span>
+ <span class="normal">()</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Gets the current delay between key presses when injecting text input.
+ See <code><a href="UiObject.html#setText(java.lang.String)">setText(String)</a></code></p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>current delay in milliseconds</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="getScrollAcknowledgmentTimeout()"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ long
+ </span>
+ <span class="sympad">getScrollAcknowledgmentTimeout</span>
+ <span class="normal">()</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Gets the timeout for waiting for an acknowledgement of an
+ uiautomtor scroll swipe action.
+
+ The acknowledgment is an <a href="http://developer.android.com/reference/android/view/accessibility/AccessibilityEvent.html">AccessibilityEvent</a>,
+ corresponding to the scroll action, that lets the framework determine if
+ the scroll action was successful. Generally, this timeout should not be modified.
+ See <code><a href="UiScrollable.html">UiScrollable</a></code></p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>current timeout in milliseconds</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="getWaitForIdleTimeout()"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ long
+ </span>
+ <span class="sympad">getWaitForIdleTimeout</span>
+ <span class="normal">()</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Gets the current timeout used for waiting for the user interface to go
+ into an idle state.
+
+ By default, all core uiautomator objects except <code><a href="UiDevice.html">UiDevice</a></code> will perform
+ this wait before starting to search for the widget specified by the
+ object's <code><a href="UiSelector.html">UiSelector</a></code>. Once the idle state is detected or the
+ timeout elapses (whichever occurs first), the object will start to wait
+ for the selector to find a match.
+ See <code><a href="#setWaitForSelectorTimeout(long)">setWaitForSelectorTimeout(long)</a></code></p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>Current timeout value in milliseconds</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="getWaitForSelectorTimeout()"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ long
+ </span>
+ <span class="sympad">getWaitForSelectorTimeout</span>
+ <span class="normal">()</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Gets the current timeout for waiting for a widget to become visible in
+ the user interface so that it can be matched by a selector.
+
+ Because user interface content is dynamic, sometimes a widget may not
+ be visible immediately and won't be detected by a selector. This timeout
+ allows the uiautomator framework to wait for a match to be found, up until
+ the timeout elapses.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>Current timeout value in milliseconds</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="setActionAcknowledgmentTimeout(long)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ <a href="#">Configurator</a>
+ </span>
+ <span class="sympad">setActionAcknowledgmentTimeout</span>
+ <span class="normal">(long timeout)</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Sets the timeout for waiting for an acknowledgment of generic uiautomator
+ actions, such as clicks, text setting, and menu presses.
+
+ The acknowledgment is an <a href="http://developer.android.com/reference/android/view/accessibility/AccessibilityEvent.html">AccessibilityEvent</a>,
+ corresponding to an action, that lets the framework determine if the
+ action was successful. Generally, this timeout should not be modified.
+ See <code><a href="UiObject.html">UiObject</a></code></p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>timeout</td>
+ <td>Timeout value in milliseconds</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>self</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="setKeyInjectionDelay(long)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ <a href="#">Configurator</a>
+ </span>
+ <span class="sympad">setKeyInjectionDelay</span>
+ <span class="normal">(long delay)</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Sets a delay between key presses when injecting text input.
+ See <code><a href="UiObject.html#setText(java.lang.String)">setText(String)</a></code></p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>delay</td>
+ <td>Delay value in milliseconds</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>self</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="setScrollAcknowledgmentTimeout(long)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ <a href="#">Configurator</a>
+ </span>
+ <span class="sympad">setScrollAcknowledgmentTimeout</span>
+ <span class="normal">(long timeout)</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Sets the timeout for waiting for an acknowledgement of an
+ uiautomtor scroll swipe action.
+
+ The acknowledgment is an <a href="http://developer.android.com/reference/android/view/accessibility/AccessibilityEvent.html">AccessibilityEvent</a>,
+ corresponding to the scroll action, that lets the framework determine if
+ the scroll action was successful. Generally, this timeout should not be modified.
+ See <code><a href="UiScrollable.html">UiScrollable</a></code></p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>timeout</td>
+ <td>Timeout value in milliseconds</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>self</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="setWaitForIdleTimeout(long)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ <a href="#">Configurator</a>
+ </span>
+ <span class="sympad">setWaitForIdleTimeout</span>
+ <span class="normal">(long timeout)</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Sets the timeout for waiting for the user interface to go into an idle
+ state before starting a uiautomator action.
+
+ By default, all core uiautomator objects except <code><a href="UiDevice.html">UiDevice</a></code> will perform
+ this wait before starting to search for the widget specified by the
+ object's <code><a href="UiSelector.html">UiSelector</a></code>. Once the idle state is detected or the
+ timeout elapses (whichever occurs first), the object will start to wait
+ for the selector to find a match.
+ See <code><a href="#setWaitForSelectorTimeout(long)">setWaitForSelectorTimeout(long)</a></code></p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>timeout</td>
+ <td>Timeout value in milliseconds</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>self</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="setWaitForSelectorTimeout(long)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ <a href="#">Configurator</a>
+ </span>
+ <span class="sympad">setWaitForSelectorTimeout</span>
+ <span class="normal">(long timeout)</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Sets the timeout for waiting for a widget to become visible in the user
+ interface so that it can be matched by a selector.
+
+ Because user interface content is dynamic, sometimes a widget may not
+ be visible immediately and won't be detected by a selector. This timeout
+ allows the uiautomator framework to wait for a match to be found, up until
+ the timeout elapses.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>timeout</td>
+ <td>Timeout value in milliseconds.</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>self</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+
+
+
+
+
+<!-- ========= METHOD DETAIL ======== -->
+
+
+
+
diff --git a/docs/html/tools/help/uiautomator/IAutomationSupport.jd b/docs/html/tools/help/uiautomator/IAutomationSupport.jd
index 4120f2b..1e9e301 100644
--- a/docs/html/tools/help/uiautomator/IAutomationSupport.jd
+++ b/docs/html/tools/help/uiautomator/IAutomationSupport.jd
@@ -11,58 +11,8 @@
</p>
-
-
-
-
-</div><!-- jd-descr -->
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-<div class="jd-descr">
-
-
<h2>Summary</h2>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
<!-- ========== METHOD SUMMARY =========== -->
<table id="pubmethods" class="jd-sumtable"><tr><th colspan="12">Public Methods</th></tr>
@@ -97,31 +47,6 @@
</div><!-- jd-descr (summary) -->
-<!-- Details -->
-
-
-
-
-
-
-
-
-<!-- XML Attributes -->
-
-
-<!-- Enum Values -->
-
-
-<!-- Constants -->
-
-
-<!-- Fields -->
-
-
-<!-- Public ctors -->
-
-
-
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<!-- Protected ctors -->
@@ -149,20 +74,9 @@
<span class="sympad">sendStatus</span>
<span class="normal">(int resultCode, Bundle status)</span>
</h4>
- <div class="api-level">
- <div>
-
</div>
-
-
- </div>
- <div class="jd-details-descr">
-
+<div class="jd-details-descr">
<div class="jd-tagdata jd-tagdescr"><p>Allows the running test cases to send out interim status</p></div>
-
- </div>
</div>
-
-
diff --git a/docs/html/tools/help/uiautomator/UiAutomatorTestCase.jd b/docs/html/tools/help/uiautomator/UiAutomatorTestCase.jd
index 48c63ba..0d8d1bc 100644
--- a/docs/html/tools/help/uiautomator/UiAutomatorTestCase.jd
+++ b/docs/html/tools/help/uiautomator/UiAutomatorTestCase.jd
@@ -14,27 +14,6 @@
</ul>
</p>
-
-
-
-
-</div><!-- jd-descr -->
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
<div class="jd-descr">
diff --git a/docs/html/tools/help/uiautomator/UiCollection.jd b/docs/html/tools/help/uiautomator/UiCollection.jd
index ed92ca7..3fc32b7 100644
--- a/docs/html/tools/help/uiautomator/UiCollection.jd
+++ b/docs/html/tools/help/uiautomator/UiCollection.jd
@@ -9,8 +9,6 @@
or targeting a sub elements by a child's text or description.
</p>
-<div class="jd-descr">
-
<h2>Summary</h2>
@@ -1267,5 +1265,4 @@
</div>
</div>
-</div>
diff --git a/docs/html/tools/help/uiautomator/UiDevice.jd b/docs/html/tools/help/uiautomator/UiDevice.jd
index 1c8805b..574245e 100644
--- a/docs/html/tools/help/uiautomator/UiDevice.jd
+++ b/docs/html/tools/help/uiautomator/UiDevice.jd
@@ -5,35 +5,9 @@
<style>
h4.jd-details-title {background-color: #DEE8F1;}
</style>
-
-<h2>Class Overview</h2>
-<p>UiDevice provides access to state information about the device.
- You can also use this class to simulate user actions on the device,
- such as pressing the d-pad or pressing the Home and Menu buttons.</p>
-
-
-
-
-
-</div><!-- jd-descr -->
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-<div class="jd-descr">
-
+<p>Provides access to state information about the device. You can
+also use this class to simulate user actions on the device, such as pressing
+the d-pad or pressing the Home and Menu buttons.</p>
<h2>Summary</h2>
@@ -68,866 +42,957 @@
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- void
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#clearLastTraversedText()">clearLastTraversedText</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#clearLastTraversedText()">clearLastTraversedText</a></span>()</nobr>
+
<div class="jd-descrdiv">Clears the text from the last UI traversal event.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#click(int, int)">click</a></span>(int x, int y)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#click(int, int)">click</a></span>(int x, int y)</nobr>
+
<div class="jd-descrdiv">Perform a click at arbitrary coordinates specified by the user</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- void
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#dumpWindowHierarchy(java.lang.String)">dumpWindowHierarchy</a></span>(String fileName)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#drag(int, int, int, int, int)">drag</a></span>(int startX, int startY, int endX, int endY, int steps)</nobr>
+
+ <div class="jd-descrdiv">Performs a swipe from one coordinate to another coordinate.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#dumpWindowHierarchy(java.lang.String)">dumpWindowHierarchy</a></span>(String fileName)</nobr>
+
<div class="jd-descrdiv">Helper method used for debugging to dump the current window's layout hierarchy.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- void
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#freezeRotation()">freezeRotation</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#freezeRotation()">freezeRotation</a></span>()</nobr>
+
<div class="jd-descrdiv">Disables the sensors and freezes the device rotation at its
current rotation state.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- String
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getCurrentActivityName()">getCurrentActivityName</a></span>()
-
- <div class="jd-descrdiv">
- <em>
- This method is deprecated.
- The results returned should be considered unreliable</em></div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getCurrentActivityName()">getCurrentActivityName</a></span>()</nobr>
+
+ <div class="jd-descrdiv"><em>
+ This method is deprecated.
+ The results returned should be considered unreliable</em></div>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- String
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getCurrentPackageName()">getCurrentPackageName</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getCurrentPackageName()">getCurrentPackageName</a></span>()</nobr>
+
<div class="jd-descrdiv">Retrieves the name of the last package to report accessibility events.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- int
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ int</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getDisplayHeight()">getDisplayHeight</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getDisplayHeight()">getDisplayHeight</a></span>()</nobr>
+
<div class="jd-descrdiv">Gets the height of the display, in pixels.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- int
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ int</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getDisplayRotation()">getDisplayRotation</a></span>()
-
- <div class="jd-descrdiv">Returns the current rotation of the display, as defined in Surface@return</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getDisplayRotation()">getDisplayRotation</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Returns the current rotation of the display, as defined in <code><a href="../../../../../reference/android/view/Surface.html">Surface</a></code></div>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- int
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ Point</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getDisplayWidth()">getDisplayWidth</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getDisplaySizeDp()">getDisplaySizeDp</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Returns the display size in dp (device-independent pixel)
+
+ The returned display size is adjusted per screen rotation.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ int</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getDisplayWidth()">getDisplayWidth</a></span>()</nobr>
+
<div class="jd-descrdiv">Gets the width of the display, in pixels.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
static
-
- <a href="UiDevice.html">UiDevice</a>
+
+ <a href="#">UiDevice</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getInstance()">getInstance</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getInstance()">getInstance</a></span>()</nobr>
+
<div class="jd-descrdiv">Retrieves a singleton instance of UiDevice</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- String
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getLastTraversedText()">getLastTraversedText</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getLastTraversedText()">getLastTraversedText</a></span>()</nobr>
+
<div class="jd-descrdiv">Retrieves the text from the last UI traversal event received.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- String
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getProductName()">getProductName</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getProductName()">getProductName</a></span>()</nobr>
+
<div class="jd-descrdiv">Retrieves the product name of the device.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#hasAnyWatcherTriggered()">hasAnyWatcherTriggered</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#hasAnyWatcherTriggered()">hasAnyWatcherTriggered</a></span>()</nobr>
+
<div class="jd-descrdiv">Checks if any registered <code><a href="UiWatcher.html">UiWatcher</a></code> have triggered.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#hasWatcherTriggered(java.lang.String)">hasWatcherTriggered</a></span>(String watcherName)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#hasWatcherTriggered(java.lang.String)">hasWatcherTriggered</a></span>(String watcherName)</nobr>
+
<div class="jd-descrdiv">Checks if a specific registered <code><a href="UiWatcher.html">UiWatcher</a></code> has triggered.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#isNaturalOrientation()">isNaturalOrientation</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#isNaturalOrientation()">isNaturalOrientation</a></span>()</nobr>
+
<div class="jd-descrdiv">Check if the device is in its natural orientation.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#isScreenOn()">isScreenOn</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#isScreenOn()">isScreenOn</a></span>()</nobr>
+
<div class="jd-descrdiv">Checks the power manager if the screen is ON.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#pressBack()">pressBack</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#openNotification()">openNotification</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Opens the notification shade.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#openQuickSettings()">openQuickSettings</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Opens the Quick Settings shade.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#pressBack()">pressBack</a></span>()</nobr>
+
<div class="jd-descrdiv">Simulates a short press on the BACK button.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#pressDPadCenter()">pressDPadCenter</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#pressDPadCenter()">pressDPadCenter</a></span>()</nobr>
+
<div class="jd-descrdiv">Simulates a short press on the CENTER button.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#pressDPadDown()">pressDPadDown</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#pressDPadDown()">pressDPadDown</a></span>()</nobr>
+
<div class="jd-descrdiv">Simulates a short press on the DOWN button.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#pressDPadLeft()">pressDPadLeft</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#pressDPadLeft()">pressDPadLeft</a></span>()</nobr>
+
<div class="jd-descrdiv">Simulates a short press on the LEFT button.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#pressDPadRight()">pressDPadRight</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#pressDPadRight()">pressDPadRight</a></span>()</nobr>
+
<div class="jd-descrdiv">Simulates a short press on the RIGHT button.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#pressDPadUp()">pressDPadUp</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#pressDPadUp()">pressDPadUp</a></span>()</nobr>
+
<div class="jd-descrdiv">Simulates a short press on the UP button.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#pressDelete()">pressDelete</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#pressDelete()">pressDelete</a></span>()</nobr>
+
<div class="jd-descrdiv">Simulates a short press on the DELETE key.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#pressEnter()">pressEnter</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#pressEnter()">pressEnter</a></span>()</nobr>
+
<div class="jd-descrdiv">Simulates a short press on the ENTER key.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#pressHome()">pressHome</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#pressHome()">pressHome</a></span>()</nobr>
+
<div class="jd-descrdiv">Simulates a short press on the HOME button.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#pressKeyCode(int)">pressKeyCode</a></span>(int keyCode)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#pressKeyCode(int, int)">pressKeyCode</a></span>(int keyCode, int metaState)</nobr>
+
<div class="jd-descrdiv">Simulates a short press using a key code.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#pressKeyCode(int, int)">pressKeyCode</a></span>(int keyCode, int metaState)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#pressKeyCode(int)">pressKeyCode</a></span>(int keyCode)</nobr>
+
<div class="jd-descrdiv">Simulates a short press using a key code.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#pressMenu()">pressMenu</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#pressMenu()">pressMenu</a></span>()</nobr>
+
<div class="jd-descrdiv">Simulates a short press on the MENU button.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#pressRecentApps()">pressRecentApps</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#pressRecentApps()">pressRecentApps</a></span>()</nobr>
+
<div class="jd-descrdiv">Simulates a short press on the Recent Apps button.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#pressSearch()">pressSearch</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#pressSearch()">pressSearch</a></span>()</nobr>
+
<div class="jd-descrdiv">Simulates a short press on the SEARCH button.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- void
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#registerWatcher(java.lang.String, com.android.uiautomator.core.UiWatcher)">registerWatcher</a></span>(String name, <a href="UiWatcher.html">UiWatcher</a> watcher)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#registerWatcher(java.lang.String, com.android.uiautomator.core.UiWatcher)">registerWatcher</a></span>(String name, <a href="UiWatcher.html">UiWatcher</a> watcher)</nobr>
+
<div class="jd-descrdiv">Registers a <code><a href="UiWatcher.html">UiWatcher</a></code> to run automatically when the testing framework is unable to
find a match using a <code><a href="UiSelector.html">UiSelector</a></code>.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- void
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#removeWatcher(java.lang.String)">removeWatcher</a></span>(String name)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#removeWatcher(java.lang.String)">removeWatcher</a></span>(String name)</nobr>
+
<div class="jd-descrdiv">Removes a previously registered <code><a href="UiWatcher.html">UiWatcher</a></code>.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- void
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#resetWatcherTriggers()">resetWatcherTriggers</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#resetWatcherTriggers()">resetWatcherTriggers</a></span>()</nobr>
+
<div class="jd-descrdiv">Resets a <code><a href="UiWatcher.html">UiWatcher</a></code> that has been triggered.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- void
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#runWatchers()">runWatchers</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#runWatchers()">runWatchers</a></span>()</nobr>
+
<div class="jd-descrdiv">This method forces all registered watchers to run.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- void
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#setOrientationLeft()">setOrientationLeft</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#setCompressedLayoutHeirarchy(boolean)">setCompressedLayoutHeirarchy</a></span>(boolean compressed)</nobr>
+
+ <div class="jd-descrdiv">Enables or disables layout hierarchy compression.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#setOrientationLeft()">setOrientationLeft</a></span>()</nobr>
+
<div class="jd-descrdiv">Simulates orienting the device to the left and also freezes rotation
by disabling the sensors.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- void
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#setOrientationNatural()">setOrientationNatural</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#setOrientationNatural()">setOrientationNatural</a></span>()</nobr>
+
<div class="jd-descrdiv">Simulates orienting the device into its natural orientation and also freezes rotation
by disabling the sensors.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- void
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#setOrientationRight()">setOrientationRight</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#setOrientationRight()">setOrientationRight</a></span>()</nobr>
+
<div class="jd-descrdiv">Simulates orienting the device to the right and also freezes rotation
by disabling the sensors.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- void
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#sleep()">sleep</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#sleep()">sleep</a></span>()</nobr>
+
<div class="jd-descrdiv">This method simply presses the power button if the screen is ON else
it does nothing if the screen is already OFF.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#swipe(android.graphics.Point[], int)">swipe</a></span>(Point[] segments, int segmentSteps)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#swipe(android.graphics.Point[], int)">swipe</a></span>(Point[] segments, int segmentSteps)</nobr>
+
<div class="jd-descrdiv">Performs a swipe between points in the Point array.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#swipe(int, int, int, int, int)">swipe</a></span>(int startX, int startY, int endX, int endY, int steps)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#swipe(int, int, int, int, int)">swipe</a></span>(int startX, int startY, int endX, int endY, int steps)</nobr>
+
<div class="jd-descrdiv">Performs a swipe from one coordinate to another using the number of steps
to determine smoothness and speed.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#takeScreenshot(java.io.File, float, int)">takeScreenshot</a></span>(File storePath, float scale, int quality)
-
- <div class="jd-descrdiv">Take a screenshot of current window and store it as PNG
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#takeScreenshot(java.io.File)">takeScreenshot</a></span>(File storePath)</nobr>
- The screenshot is adjusted per screen rotation</div>
-
- </td></tr>
-
-
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
- </td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#takeScreenshot(java.io.File)">takeScreenshot</a></span>(File storePath)
-
<div class="jd-descrdiv">Take a screenshot of current window and store it as PNG
Default scale of 1.0f (original size) and 90% quality is used
The screenshot is adjusted per screen rotation</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- void
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#unfreezeRotation()">unfreezeRotation</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#takeScreenshot(java.io.File, float, int)">takeScreenshot</a></span>(File storePath, float scale, int quality)</nobr>
+
+ <div class="jd-descrdiv">Take a screenshot of current window and store it as PNG
+
+ The screenshot is adjusted per screen rotation</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#unfreezeRotation()">unfreezeRotation</a></span>()</nobr>
+
<div class="jd-descrdiv">Re-enables the sensors and un-freezes the device rotation allowing its contents
to rotate with the device physical rotation.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- void
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#waitForIdle(long)">waitForIdle</a></span>(long time)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#waitForIdle(long)">waitForIdle</a></span>(long timeout)</nobr>
+
<div class="jd-descrdiv">Waits for the current application to idle.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- void
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#waitForIdle()">waitForIdle</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#waitForIdle()">waitForIdle</a></span>()</nobr>
+
<div class="jd-descrdiv">Waits for the current application to idle.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#waitForWindowUpdate(java.lang.String, long)">waitForWindowUpdate</a></span>(String packageName, long timeout)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#waitForWindowUpdate(java.lang.String, long)">waitForWindowUpdate</a></span>(String packageName, long timeout)</nobr>
+
<div class="jd-descrdiv">Waits for a window content update event to occur.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- void
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#wakeUp()">wakeUp</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#wakeUp()">wakeUp</a></span>()</nobr>
+
<div class="jd-descrdiv">This method simulates pressing the power button if the screen is OFF else
it does nothing if the screen is already ON.</div>
-
+
</td></tr>
@@ -946,7 +1011,7 @@
<div style="clear:left;">Inherited Methods</div></th></tr>
-<tr class="api apilevel-" >
+<tr class="api" >
<td colspan="12">
<a href="#" onclick="return toggleInherited(this, null)" id="inherited-methods-java.lang.Object" class="jd-expando-trigger closed"
><img id="inherited-methods-java.lang.Object-trigger"
@@ -962,150 +1027,182 @@
</div>
<div id="inherited-methods-java.lang.Object-summary" style="display: none;">
<table class="jd-sumtable-expando">
-
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ Object</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">equals</span>(Object arg0)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">clone</span>()</nobr>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">equals</span>(Object arg0)</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">finalize</span>()</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- Class<?>
+
+
+ Class<?></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">getClass</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">getClass</span>()</nobr>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- int
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ int</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">hashCode</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">hashCode</span>()</nobr>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">notify</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">notify</span>()</nobr>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">notifyAll</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">notifyAll</span>()</nobr>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- String
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">toString</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">toString</span>()</nobr>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">wait</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">wait</span>()</nobr>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">wait</span>(long arg0, int arg1)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">wait</span>(long arg0, int arg1)</nobr>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">wait</span>(long arg0)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">wait</span>(long arg0)</nobr>
+
</td></tr>
@@ -1157,31 +1254,29 @@
-<a id="clearLastTraversedText()"></a>
+<A NAME="clearLastTraversedText()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
void
</span>
<span class="sympad">clearLastTraversedText</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Clears the text from the last UI traversal event.
See <code><a href="#getLastTraversedText()">getLastTraversedText()</a></code>.</p></div>
@@ -1189,41 +1284,39 @@
</div>
-<a id="click(int, int)"></a>
+<A NAME="click(int, int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">click</span>
<span class="normal">(int x, int y)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Perform a click at arbitrary coordinates specified by the user</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>x</th>
+ <th>x</td>
<td>coordinate</td>
</tr>
<tr>
- <th>y</th>
+ <th>y</td>
<td>coordinate</td>
</tr>
</table>
@@ -1237,31 +1330,88 @@
</div>
-<a id="dumpWindowHierarchy(java.lang.String)"></a>
+<A NAME="drag(int, int, int, int, int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api apilevel-18">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
+ boolean
+ </span>
+ <span class="sympad">drag</span>
+ <span class="normal">(int startX, int startY, int endX, int endY, int steps)</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs a swipe from one coordinate to another coordinate. You can control
+ the smoothness and speed of the swipe by specifying the number of steps.
+ Each step execution is throttled to 5 milliseconds per step, so for a 100
+ steps, the swipe will take around 0.5 seconds to complete.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>startX</td>
+ <td>X-axis value for the starting coordinate</td>
+ </tr>
+ <tr>
+ <th>startY</td>
+ <td>Y-axis value for the starting coordinate</td>
+ </tr>
+ <tr>
+ <th>endX</td>
+ <td>X-axis value for the ending coordinate</td>
+ </tr>
+ <tr>
+ <th>endY</td>
+ <td>Y-axis value for the ending coordinate</td>
+ </tr>
+ <tr>
+ <th>steps</td>
+ <td>is the number of steps for the swipe action</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>true if swipe is performed, false if the operation fails
+ or the coordinates are invalid</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="dumpWindowHierarchy(java.lang.String)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
void
</span>
<span class="sympad">dumpWindowHierarchy</span>
<span class="normal">(String fileName)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Helper method used for debugging to dump the current window's layout hierarchy.
The file root location is /data/local/tmp</p></div>
@@ -1269,40 +1419,38 @@
</div>
-<a id="freezeRotation()"></a>
+<A NAME="freezeRotation()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
void
</span>
<span class="sympad">freezeRotation</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Disables the sensors and freezes the device rotation at its
current rotation state.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th></td>
<td>RemoteException</td>
- </tr>
+ </tr>
<tr>
<th>RemoteException</td>
<td></td>
@@ -1314,34 +1462,32 @@
</div>
-<a id="getCurrentActivityName()"></a>
+<A NAME="getCurrentActivityName()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
String
</span>
<span class="sympad">getCurrentActivityName</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
<p>
- <p class="caution">
- <strong>
- This method is deprecated.</strong><br/> The results returned should be considered unreliable
+ <p class="caution"><strong>
+ This method is deprecated.</strong><br/>
+ The results returned should be considered unreliable
</p>
<div class="jd-tagdata jd-tagdescr"><p>Retrieves the last activity to report accessibility events.</p></div>
<div class="jd-tagdata">
@@ -1353,31 +1499,29 @@
</div>
-<a id="getCurrentPackageName()"></a>
+<A NAME="getCurrentPackageName()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
String
</span>
<span class="sympad">getCurrentPackageName</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Retrieves the name of the last package to report accessibility events.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -1388,31 +1532,29 @@
</div>
-<a id="getDisplayHeight()"></a>
+<A NAME="getDisplayHeight()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
int
</span>
<span class="sympad">getDisplayHeight</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Gets the height of the display, in pixels. The size is adjusted based
on the current orientation of the display.</p></div>
<div class="jd-tagdata">
@@ -1424,65 +1566,84 @@
</div>
-<a id="getDisplayRotation()"></a>
+<A NAME="getDisplayRotation()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
int
</span>
<span class="sympad">getDisplayRotation</span>
<span class="normal">()</span>
</h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Returns the current rotation of the display, as defined in Surface@return</p></div>
- <div class="jd-tagdata">
- <h5 class="jd-tagtitle">Since</h5>
- <ul class="nolist"><li>Android API Level 17</li></ul>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Returns the current rotation of the display, as defined in <code><a href="../../../../../reference/android/view/Surface.html">Surface</a></code></p></div>
+
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 17</li></ul>
+ </div>
</div>
+
+
+<A NAME="getDisplaySizeDp()"></A>
+
+<div class="jd-details api apilevel-18">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ Point
+ </span>
+ <span class="sympad">getDisplaySizeDp</span>
+ <span class="normal">()</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Returns the display size in dp (device-independent pixel)
+
+ The returned display size is adjusted per screen rotation. Also this will return the actual
+ size of the screen, rather than adjusted per system decorations (like status bar).</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>a Point containing the display size in dp
+</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
</div>
</div>
-<a id="getDisplayWidth()"></a>
+<A NAME="getDisplayWidth()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
int
</span>
<span class="sympad">getDisplayWidth</span>
<span class="normal">()</span>
</h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Gets the width of the display, in pixels. The width and height details
are reported based on the current orientation of the display.</p></div>
<div class="jd-tagdata">
@@ -1494,31 +1655,23 @@
</div>
-<a id="getInstance()"></a>
+<A NAME="getInstance()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
- static
-
-
-
- <a href="UiDevice.html">UiDevice</a>
+ public
+ static
+
+
+
+ <a href="#">UiDevice</a>
</span>
<span class="sympad">getInstance</span>
<span class="normal">()</span>
</h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Retrieves a singleton instance of UiDevice</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -1529,31 +1682,29 @@
</div>
-<a id="getLastTraversedText()"></a>
+<A NAME="getLastTraversedText()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
String
</span>
<span class="sympad">getLastTraversedText</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Retrieves the text from the last UI traversal event received.
You can use this method to read the contents in a WebView container
@@ -1573,31 +1724,23 @@
</div>
-<a id="getProductName()"></a>
+<A NAME="getProductName()"></A>
-<div class="jd-details api ">
+<div class="jd-details api apilevel-17">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
String
</span>
<span class="sympad">getProductName</span>
<span class="normal">()</span>
</h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Retrieves the product name of the device.
This method provides information on what type of device the test is running on. This value is
@@ -1607,38 +1750,36 @@
<ul class="nolist"><li>product name of the device</li></ul>
</div>
<div class="jd-tagdata">
- <h5 class="jd-tagtitle">Since</h5>
- <ul class="nolist"><li>Android API Level 17</li></ul>
-</div>
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 17</li></ul>
+ </div>
</div>
</div>
-<a id="hasAnyWatcherTriggered()"></a>
+<A NAME="hasAnyWatcherTriggered()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">hasAnyWatcherTriggered</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Checks if any registered <code><a href="UiWatcher.html">UiWatcher</a></code> have triggered.
See <code><a href="#registerWatcher(java.lang.String, com.android.uiautomator.core.UiWatcher)">registerWatcher(String, UiWatcher)</a></code>
@@ -1648,31 +1789,29 @@
</div>
-<a id="hasWatcherTriggered(java.lang.String)"></a>
+<A NAME="hasWatcherTriggered(java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">hasWatcherTriggered</span>
<span class="normal">(String watcherName)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Checks if a specific registered <code><a href="UiWatcher.html">UiWatcher</a></code> has triggered.
See <code><a href="#registerWatcher(java.lang.String, com.android.uiautomator.core.UiWatcher)">registerWatcher(String, UiWatcher)</a></code>. If a UiWatcher runs and its
<code><a href="UiWatcher.html#checkForCondition()">checkForCondition()</a></code> call returned <code>true</code>, then
@@ -1687,31 +1826,23 @@
</div>
-<a id="isNaturalOrientation()"></a>
+<A NAME="isNaturalOrientation()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">isNaturalOrientation</span>
<span class="normal">()</span>
</h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Check if the device is in its natural orientation. This is determined by checking if the
orientation is at 0 or 180 degrees.</p></div>
<div class="jd-tagdata">
@@ -1719,38 +1850,36 @@
<ul class="nolist"><li>true if it is in natural orientation</li></ul>
</div>
<div class="jd-tagdata">
- <h5 class="jd-tagtitle">Since</h5>
- <ul class="nolist"><li>Android API Level 17</li></ul>
-</div>
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 17</li></ul>
+ </div>
</div>
</div>
-<a id="isScreenOn()"></a>
+<A NAME="isScreenOn()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">isScreenOn</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Checks the power manager if the screen is ON.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -1758,11 +1887,11 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th></td>
<td>RemoteException</td>
- </tr>
+ </tr>
<tr>
<th>RemoteException</td>
<td></td>
@@ -1774,31 +1903,89 @@
</div>
-<a id="pressBack()"></a>
+<A NAME="openNotification()"></A>
-<div class="jd-details api ">
+<div class="jd-details api apilevel-18">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
+ boolean
+ </span>
+ <span class="sympad">openNotification</span>
+ <span class="normal">()</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Opens the notification shade.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>true if successful, else return false</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="openQuickSettings()"></A>
+
+<div class="jd-details api apilevel-18">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ boolean
+ </span>
+ <span class="sympad">openQuickSettings</span>
+ <span class="normal">()</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Opens the Quick Settings shade.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>true if successful, else return false</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="pressBack()"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
boolean
</span>
<span class="sympad">pressBack</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Simulates a short press on the BACK button.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -1809,31 +1996,29 @@
</div>
-<a id="pressDPadCenter()"></a>
+<A NAME="pressDPadCenter()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">pressDPadCenter</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Simulates a short press on the CENTER button.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -1844,31 +2029,29 @@
</div>
-<a id="pressDPadDown()"></a>
+<A NAME="pressDPadDown()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">pressDPadDown</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Simulates a short press on the DOWN button.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -1879,31 +2062,29 @@
</div>
-<a id="pressDPadLeft()"></a>
+<A NAME="pressDPadLeft()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">pressDPadLeft</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Simulates a short press on the LEFT button.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -1914,31 +2095,29 @@
</div>
-<a id="pressDPadRight()"></a>
+<A NAME="pressDPadRight()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">pressDPadRight</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Simulates a short press on the RIGHT button.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -1949,31 +2128,29 @@
</div>
-<a id="pressDPadUp()"></a>
+<A NAME="pressDPadUp()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">pressDPadUp</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Simulates a short press on the UP button.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -1984,31 +2161,29 @@
</div>
-<a id="pressDelete()"></a>
+<A NAME="pressDelete()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">pressDelete</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Simulates a short press on the DELETE key.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -2019,31 +2194,29 @@
</div>
-<a id="pressEnter()"></a>
+<A NAME="pressEnter()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">pressEnter</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Simulates a short press on the ENTER key.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -2054,31 +2227,29 @@
</div>
-<a id="pressHome()"></a>
+<A NAME="pressHome()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">pressHome</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Simulates a short press on the HOME button.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -2089,80 +2260,41 @@
</div>
-<a id="pressKeyCode(int)"></a>
+<A NAME="pressKeyCode(int, int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- boolean
- </span>
- <span class="sympad">pressKeyCode</span>
- <span class="normal">(int keyCode)</span>
- </h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
- <div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Simulates a short press using a key code.
-
- See KeyEvent</p></div>
- <div class="jd-tagdata">
- <h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true if successful, else return false</li></ul>
- </div>
-
- </div>
-</div>
+ public
-<a id="pressKeyCode(int, int)"></a>
-<div class="jd-details api ">
- <h4 class="jd-details-title">
- <span class="normal">
- public
-
-
-
-
+
boolean
</span>
<span class="sympad">pressKeyCode</span>
<span class="normal">(int keyCode, int metaState)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Simulates a short press using a key code.
- See KeyEvent.</p></div>
+ See <code><a href="../../../../../reference/android/view/KeyEvent.html">KeyEvent</a></code>.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>keyCode</th>
+ <th>keyCode</td>
<td>the key code of the event.</td>
</tr>
<tr>
- <th>metaState</th>
+ <th>metaState</td>
<td>an integer in which each bit set to 1 represents a pressed meta key</td>
</tr>
</table>
@@ -2176,31 +2308,64 @@
</div>
-<a id="pressMenu()"></a>
+<A NAME="pressKeyCode(int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
+ boolean
+ </span>
+ <span class="sympad">pressKeyCode</span>
+ <span class="normal">(int keyCode)</span>
+ </h4>
+ <div class="api-level">
+ <div></div>
+
+
+
+ </div>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Simulates a short press using a key code.
+
+ See <code><a href="../../../../../reference/android/view/KeyEvent.html">KeyEvent</a></code></p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>true if successful, else return false</li></ul>
+ </div>
+
+ </div>
+</div>
+
+
+<A NAME="pressMenu()"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
boolean
</span>
<span class="sympad">pressMenu</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Simulates a short press on the MENU button.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -2211,31 +2376,29 @@
</div>
-<a id="pressRecentApps()"></a>
+<A NAME="pressRecentApps()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">pressRecentApps</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Simulates a short press on the Recent Apps button.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -2243,11 +2406,11 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th></td>
<td>RemoteException</td>
- </tr>
+ </tr>
<tr>
<th>RemoteException</td>
<td></td>
@@ -2259,31 +2422,29 @@
</div>
-<a id="pressSearch()"></a>
+<A NAME="pressSearch()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">pressSearch</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Simulates a short press on the SEARCH button.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -2294,42 +2455,40 @@
</div>
-<a id="registerWatcher(java.lang.String, com.android.uiautomator.core.UiWatcher)"></a>
+<A NAME="registerWatcher(java.lang.String, com.android.uiautomator.core.UiWatcher)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
void
</span>
<span class="sympad">registerWatcher</span>
<span class="normal">(String name, <a href="UiWatcher.html">UiWatcher</a> watcher)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Registers a <code><a href="UiWatcher.html">UiWatcher</a></code> to run automatically when the testing framework is unable to
find a match using a <code><a href="UiSelector.html">UiSelector</a></code>. See <code><a href="#runWatchers()">runWatchers()</a></code></p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>name</th>
+ <th>name</td>
<td>to register the UiWatcher</td>
</tr>
<tr>
- <th>watcher</th>
+ <th>watcher</td>
<td><code><a href="UiWatcher.html">UiWatcher</a></code></td>
</tr>
</table>
@@ -2339,31 +2498,29 @@
</div>
-<a id="removeWatcher(java.lang.String)"></a>
+<A NAME="removeWatcher(java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
void
</span>
<span class="sympad">removeWatcher</span>
<span class="normal">(String name)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Removes a previously registered <code><a href="UiWatcher.html">UiWatcher</a></code>.
See <code><a href="#registerWatcher(java.lang.String, com.android.uiautomator.core.UiWatcher)">registerWatcher(String, UiWatcher)</a></code></p></div>
@@ -2371,50 +2528,39 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>name</th>
+ <th>name</td>
<td>used to register the UiWatcher</td>
</tr>
</table>
</div>
- <div class="jd-tagdata">
- <h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
- <tr>
- <th></td>
- <td>UiAutomationException</td>
- </tr>
- </table>
- </div>
</div>
</div>
-<a id="resetWatcherTriggers()"></a>
+<A NAME="resetWatcherTriggers()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
void
</span>
<span class="sympad">resetWatcherTriggers</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Resets a <code><a href="UiWatcher.html">UiWatcher</a></code> that has been triggered.
If a UiWatcher runs and its <code><a href="UiWatcher.html#checkForCondition()">checkForCondition()</a></code> call
returned <code>true</code>, then the UiWatcher is considered triggered.
@@ -2424,31 +2570,29 @@
</div>
-<a id="runWatchers()"></a>
+<A NAME="runWatchers()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
void
</span>
<span class="sympad">runWatchers</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>This method forces all registered watchers to run.
See <code><a href="#registerWatcher(java.lang.String, com.android.uiautomator.core.UiWatcher)">registerWatcher(String, UiWatcher)</a></code></p></div>
@@ -2456,31 +2600,63 @@
</div>
-<a id="setOrientationLeft()"></a>
+<A NAME="setCompressedLayoutHeirarchy(boolean)"></A>
-<div class="jd-details api ">
+<div class="jd-details api apilevel-18">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
+ void
+ </span>
+ <span class="sympad">setCompressedLayoutHeirarchy</span>
+ <span class="normal">(boolean compressed)</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Enables or disables layout hierarchy compression.
+
+ If compression is enabled, the layout hierarchy derived from the Acessibility
+ framework will only contain nodes that are important for uiautomator
+ testing. Any unnecessary surrounding layout nodes that make viewing
+ and searching the hierarchy inefficient are removed.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>compressed</td>
+ <td>true to enable compression; else, false to disable</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="setOrientationLeft()"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
void
</span>
<span class="sympad">setOrientationLeft</span>
<span class="normal">()</span>
</h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Simulates orienting the device to the left and also freezes rotation
by disabling the sensors.
@@ -2488,11 +2664,11 @@
see <code><a href="#unfreezeRotation()">unfreezeRotation()</a></code>.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th></td>
<td>RemoteException</td>
- </tr>
+ </tr>
<tr>
<th>RemoteException</td>
<td></td>
@@ -2500,38 +2676,30 @@
</table>
</div>
<div class="jd-tagdata">
- <h5 class="jd-tagtitle">Since</h5>
- <ul class="nolist"><li>Android API Level 17</li></ul>
-</div>
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 17</li></ul>
+ </div>
</div>
</div>
-<a id="setOrientationNatural()"></a>
+<A NAME="setOrientationNatural()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
void
</span>
<span class="sympad">setOrientationNatural</span>
<span class="normal">()</span>
</h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Simulates orienting the device into its natural orientation and also freezes rotation
by disabling the sensors.
@@ -2539,11 +2707,11 @@
see <code><a href="#unfreezeRotation()">unfreezeRotation()</a></code>.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th></td>
<td>RemoteException</td>
- </tr>
+ </tr>
<tr>
<th>RemoteException</td>
<td></td>
@@ -2551,38 +2719,30 @@
</table>
</div>
<div class="jd-tagdata">
- <h5 class="jd-tagtitle">Since</h5>
- <ul class="nolist"><li>Android API Level 17</li></ul>
-</div>
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 17</li></ul>
+ </div>
</div>
</div>
-<a id="setOrientationRight()"></a>
+<A NAME="setOrientationRight()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
void
</span>
<span class="sympad">setOrientationRight</span>
<span class="normal">()</span>
</h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Simulates orienting the device to the right and also freezes rotation
by disabling the sensors.
@@ -2590,11 +2750,11 @@
see <code><a href="#unfreezeRotation()">unfreezeRotation()</a></code>.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th></td>
<td>RemoteException</td>
- </tr>
+ </tr>
<tr>
<th>RemoteException</td>
<td></td>
@@ -2602,47 +2762,45 @@
</table>
</div>
<div class="jd-tagdata">
- <h5 class="jd-tagtitle">Since</h5>
- <ul class="nolist"><li>Android API Level 17</li></ul>
-</div>
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 17</li></ul>
+ </div>
</div>
</div>
-<a id="sleep()"></a>
+<A NAME="sleep()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
void
</span>
<span class="sympad">sleep</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>This method simply presses the power button if the screen is ON else
it does nothing if the screen is already OFF.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th></td>
<td>RemoteException</td>
- </tr>
+ </tr>
<tr>
<th>RemoteException</td>
<td></td>
@@ -2654,42 +2812,40 @@
</div>
-<a id="swipe(android.graphics.Point[], int)"></a>
+<A NAME="swipe(android.graphics.Point[], int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">swipe</span>
<span class="normal">(Point[] segments, int segmentSteps)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Performs a swipe between points in the Point array. Each step execution is throttled
to 5ms per step. So for a 100 steps, the swipe will take about 1/2 second to complete</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>segments</th>
+ <th>segments</td>
<td>is Point array containing at least one Point object</td>
</tr>
<tr>
- <th>segmentSteps</th>
+ <th>segmentSteps</td>
<td>steps to inject between two Points</td>
</tr>
</table>
@@ -2703,31 +2859,29 @@
</div>
-<a id="swipe(int, int, int, int, int)"></a>
+<A NAME="swipe(int, int, int, int, int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">swipe</span>
<span class="normal">(int startX, int startY, int endX, int endY, int steps)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Performs a swipe from one coordinate to another using the number of steps
to determine smoothness and speed. Each step execution is throttled to 5ms
per step. So for a 100 steps, the swipe will take about 1/2 second to complete.</p></div>
@@ -2735,7 +2889,7 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>steps</th>
+ <th>steps</td>
<td>is the number of move steps sent to the system</td>
</tr>
</table>
@@ -2749,31 +2903,65 @@
</div>
-<a id="takeScreenshot(java.io.File, float, int)"></a>
+<A NAME="takeScreenshot(java.io.File)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
+ boolean
+ </span>
+ <span class="sympad">takeScreenshot</span>
+ <span class="normal">(File storePath)</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Take a screenshot of current window and store it as PNG
+
+ Default scale of 1.0f (original size) and 90% quality is used
+ The screenshot is adjusted per screen rotation</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>storePath</td>
+ <td>where the PNG should be written to</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>true if screen shot is created successfully, false otherwise</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 17</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="takeScreenshot(java.io.File, float, int)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
boolean
</span>
<span class="sympad">takeScreenshot</span>
<span class="normal">(File storePath, float scale, int quality)</span>
</h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Take a screenshot of current window and store it as PNG
The screenshot is adjusted per screen rotation</p></div>
@@ -2781,15 +2969,15 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>storePath</th>
+ <th>storePath</td>
<td>where the PNG should be written to</td>
</tr>
<tr>
- <th>scale</th>
+ <th>scale</td>
<td>scale the screenshot down if needed; 1.0f for original size</td>
</tr>
<tr>
- <th>quality</th>
+ <th>quality</td>
<td>quality of the PNG compression; range: 0-100</td>
</tr>
</table>
@@ -2799,94 +2987,42 @@
<ul class="nolist"><li>true if screen shot is created successfully, false otherwise</li></ul>
</div>
<div class="jd-tagdata">
- <h5 class="jd-tagtitle">Since</h5>
- <ul class="nolist"><li>Android API Level 17</li></ul>
-</div>
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 17</li></ul>
+ </div>
</div>
</div>
-<a id="takeScreenshot(java.io.File)"></a>
+<A NAME="unfreezeRotation()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- boolean
- </span>
- <span class="sympad">takeScreenshot</span>
- <span class="normal">(File storePath)</span>
- </h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
- <div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Take a screenshot of current window and store it as PNG
-
- Default scale of 1.0f (original size) and 90% quality is used
- The screenshot is adjusted per screen rotation</p></div>
- <div class="jd-tagdata">
- <h5 class="jd-tagtitle">Parameters</h5>
- <table class="jd-tagtable">
- <tr>
- <th>storePath</th>
- <td>where the PNG should be written to</td>
- </tr>
- </table>
- </div>
- <div class="jd-tagdata">
- <h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true if screen shot is created successfully, false otherwise</li></ul>
- </div>
- <div class="jd-tagdata">
- <h5 class="jd-tagtitle">Since</h5>
- <ul class="nolist"><li>Android API Level 17</li></ul>
-</div>
- </div>
-</div>
+ public
-<a id="unfreezeRotation()"></a>
-<div class="jd-details api ">
- <h4 class="jd-details-title">
- <span class="normal">
- public
-
-
-
-
+
void
</span>
<span class="sympad">unfreezeRotation</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Re-enables the sensors and un-freezes the device rotation allowing its contents
to rotate with the device physical rotation. During a test execution, it is best to
keep the device frozen in a specific orientation until the test case execution has completed.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th>RemoteException</td>
<td></td>
@@ -2898,62 +3034,67 @@
</div>
-<a id="waitForIdle(long)"></a>
+<A NAME="waitForIdle(long)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
void
</span>
<span class="sympad">waitForIdle</span>
- <span class="normal">(long time)</span>
+ <span class="normal">(long timeout)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Waits for the current application to idle.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>timeout</td>
+ <td>in milliseconds</td>
+ </tr>
+ </table>
+ </div>
</div>
</div>
-<a id="waitForIdle()"></a>
+<A NAME="waitForIdle()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
void
</span>
<span class="sympad">waitForIdle</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Waits for the current application to idle.
Default wait timeout is 10 seconds</p></div>
@@ -2961,31 +3102,29 @@
</div>
-<a id="waitForWindowUpdate(java.lang.String, long)"></a>
+<A NAME="waitForWindowUpdate(java.lang.String, long)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">waitForWindowUpdate</span>
<span class="normal">(String packageName, long timeout)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Waits for a window content update event to occur.
If a package name for the window is specified, but the current window
@@ -2994,12 +3133,12 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>packageName</th>
+ <th>packageName</td>
<td>the specified window package name (can be <code>null</code>).
If <code>null</code>, a window update from any front-end window will end the wait</td>
</tr>
<tr>
- <th>timeout</th>
+ <th>timeout</td>
<td>the timeout for the wait</td>
</tr>
</table>
@@ -3014,31 +3153,29 @@
</div>
-<a id="wakeUp()"></a>
+<A NAME="wakeUp()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
void
</span>
<span class="sympad">wakeUp</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>This method simulates pressing the power button if the screen is OFF else
it does nothing if the screen is already ON.
@@ -3046,11 +3183,11 @@
to allow the device time to wake up and accept input.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th></td>
<td>RemoteException</td>
- </tr>
+ </tr>
<tr>
<th>RemoteException</td>
<td></td>
@@ -3059,7 +3196,6 @@
</div>
</div>
-</div>
@@ -3069,5 +3205,4 @@
-<!-- ========= END OF CLASS DATA ========= -->
diff --git a/docs/html/tools/help/uiautomator/UiObject.jd b/docs/html/tools/help/uiautomator/UiObject.jd
index a22df50..45007e0 100644
--- a/docs/html/tools/help/uiautomator/UiObject.jd
+++ b/docs/html/tools/help/uiautomator/UiObject.jd
@@ -5,31 +5,12 @@
<style>
h4.jd-details-title {background-color: #DEE8F1;}
</style>
-<p>A UiObject is a representation of a user interface (UI) element. It is not in any way directly bound to a
- UI element as an object reference. A UiObject holds information to help it
- locate a matching UI element at runtime based on the <code><a href="UiSelector.html">UiSelector</a></code> properties specified in
- its constructor. Since a UiObject is a representative for a UI element, it can
- be reused for different views with matching UI elements.
-</p>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-<div class="jd-descr">
-
+<p>A <code><a href="#">UiObject</a></code> is a representation of a view. It is
+not in any way directly bound to a view as an object reference. A <code><a href="#">UiObject</a></code>
+contains information to help it locate a matching view at runtime based on the
+<code><a href="#UiSelector.html">UiSelector</a></code> properties specified in
+its constructor. Once you create an instance of a UiObject, it can be reused for
+different views that match the selector criteria.</p>
<h2>Summary</h2>
@@ -45,6 +26,63 @@
+<!-- =========== ENUM CONSTANT SUMMARY =========== -->
+<table id="constants" class="jd-sumtable"><tr><th colspan="12">Constants</th></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol">int</td>
+ <td class="jd-linkcol"><a href="#FINGER_TOUCH_HALF_WIDTH">FINGER_TOUCH_HALF_WIDTH</a></td>
+ <td class="jd-descrcol" width="100%"></td>
+ </tr>
+
+
+ <tr class="api" >
+ <td class="jd-typecol">int</td>
+ <td class="jd-linkcol"><a href="#SWIPE_MARGIN_LIMIT">SWIPE_MARGIN_LIMIT</a></td>
+ <td class="jd-descrcol" width="100%"></td>
+ </tr>
+
+
+ <tr class="api" >
+ <td class="jd-typecol">long</td>
+ <td class="jd-linkcol"><a href="#WAIT_FOR_EVENT_TMEOUT">WAIT_FOR_EVENT_TMEOUT</a></td>
+ <td class="jd-descrcol" width="100%"><em>
+ This constant is deprecated.
+ use <code><a href="Configurator.html#setScrollAcknowledgmentTimeout(long)">setScrollAcknowledgmentTimeout(long)</a></code>
+</em></td>
+ </tr>
+
+
+ <tr class="api" >
+ <td class="jd-typecol">long</td>
+ <td class="jd-linkcol"><a href="#WAIT_FOR_SELECTOR_POLL">WAIT_FOR_SELECTOR_POLL</a></td>
+ <td class="jd-descrcol" width="100%"></td>
+ </tr>
+
+
+ <tr class="api" >
+ <td class="jd-typecol">long</td>
+ <td class="jd-linkcol"><a href="#WAIT_FOR_SELECTOR_TIMEOUT">WAIT_FOR_SELECTOR_TIMEOUT</a></td>
+ <td class="jd-descrcol" width="100%"><em>
+ This constant is deprecated.
+ use <code><a href="Configurator.html#setWaitForSelectorTimeout(long)">setWaitForSelectorTimeout(long)</a></code>
+</em></td>
+ </tr>
+
+
+ <tr class="api" >
+ <td class="jd-typecol">long</td>
+ <td class="jd-linkcol"><a href="#WAIT_FOR_WINDOW_TMEOUT">WAIT_FOR_WINDOW_TMEOUT</a></td>
+ <td class="jd-descrcol" width="100%"></td>
+ </tr>
+
+
+
+</table>
+
+
@@ -60,22 +98,22 @@
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
-
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ </nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#UiObject(com.android.uiautomator.core.UiSelector)">UiObject</a></span>(<a href="UiSelector.html">UiSelector</a> selector)
-
- <div class="jd-descrdiv">Constructs a UiObject to represent a specific UI element matched by the specified
- <code><a href="UiSelector.html">UiSelector</a></code> selector properties.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#UiObject(com.android.uiautomator.core.UiSelector)">UiObject</a></span>(<a href="UiSelector.html">UiSelector</a> selector)</nobr>
+
+ <div class="jd-descrdiv">Constructs a UiObject to represent a view that matches the specified
+ selector criteria.</div>
+
</td></tr>
@@ -92,642 +130,766 @@
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- void
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#clearTextField()">clearTextField</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#clearTextField()">clearTextField</a></span>()</nobr>
+
<div class="jd-descrdiv">Clears the existing text contents in an editable field.</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#click()">click</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#click()">click</a></span>()</nobr>
+
<div class="jd-descrdiv">Performs a click at the center of the visible bounds of the UI element represented
by this UiObject.</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#clickAndWaitForNewWindow(long)">clickAndWaitForNewWindow</a></span>(long timeout)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#clickAndWaitForNewWindow(long)">clickAndWaitForNewWindow</a></span>(long timeout)</nobr>
+
<div class="jd-descrdiv">Performs a click at the center of the visible bounds of the UI element represented
by this UiObject and waits for window transitions.</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#clickAndWaitForNewWindow()">clickAndWaitForNewWindow</a></span>()
-
- <div class="jd-descrdiv">See <code><a href="#clickAndWaitForNewWindow(long)">clickAndWaitForNewWindow(long)</a></code>
- This method is intended to reliably wait for window transitions that would typically take
- longer than the usual default timeouts.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#clickAndWaitForNewWindow()">clickAndWaitForNewWindow</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Waits for window transitions that would typically take longer than the
+ usual default timeouts.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#clickBottomRight()">clickBottomRight</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#clickBottomRight()">clickBottomRight</a></span>()</nobr>
+
<div class="jd-descrdiv">Clicks the bottom and right corner of the UI element</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#clickTopLeft()">clickTopLeft</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#clickTopLeft()">clickTopLeft</a></span>()</nobr>
+
<div class="jd-descrdiv">Clicks the top and left corner of the UI element</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#exists()">exists</a></span>()
-
- <div class="jd-descrdiv">Check if UI element exists.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#dragTo(com.android.uiautomator.core.UiObject, int)">dragTo</a></span>(<a href="#">UiObject</a> destObj, int steps)</nobr>
+
+ <div class="jd-descrdiv">Drags this object to a destination UiObject.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- Rect
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getBounds()">getBounds</a></span>()
-
- <div class="jd-descrdiv">Returns the UI element's <code>bounds</code> property.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#dragTo(int, int, int)">dragTo</a></span>(int destX, int destY, int steps)</nobr>
+
+ <div class="jd-descrdiv">Drags this object to arbitrary coordinates.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiObject.html">UiObject</a>
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getChild(com.android.uiautomator.core.UiSelector)">getChild</a></span>(<a href="UiSelector.html">UiSelector</a> selector)
-
- <div class="jd-descrdiv">Creates a new UiObject representing a child UI element of the element currently represented
- by this UiObject.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#exists()">exists</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Check if view exists.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- int
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ Rect</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getChildCount()">getChildCount</a></span>()
-
- <div class="jd-descrdiv">Counts the child UI elements immediately under the UI element currently represented by
- this UiObject.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getBounds()">getBounds</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Returns the view's <code>bounds</code> property.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- String
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiObject</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getContentDescription()">getContentDescription</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getChild(com.android.uiautomator.core.UiSelector)">getChild</a></span>(<a href="UiSelector.html">UiSelector</a> selector)</nobr>
+
+ <div class="jd-descrdiv">Creates a new UiObject for a child view that is under the present UiObject.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ int</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getChildCount()">getChildCount</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Counts the child views immediately under the present UiObject.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getClassName()">getClassName</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Retrieves the <code>className</code> property of the UI element.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getContentDescription()">getContentDescription</a></span>()</nobr>
+
<div class="jd-descrdiv">Reads the <code>content_desc</code> property of the UI element</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiObject.html">UiObject</a>
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiObject</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getFromParent(com.android.uiautomator.core.UiSelector)">getFromParent</a></span>(<a href="UiSelector.html">UiSelector</a> selector)
-
- <div class="jd-descrdiv">Creates a new UiObject representing a child UI element from the parent element currently
- represented by this object.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getFromParent(com.android.uiautomator.core.UiSelector)">getFromParent</a></span>(<a href="UiSelector.html">UiSelector</a> selector)</nobr>
+
+ <div class="jd-descrdiv">Creates a new UiObject for a sibling view or a child of the sibling view,
+ relative to the present UiObject.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- String
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getPackageName()">getPackageName</a></span>()
-
- <div class="jd-descrdiv">Reads the UI element's <code>package</code> property</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getPackageName()">getPackageName</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Reads the view's <code>package</code> property</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+
+ <a href="UiSelector.html">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getSelector()">getSelector</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getSelector()">getSelector</a></span>()</nobr>
+
<div class="jd-descrdiv">Debugging helper.</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- String
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getText()">getText</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getText()">getText</a></span>()</nobr>
+
<div class="jd-descrdiv">Reads the <code>text</code> property of the UI element</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- Rect
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ Rect</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getVisibleBounds()">getVisibleBounds</a></span>()
-
- <div class="jd-descrdiv">Returns the visible bounds of the UI element.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getVisibleBounds()">getVisibleBounds</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Returns the visible bounds of the view.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#isCheckable()">isCheckable</a></span>()
-
- <div class="jd-descrdiv">Check if the UI element's <code>checkable</code> property is currently true</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#isCheckable()">isCheckable</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Checks if the UI element's <code>checkable</code> property is currently true.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#isChecked()">isChecked</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#isChecked()">isChecked</a></span>()</nobr>
+
<div class="jd-descrdiv">Check if the UI element's <code>checked</code> property is currently true</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#isClickable()">isClickable</a></span>()
-
- <div class="jd-descrdiv">Check if the UI element's <code>clickable</code> property is currently true</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#isClickable()">isClickable</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Checks if the UI element's <code>clickable</code> property is currently true.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#isEnabled()">isEnabled</a></span>()
-
- <div class="jd-descrdiv">Check if the UI element's <code>enabled</code> property is currently true</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#isEnabled()">isEnabled</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Checks if the UI element's <code>enabled</code> property is currently true.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#isFocusable()">isFocusable</a></span>()
-
- <div class="jd-descrdiv">Check if the UI element's <code>focusable</code> property is currently true</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#isFocusable()">isFocusable</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Check if the UI element's <code>focusable</code> property is currently true.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#isFocused()">isFocused</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#isFocused()">isFocused</a></span>()</nobr>
+
<div class="jd-descrdiv">Check if the UI element's <code>focused</code> property is currently true</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#isLongClickable()">isLongClickable</a></span>()
-
- <div class="jd-descrdiv">Check if the UI element's <code>long-clickable</code> property is currently true</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#isLongClickable()">isLongClickable</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Check if the view's <code>long-clickable</code> property is currently true</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#isScrollable()">isScrollable</a></span>()
-
- <div class="jd-descrdiv">Check if the UI element's <code>scrollable</code> property is currently true</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#isScrollable()">isScrollable</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Check if the view's <code>scrollable</code> property is currently true</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#isSelected()">isSelected</a></span>()
-
- <div class="jd-descrdiv">Check if the UI element's <code>selected</code> property is currently true</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#isSelected()">isSelected</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Checks if the UI element's <code>selected</code> property is currently true.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#longClick()">longClick</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#longClick()">longClick</a></span>()</nobr>
+
<div class="jd-descrdiv">Long clicks the center of the visible bounds of the UI element</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#longClickBottomRight()">longClickBottomRight</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#longClickBottomRight()">longClickBottomRight</a></span>()</nobr>
+
<div class="jd-descrdiv">Long clicks bottom and right corner of the UI element</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#longClickTopLeft()">longClickTopLeft</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#longClickTopLeft()">longClickTopLeft</a></span>()</nobr>
+
<div class="jd-descrdiv">Long clicks on the top and left corner of the UI element</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#setText(java.lang.String)">setText</a></span>(String text)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#performMultiPointerGesture(android.view.MotionEvent.PointerCoords[]...)">performMultiPointerGesture</a></span>(PointerCoords... touches)</nobr>
+
+ <div class="jd-descrdiv">Performs a multi-touch gesture.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#performTwoPointerGesture(android.graphics.Point, android.graphics.Point, android.graphics.Point, android.graphics.Point, int)">performTwoPointerGesture</a></span>(Point startPoint1, Point startPoint2, Point endPoint1, Point endPoint2, int steps)</nobr>
+
+ <div class="jd-descrdiv">Generates a two-pointer gesture with arbitrary starting and ending points.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#pinchIn(int, int)">pinchIn</a></span>(int percent, int steps)</nobr>
+
+ <div class="jd-descrdiv">Performs a two-pointer gesture, where each pointer moves diagonally
+ toward the other, from the edges to the center of this UiObject .</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#pinchOut(int, int)">pinchOut</a></span>(int percent, int steps)</nobr>
+
+ <div class="jd-descrdiv">Performs a two-pointer gesture, where each pointer moves diagonally
+ opposite across the other, from the center out towards the edges of the
+ this UiObject.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#setText(java.lang.String)">setText</a></span>(String text)</nobr>
+
<div class="jd-descrdiv">Sets the text in an editable field, after clearing the field's content.</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#swipeDown(int)">swipeDown</a></span>(int steps)
-
- <div class="jd-descrdiv">Perform the action on the UI element that is represented by this object, Also see
- #scrollToBeginning(int), #scrollToEnd(int), #scrollBackward(),
- #scrollForward().</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#swipeDown(int)">swipeDown</a></span>(int steps)</nobr>
+
+ <div class="jd-descrdiv">Performs the swipe down action on the UiObject.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#swipeLeft(int)">swipeLeft</a></span>(int steps)
-
- <div class="jd-descrdiv">Perform the action on the UI element that is represented by this object.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#swipeLeft(int)">swipeLeft</a></span>(int steps)</nobr>
+
+ <div class="jd-descrdiv">Performs the swipe left action on the UiObject.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#swipeRight(int)">swipeRight</a></span>(int steps)
-
- <div class="jd-descrdiv">Perform the action on the UI element that is represented by this object.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#swipeRight(int)">swipeRight</a></span>(int steps)</nobr>
+
+ <div class="jd-descrdiv">Performs the swipe right action on the UiObject.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#swipeUp(int)">swipeUp</a></span>(int steps)
-
- <div class="jd-descrdiv">Perform the action on the UI element that is represented by this UiObject.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#swipeUp(int)">swipeUp</a></span>(int steps)</nobr>
+
+ <div class="jd-descrdiv">Performs the swipe up action on the UiObject.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#waitForExists(long)">waitForExists</a></span>(long timeout)
-
- <div class="jd-descrdiv">Waits a specified length of time for a UI element to become visible.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#waitForExists(long)">waitForExists</a></span>(long timeout)</nobr>
+
+ <div class="jd-descrdiv">Waits a specified length of time for a view to become visible.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#waitUntilGone(long)">waitUntilGone</a></span>(long timeout)
-
- <div class="jd-descrdiv">Waits a specified length of time for a UI element to become undetectable.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#waitUntilGone(long)">waitUntilGone</a></span>(long timeout)</nobr>
+
+ <div class="jd-descrdiv">Waits a specified length of time for a view to become undetectable.</div>
+
</td></tr>
@@ -737,6 +899,34 @@
+<!-- ========== METHOD SUMMARY =========== -->
+<table id="promethods" class="jd-sumtable"><tr><th colspan="12">Protected Methods</th></tr>
+
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ AccessibilityNodeInfo</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#findAccessibilityNodeInfo(long)">findAccessibilityNodeInfo</a></span>(long timeout)</nobr>
+
+ <div class="jd-descrdiv">Finds a matching UI element in the accessibility hierarchy, by
+ using the selector for this UiObject.</div>
+
+ </td></tr>
+
+
+
+</table>
+
+
@@ -746,7 +936,7 @@
<div style="clear:left;">Inherited Methods</div></th></tr>
-<tr class="api apilevel-" >
+<tr class="api" >
<td colspan="12">
<a href="#" onclick="return toggleInherited(this, null)" id="inherited-methods-java.lang.Object" class="jd-expando-trigger closed"
><img id="inherited-methods-java.lang.Object-trigger"
@@ -762,150 +952,182 @@
</div>
<div id="inherited-methods-java.lang.Object-summary" style="display: none;">
<table class="jd-sumtable-expando">
-
-
+
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ Object</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">equals</span>(Object arg0)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">clone</span>()</nobr>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">equals</span>(Object arg0)</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">finalize</span>()</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- Class<?>
+
+
+ Class<?></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">getClass</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">getClass</span>()</nobr>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- int
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ int</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">hashCode</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">hashCode</span>()</nobr>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">notify</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">notify</span>()</nobr>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">notifyAll</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">notifyAll</span>()</nobr>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- String
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">toString</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">toString</span>()</nobr>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">wait</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">wait</span>()</nobr>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">wait</span>(long arg0, int arg1)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">wait</span>(long arg0, int arg1)</nobr>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">wait</span>(long arg0)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">wait</span>(long arg0)</nobr>
+
</td></tr>
@@ -938,6 +1160,251 @@
<!-- Constants -->
+<!-- ========= ENUM CONSTANTS DETAIL ======== -->
+<h2>Constants</h2>
+
+
+
+
+<A NAME="FINGER_TOUCH_HALF_WIDTH"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ protected
+ static
+ final
+ int
+ </span>
+ FINGER_TOUCH_HALF_WIDTH
+ </h4>
+ <div class="api-level">
+
+
+
+
+ </div>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p></p></div>
+
+
+ <div class="jd-tagdata">
+ <span class="jd-tagtitle">Constant Value: </span>
+ <span>
+
+ 20
+ (0x00000014)
+
+ </span>
+ </div>
+
+ </div>
+</div>
+
+
+
+<A NAME="SWIPE_MARGIN_LIMIT"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ protected
+ static
+ final
+ int
+ </span>
+ SWIPE_MARGIN_LIMIT
+ </h4>
+ <div class="api-level">
+
+
+
+
+ </div>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p></p></div>
+
+
+ <div class="jd-tagdata">
+ <span class="jd-tagtitle">Constant Value: </span>
+ <span>
+
+ 5
+ (0x00000005)
+
+ </span>
+ </div>
+
+ </div>
+</div>
+
+
+
+<A NAME="WAIT_FOR_EVENT_TMEOUT"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ protected
+ static
+ final
+ long
+ </span>
+ WAIT_FOR_EVENT_TMEOUT
+ </h4>
+ <div class="api-level">
+
+
+
+
+ </div>
+ <div class="jd-details-descr">
+ <p>
+ <p class="caution"><strong>
+ This constant is deprecated.</strong><br/>
+ use <code><a href="Configurator.html#setScrollAcknowledgmentTimeout(long)">setScrollAcknowledgmentTimeout(long)</a></code>
+
+ </p>
+ <div class="jd-tagdata jd-tagdescr"><p></p></div>
+
+
+ <div class="jd-tagdata">
+ <span class="jd-tagtitle">Constant Value: </span>
+ <span>
+
+ 3000
+ (0x0000000000000bb8)
+
+ </span>
+ </div>
+
+ </div>
+</div>
+
+
+
+<A NAME="WAIT_FOR_SELECTOR_POLL"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ protected
+ static
+ final
+ long
+ </span>
+ WAIT_FOR_SELECTOR_POLL
+ </h4>
+ <div class="api-level">
+
+
+
+
+ </div>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p></p></div>
+
+
+ <div class="jd-tagdata">
+ <span class="jd-tagtitle">Constant Value: </span>
+ <span>
+
+ 1000
+ (0x00000000000003e8)
+
+ </span>
+ </div>
+
+ </div>
+</div>
+
+
+
+<A NAME="WAIT_FOR_SELECTOR_TIMEOUT"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ protected
+ static
+ final
+ long
+ </span>
+ WAIT_FOR_SELECTOR_TIMEOUT
+ </h4>
+ <div class="api-level">
+
+
+
+
+ </div>
+ <div class="jd-details-descr">
+ <p>
+ <p class="caution"><strong>
+ This constant is deprecated.</strong><br/>
+ use <code><a href="Configurator.html#setWaitForSelectorTimeout(long)">setWaitForSelectorTimeout(long)</a></code>
+
+ </p>
+ <div class="jd-tagdata jd-tagdescr"><p></p></div>
+
+
+ <div class="jd-tagdata">
+ <span class="jd-tagtitle">Constant Value: </span>
+ <span>
+
+ 10000
+ (0x0000000000002710)
+
+ </span>
+ </div>
+
+ </div>
+</div>
+
+
+
+<A NAME="WAIT_FOR_WINDOW_TMEOUT"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ protected
+ static
+ final
+ long
+ </span>
+ WAIT_FOR_WINDOW_TMEOUT
+ </h4>
+ <div class="api-level">
+
+
+
+
+ </div>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p></p></div>
+
+
+ <div class="jd-tagdata">
+ <span class="jd-tagtitle">Constant Value: </span>
+ <span>
+
+ 5500
+ (0x000000000000157c)
+
+ </span>
+ </div>
+
+ </div>
+</div>
+
+
+
+
<!-- Fields -->
@@ -949,33 +1416,31 @@
-<a id="UiObject(com.android.uiautomator.core.UiSelector)"></a>
+<A NAME="UiObject(com.android.uiautomator.core.UiSelector)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
-
+ public
+
+
+
+
+
</span>
<span class="sympad">UiObject</span>
<span class="normal">(<a href="UiSelector.html">UiSelector</a> selector)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Constructs a UiObject to represent a specific UI element matched by the specified
- <code><a href="UiSelector.html">UiSelector</a></code> selector properties.</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Constructs a UiObject to represent a view that matches the specified
+ selector criteria.</p></div>
</div>
</div>
@@ -996,31 +1461,29 @@
-<a id="clearTextField()"></a>
+<A NAME="clearTextField()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
void
</span>
<span class="sympad">clearTextField</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Clears the existing text contents in an editable field.
The <code><a href="UiSelector.html">UiSelector</a></code> of this object must reference a UI element that is editable.
@@ -1037,7 +1500,8 @@
Also, not all editable fields support the long-press functionality.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1049,31 +1513,29 @@
</div>
-<a id="click()"></a>
+<A NAME="click()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">click</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Performs a click at the center of the visible bounds of the UI element represented
by this UiObject.</p></div>
<div class="jd-tagdata">
@@ -1082,7 +1544,8 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1094,31 +1557,29 @@
</div>
-<a id="clickAndWaitForNewWindow(long)"></a>
+<A NAME="clickAndWaitForNewWindow(long)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">clickAndWaitForNewWindow</span>
<span class="normal">(long timeout)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Performs a click at the center of the visible bounds of the UI element represented
by this UiObject and waits for window transitions.
@@ -1131,7 +1592,7 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>timeout</th>
+ <th>timeout</td>
<td>timeout before giving up on waiting for a new window</td>
</tr>
</table>
@@ -1142,7 +1603,8 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1154,41 +1616,40 @@
</div>
-<a id="clickAndWaitForNewWindow()"></a>
+<A NAME="clickAndWaitForNewWindow()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">clickAndWaitForNewWindow</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>See <code><a href="#clickAndWaitForNewWindow(long)">clickAndWaitForNewWindow(long)</a></code>
- This method is intended to reliably wait for window transitions that would typically take
- longer than the usual default timeouts.</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Waits for window transitions that would typically take longer than the
+ usual default timeouts.
+ See <code><a href="#clickAndWaitForNewWindow(long)">clickAndWaitForNewWindow(long)</a></code></p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
<ul class="nolist"><li>true if the event was triggered, else false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1200,31 +1661,29 @@
</div>
-<a id="clickBottomRight()"></a>
+<A NAME="clickBottomRight()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">clickBottomRight</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Clicks the bottom and right corner of the UI element</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -1232,11 +1691,8 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
- <tr>
- <th>Exception</td>
- <td></td>
- </tr>
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1248,31 +1704,29 @@
</div>
-<a id="clickTopLeft()"></a>
+<A NAME="clickTopLeft()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">clickTopLeft</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Clicks the top and left corner of the UI element</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -1280,11 +1734,8 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
- <tr>
- <th>Exception</td>
- <td></td>
- </tr>
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1296,134 +1747,243 @@
</div>
-<a id="exists()"></a>
+<A NAME="dragTo(com.android.uiautomator.core.UiObject, int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
+ boolean
+ </span>
+ <span class="sympad">dragTo</span>
+ <span class="normal">(<a href="#">UiObject</a> destObj, int steps)</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Drags this object to a destination UiObject.
+ The number of steps specified in your input parameter can influence the
+ drag speed, and varying speeds may impact the results. Consider
+ evaluating different speeds when using this method in your tests.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>destObj</td>
+ <td>the destination UiObject.</td>
+ </tr>
+ <tr>
+ <th>steps</td>
+ <td>usually 40 steps. You can increase or decrease the steps to change the speed.</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>true if successful</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Throws</h5>
+ <table class="jd-tagtable">
+
+ <tr>
+ <th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
+ <td></td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="dragTo(int, int, int)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ boolean
+ </span>
+ <span class="sympad">dragTo</span>
+ <span class="normal">(int destX, int destY, int steps)</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Drags this object to arbitrary coordinates.
+ The number of steps specified in your input parameter can influence the
+ drag speed, and varying speeds may impact the results. Consider
+ evaluating different speeds when using this method in your tests.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>destX</td>
+ <td>the X-axis coordinate.</td>
+ </tr>
+ <tr>
+ <th>destY</td>
+ <td>the Y-axis coordinate.</td>
+ </tr>
+ <tr>
+ <th>steps</td>
+ <td>usually 40 steps. You can increase or decrease the steps to change the speed.</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>true if successful</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Throws</h5>
+ <table class="jd-tagtable">
+
+ <tr>
+ <th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
+ <td></td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="exists()"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
boolean
</span>
<span class="sympad">exists</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Check if UI element exists.
+
+ <div class="jd-tagdata jd-tagdescr"><p>Check if view exists.
This methods performs a <code><a href="#waitForExists(long)">waitForExists(long)</a></code> with zero timeout. This
- basically returns immediately whether the UI element represented by this UiObject
- exists or not. If you need to wait longer for this UI element, then see
+ basically returns immediately whether the view represented by this UiObject
+ exists or not. If you need to wait longer for this view, then see
<code><a href="#waitForExists(long)">waitForExists(long)</a></code>.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true if the UI element represented by this UiObject does exist
-</li></ul>
+ <ul class="nolist"><li>true if the view represented by this UiObject does exist</li></ul>
</div>
</div>
</div>
-<a id="getBounds()"></a>
+<A NAME="getBounds()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
Rect
</span>
<span class="sympad">getBounds</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Returns the UI element's <code>bounds</code> property. See <code><a href="#getVisibleBounds()">getVisibleBounds()</a></code></p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Returns the view's <code>bounds</code> property. See <code><a href="#getVisibleBounds()">getVisibleBounds()</a></code></p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
<ul class="nolist"><li>Rect</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
</tr>
</table>
</div>
+
</div>
</div>
-<a id="getChild(com.android.uiautomator.core.UiSelector)"></a>
+<A NAME="getChild(com.android.uiautomator.core.UiSelector)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiObject.html">UiObject</a>
+ public
+
+
+
+
+ <a href="#">UiObject</a>
</span>
<span class="sympad">getChild</span>
<span class="normal">(<a href="UiSelector.html">UiSelector</a> selector)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Creates a new UiObject representing a child UI element of the element currently represented
- by this UiObject.</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Creates a new UiObject for a child view that is under the present UiObject.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>selector</th>
- <td>for UI element to match</td>
+ <th>selector</td>
+ <td>for child view to match</td>
</tr>
</table>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>a new UiObject representing the matched UI element
-</li></ul>
+ <ul class="nolist"><li>a new UiObject representing the child view</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1435,40 +1995,38 @@
</div>
-<a id="getChildCount()"></a>
+<A NAME="getChildCount()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
int
</span>
<span class="sympad">getChildCount</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Counts the child UI elements immediately under the UI element currently represented by
- this UiObject.</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Counts the child views immediately under the present UiObject.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>the count of child UI elements.</li></ul>
+ <ul class="nolist"><li>the count of child views.</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1480,31 +2038,68 @@
</div>
-<a id="getContentDescription()"></a>
+<A NAME="getClassName()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
+ String
+ </span>
+ <span class="sympad">getClassName</span>
+ <span class="normal">()</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Retrieves the <code>className</code> property of the UI element.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>class name of the current node represented by this UiObject</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Throws</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
+ <td>if no match was found</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="getContentDescription()"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
String
</span>
<span class="sympad">getContentDescription</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Reads the <code>content_desc</code> property of the UI element</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -1512,7 +2107,8 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1524,51 +2120,48 @@
</div>
-<a id="getFromParent(com.android.uiautomator.core.UiSelector)"></a>
+<A NAME="getFromParent(com.android.uiautomator.core.UiSelector)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiObject.html">UiObject</a>
+ public
+
+
+
+
+ <a href="#">UiObject</a>
</span>
<span class="sympad">getFromParent</span>
<span class="normal">(<a href="UiSelector.html">UiSelector</a> selector)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Creates a new UiObject representing a child UI element from the parent element currently
- represented by this object. Essentially this is starting the search from the parent
- element and can also be used to find sibling UI elements to the one currently represented
- by this UiObject.</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Creates a new UiObject for a sibling view or a child of the sibling view,
+ relative to the present UiObject.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>selector</th>
- <td>for the UI element to match</td>
+ <th>selector</td>
+ <td>for a sibling view or children of the sibling view</td>
</tr>
</table>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>a new UiObject representing the matched UI element</li></ul>
+ <ul class="nolist"><li>a new UiObject representing the matched view</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1580,39 +2173,38 @@
</div>
-<a id="getPackageName()"></a>
+<A NAME="getPackageName()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
String
</span>
<span class="sympad">getPackageName</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Reads the UI element's <code>package</code> property</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Reads the view's <code>package</code> property</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
<ul class="nolist"><li>true if it is else false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1624,68 +2216,63 @@
</div>
-<a id="getSelector()"></a>
+<A NAME="getSelector()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
- final
-
-
+ public
+
+ final
+
+
<a href="UiSelector.html">UiSelector</a>
</span>
<span class="sympad">getSelector</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Debugging helper. A test can dump the properties of a selector as a string
to its logs if needed. <code>getSelector().toString();</code></p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li><code><a href="UiSelector.html">UiSelector</a></code>
-</li></ul>
+ <ul class="nolist"><li><code><a href="UiSelector.html">UiSelector</a></code></li></ul>
</div>
</div>
</div>
-<a id="getText()"></a>
+<A NAME="getText()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
String
</span>
<span class="sympad">getText</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Reads the <code>text</code> property of the UI element</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -1693,11 +2280,10 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
- <td>if no match could be found
-</td>
+ <td>if no match could be found</td>
</tr>
</table>
</div>
@@ -1706,34 +2292,26 @@
</div>
-<a id="getVisibleBounds()"></a>
+<A NAME="getVisibleBounds()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
Rect
</span>
<span class="sympad">getVisibleBounds</span>
<span class="normal">()</span>
</h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Returns the visible bounds of the UI element.
- If a portion of the UI element is visible, only the bounds of the visible portion are
+ <div class="jd-tagdata jd-tagdescr"><p>Returns the visible bounds of the view.
+
+ If a portion of the view is visible, only the bounds of the visible portion are
reported.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -1741,58 +2319,59 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
- <tr>
- <th></td>
- <td>UiObjectNotFoundException</td>
- </tr>
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
</tr>
</table>
</div>
- <div class="jd-tagdata">
- <h5 class="jd-tagtitle">Since</h5>
- <ul class="nolist"><li>Android API Level 17</li></ul>
-</div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">See Also</h5>
+ <ul class="nolist"><li><code><a href="#getBounds()">getBounds()</a></code></li>
+ </ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 17</li></ul>
+ </div>
</div>
</div>
-<a id="isCheckable()"></a>
+<A NAME="isCheckable()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">isCheckable</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Check if the UI element's <code>checkable</code> property is currently true</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Checks if the UI element's <code>checkable</code> property is currently true.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
<ul class="nolist"><li>true if it is else false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1804,40 +2383,37 @@
</div>
-<a id="isChecked()"></a>
+<A NAME="isChecked()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">isChecked</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Check if the UI element's <code>checked</code> property is currently true</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true if it is else false
-</li></ul>
+ <ul class="nolist"><li>true if it is else false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1849,39 +2425,38 @@
</div>
-<a id="isClickable()"></a>
+<A NAME="isClickable()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">isClickable</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Check if the UI element's <code>clickable</code> property is currently true</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Checks if the UI element's <code>clickable</code> property is currently true.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
<ul class="nolist"><li>true if it is else false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1893,39 +2468,38 @@
</div>
-<a id="isEnabled()"></a>
+<A NAME="isEnabled()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">isEnabled</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Check if the UI element's <code>enabled</code> property is currently true</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Checks if the UI element's <code>enabled</code> property is currently true.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
<ul class="nolist"><li>true if it is else false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1937,39 +2511,38 @@
</div>
-<a id="isFocusable()"></a>
+<A NAME="isFocusable()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">isFocusable</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Check if the UI element's <code>focusable</code> property is currently true</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Check if the UI element's <code>focusable</code> property is currently true.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
<ul class="nolist"><li>true if it is else false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1981,31 +2554,29 @@
</div>
-<a id="isFocused()"></a>
+<A NAME="isFocused()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">isFocused</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Check if the UI element's <code>focused</code> property is currently true</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -2013,7 +2584,8 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2025,39 +2597,38 @@
</div>
-<a id="isLongClickable()"></a>
+<A NAME="isLongClickable()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">isLongClickable</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Check if the UI element's <code>long-clickable</code> property is currently true</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Check if the view's <code>long-clickable</code> property is currently true</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
<ul class="nolist"><li>true if it is else false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2069,39 +2640,38 @@
</div>
-<a id="isScrollable()"></a>
+<A NAME="isScrollable()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">isScrollable</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Check if the UI element's <code>scrollable</code> property is currently true</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Check if the view's <code>scrollable</code> property is currently true</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
<ul class="nolist"><li>true if it is else false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2113,39 +2683,38 @@
</div>
-<a id="isSelected()"></a>
+<A NAME="isSelected()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">isSelected</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Check if the UI element's <code>selected</code> property is currently true</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Checks if the UI element's <code>selected</code> property is currently true.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
<ul class="nolist"><li>true if it is else false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2157,31 +2726,29 @@
</div>
-<a id="longClick()"></a>
+<A NAME="longClick()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">longClick</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Long clicks the center of the visible bounds of the UI element</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -2189,7 +2756,8 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2201,31 +2769,29 @@
</div>
-<a id="longClickBottomRight()"></a>
+<A NAME="longClickBottomRight()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">longClickBottomRight</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Long clicks bottom and right corner of the UI element</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -2233,7 +2799,8 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2245,31 +2812,29 @@
</div>
-<a id="longClickTopLeft()"></a>
+<A NAME="longClickTopLeft()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">longClickTopLeft</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Long clicks on the top and left corner of the UI element</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
@@ -2277,7 +2842,8 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2289,31 +2855,254 @@
</div>
-<a id="setText(java.lang.String)"></a>
+<A NAME="performMultiPointerGesture(android.view.MotionEvent.PointerCoords[]...)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
+ boolean
+ </span>
+ <span class="sympad">performMultiPointerGesture</span>
+ <span class="normal">(PointerCoords... touches)</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs a multi-touch gesture. You must specify touch coordinates for
+ at least 2 pointers. Each pointer must have all of its touch steps
+ defined in an array of <code><a href="../../../../../reference/android/view/MotionEvent.PointerCoords.html">MotionEvent.PointerCoords</a></code>. You can use this method to
+ specify complex gestures, like circles and irregular shapes, where each
+ pointer may take a different path.
+
+ To create a single point on a pointer's touch path:
+ <code>
+ PointerCoords p = new PointerCoords();
+ p.x = stepX;
+ p.y = stepY;
+ p.pressure = 1;
+ p.size = 1;
+ </code></p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>touches</td>
+ <td>represents the pointers' paths. Each <code><a href="../../../../../reference/android/view/MotionEvent.PointerCoords.html">MotionEvent.PointerCoords</a></code>
+ array represents a different pointer. Each <code><a href="../../../../../reference/android/view/MotionEvent.PointerCoords.html">MotionEvent.PointerCoords</a></code> in an
+ array element represents a touch point on a pointer's path.</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li><code>true</code> if all touch events for this gesture are injected successfully,
+ <code>false</code> otherwise</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="performTwoPointerGesture(android.graphics.Point, android.graphics.Point, android.graphics.Point, android.graphics.Point, int)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ boolean
+ </span>
+ <span class="sympad">performTwoPointerGesture</span>
+ <span class="normal">(Point startPoint1, Point startPoint2, Point endPoint1, Point endPoint2, int steps)</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Generates a two-pointer gesture with arbitrary starting and ending points.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>startPoint1</td>
+ <td>start point of pointer 1</td>
+ </tr>
+ <tr>
+ <th>startPoint2</td>
+ <td>start point of pointer 2</td>
+ </tr>
+ <tr>
+ <th>endPoint1</td>
+ <td>end point of pointer 1</td>
+ </tr>
+ <tr>
+ <th>endPoint2</td>
+ <td>end point of pointer 2</td>
+ </tr>
+ <tr>
+ <th>steps</td>
+ <td>the number of steps for the gesture. Steps are injected
+ about 5 milliseconds apart, so 100 steps may take around 0.5 seconds to complete.</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li><code>true</code> if all touch events for this gesture are injected successfully,
+ <code>false</code> otherwise</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="pinchIn(int, int)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ boolean
+ </span>
+ <span class="sympad">pinchIn</span>
+ <span class="normal">(int percent, int steps)</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs a two-pointer gesture, where each pointer moves diagonally
+ toward the other, from the edges to the center of this UiObject .</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>percent</td>
+ <td>percentage of the object's diagonal length for the pinch gesture</td>
+ </tr>
+ <tr>
+ <th>steps</td>
+ <td>the number of steps for the gesture. Steps are injected
+ about 5 milliseconds apart, so 100 steps may take around 0.5 seconds to complete.</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li><code>true</code> if all touch events for this gesture are injected successfully,
+ <code>false</code> otherwise</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Throws</h5>
+ <table class="jd-tagtable">
+
+ <tr>
+ <th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
+ <td></td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="pinchOut(int, int)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ boolean
+ </span>
+ <span class="sympad">pinchOut</span>
+ <span class="normal">(int percent, int steps)</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs a two-pointer gesture, where each pointer moves diagonally
+ opposite across the other, from the center out towards the edges of the
+ this UiObject.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>percent</td>
+ <td>percentage of the object's diagonal length for the pinch gesture</td>
+ </tr>
+ <tr>
+ <th>steps</td>
+ <td>the number of steps for the gesture. Steps are injected
+ about 5 milliseconds apart, so 100 steps may take around 0.5 seconds to complete.</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li><code>true</code> if all touch events for this gesture are injected successfully,
+ <code>false</code> otherwise</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Throws</h5>
+ <table class="jd-tagtable">
+
+ <tr>
+ <th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
+ <td></td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="setText(java.lang.String)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
boolean
</span>
<span class="sympad">setText</span>
<span class="normal">(String text)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Sets the text in an editable field, after clearing the field's content.
The <code><a href="UiSelector.html">UiSelector</a></code> selector of this object must reference a UI element that is editable.
@@ -2328,7 +3117,7 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>text</th>
+ <th>text</td>
<td>string to set</td>
</tr>
</table>
@@ -2339,7 +3128,8 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2351,41 +3141,44 @@
</div>
-<a id="swipeDown(int)"></a>
+<A NAME="swipeDown(int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">swipeDown</span>
<span class="normal">(int steps)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Perform the action on the UI element that is represented by this object, Also see
- #scrollToBeginning(int), #scrollToEnd(int), #scrollBackward(),
- #scrollForward(). This method will perform the swipe gesture over any
- surface. The targeted UI element does not need to have the attribute
- <code>scrollable</code> set to <code>true</code> for this operation to be performed.</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs the swipe down action on the UiObject.
+ The swipe gesture can be performed over any surface. The targeted
+ UI element does not need to be scrollable.
+ See also:
+ <ul>
+ <li><code><a href="UiScrollable.html#scrollToBeginning(int)">scrollToBeginning(int)</a></code></li>
+ <li><code><a href="UiScrollable.html#scrollToEnd(int)">scrollToEnd(int)</a></code></li>
+ <li><code><a href="UiScrollable.html#scrollBackward()">scrollBackward()</a></code></li>
+ <li><code><a href="UiScrollable.html#scrollForward()">scrollForward()</a></code></li>
+ </ul></p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>steps</th>
+ <th>steps</td>
<td>indicates the number of injected move steps into the system. Steps are
injected about 5ms apart. So a 100 steps may take about 1/2 second to complete.</td>
</tr>
@@ -2397,7 +3190,8 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2409,41 +3203,44 @@
</div>
-<a id="swipeLeft(int)"></a>
+<A NAME="swipeLeft(int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">swipeLeft</span>
<span class="normal">(int steps)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Perform the action on the UI element that is represented by this object. Also see
- #scrollToBeginning(int), #scrollToEnd(int), #scrollBackward(),
- #scrollForward(). This method will perform the swipe gesture over any
- surface. The targeted UI element does not need to have the attribute
- <code>scrollable</code> set to <code>true</code> for this operation to be performed.</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs the swipe left action on the UiObject.
+ The swipe gesture can be performed over any surface. The targeted
+ UI element does not need to be scrollable.
+ See also:
+ <ul>
+ <li><code><a href="UiScrollable.html#scrollToBeginning(int)">scrollToBeginning(int)</a></code></li>
+ <li><code><a href="UiScrollable.html#scrollToEnd(int)">scrollToEnd(int)</a></code></li>
+ <li><code><a href="UiScrollable.html#scrollBackward()">scrollBackward()</a></code></li>
+ <li><code><a href="UiScrollable.html#scrollForward()">scrollForward()</a></code></li>
+ </ul></p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>steps</th>
+ <th>steps</td>
<td>indicates the number of injected move steps into the system. Steps are
injected about 5ms apart. So a 100 steps may take about 1/2 second to complete.</td>
</tr>
@@ -2455,7 +3252,8 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2467,41 +3265,44 @@
</div>
-<a id="swipeRight(int)"></a>
+<A NAME="swipeRight(int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">swipeRight</span>
<span class="normal">(int steps)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Perform the action on the UI element that is represented by this object. Also see
- #scrollToBeginning(int), #scrollToEnd(int), #scrollBackward(),
- #scrollForward(). This method will perform the swipe gesture over any
- surface. The targeted UI element does not need to have the attribute
- <code>scrollable</code> set to <code>true</code> for this operation to be performed.</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs the swipe right action on the UiObject.
+ The swipe gesture can be performed over any surface. The targeted
+ UI element does not need to be scrollable.
+ See also:
+ <ul>
+ <li><code><a href="UiScrollable.html#scrollToBeginning(int)">scrollToBeginning(int)</a></code></li>
+ <li><code><a href="UiScrollable.html#scrollToEnd(int)">scrollToEnd(int)</a></code></li>
+ <li><code><a href="UiScrollable.html#scrollBackward()">scrollBackward()</a></code></li>
+ <li><code><a href="UiScrollable.html#scrollForward()">scrollForward()</a></code></li>
+ </ul></p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>steps</th>
+ <th>steps</td>
<td>indicates the number of injected move steps into the system. Steps are
injected about 5ms apart. So a 100 steps may take about 1/2 second to complete.</td>
</tr>
@@ -2513,7 +3314,8 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2525,39 +3327,42 @@
</div>
-<a id="swipeUp(int)"></a>
+<A NAME="swipeUp(int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">swipeUp</span>
<span class="normal">(int steps)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Perform the action on the UI element that is represented by this UiObject. Also see
- #scrollToBeginning(int), #scrollToEnd(int), #scrollBackward(),
- #scrollForward().</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs the swipe up action on the UiObject.
+ See also:
+ <ul>
+ <li><code><a href="UiScrollable.html#scrollToBeginning(int)">scrollToBeginning(int)</a></code></li>
+ <li><code><a href="UiScrollable.html#scrollToEnd(int)">scrollToEnd(int)</a></code></li>
+ <li><code><a href="UiScrollable.html#scrollBackward()">scrollBackward()</a></code></li>
+ <li><code><a href="UiScrollable.html#scrollForward()">scrollForward()</a></code></li>
+ </ul></p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>steps</th>
+ <th>steps</td>
<td>indicates the number of injected move steps into the system. Steps are
injected about 5ms apart. So a 100 steps may take about 1/2 second to complete.</td>
</tr>
@@ -2569,7 +3374,8 @@
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2581,86 +3387,81 @@
</div>
-<a id="waitForExists(long)"></a>
+<A NAME="waitForExists(long)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">waitForExists</span>
<span class="normal">(long timeout)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Waits a specified length of time for a UI element to become visible.
- This method waits until the UI element becomes visible on the display, or
+ <div class="jd-tagdata jd-tagdescr"><p>Waits a specified length of time for a view to become visible.
+
+ This method waits until the view becomes visible on the display, or
until the timeout has elapsed. You can use this method in situations where
the content that you want to select is not immediately displayed.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>timeout</th>
+ <th>timeout</td>
<td>the amount of time to wait (in milliseconds)</td>
</tr>
</table>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true if the UI element is displayed, else false if timeout elapsed while waiting
-</li></ul>
+ <ul class="nolist"><li>true if the view is displayed, else false if timeout elapsed while waiting</li></ul>
</div>
</div>
</div>
-<a id="waitUntilGone(long)"></a>
+<A NAME="waitUntilGone(long)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">waitUntilGone</span>
<span class="normal">(long timeout)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Waits a specified length of time for a UI element to become undetectable.
- This method waits until a UI element is no longer matchable, or until the
+ <div class="jd-tagdata jd-tagdescr"><p>Waits a specified length of time for a view to become undetectable.
+
+ This method waits until a view is no longer matchable, or until the
timeout has elapsed.
- A UI element becomes undetectable when the <code><a href="UiSelector.html">UiSelector</a></code> of the object is
+ A view becomes undetectable when the <code><a href="UiSelector.html">UiSelector</a></code> of the object is
unable to find a match because the element has either changed its state or is no
longer displayed.
@@ -2670,7 +3471,7 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>timeout</th>
+ <th>timeout</td>
<td>time to wait (in milliseconds)</td>
</tr>
</table>
@@ -2678,10 +3479,65 @@
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
<ul class="nolist"><li>true if the element is gone before timeout elapsed, else false if timeout elapsed
- but a matching element is still found.
-</li></ul>
+ but a matching element is still found.</li></ul>
</div>
</div>
</div>
+
+
+
+
+<!-- ========= METHOD DETAIL ======== -->
+
+<h2>Protected Methods</h2>
+
+
+
+<A NAME="findAccessibilityNodeInfo(long)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ protected
+
+
+
+
+ AccessibilityNodeInfo
+ </span>
+ <span class="sympad">findAccessibilityNodeInfo</span>
+ <span class="normal">(long timeout)</span>
+ </h4>
+ <div class="api-level">
+ <div></div>
+
+
+
+ </div>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Finds a matching UI element in the accessibility hierarchy, by
+ using the selector for this UiObject.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>timeout</td>
+ <td>in milliseconds</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>AccessibilityNodeInfo if found else null</li></ul>
+ </div>
+
+ </div>
+
+
+
+
+
+
diff --git a/docs/html/tools/help/uiautomator/UiObjectNotFoundException.jd b/docs/html/tools/help/uiautomator/UiObjectNotFoundException.jd
index 02c607d..b41cfe5 100644
--- a/docs/html/tools/help/uiautomator/UiObjectNotFoundException.jd
+++ b/docs/html/tools/help/uiautomator/UiObjectNotFoundException.jd
@@ -9,29 +9,6 @@
to any UI element displayed.
</p>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-<div class="jd-descr">
-
-
<h2>Summary</h2>
@@ -627,4 +604,3 @@
<div class="jd-tagdata jd-tagdescr"><p></p></div>
</div>
-</div>
diff --git a/docs/html/tools/help/uiautomator/UiScrollable.jd b/docs/html/tools/help/uiautomator/UiScrollable.jd
index 33566a2..7405f3b 100644
--- a/docs/html/tools/help/uiautomator/UiScrollable.jd
+++ b/docs/html/tools/help/uiautomator/UiScrollable.jd
@@ -5,33 +5,9 @@
<style>
h4.jd-details-title {background-color: #DEE8F1;}
</style>
-<p>UiScrollable is a <code><a href="UiCollection.html">UiCollection</a></code> and provides support for searching for items in a
- scrollable user interface (UI) elements. This class can be used with horizontally or vertically scrollable controls..
-</p>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-<div class="jd-descr">
-
-
+<p>A <code><a href="UiCollection.html">UiCollection</a></code>
+that supports searching for items in scrollable layout elements. This class can
+be used with horizontally or vertically scrollable controls.</p>
<h2>Summary</h2>
@@ -49,6 +25,90 @@
+<!-- =========== ENUM CONSTANT SUMMARY =========== -->
+<table id="inhconstants" class="jd-sumtable"><tr><th>
+ <a href="#" class="toggle-all" onclick="return toggleAllInherited(this, null)">[Expand]</a>
+ <div style="clear:left;">Inherited Constants</div></th></tr>
+
+
+
+
+<tr class="api" >
+<td colspan="12">
+
+ <a href="#" onclick="return toggleInherited(this, null)" id="inherited-constants-com.android.uiautomator.core.UiObject" class="jd-expando-trigger closed"
+ ><img id="inherited-constants-com.android.uiautomator.core.UiObject-trigger"
+ src="../../../../../assets/images/triangle-closed.png"
+ class="jd-expando-trigger-img" /></a>From class
+<a href="UiObject.html">com.android.uiautomator.core.UiObject</a>
+<div id="inherited-constants-com.android.uiautomator.core.UiObject">
+ <div id="inherited-constants-com.android.uiautomator.core.UiObject-list"
+ class="jd-inheritedlinks">
+ </div>
+ <div id="inherited-constants-com.android.uiautomator.core.UiObject-summary" style="display: none;">
+ <table class="jd-sumtable-expando">
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol">int</td>
+ <td class="jd-linkcol"><a href="UiObject.html#FINGER_TOUCH_HALF_WIDTH">FINGER_TOUCH_HALF_WIDTH</a></td>
+ <td class="jd-descrcol" width="100%"></td>
+ </tr>
+
+
+ <tr class="api" >
+ <td class="jd-typecol">int</td>
+ <td class="jd-linkcol"><a href="UiObject.html#SWIPE_MARGIN_LIMIT">SWIPE_MARGIN_LIMIT</a></td>
+ <td class="jd-descrcol" width="100%"></td>
+ </tr>
+
+
+ <tr class="api" >
+ <td class="jd-typecol">long</td>
+ <td class="jd-linkcol"><a href="UiObject.html#WAIT_FOR_EVENT_TMEOUT">WAIT_FOR_EVENT_TMEOUT</a></td>
+ <td class="jd-descrcol" width="100%"><em>
+ This constant is deprecated.
+ use <code><a href="Configurator.html#setScrollAcknowledgmentTimeout(long)">setScrollAcknowledgmentTimeout(long)</a></code>
+</em></td>
+ </tr>
+
+
+ <tr class="api" >
+ <td class="jd-typecol">long</td>
+ <td class="jd-linkcol"><a href="UiObject.html#WAIT_FOR_SELECTOR_POLL">WAIT_FOR_SELECTOR_POLL</a></td>
+ <td class="jd-descrcol" width="100%"></td>
+ </tr>
+
+
+ <tr class="api" >
+ <td class="jd-typecol">long</td>
+ <td class="jd-linkcol"><a href="UiObject.html#WAIT_FOR_SELECTOR_TIMEOUT">WAIT_FOR_SELECTOR_TIMEOUT</a></td>
+ <td class="jd-descrcol" width="100%"><em>
+ This constant is deprecated.
+ use <code><a href="Configurator.html#setWaitForSelectorTimeout(long)">setWaitForSelectorTimeout(long)</a></code>
+</em></td>
+ </tr>
+
+
+ <tr class="api" >
+ <td class="jd-typecol">long</td>
+ <td class="jd-linkcol"><a href="UiObject.html#WAIT_FOR_WINDOW_TMEOUT">WAIT_FOR_WINDOW_TMEOUT</a></td>
+ <td class="jd-descrcol" width="100%"></td>
+ </tr>
+
+
+</table>
+ </div>
+</div>
+</td></tr>
+
+
+
+
+</table>
+
+
@@ -61,22 +121,21 @@
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
-
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ </nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#UiScrollable(com.android.uiautomator.core.UiSelector)">UiScrollable</a></span>(<a href="UiSelector.html">UiSelector</a> container)
-
- <div class="jd-descrdiv">UiScrollable is a <code><a href="UiCollection.html">UiCollection</a></code> and as such requires a <code><a href="UiSelector.html">UiSelector</a></code> to
- identify the container UI element of the scrollable collection.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#UiScrollable(com.android.uiautomator.core.UiSelector)">UiScrollable</a></span>(<a href="UiSelector.html">UiSelector</a> container)</nobr>
+
+ <div class="jd-descrdiv">Constructor.</div>
+
</td></tr>
@@ -93,480 +152,500 @@
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#flingBackward()">flingBackward</a></span>()
-
- <div class="jd-descrdiv">See <code><a href="#scrollBackward(int)">scrollBackward(int)</a></code></div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#flingBackward()">flingBackward</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Performs a backwards fling action with the default number of fling
+ steps (5).</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#flingForward()">flingForward</a></span>()
-
- <div class="jd-descrdiv">A convenience version of <code><a href="#scrollForward(int)">scrollForward(int)</a></code>, performs a fling</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#flingForward()">flingForward</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Performs a forward fling with the default number of fling steps (5).</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#flingToBeginning(int)">flingToBeginning</a></span>(int maxSwipes)
-
- <div class="jd-descrdiv">See <code><a href="#scrollToBeginning(int, int)">scrollToBeginning(int, int)</a></code></div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#flingToBeginning(int)">flingToBeginning</a></span>(int maxSwipes)</nobr>
+
+ <div class="jd-descrdiv">Performs a fling gesture to reach the beginning of a scrollable layout element.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#flingToEnd(int)">flingToEnd</a></span>(int maxSwipes)
-
- <div class="jd-descrdiv">See <code><a href="#scrollToEnd(int, int)">scrollToEnd(int, int)</a></code></div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#flingToEnd(int)">flingToEnd</a></span>(int maxSwipes)</nobr>
+
+ <div class="jd-descrdiv">Performs a fling gesture to reach the end of a scrollable layout element.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiObject.html">UiObject</a>
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="UiObject.html">UiObject</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getChildByDescription(com.android.uiautomator.core.UiSelector, java.lang.String, boolean)">getChildByDescription</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern, String text, boolean allowScrollSearch)
-
- <div class="jd-descrdiv">See <code><a href="#getChildByDescription(com.android.uiautomator.core.UiSelector, java.lang.String)">getChildByDescription(UiSelector, String)</a></code></div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getChildByDescription(com.android.uiautomator.core.UiSelector, java.lang.String, boolean)">getChildByDescription</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern, String text, boolean allowScrollSearch)</nobr>
+
+ <div class="jd-descrdiv">Searches for a child element in the present scrollable container.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiObject.html">UiObject</a>
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="UiObject.html">UiObject</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getChildByDescription(com.android.uiautomator.core.UiSelector, java.lang.String)">getChildByDescription</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern, String text)
-
- <div class="jd-descrdiv">Searches for child UI element within the constraints of this UiScrollable <code><a href="UiSelector.html">UiSelector</a></code>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getChildByDescription(com.android.uiautomator.core.UiSelector, java.lang.String)">getChildByDescription</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern, String text)</nobr>
+
+ <div class="jd-descrdiv">Searches for a child element in the present scrollable container.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="UiObject.html">UiObject</a></nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getChildByInstance(com.android.uiautomator.core.UiSelector, int)">getChildByInstance</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern, int instance)</nobr>
+
+ <div class="jd-descrdiv">Searches for a child element in the present scrollable container that
+ matches the selector you provided.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="UiObject.html">UiObject</a></nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getChildByText(com.android.uiautomator.core.UiSelector, java.lang.String, boolean)">getChildByText</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern, String text, boolean allowScrollSearch)</nobr>
+
+ <div class="jd-descrdiv">Searches for a child element in the present scrollable container.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="UiObject.html">UiObject</a></nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getChildByText(com.android.uiautomator.core.UiSelector, java.lang.String)">getChildByText</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern, String text)</nobr>
+
+ <div class="jd-descrdiv">Searches for a child element in the present scrollable
container.</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiObject.html">UiObject</a>
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ int</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getChildByInstance(com.android.uiautomator.core.UiSelector, int)">getChildByInstance</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern, int instance)
-
- <div class="jd-descrdiv">Searches for child UI element within the constraints of this UiScrollable <code><a href="UiSelector.html">UiSelector</a></code>
- selector.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getMaxSearchSwipes()">getMaxSearchSwipes</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Gets the maximum number of scrolls allowed when performing a
+ scroll action in search of a child element.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiObject.html">UiObject</a>
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ double</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getChildByText(com.android.uiautomator.core.UiSelector, java.lang.String, boolean)">getChildByText</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern, String text, boolean allowScrollSearch)
-
- <div class="jd-descrdiv">See <code><a href="#getChildByText(com.android.uiautomator.core.UiSelector, java.lang.String)">getChildByText(UiSelector, String)</a></code></div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#getSwipeDeadZonePercentage()">getSwipeDeadZonePercentage</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Returns the percentage of a widget's size that's considered as a no-touch
+ zone when swiping.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiObject.html">UiObject</a>
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getChildByText(com.android.uiautomator.core.UiSelector, java.lang.String)">getChildByText</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern, String text)
-
- <div class="jd-descrdiv">Searches for child UI element within the constraints of this UiScrollable <code><a href="UiSelector.html">UiSelector</a></code>
- container.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#scrollBackward(int)">scrollBackward</a></span>(int steps)</nobr>
+
+ <div class="jd-descrdiv">Performs a backward scroll.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- int
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getMaxSearchSwipes()">getMaxSearchSwipes</a></span>()
-
- <div class="jd-descrdiv">#getChildByDescription(String, boolean) and #getChildByText(String, boolean)
- use an arguments that specifies if scrolling is allowed while searching for the UI element.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#scrollBackward()">scrollBackward</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Performs a backward scroll with the default number of scroll steps (55).</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- double
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#getSwipeDeadZonePercentage()">getSwipeDeadZonePercentage</a></span>()
-
- <div class="jd-descrdiv">Returns the percentage of a widget's size that's considered as a no touch zone when swiping.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#scrollDescriptionIntoView(java.lang.String)">scrollDescriptionIntoView</a></span>(String text)</nobr>
+
+ <div class="jd-descrdiv">Performs a forward scroll action on the scrollable layout element until
+ the content-description is found, or until swipe attempts have been exhausted.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#scrollBackward(int)">scrollBackward</a></span>(int steps)
-
- <div class="jd-descrdiv">Perform a scroll backward.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#scrollForward()">scrollForward</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Performs a forward scroll with the default number of scroll steps (55).</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#scrollBackward()">scrollBackward</a></span>()
-
- <div class="jd-descrdiv">See <code><a href="#scrollBackward(int)">scrollBackward(int)</a></code></div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#scrollForward(int)">scrollForward</a></span>(int steps)</nobr>
+
+ <div class="jd-descrdiv">Performs a forward scroll.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#scrollDescriptionIntoView(java.lang.String)">scrollDescriptionIntoView</a></span>(String text)
-
- <div class="jd-descrdiv">Performs a swipe Up on the UI element until the requested content-description
- is visible or until swipe attempts have been exhausted.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#scrollIntoView(com.android.uiautomator.core.UiSelector)">scrollIntoView</a></span>(<a href="UiSelector.html">UiSelector</a> selector)</nobr>
+
+ <div class="jd-descrdiv">Perform a scroll forward action to move through the scrollable layout
+ element until a visible item that matches the selector is found.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#scrollForward()">scrollForward</a></span>()
-
- <div class="jd-descrdiv">A convenience version of <code><a href="#scrollForward(int)">scrollForward(int)</a></code>, performs a regular scroll</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#scrollIntoView(com.android.uiautomator.core.UiObject)">scrollIntoView</a></span>(<a href="UiObject.html">UiObject</a> obj)</nobr>
+
+ <div class="jd-descrdiv">Perform a forward scroll action to move through the scrollable layout element until
+ a visible item that matches the <code><a href="UiObject.html">UiObject</a></code> is found.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#scrollForward(int)">scrollForward</a></span>(int steps)
-
- <div class="jd-descrdiv">Perform a scroll forward.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#scrollTextIntoView(java.lang.String)">scrollTextIntoView</a></span>(String text)</nobr>
+
+ <div class="jd-descrdiv">Performs a forward scroll action on the scrollable layout element until
+ the text you provided is visible, or until swipe attempts have been exhausted.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#scrollIntoView(com.android.uiautomator.core.UiSelector)">scrollIntoView</a></span>(<a href="UiSelector.html">UiSelector</a> selector)
-
- <div class="jd-descrdiv">Perform a scroll search for a UI element matching the <code><a href="UiSelector.html">UiSelector</a></code> selector argument.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#scrollToBeginning(int)">scrollToBeginning</a></span>(int maxSwipes)</nobr>
+
+ <div class="jd-descrdiv">Scrolls to the beginning of a scrollable layout element.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#scrollTextIntoView(java.lang.String)">scrollTextIntoView</a></span>(String text)
-
- <div class="jd-descrdiv">Performs a swipe up on the UI element until the requested text is visible
- or until swipe attempts have been exhausted.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#scrollToBeginning(int, int)">scrollToBeginning</a></span>(int maxSwipes, int steps)</nobr>
+
+ <div class="jd-descrdiv">Scrolls to the beginning of a scrollable layout element.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#scrollToBeginning(int)">scrollToBeginning</a></span>(int maxSwipes)
-
- <div class="jd-descrdiv">See <code><a href="#scrollToBeginning(int, int)">scrollToBeginning(int, int)</a></code></div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#scrollToEnd(int, int)">scrollToEnd</a></span>(int maxSwipes, int steps)</nobr>
+
+ <div class="jd-descrdiv">Scrolls to the end of a scrollable layout element.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#scrollToBeginning(int, int)">scrollToBeginning</a></span>(int maxSwipes, int steps)
-
- <div class="jd-descrdiv">Scrolls to the beginning of a scrollable UI element.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#scrollToEnd(int)">scrollToEnd</a></span>(int maxSwipes)</nobr>
+
+ <div class="jd-descrdiv">Scrolls to the end of a scrollable layout element.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiScrollable</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#scrollToEnd(int, int)">scrollToEnd</a></span>(int maxSwipes, int steps)
-
- <div class="jd-descrdiv">Scrolls to the end of a scrollable UI element.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#setAsHorizontalList()">setAsHorizontalList</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Set the direction of swipes to be horizontal when performing scroll actions.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiScrollable</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#scrollToEnd(int)">scrollToEnd</a></span>(int maxSwipes)
-
- <div class="jd-descrdiv">See {@link UiScrollable#scrollToEnd(int, int)</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#setAsVerticalList()">setAsVerticalList</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Set the direction of swipes to be vertical when performing scroll actions.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- void
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiScrollable</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#setAsHorizontalList()">setAsHorizontalList</a></span>()
-
- <div class="jd-descrdiv">Set the direction of swipes when performing scroll search
-</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#setMaxSearchSwipes(int)">setMaxSearchSwipes</a></span>(int swipes)</nobr>
+
+ <div class="jd-descrdiv">Sets the maximum number of scrolls allowed when performing a
+ scroll action in search of a child element.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- void
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiScrollable</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#setAsVerticalList()">setAsVerticalList</a></span>()
-
- <div class="jd-descrdiv">Set the direction of swipes when performing scroll search
-</div>
-
- </td></tr>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#setSwipeDeadZonePercentage(double)">setSwipeDeadZonePercentage</a></span>(double swipeDeadZonePercentage)</nobr>
+ <div class="jd-descrdiv">Sets the percentage of a widget's size that's considered as no-touch
+ zone when swiping.</div>
-
- <tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- void
- </td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#setMaxSearchSwipes(int)">setMaxSearchSwipes</a></span>(int swipes)
-
- <div class="jd-descrdiv">#getChildByDescription(String, boolean) and #getChildByText(String, boolean)
- use an arguments that specifies if scrolling is allowed while searching for the UI element.</div>
-
- </td></tr>
-
-
-
- <tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- void
- </td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#setSwipeDeadZonePercentage(double)">setSwipeDeadZonePercentage</a></span>(double swipeDeadZonePercentage)
-
- <div class="jd-descrdiv">Sets the percentage of a widget's size that's considered as a no touch zone when swiping.</div>
-
</td></tr>
@@ -576,6 +655,34 @@
+<!-- ========== METHOD SUMMARY =========== -->
+<table id="promethods" class="jd-sumtable"><tr><th colspan="12">Protected Methods</th></tr>
+
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#exists(com.android.uiautomator.core.UiSelector)">exists</a></span>(<a href="UiSelector.html">UiSelector</a> selector)</nobr>
+
+ <div class="jd-descrdiv">Used privately when performing swipe searches to decide if an element has become
+ visible or not.</div>
+
+ </td></tr>
+
+
+
+</table>
+
+
@@ -585,7 +692,7 @@
<div style="clear:left;">Inherited Methods</div></th></tr>
-<tr class="api apilevel-" >
+<tr class="api" >
<td colspan="12">
<a href="#" onclick="return toggleInherited(this, null)" id="inherited-methods-com.android.uiautomator.core.UiCollection" class="jd-expando-trigger closed"
><img id="inherited-methods-com.android.uiautomator.core.UiCollection-trigger"
@@ -601,82 +708,82 @@
</div>
<div id="inherited-methods-com.android.uiautomator.core.UiCollection-summary" style="display: none;">
<table class="jd-sumtable-expando">
-
-
+
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiObject.html">UiObject</a>
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="UiObject.html">UiObject</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiCollection.html#getChildByDescription(com.android.uiautomator.core.UiSelector, java.lang.String)">getChildByDescription</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern, String text)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiCollection.html#getChildByDescription(com.android.uiautomator.core.UiSelector, java.lang.String)">getChildByDescription</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern, String text)</nobr>
+
<div class="jd-descrdiv">Searches for child UI element within the constraints of this UiCollection <code><a href="UiSelector.html">UiSelector</a></code>
selector.</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiObject.html">UiObject</a>
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="UiObject.html">UiObject</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiCollection.html#getChildByInstance(com.android.uiautomator.core.UiSelector, int)">getChildByInstance</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern, int instance)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiCollection.html#getChildByInstance(com.android.uiautomator.core.UiSelector, int)">getChildByInstance</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern, int instance)</nobr>
+
<div class="jd-descrdiv">Searches for child UI element within the constraints of this UiCollection <code><a href="UiSelector.html">UiSelector</a></code>
selector.</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiObject.html">UiObject</a>
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="UiObject.html">UiObject</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiCollection.html#getChildByText(com.android.uiautomator.core.UiSelector, java.lang.String)">getChildByText</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern, String text)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiCollection.html#getChildByText(com.android.uiautomator.core.UiSelector, java.lang.String)">getChildByText</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern, String text)</nobr>
+
<div class="jd-descrdiv">Searches for child UI element within the constraints of this UiCollection <code><a href="UiSelector.html">UiSelector</a></code>
selector.</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- int
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ int</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiCollection.html#getChildCount(com.android.uiautomator.core.UiSelector)">getChildCount</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiCollection.html#getChildCount(com.android.uiautomator.core.UiSelector)">getChildCount</a></span>(<a href="UiSelector.html">UiSelector</a> childPattern)</nobr>
+
<div class="jd-descrdiv">Counts child UI element instances matching the <code>childPattern</code>
argument.</div>
-
+
</td></tr>
@@ -687,7 +794,7 @@
-<tr class="api apilevel-" >
+<tr class="api" >
<td colspan="12">
<a href="#" onclick="return toggleInherited(this, null)" id="inherited-methods-com.android.uiautomator.core.UiObject" class="jd-expando-trigger closed"
><img id="inherited-methods-com.android.uiautomator.core.UiObject-trigger"
@@ -703,645 +810,788 @@
</div>
<div id="inherited-methods-com.android.uiautomator.core.UiObject-summary" style="display: none;">
<table class="jd-sumtable-expando">
-
-
+
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- void
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#clearTextField()">clearTextField</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#clearTextField()">clearTextField</a></span>()</nobr>
+
<div class="jd-descrdiv">Clears the existing text contents in an editable field.</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#click()">click</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#click()">click</a></span>()</nobr>
+
<div class="jd-descrdiv">Performs a click at the center of the visible bounds of the UI element represented
by this UiObject.</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#clickAndWaitForNewWindow(long)">clickAndWaitForNewWindow</a></span>(long timeout)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#clickAndWaitForNewWindow(long)">clickAndWaitForNewWindow</a></span>(long timeout)</nobr>
+
<div class="jd-descrdiv">Performs a click at the center of the visible bounds of the UI element represented
by this UiObject and waits for window transitions.</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#clickAndWaitForNewWindow()">clickAndWaitForNewWindow</a></span>()
-
- <div class="jd-descrdiv">See <code><a href="UiObject.html#clickAndWaitForNewWindow(long)">clickAndWaitForNewWindow(long)</a></code>
- This method is intended to reliably wait for window transitions that would typically take
- longer than the usual default timeouts.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#clickAndWaitForNewWindow()">clickAndWaitForNewWindow</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Waits for window transitions that would typically take longer than the
+ usual default timeouts.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#clickBottomRight()">clickBottomRight</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#clickBottomRight()">clickBottomRight</a></span>()</nobr>
+
<div class="jd-descrdiv">Clicks the bottom and right corner of the UI element</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#clickTopLeft()">clickTopLeft</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#clickTopLeft()">clickTopLeft</a></span>()</nobr>
+
<div class="jd-descrdiv">Clicks the top and left corner of the UI element</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#exists()">exists</a></span>()
-
- <div class="jd-descrdiv">Check if UI element exists.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#dragTo(com.android.uiautomator.core.UiObject, int)">dragTo</a></span>(<a href="UiObject.html">UiObject</a> destObj, int steps)</nobr>
+
+ <div class="jd-descrdiv">Drags this object to a destination UiObject.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- Rect
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#getBounds()">getBounds</a></span>()
-
- <div class="jd-descrdiv">Returns the UI element's <code>bounds</code> property.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#dragTo(int, int, int)">dragTo</a></span>(int destX, int destY, int steps)</nobr>
+
+ <div class="jd-descrdiv">Drags this object to arbitrary coordinates.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiObject.html">UiObject</a>
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#getChild(com.android.uiautomator.core.UiSelector)">getChild</a></span>(<a href="UiSelector.html">UiSelector</a> selector)
-
- <div class="jd-descrdiv">Creates a new UiObject representing a child UI element of the element currently represented
- by this UiObject.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#exists()">exists</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Check if view exists.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- int
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ AccessibilityNodeInfo</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#getChildCount()">getChildCount</a></span>()
-
- <div class="jd-descrdiv">Counts the child UI elements immediately under the UI element currently represented by
- this UiObject.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#findAccessibilityNodeInfo(long)">findAccessibilityNodeInfo</a></span>(long timeout)</nobr>
+
+ <div class="jd-descrdiv">Finds a matching UI element in the accessibility hierarchy, by
+ using the selector for this UiObject.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- String
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ Rect</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#getContentDescription()">getContentDescription</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#getBounds()">getBounds</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Returns the view's <code>bounds</code> property.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="UiObject.html">UiObject</a></nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#getChild(com.android.uiautomator.core.UiSelector)">getChild</a></span>(<a href="UiSelector.html">UiSelector</a> selector)</nobr>
+
+ <div class="jd-descrdiv">Creates a new UiObject for a child view that is under the present UiObject.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ int</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#getChildCount()">getChildCount</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Counts the child views immediately under the present UiObject.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#getClassName()">getClassName</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Retrieves the <code>className</code> property of the UI element.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#getContentDescription()">getContentDescription</a></span>()</nobr>
+
<div class="jd-descrdiv">Reads the <code>content_desc</code> property of the UI element</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiObject.html">UiObject</a>
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="UiObject.html">UiObject</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#getFromParent(com.android.uiautomator.core.UiSelector)">getFromParent</a></span>(<a href="UiSelector.html">UiSelector</a> selector)
-
- <div class="jd-descrdiv">Creates a new UiObject representing a child UI element from the parent element currently
- represented by this object.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#getFromParent(com.android.uiautomator.core.UiSelector)">getFromParent</a></span>(<a href="UiSelector.html">UiSelector</a> selector)</nobr>
+
+ <div class="jd-descrdiv">Creates a new UiObject for a sibling view or a child of the sibling view,
+ relative to the present UiObject.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- String
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#getPackageName()">getPackageName</a></span>()
-
- <div class="jd-descrdiv">Reads the UI element's <code>package</code> property</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#getPackageName()">getPackageName</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Reads the view's <code>package</code> property</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+
+ <a href="UiSelector.html">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#getSelector()">getSelector</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#getSelector()">getSelector</a></span>()</nobr>
+
<div class="jd-descrdiv">Debugging helper.</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- String
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#getText()">getText</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#getText()">getText</a></span>()</nobr>
+
<div class="jd-descrdiv">Reads the <code>text</code> property of the UI element</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- Rect
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ Rect</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#getVisibleBounds()">getVisibleBounds</a></span>()
-
- <div class="jd-descrdiv">Returns the visible bounds of the UI element.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#getVisibleBounds()">getVisibleBounds</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Returns the visible bounds of the view.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#isCheckable()">isCheckable</a></span>()
-
- <div class="jd-descrdiv">Check if the UI element's <code>checkable</code> property is currently true</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#isCheckable()">isCheckable</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Checks if the UI element's <code>checkable</code> property is currently true.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#isChecked()">isChecked</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#isChecked()">isChecked</a></span>()</nobr>
+
<div class="jd-descrdiv">Check if the UI element's <code>checked</code> property is currently true</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#isClickable()">isClickable</a></span>()
-
- <div class="jd-descrdiv">Check if the UI element's <code>clickable</code> property is currently true</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#isClickable()">isClickable</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Checks if the UI element's <code>clickable</code> property is currently true.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#isEnabled()">isEnabled</a></span>()
-
- <div class="jd-descrdiv">Check if the UI element's <code>enabled</code> property is currently true</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#isEnabled()">isEnabled</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Checks if the UI element's <code>enabled</code> property is currently true.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#isFocusable()">isFocusable</a></span>()
-
- <div class="jd-descrdiv">Check if the UI element's <code>focusable</code> property is currently true</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#isFocusable()">isFocusable</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Check if the UI element's <code>focusable</code> property is currently true.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#isFocused()">isFocused</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#isFocused()">isFocused</a></span>()</nobr>
+
<div class="jd-descrdiv">Check if the UI element's <code>focused</code> property is currently true</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#isLongClickable()">isLongClickable</a></span>()
-
- <div class="jd-descrdiv">Check if the UI element's <code>long-clickable</code> property is currently true</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#isLongClickable()">isLongClickable</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Check if the view's <code>long-clickable</code> property is currently true</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#isScrollable()">isScrollable</a></span>()
-
- <div class="jd-descrdiv">Check if the UI element's <code>scrollable</code> property is currently true</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#isScrollable()">isScrollable</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Check if the view's <code>scrollable</code> property is currently true</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#isSelected()">isSelected</a></span>()
-
- <div class="jd-descrdiv">Check if the UI element's <code>selected</code> property is currently true</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#isSelected()">isSelected</a></span>()</nobr>
+
+ <div class="jd-descrdiv">Checks if the UI element's <code>selected</code> property is currently true.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#longClick()">longClick</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#longClick()">longClick</a></span>()</nobr>
+
<div class="jd-descrdiv">Long clicks the center of the visible bounds of the UI element</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#longClickBottomRight()">longClickBottomRight</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#longClickBottomRight()">longClickBottomRight</a></span>()</nobr>
+
<div class="jd-descrdiv">Long clicks bottom and right corner of the UI element</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#longClickTopLeft()">longClickTopLeft</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#longClickTopLeft()">longClickTopLeft</a></span>()</nobr>
+
<div class="jd-descrdiv">Long clicks on the top and left corner of the UI element</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#setText(java.lang.String)">setText</a></span>(String text)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#performMultiPointerGesture(android.view.MotionEvent.PointerCoords[]...)">performMultiPointerGesture</a></span>(PointerCoords... touches)</nobr>
+
+ <div class="jd-descrdiv">Performs a multi-touch gesture.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#performTwoPointerGesture(android.graphics.Point, android.graphics.Point, android.graphics.Point, android.graphics.Point, int)">performTwoPointerGesture</a></span>(Point startPoint1, Point startPoint2, Point endPoint1, Point endPoint2, int steps)</nobr>
+
+ <div class="jd-descrdiv">Generates a two-pointer gesture with arbitrary starting and ending points.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#pinchIn(int, int)">pinchIn</a></span>(int percent, int steps)</nobr>
+
+ <div class="jd-descrdiv">Performs a two-pointer gesture, where each pointer moves diagonally
+ toward the other, from the edges to the center of this UiObject .</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#pinchOut(int, int)">pinchOut</a></span>(int percent, int steps)</nobr>
+
+ <div class="jd-descrdiv">Performs a two-pointer gesture, where each pointer moves diagonally
+ opposite across the other, from the center out towards the edges of the
+ this UiObject.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#setText(java.lang.String)">setText</a></span>(String text)</nobr>
+
<div class="jd-descrdiv">Sets the text in an editable field, after clearing the field's content.</div>
-
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#swipeDown(int)">swipeDown</a></span>(int steps)
-
- <div class="jd-descrdiv">Perform the action on the UI element that is represented by this object, Also see
- #scrollToBeginning(int), #scrollToEnd(int), #scrollBackward(),
- #scrollForward().</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#swipeDown(int)">swipeDown</a></span>(int steps)</nobr>
+
+ <div class="jd-descrdiv">Performs the swipe down action on the UiObject.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#swipeLeft(int)">swipeLeft</a></span>(int steps)
-
- <div class="jd-descrdiv">Perform the action on the UI element that is represented by this object.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#swipeLeft(int)">swipeLeft</a></span>(int steps)</nobr>
+
+ <div class="jd-descrdiv">Performs the swipe left action on the UiObject.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#swipeRight(int)">swipeRight</a></span>(int steps)
-
- <div class="jd-descrdiv">Perform the action on the UI element that is represented by this object.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#swipeRight(int)">swipeRight</a></span>(int steps)</nobr>
+
+ <div class="jd-descrdiv">Performs the swipe right action on the UiObject.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#swipeUp(int)">swipeUp</a></span>(int steps)
-
- <div class="jd-descrdiv">Perform the action on the UI element that is represented by this UiObject.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#swipeUp(int)">swipeUp</a></span>(int steps)</nobr>
+
+ <div class="jd-descrdiv">Performs the swipe up action on the UiObject.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#waitForExists(long)">waitForExists</a></span>(long timeout)
-
- <div class="jd-descrdiv">Waits a specified length of time for a UI element to become visible.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#waitForExists(long)">waitForExists</a></span>(long timeout)</nobr>
+
+ <div class="jd-descrdiv">Waits a specified length of time for a view to become visible.</div>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="UiObject.html#waitUntilGone(long)">waitUntilGone</a></span>(long timeout)
-
- <div class="jd-descrdiv">Waits a specified length of time for a UI element to become undetectable.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="UiObject.html#waitUntilGone(long)">waitUntilGone</a></span>(long timeout)</nobr>
+
+ <div class="jd-descrdiv">Waits a specified length of time for a view to become undetectable.</div>
+
</td></tr>
@@ -1352,7 +1602,7 @@
-<tr class="api apilevel-" >
+<tr class="api" >
<td colspan="12">
<a href="#" onclick="return toggleInherited(this, null)" id="inherited-methods-java.lang.Object" class="jd-expando-trigger closed"
><img id="inherited-methods-java.lang.Object-trigger"
@@ -1368,150 +1618,182 @@
</div>
<div id="inherited-methods-java.lang.Object-summary" style="display: none;">
<table class="jd-sumtable-expando">
-
-
+
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ Object</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">equals</span>(Object arg0)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">clone</span>()</nobr>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">equals</span>(Object arg0)</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">finalize</span>()</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- Class<?>
+
+
+ Class<?></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">getClass</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">getClass</span>()</nobr>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- int
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ int</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">hashCode</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">hashCode</span>()</nobr>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">notify</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">notify</span>()</nobr>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">notifyAll</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">notifyAll</span>()</nobr>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
-
-
-
- String
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">toString</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">toString</span>()</nobr>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">wait</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">wait</span>()</nobr>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">wait</span>(long arg0, int arg1)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">wait</span>(long arg0, int arg1)</nobr>
+
</td></tr>
-
+
<tr class="api" >
- <td class="jd-typecol">
-
-
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">wait</span>(long arg0)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">wait</span>(long arg0)</nobr>
+
</td></tr>
@@ -1555,41 +1837,37 @@
-<a id="UiScrollable(com.android.uiautomator.core.UiSelector)"></a>
+<A NAME="UiScrollable(com.android.uiautomator.core.UiSelector)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
-
+ public
+
+
+
+
+
</span>
<span class="sympad">UiScrollable</span>
<span class="normal">(<a href="UiSelector.html">UiSelector</a> container)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>UiScrollable is a <code><a href="UiCollection.html">UiCollection</a></code> and as such requires a <code><a href="UiSelector.html">UiSelector</a></code> to
- identify the container UI element of the scrollable collection. Further operations on
- the items in the container will require specifying UiSelector as an item selector.</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Constructor.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>container</th>
- <td>a <code><a href="UiSelector.html">UiSelector</a></code> selector
-</td>
+ <th>container</td>
+ <td>a <code><a href="UiSelector.html">UiSelector</a></code> selector to identify the scrollable
+ layout element.</td>
</tr>
</table>
</div>
@@ -1613,40 +1891,42 @@
-<a id="flingBackward()"></a>
+<A NAME="flingBackward()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">flingBackward</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>See <code><a href="#scrollBackward(int)">scrollBackward(int)</a></code></p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs a backwards fling action with the default number of fling
+ steps (5). If the swipe direction is set to vertical,
+ then the swipe will be performed from top to bottom. If the swipe
+ direction is set to horizontal, then the swipes will be performed from
+ left to right. Make sure to take into account devices configured with
+ right-to-left languages like Arabic and Hebrew.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true if scrolled and false if the control can't scroll anymore
-</li></ul>
+ <ul class="nolist"><li>true if scrolled, and false if can't scroll anymore</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1658,40 +1938,42 @@
</div>
-<a id="flingForward()"></a>
+<A NAME="flingForward()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">flingForward</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>A convenience version of <code><a href="#scrollForward(int)">scrollForward(int)</a></code>, performs a fling</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs a forward fling with the default number of fling steps (5).
+ If the swipe direction is set to vertical, then the swipes will be
+ performed from bottom to top. If the swipe
+ direction is set to horizontal, then the swipes will be performed from
+ right to left. Make sure to take into account devices configured with
+ right-to-left languages like Arabic and Hebrew.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true if scrolled and false if the control can't scroll anymore
-</li></ul>
+ <ul class="nolist"><li>true if scrolled, false if can't scroll anymore</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1703,40 +1985,40 @@
</div>
-<a id="flingToBeginning(int)"></a>
+<A NAME="flingToBeginning(int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">flingToBeginning</span>
<span class="normal">(int maxSwipes)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>See <code><a href="#scrollToBeginning(int, int)">scrollToBeginning(int, int)</a></code></p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs a fling gesture to reach the beginning of a scrollable layout element.
+ The beginning can be at the top-most edge in the case of vertical controls, or
+ the left-most edge for horizontal controls. Make sure to take into
+ account devices configured with right-to-left languages like Arabic and Hebrew.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true on scrolled else false
-</li></ul>
+ <ul class="nolist"><li>true on scrolled else false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1748,40 +2030,40 @@
</div>
-<a id="flingToEnd(int)"></a>
+<A NAME="flingToEnd(int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">flingToEnd</span>
<span class="normal">(int maxSwipes)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>See <code><a href="#scrollToEnd(int, int)">scrollToEnd(int, int)</a></code></p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs a fling gesture to reach the end of a scrollable layout element.
+ The end can be at the bottom-most edge in the case of vertical controls, or
+ the right-most edge for horizontal controls. Make sure to take into
+ account devices configured with right-to-left languages like Arabic and Hebrew.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true on scrolled else false
-</li></ul>
+ <ul class="nolist"><li>true on scrolled, else false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1793,56 +2075,61 @@
</div>
-<a id="getChildByDescription(com.android.uiautomator.core.UiSelector, java.lang.String, boolean)"></a>
+<A NAME="getChildByDescription(com.android.uiautomator.core.UiSelector, java.lang.String, boolean)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
<a href="UiObject.html">UiObject</a>
</span>
<span class="sympad">getChildByDescription</span>
<span class="normal">(<a href="UiSelector.html">UiSelector</a> childPattern, String text, boolean allowScrollSearch)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>See <code><a href="#getChildByDescription(com.android.uiautomator.core.UiSelector, java.lang.String)">getChildByDescription(UiSelector, String)</a></code></p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Searches for a child element in the present scrollable container.
+ The search first looks for a child element that matches the selector
+ you provided, then looks for the content-description in its children elements.
+ If both search conditions are fulfilled, the method returns a {@ link UiObject}
+ representing the element matching the selector (not the child element in its
+ subhierarchy containing the content-description).</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>childPattern</th>
- <td><code><a href="UiSelector.html">UiSelector</a></code> selector of the child pattern to match and return</td>
+ <th>childPattern</td>
+ <td><code><a href="UiSelector.html">UiSelector</a></code> for a child in a scollable layout element</td>
</tr>
<tr>
- <th>text</th>
- <td>String may be a partial match for the content-description of a child element.</td>
+ <th>text</td>
+ <td>Content-description to find in the children of
+ the <code>childPattern</code> match (may be a partial match)</td>
</tr>
<tr>
- <th>allowScrollSearch</th>
+ <th>allowScrollSearch</td>
<td>set to true if scrolling is allowed</td>
</tr>
</table>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li><code><a href="UiObject.html">UiObject</a></code> pointing at and instance of <code>childPattern</code></li></ul>
+ <ul class="nolist"><li><code><a href="UiObject.html">UiObject</a></code> representing the child element that matches the search conditions</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1854,58 +2141,58 @@
</div>
-<a id="getChildByDescription(com.android.uiautomator.core.UiSelector, java.lang.String)"></a>
+<A NAME="getChildByDescription(com.android.uiautomator.core.UiSelector, java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
<a href="UiObject.html">UiObject</a>
</span>
<span class="sympad">getChildByDescription</span>
<span class="normal">(<a href="UiSelector.html">UiSelector</a> childPattern, String text)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Searches for child UI element within the constraints of this UiScrollable <code><a href="UiSelector.html">UiSelector</a></code>
- container. It looks for any child matching the <code>childPattern</code> argument within its
- hierarchy with a matching content-description text. The returned UiObject will represent the
- UI element matching the <code>childPattern</code> and not the sub element that matched the
- content description.</p>
- By default this operation will perform scroll search while attempting to find the UI element
+
+ <div class="jd-tagdata jd-tagdescr"><p>Searches for a child element in the present scrollable container.
+ The search first looks for a child element that matches the selector
+ you provided, then looks for the content-description in its children elements.
+ If both search conditions are fulfilled, the method returns a {@ link UiObject}
+ representing the element matching the selector (not the child element in its
+ subhierarchy containing the content-description). By default, this method performs a
+ scroll search.
See <code><a href="#getChildByDescription(com.android.uiautomator.core.UiSelector, java.lang.String, boolean)">getChildByDescription(UiSelector, String, boolean)</a></code></p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>childPattern</th>
- <td><code><a href="UiSelector.html">UiSelector</a></code> selector of the child pattern to match and return</td>
+ <th>childPattern</td>
+ <td><code><a href="UiSelector.html">UiSelector</a></code> for a child in a scollable layout element</td>
</tr>
<tr>
- <th>text</th>
- <td>String of the identifying child contents of of the <code>childPattern</code></td>
+ <th>text</td>
+ <td>Content-description to find in the children of
+ the <code>childPattern</code> match</td>
</tr>
</table>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li><code><a href="UiObject.html">UiObject</a></code> pointing at and instance of <code>childPattern</code></li></ul>
+ <ul class="nolist"><li><code><a href="UiObject.html">UiObject</a></code> representing the child element that matches the search conditions</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1917,56 +2204,53 @@
</div>
-<a id="getChildByInstance(com.android.uiautomator.core.UiSelector, int)"></a>
+<A NAME="getChildByInstance(com.android.uiautomator.core.UiSelector, int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
<a href="UiObject.html">UiObject</a>
</span>
<span class="sympad">getChildByInstance</span>
<span class="normal">(<a href="UiSelector.html">UiSelector</a> childPattern, int instance)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Searches for child UI element within the constraints of this UiScrollable <code><a href="UiSelector.html">UiSelector</a></code>
- selector. It looks for any child matching the <code>childPattern</code> argument and
- return the <code>instance</code> specified. The operation is performed only on the visible
- items and no scrolling is performed in this case.</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Searches for a child element in the present scrollable container that
+ matches the selector you provided. The search is performed without
+ scrolling and only on visible elements.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>childPattern</th>
- <td><code><a href="UiSelector.html">UiSelector</a></code> selector of the child pattern to match and return</td>
+ <th>childPattern</td>
+ <td><code><a href="UiSelector.html">UiSelector</a></code> for a child in a scollable layout element</td>
</tr>
<tr>
- <th>instance</th>
- <td>int the desired matched instance of this <code>childPattern</code></td>
+ <th>instance</td>
+ <td>int number representing the occurance of
+ a <code>childPattern</code> match</td>
</tr>
</table>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li><code><a href="UiObject.html">UiObject</a></code> pointing at and instance of <code>childPattern</code>
-</li></ul>
+ <ul class="nolist"><li><code><a href="UiObject.html">UiObject</a></code> representing the child element that matches the search conditions</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -1978,56 +2262,59 @@
</div>
-<a id="getChildByText(com.android.uiautomator.core.UiSelector, java.lang.String, boolean)"></a>
+<A NAME="getChildByText(com.android.uiautomator.core.UiSelector, java.lang.String, boolean)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
<a href="UiObject.html">UiObject</a>
</span>
<span class="sympad">getChildByText</span>
<span class="normal">(<a href="UiSelector.html">UiSelector</a> childPattern, String text, boolean allowScrollSearch)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>See <code><a href="#getChildByText(com.android.uiautomator.core.UiSelector, java.lang.String)">getChildByText(UiSelector, String)</a></code></p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Searches for a child element in the present scrollable container. The
+ search first looks for a child element that matches the
+ selector you provided, then looks for the text in its children elements.
+ If both search conditions are fulfilled, the method returns a {@ link UiObject}
+ representing the element matching the selector (not the child element in its
+ subhierarchy containing the text).</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>childPattern</th>
- <td><code><a href="UiSelector.html">UiSelector</a></code> selector of the child pattern to match and return</td>
+ <th>childPattern</td>
+ <td><code><a href="UiSelector.html">UiSelector</a></code> selector for a child in a scrollable layout element</td>
</tr>
<tr>
- <th>text</th>
- <td>String of the identifying child contents of of the <code>childPattern</code></td>
+ <th>text</td>
+ <td>String to find in the children of the <code>childPattern</code> match</td>
</tr>
<tr>
- <th>allowScrollSearch</th>
+ <th>allowScrollSearch</td>
<td>set to true if scrolling is allowed</td>
</tr>
</table>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li><code><a href="UiObject.html">UiObject</a></code> pointing at and instance of <code>childPattern</code></li></ul>
+ <ul class="nolist"><li><code><a href="UiObject.html">UiObject</a></code> representing the child element that matches the search conditions</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2039,59 +2326,58 @@
</div>
-<a id="getChildByText(com.android.uiautomator.core.UiSelector, java.lang.String)"></a>
+<A NAME="getChildByText(com.android.uiautomator.core.UiSelector, java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
<a href="UiObject.html">UiObject</a>
</span>
<span class="sympad">getChildByText</span>
<span class="normal">(<a href="UiSelector.html">UiSelector</a> childPattern, String text)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Searches for child UI element within the constraints of this UiScrollable <code><a href="UiSelector.html">UiSelector</a></code>
- container. It looks for any child matching the <code>childPattern</code> argument that has
- a sub UI element anywhere within its sub hierarchy that has text attribute
- <code>text</code>. The returned UiObject will point at the <code>childPattern</code>
- instance that matched the search and not at the text matched sub element</p>
- By default this operation will perform scroll search while attempting to find the UI
- element.
+
+ <div class="jd-tagdata jd-tagdescr"><p>Searches for a child element in the present scrollable
+ container. The search first looks for a child element that matches the
+ selector you provided, then looks for the text in its children elements.
+ If both search conditions are fulfilled, the method returns a {@ link UiObject}
+ representing the element matching the selector (not the child element in its
+ subhierarchy containing the text). By default, this method performs a
+ scroll search.
See <code><a href="#getChildByText(com.android.uiautomator.core.UiSelector, java.lang.String, boolean)">getChildByText(UiSelector, String, boolean)</a></code></p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>childPattern</th>
- <td><code><a href="UiSelector.html">UiSelector</a></code> selector of the child pattern to match and return</td>
+ <th>childPattern</td>
+ <td><code><a href="UiSelector.html">UiSelector</a></code> selector for a child in a scrollable layout element</td>
</tr>
<tr>
- <th>text</th>
- <td>String of the identifying child contents of of the <code>childPattern</code></td>
+ <th>text</td>
+ <td>String to find in the children of the <code>childPattern</code> match</td>
</tr>
</table>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li><code><a href="UiObject.html">UiObject</a></code> pointing at and instance of <code>childPattern</code></li></ul>
+ <ul class="nolist"><li><code><a href="UiObject.html">UiObject</a></code> representing the child element that matches the search conditions</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
+
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2103,135 +2389,124 @@
</div>
-<a id="getMaxSearchSwipes()"></a>
+<A NAME="getMaxSearchSwipes()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
int
</span>
<span class="sympad">getMaxSearchSwipes</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>#getChildByDescription(String, boolean) and #getChildByText(String, boolean)
- use an arguments that specifies if scrolling is allowed while searching for the UI element.
- The number of scrolls currently allowed to perform a search can be read by this method.
- See <code><a href="#setMaxSearchSwipes(int)">setMaxSearchSwipes(int)</a></code></p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Gets the maximum number of scrolls allowed when performing a
+ scroll action in search of a child element.
+ See <code><a href="#getChildByDescription(com.android.uiautomator.core.UiSelector, java.lang.String)">getChildByDescription(UiSelector, String)</a></code> and
+ <code><a href="#getChildByText(com.android.uiautomator.core.UiSelector, java.lang.String)">getChildByText(UiSelector, String)</a></code>.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>max value of the number of swipes currently allowed during a scroll search
-</li></ul>
+ <ul class="nolist"><li>max the number of search swipes to perform until giving up</li></ul>
</div>
</div>
</div>
-<a id="getSwipeDeadZonePercentage()"></a>
+<A NAME="getSwipeDeadZonePercentage()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
double
</span>
<span class="sympad">getSwipeDeadZonePercentage</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Returns the percentage of a widget's size that's considered as a no touch zone when swiping.
- Dead zones are set as percentage of a widget's total width or height, denoting a margin
- around the swipable area of the widget. Swipes must start and
- end inside this margin.
-
- This is important when the widget being swiped may not respond to the swipe if
- started at a point too near to the edge. The default is 10% from either edge.</p></div>
+ <div class="jd-tagdata jd-tagdescr"><p>Returns the percentage of a widget's size that's considered as a no-touch
+ zone when swiping. The no-touch zone is set as a percentage of a widget's total
+ width or height, denoting a margin around the swipable area of the widget.
+ Swipes must start and end inside this margin. This is important when the
+ widget being swiped may not respond to the swipe if started at a point
+ too near to the edge. The default is 10% from either edge.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>a value between 0 and 1
-</li></ul>
+ <ul class="nolist"><li>a value between 0 and 1</li></ul>
</div>
</div>
</div>
-<a id="scrollBackward(int)"></a>
+<A NAME="scrollBackward(int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">scrollBackward</span>
<span class="normal">(int steps)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Perform a scroll backward. If this list is set to vertical (see <code><a href="#setAsVerticalList()">setAsVerticalList()</a></code>
- default) then the swipes will be executed from the top to bottom. If this list is set
- to horizontal (see <code><a href="#setAsHorizontalList()">setAsHorizontalList()</a></code>) then the swipes will be executed from
- the left to right. Caution is required on devices configured with right to left languages
- like Arabic and Hebrew.</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs a backward scroll. If the swipe direction is set to vertical,
+ then the swipes will be performed from top to bottom. If the swipe
+ direction is set to horizontal, then the swipes will be performed from
+ left to right. Make sure to take into account devices configured with
+ right-to-left languages like Arabic and Hebrew.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>steps</th>
- <td>use steps to control the speed, so that it may be a scroll, or fling</td>
+ <th>steps</td>
+ <td>number of steps. Use this to control the speed of the scroll action.</td>
</tr>
</table>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true if scrolled and false if the control can't scroll anymore
-</li></ul>
+ <ul class="nolist"><li>true if scrolled, false if can't scroll anymore</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2243,40 +2518,42 @@
</div>
-<a id="scrollBackward()"></a>
+<A NAME="scrollBackward()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">scrollBackward</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>See <code><a href="#scrollBackward(int)">scrollBackward(int)</a></code></p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs a backward scroll with the default number of scroll steps (55).
+ If the swipe direction is set to vertical,
+ then the swipes will be performed from top to bottom. If the swipe
+ direction is set to horizontal, then the swipes will be performed from
+ left to right. Make sure to take into account devices configured with
+ right-to-left languages like Arabic and Hebrew.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true if scrolled and false if the control can't scroll anymore
-</li></ul>
+ <ul class="nolist"><li>true if scrolled, and false if can't scroll anymore</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2288,50 +2565,48 @@
</div>
-<a id="scrollDescriptionIntoView(java.lang.String)"></a>
+<A NAME="scrollDescriptionIntoView(java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">scrollDescriptionIntoView</span>
<span class="normal">(String text)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Performs a swipe Up on the UI element until the requested content-description
- is visible or until swipe attempts have been exhausted. See <code><a href="#setMaxSearchSwipes(int)">setMaxSearchSwipes(int)</a></code></p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs a forward scroll action on the scrollable layout element until
+ the content-description is found, or until swipe attempts have been exhausted.
+ See <code><a href="#setMaxSearchSwipes(int)">setMaxSearchSwipes(int)</a></code></p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>text</th>
- <td>to look for anywhere within the contents of this scrollable.</td>
+ <th>text</td>
+ <td>content-description to find within the contents of this scrollable layout element.</td>
</tr>
</table>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true if item us found else false
-</li></ul>
+ <ul class="nolist"><li>true if item is found; else, false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2343,40 +2618,42 @@
</div>
-<a id="scrollForward()"></a>
+<A NAME="scrollForward()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">scrollForward</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>A convenience version of <code><a href="#scrollForward(int)">scrollForward(int)</a></code>, performs a regular scroll</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs a forward scroll with the default number of scroll steps (55).
+ If the swipe direction is set to vertical,
+ then the swipes will be performed from bottom to top. If the swipe
+ direction is set to horizontal, then the swipes will be performed from
+ right to left. Make sure to take into account devices configured with
+ right-to-left languages like Arabic and Hebrew.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true if scrolled and false if the control can't scroll anymore
-</li></ul>
+ <ul class="nolist"><li>true if scrolled, false if can't scroll anymore</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2388,53 +2665,50 @@
</div>
-<a id="scrollForward(int)"></a>
+<A NAME="scrollForward(int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">scrollForward</span>
<span class="normal">(int steps)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Perform a scroll forward. If this list is set to vertical (see <code><a href="#setAsVerticalList()">setAsVerticalList()</a></code>
- default) then the swipes will be executed from the bottom to top. If this list is set
- to horizontal (see <code><a href="#setAsHorizontalList()">setAsHorizontalList()</a></code>) then the swipes will be executed from
- the right to left. Caution is required on devices configured with right to left languages
- like Arabic and Hebrew.</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs a forward scroll. If the swipe direction is set to vertical,
+ then the swipes will be performed from bottom to top. If the swipe
+ direction is set to horizontal, then the swipes will be performed from
+ right to left. Make sure to take into account devices configured with
+ right-to-left languages like Arabic and Hebrew.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>steps</th>
- <td>use steps to control the speed, so that it may be a scroll, or fling</td>
+ <th>steps</td>
+ <td>number of steps. Use this to control the speed of the scroll action</td>
</tr>
</table>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true if scrolled and false if the control can't scroll anymore
-</li></ul>
+ <ul class="nolist"><li>true if scrolled, false if can't scroll anymore</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2446,50 +2720,49 @@
</div>
-<a id="scrollIntoView(com.android.uiautomator.core.UiSelector)"></a>
+<A NAME="scrollIntoView(com.android.uiautomator.core.UiSelector)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">scrollIntoView</span>
<span class="normal">(<a href="UiSelector.html">UiSelector</a> selector)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Perform a scroll search for a UI element matching the <code><a href="UiSelector.html">UiSelector</a></code> selector argument.
+
+ <div class="jd-tagdata jd-tagdescr"><p>Perform a scroll forward action to move through the scrollable layout
+ element until a visible item that matches the selector is found.
+
See <code><a href="#scrollDescriptionIntoView(java.lang.String)">scrollDescriptionIntoView(String)</a></code> and <code><a href="#scrollTextIntoView(java.lang.String)">scrollTextIntoView(String)</a></code>.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>selector</th>
+ <th>selector</td>
<td><code><a href="UiSelector.html">UiSelector</a></code> selector</td>
</tr>
</table>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true if the item was found and now is in view else false
-</li></ul>
+ <ul class="nolist"><li>true if the item was found and now is in view; else, false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2501,50 +2774,100 @@
</div>
-<a id="scrollTextIntoView(java.lang.String)"></a>
+<A NAME="scrollIntoView(com.android.uiautomator.core.UiObject)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
+ boolean
+ </span>
+ <span class="sympad">scrollIntoView</span>
+ <span class="normal">(<a href="UiObject.html">UiObject</a> obj)</span>
+ </h4>
+ <div class="api-level">
+ <div></div>
+
+
+
+ </div>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Perform a forward scroll action to move through the scrollable layout element until
+ a visible item that matches the <code><a href="UiObject.html">UiObject</a></code> is found.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>obj</td>
+ <td><code><a href="UiObject.html">UiObject</a></code></td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>true if the item was found and now is in view else false</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Throws</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
+ <td></td>
+ </tr>
+ </table>
+ </div>
+
+ </div>
+</div>
+
+
+<A NAME="scrollTextIntoView(java.lang.String)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
boolean
</span>
<span class="sympad">scrollTextIntoView</span>
<span class="normal">(String text)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Performs a swipe up on the UI element until the requested text is visible
- or until swipe attempts have been exhausted. See <code><a href="#setMaxSearchSwipes(int)">setMaxSearchSwipes(int)</a></code></p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Performs a forward scroll action on the scrollable layout element until
+ the text you provided is visible, or until swipe attempts have been exhausted.
+ See <code><a href="#setMaxSearchSwipes(int)">setMaxSearchSwipes(int)</a></code></p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>text</th>
- <td>to look for</td>
+ <th>text</td>
+ <td>test to look for</td>
</tr>
</table>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true if item us found else false
-</li></ul>
+ <ul class="nolist"><li>true if item is found; else, false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2556,40 +2879,40 @@
</div>
-<a id="scrollToBeginning(int)"></a>
+<A NAME="scrollToBeginning(int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">scrollToBeginning</span>
<span class="normal">(int maxSwipes)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>See <code><a href="#scrollToBeginning(int, int)">scrollToBeginning(int, int)</a></code></p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Scrolls to the beginning of a scrollable layout element. The beginning
+ can be at the top-most edge in the case of vertical controls, or the
+ left-most edge for horizontal controls. Make sure to take into account
+ devices configured with right-to-left languages like Arabic and Hebrew.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true on scrolled else false
-</li></ul>
+ <ul class="nolist"><li>true on scrolled else false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2601,51 +2924,49 @@
</div>
-<a id="scrollToBeginning(int, int)"></a>
+<A NAME="scrollToBeginning(int, int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">scrollToBeginning</span>
<span class="normal">(int maxSwipes, int steps)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Scrolls to the beginning of a scrollable UI element. The beginning could be the top most
- in case of vertical lists or the left most in case of horizontal lists. Caution is required
- on devices configured with right to left languages like Arabic and Hebrew.</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Scrolls to the beginning of a scrollable layout element. The beginning
+ can be at the top-most edge in the case of vertical controls, or the
+ left-most edge for horizontal controls. Make sure to take into account
+ devices configured with right-to-left languages like Arabic and Hebrew.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>steps</th>
+ <th>steps</td>
<td>use steps to control the speed, so that it may be a scroll, or fling</td>
</tr>
</table>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true on scrolled else false
-</li></ul>
+ <ul class="nolist"><li>true on scrolled else false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2657,51 +2978,49 @@
</div>
-<a id="scrollToEnd(int, int)"></a>
+<A NAME="scrollToEnd(int, int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">scrollToEnd</span>
<span class="normal">(int maxSwipes, int steps)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Scrolls to the end of a scrollable UI element. The end could be the bottom most
- in case of vertical controls or the right most for horizontal controls. Caution
- is required on devices configured with right to left languages like Arabic and Hebrew.</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Scrolls to the end of a scrollable layout element. The end can be at the
+ bottom-most edge in the case of vertical controls, or the right-most edge for
+ horizontal controls. Make sure to take into account devices configured with
+ right-to-left languages like Arabic and Hebrew.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>steps</th>
+ <th>steps</td>
<td>use steps to control the speed, so that it may be a scroll, or fling</td>
</tr>
</table>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true on scrolled else false
-</li></ul>
+ <ul class="nolist"><li>true on scrolled else false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2713,40 +3032,40 @@
</div>
-<a id="scrollToEnd(int)"></a>
+<A NAME="scrollToEnd(int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
boolean
</span>
<span class="sympad">scrollToEnd</span>
<span class="normal">(int maxSwipes)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>See {@link UiScrollable#scrollToEnd(int, int)</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Scrolls to the end of a scrollable layout element. The end can be at the
+ bottom-most edge in the case of vertical controls, or the right-most edge for
+ horizontal controls. Make sure to take into account devices configured with
+ right-to-left languages like Arabic and Hebrew.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>true on scrolled else false
-</li></ul>
+ <ul class="nolist"><li>true on scrolled, else false</li></ul>
</div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Throws</h5>
- <table class="jd-tagtable">
+ <table class="jd-tagtable">
<tr>
<th><a href="UiObjectNotFoundException.html">UiObjectNotFoundException</a></td>
<td></td>
@@ -2758,157 +3077,207 @@
</div>
-<a id="setAsHorizontalList()"></a>
+<A NAME="setAsHorizontalList()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- void
+ public
+
+
+
+
+ <a href="#">UiScrollable</a>
</span>
<span class="sympad">setAsHorizontalList</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Set the direction of swipes when performing scroll search
-</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Set the direction of swipes to be horizontal when performing scroll actions.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>reference to itself</li></ul>
+ </div>
</div>
</div>
-<a id="setAsVerticalList()"></a>
+<A NAME="setAsVerticalList()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- void
+ public
+
+
+
+
+ <a href="#">UiScrollable</a>
</span>
<span class="sympad">setAsVerticalList</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Set the direction of swipes when performing scroll search
-</p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Set the direction of swipes to be vertical when performing scroll actions.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>reference to itself</li></ul>
+ </div>
</div>
</div>
-<a id="setMaxSearchSwipes(int)"></a>
+<A NAME="setMaxSearchSwipes(int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- void
+ public
+
+
+
+
+ <a href="#">UiScrollable</a>
</span>
<span class="sympad">setMaxSearchSwipes</span>
<span class="normal">(int swipes)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>#getChildByDescription(String, boolean) and #getChildByText(String, boolean)
- use an arguments that specifies if scrolling is allowed while searching for the UI element.
- The number of scrolls allowed to perform a search can be modified by this method.
- The current value can be read by calling <code><a href="#getMaxSearchSwipes()">getMaxSearchSwipes()</a></code></p></div>
+
+ <div class="jd-tagdata jd-tagdescr"><p>Sets the maximum number of scrolls allowed when performing a
+ scroll action in search of a child element.
+ See <code><a href="#getChildByDescription(com.android.uiautomator.core.UiSelector, java.lang.String)">getChildByDescription(UiSelector, String)</a></code> and
+ <code><a href="#getChildByText(com.android.uiautomator.core.UiSelector, java.lang.String)">getChildByText(UiSelector, String)</a></code>.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>swipes</th>
- <td>is the number of search swipes until abort
-</td>
+ <th>swipes</td>
+ <td>the number of search swipes to perform until giving up</td>
</tr>
</table>
</div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>reference to itself</li></ul>
+ </div>
</div>
</div>
-<a id="setSwipeDeadZonePercentage(double)"></a>
+<A NAME="setSwipeDeadZonePercentage(double)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- void
+ public
+
+
+
+
+ <a href="#">UiScrollable</a>
</span>
<span class="sympad">setSwipeDeadZonePercentage</span>
<span class="normal">(double swipeDeadZonePercentage)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Sets the percentage of a widget's size that's considered as a no touch zone when swiping.
- Dead zones are set as percentage of a widget's total width or height, denoting a margin
- around the swipable area of the widget. Swipes must always start and
- end inside this margin.
-
- This is important when the widget being swiped may not respond to the swipe if
- started at a point too near to the edge. The default is 10% from either edge</p></div>
+ <div class="jd-tagdata jd-tagdescr"><p>Sets the percentage of a widget's size that's considered as no-touch
+ zone when swiping.
+ The no-touch zone is set as percentage of a widget's total width or height,
+ denoting a margin around the swipable area of the widget. Swipes must
+ always start and end inside this margin. This is important when the
+ widget being swiped may not respond to the swipe if started at a point
+ too near to the edge. The default is 10% from either edge.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>swipeDeadZonePercentage</th>
- <td>is a value between 0 and 1
-</td>
+ <th>swipeDeadZonePercentage</td>
+ <td>is a value between 0 and 1</td>
</tr>
</table>
</div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>reference to itself</li></ul>
+ </div>
</div>
</div>
+
+
+
+
+
+<!-- ========= METHOD DETAIL ======== -->
+
+<h2>Protected Methods</h2>
+
+
+
+<A NAME="exists(com.android.uiautomator.core.UiSelector)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ protected
+
+
+
+
+ boolean
+ </span>
+ <span class="sympad">exists</span>
+ <span class="normal">(<a href="UiSelector.html">UiSelector</a> selector)</span>
+ </h4>
+ <div class="api-level">
+ <div></div>
+
+
+
+ </div>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Used privately when performing swipe searches to decide if an element has become
+ visible or not.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>true if found else false</li></ul>
+ </div>
+
+ </div>
+
+
+
+
+
diff --git a/docs/html/tools/help/uiautomator/UiSelector.jd b/docs/html/tools/help/uiautomator/UiSelector.jd
index 96d3fd8..c9a1eed 100644
--- a/docs/html/tools/help/uiautomator/UiSelector.jd
+++ b/docs/html/tools/help/uiautomator/UiSelector.jd
@@ -5,40 +5,10 @@
<style>
h4.jd-details-title {background-color: #DEE8F1;}
</style>
-
-
-<h2>Class Overview</h2>
-<p>This class provides the mechanism for tests to describe the UI elements they
- intend to target. A UI element has many properties associated with it such as
- text value, content-description, class name and multiple state information like
- selected, enabled, checked etc. Additionally UiSelector allows targeting of UI
- elements within a specific display hierarchies to distinguish similar elements
- based in the hierarchies they're in.</p>
-
-
-
-
-
-</div><!-- jd-descr -->
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-<div class="jd-descr">
-
-
+<p>Specifies the elements in the layout hierarchy for tests to target, filtered
+by properties such as text value, content-description, class name, and state
+information. You can also target an element by its location in a layout
+hierarchy.</p>
<h2>Summary</h2>
@@ -68,19 +38,19 @@
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
-
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ </nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#UiSelector()">UiSelector</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#UiSelector()">UiSelector</a></span>()</nobr>
+
</td></tr>
@@ -97,486 +67,542 @@
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#checked(boolean)">checked</a></span>(boolean val)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#checkable(boolean)">checkable</a></span>(boolean val)</nobr>
+
+ <div class="jd-descrdiv">Set the search criteria to match widgets that are checkable.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#checked(boolean)">checked</a></span>(boolean val)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match widgets that
are currently checked (usually for checkboxes).</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#childSelector(com.android.uiautomator.core.UiSelector)">childSelector</a></span>(<a href="UiSelector.html">UiSelector</a> selector)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#childSelector(com.android.uiautomator.core.UiSelector)">childSelector</a></span>(<a href="#">UiSelector</a> selector)</nobr>
+
<div class="jd-descrdiv">Adds a child UiSelector criteria to this selector.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#className(java.lang.String)">className</a></span>(String className)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#className(java.lang.String)">className</a></span>(String className)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match the class property
for a widget (for example, "android.widget.Button").</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
<T>
- <a href="UiSelector.html">UiSelector</a>
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#className(java.lang.Class<T>)">className</a></span>(Class<T> type)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#className(java.lang.Class<T>)">className</a></span>(Class<T> type)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match the class property
for a widget (for example, "android.widget.Button").</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#classNameMatches(java.lang.String)">classNameMatches</a></span>(String regex)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#classNameMatches(java.lang.String)">classNameMatches</a></span>(String regex)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match the class property
- for a widget (for example, "android.widget.Button").</div>
-
+ for a widget, using a regular expression.</div>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#clickable(boolean)">clickable</a></span>(boolean val)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#clickable(boolean)">clickable</a></span>(boolean val)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match widgets that are clickable.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#description(java.lang.String)">description</a></span>(String desc)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#description(java.lang.String)">description</a></span>(String desc)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match the content-description
property for a widget.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#descriptionContains(java.lang.String)">descriptionContains</a></span>(String desc)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#descriptionContains(java.lang.String)">descriptionContains</a></span>(String desc)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match the content-description
property for a widget.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#descriptionMatches(java.lang.String)">descriptionMatches</a></span>(String regex)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#descriptionMatches(java.lang.String)">descriptionMatches</a></span>(String regex)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match the content-description
property for a widget.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#descriptionStartsWith(java.lang.String)">descriptionStartsWith</a></span>(String desc)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#descriptionStartsWith(java.lang.String)">descriptionStartsWith</a></span>(String desc)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match the content-description
property for a widget.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#enabled(boolean)">enabled</a></span>(boolean val)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#enabled(boolean)">enabled</a></span>(boolean val)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match widgets that are enabled.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#focusable(boolean)">focusable</a></span>(boolean val)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#focusable(boolean)">focusable</a></span>(boolean val)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match widgets that are focusable.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#focused(boolean)">focused</a></span>(boolean val)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#focused(boolean)">focused</a></span>(boolean val)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match widgets that have focus.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#fromParent(com.android.uiautomator.core.UiSelector)">fromParent</a></span>(<a href="UiSelector.html">UiSelector</a> selector)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#fromParent(com.android.uiautomator.core.UiSelector)">fromParent</a></span>(<a href="#">UiSelector</a> selector)</nobr>
+
<div class="jd-descrdiv">Adds a child UiSelector criteria to this selector which is used to
start search from the parent widget.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#index(int)">index</a></span>(int index)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#index(int)">index</a></span>(int index)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match the widget by its node
index in the layout hierarchy.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#instance(int)">instance</a></span>(int instance)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#instance(int)">instance</a></span>(int instance)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match the
widget by its instance number.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#longClickable(boolean)">longClickable</a></span>(boolean val)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#longClickable(boolean)">longClickable</a></span>(boolean val)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match widgets that are long-clickable.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#packageName(java.lang.String)">packageName</a></span>(String name)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#packageName(java.lang.String)">packageName</a></span>(String name)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match the package name
of the application that contains the widget.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#packageNameMatches(java.lang.String)">packageNameMatches</a></span>(String regex)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#packageNameMatches(java.lang.String)">packageNameMatches</a></span>(String regex)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match the package name
of the application that contains the widget.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#scrollable(boolean)">scrollable</a></span>(boolean val)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#resourceId(java.lang.String)">resourceId</a></span>(String id)</nobr>
+
+ <div class="jd-descrdiv">Set the search criteria to match the given resource ID.</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#resourceIdMatches(java.lang.String)">resourceIdMatches</a></span>(String regex)</nobr>
+
+ <div class="jd-descrdiv">Set the search criteria to match the resource ID
+ of the widget, using a regular expression.http://blog.bettersoftwaretesting.com/</div>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#scrollable(boolean)">scrollable</a></span>(boolean val)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match widgets that are scrollable.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#selected(boolean)">selected</a></span>(boolean val)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#selected(boolean)">selected</a></span>(boolean val)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match widgets that
are currently selected.</div>
-
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#text(java.lang.String)">text</a></span>(String text)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#text(java.lang.String)">text</a></span>(String text)</nobr>
+
<div class="jd-descrdiv">Set the search criteria to match the visible text displayed
- for a widget (for example, the text label to launch an app).</div>
-
+ in a widget (for example, the text label to launch an app).</div>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#textContains(java.lang.String)">textContains</a></span>(String text)
-
- <div class="jd-descrdiv">Set the search criteria to match the visible text displayed
- for a widget (for example, the text label to launch an app).</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#textContains(java.lang.String)">textContains</a></span>(String text)</nobr>
+
+ <div class="jd-descrdiv">Set the search criteria to match the visible text in a widget
+ where the visible text must contain the string in your input argument.</div>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#textMatches(java.lang.String)">textMatches</a></span>(String regex)
-
- <div class="jd-descrdiv">Set the search criteria to match the visible text displayed
- for a widget (for example, the text label to launch an app).</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#textMatches(java.lang.String)">textMatches</a></span>(String regex)</nobr>
+
+ <div class="jd-descrdiv">Set the search criteria to match the visible text displayed in a layout
+ element, using a regular expression.</div>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#textStartsWith(java.lang.String)">textStartsWith</a></span>(String text)
-
- <div class="jd-descrdiv">Text property is usually the widget's visible text on the display.</div>
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#textStartsWith(java.lang.String)">textStartsWith</a></span>(String text)</nobr>
+
+ <div class="jd-descrdiv">Set the search criteria to match visible text in a widget that is
+ prefixed by the text parameter.</div>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- String
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad"><a href="#toString()">toString</a></span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#toString()">toString</a></span>()</nobr>
+
</td></tr>
@@ -586,6 +612,31 @@
+<!-- ========== METHOD SUMMARY =========== -->
+<table id="promethods" class="jd-sumtable"><tr><th colspan="12">Protected Methods</th></tr>
+
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ <a href="#">UiSelector</a></nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad"><a href="#cloneSelector()">cloneSelector</a></span>()</nobr>
+
+ </td></tr>
+
+
+
+</table>
+
+
@@ -595,7 +646,7 @@
<div style="clear:left;">Inherited Methods</div></th></tr>
-<tr class="api apilevel-" >
+<tr class="api" >
<td colspan="12">
<a href="#" onclick="return toggleInherited(this, null)" id="inherited-methods-java.lang.Object" class="jd-expando-trigger closed"
><img id="inherited-methods-java.lang.Object-trigger"
@@ -611,150 +662,182 @@
</div>
<div id="inherited-methods-java.lang.Object-summary" style="display: none;">
<table class="jd-sumtable-expando">
-
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- boolean
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ Object</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">equals</span>(Object arg0)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">clone</span>()</nobr>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ boolean</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">equals</span>(Object arg0)</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ void</nobr>
+ </td>
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">finalize</span>()</nobr>
+
+ </td></tr>
+
+
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- Class<?>
+
+
+ Class<?></nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">getClass</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">getClass</span>()</nobr>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- int
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ int</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">hashCode</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">hashCode</span>()</nobr>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">notify</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">notify</span>()</nobr>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">notifyAll</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">notifyAll</span>()</nobr>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
-
-
-
- String
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
+
+
+
+ String</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">toString</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">toString</span>()</nobr>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">wait</span>()
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">wait</span>()</nobr>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">wait</span>(long arg0, int arg1)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">wait</span>(long arg0, int arg1)</nobr>
+
</td></tr>
-
- <tr class="api">
- <td class="jd-typecol">
-
-
+
+ <tr class="api" >
+ <td class="jd-typecol"><nobr>
+
+
final
-
-
- void
+
+
+ void</nobr>
</td>
- <td class="jd-linkcol" width="100%">
- <span class="sympad">wait</span>(long arg0)
-
+ <td class="jd-linkcol" width="100%"><nobr>
+ <span class="sympad">wait</span>(long arg0)</nobr>
+
</td></tr>
@@ -798,31 +881,29 @@
-<a id="UiSelector()"></a>
+<A NAME="UiSelector()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
-
+ public
+
+
+
+
+
</span>
<span class="sympad">UiSelector</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p></p></div>
</div>
@@ -844,31 +925,76 @@
-<a id="checked(boolean)"></a>
+<A NAME="checkable(boolean)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
+ </span>
+ <span class="sympad">checkable</span>
+ <span class="normal">(boolean val)</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match widgets that are checkable.
+
+ Typically, using this search criteria alone is not useful.
+ You should also include additional criteria, such as text,
+ content-description, or the class name for a widget.
+
+ If no other search criteria is specified, and there is more
+ than one matching widget, the first widget in the tree
+ is selected.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>val</td>
+ <td>Value to match</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>UiSelector with the specified search criteria</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="checked(boolean)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">checked</span>
<span class="normal">(boolean val)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match widgets that
are currently checked (usually for checkboxes).
@@ -883,7 +1009,7 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>val</th>
+ <th>val</td>
<td>Value to match</td>
</tr>
</table>
@@ -897,31 +1023,29 @@
</div>
-<a id="childSelector(com.android.uiautomator.core.UiSelector)"></a>
+<A NAME="childSelector(com.android.uiautomator.core.UiSelector)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">childSelector</span>
- <span class="normal">(<a href="UiSelector.html">UiSelector</a> selector)</span>
+ <span class="normal">(<a href="#">UiSelector</a> selector)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Adds a child UiSelector criteria to this selector.
Use this selector to narrow the search scope to
@@ -935,38 +1059,30 @@
</div>
-<a id="className(java.lang.String)"></a>
+<A NAME="className(java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">className</span>
<span class="normal">(String className)</span>
</h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the class property
for a widget (for example, "android.widget.Button").</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>className</th>
+ <th>className</td>
<td>Value to match</td>
</tr>
</table>
@@ -975,114 +1091,120 @@
<h5 class="jd-tagtitle">Returns</h5>
<ul class="nolist"><li>UiSelector with the specified search criteria</li></ul>
</div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 17</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="className(java.lang.Class<T>)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
+ </span>
+ <span class="sympad">className</span>
+ <span class="normal">(Class<T> type)</span>
+ </h4>
+ <div class="api-level">
+ <div></div>
+
+
+
+ </div>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the class property
+ for a widget (for example, "android.widget.Button").</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>type</td>
+ <td>type</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>UiSelector with the specified search criteria</li></ul>
+ </div>
</div>
</div>
-<a id="className(java.lang.Class<T>)"></a>
+<A NAME="classNameMatches(java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
- </span>
- <span class="sympad">className</span>
- <span class="normal">(Class<T> type)</span>
- </h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
- <div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the class property
- for a widget (for example, "android.widget.Button").</p></div>
- <div class="jd-tagdata">
- <h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>UiSelector with the specified search criteria</li></ul>
- </div>
- <div class="jd-tagdata">
- <h5 class="jd-tagtitle">Since</h5>
- <ul class="nolist"><li>Android API Level 17</li></ul>
-</div>
- </div>
-</div>
+ public
-<a id="classNameMatches(java.lang.String)"></a>
-<div class="jd-details api ">
- <h4 class="jd-details-title">
- <span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">classNameMatches</span>
<span class="normal">(String regex)</span>
</h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the class property
- for a widget (for example, "android.widget.Button").</p></div>
+ for a widget, using a regular expression.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>regex</td>
+ <td>a regular expression</td>
+ </tr>
+ </table>
+ </div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
<ul class="nolist"><li>UiSelector with the specified search criteria</li></ul>
</div>
<div class="jd-tagdata">
- <h5 class="jd-tagtitle">Since</h5>
- <ul class="nolist"><li>Android API Level 17</li></ul>
-</div>
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 17</li></ul>
+ </div>
</div>
</div>
-<a id="clickable(boolean)"></a>
+<A NAME="clickable(boolean)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">clickable</span>
<span class="normal">(boolean val)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match widgets that are clickable.
Typically, using this search criteria alone is not useful.
@@ -1096,7 +1218,7 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>val</th>
+ <th>val</td>
<td>Value to match</td>
</tr>
</table>
@@ -1110,31 +1232,29 @@
</div>
-<a id="description(java.lang.String)"></a>
+<A NAME="description(java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">description</span>
<span class="normal">(String desc)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the content-description
property for a widget.
@@ -1150,7 +1270,7 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>desc</th>
+ <th>desc</td>
<td>Value to match</td>
</tr>
</table>
@@ -1164,31 +1284,29 @@
</div>
-<a id="descriptionContains(java.lang.String)"></a>
+<A NAME="descriptionContains(java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">descriptionContains</span>
<span class="normal">(String desc)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the content-description
property for a widget.
@@ -1204,7 +1322,7 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>desc</th>
+ <th>desc</td>
<td>Value to match</td>
</tr>
</table>
@@ -1218,31 +1336,23 @@
</div>
-<a id="descriptionMatches(java.lang.String)"></a>
+<A NAME="descriptionMatches(java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">descriptionMatches</span>
<span class="normal">(String regex)</span>
</h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the content-description
property for a widget.
@@ -1253,42 +1363,49 @@
for the widget must match exactly
with the string in your input argument.</p></div>
<div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>regex</td>
+ <td>a regular expression</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
<ul class="nolist"><li>UiSelector with the specified search criteria</li></ul>
</div>
<div class="jd-tagdata">
- <h5 class="jd-tagtitle">Since</h5>
- <ul class="nolist"><li>Android API Level 17</li></ul>
-</div>
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 17</li></ul>
+ </div>
</div>
</div>
-<a id="descriptionStartsWith(java.lang.String)"></a>
+<A NAME="descriptionStartsWith(java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">descriptionStartsWith</span>
<span class="normal">(String desc)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the content-description
property for a widget.
@@ -1304,7 +1421,7 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>desc</th>
+ <th>desc</td>
<td>Value to match</td>
</tr>
</table>
@@ -1318,31 +1435,29 @@
</div>
-<a id="enabled(boolean)"></a>
+<A NAME="enabled(boolean)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">enabled</span>
<span class="normal">(boolean val)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match widgets that are enabled.
Typically, using this search criteria alone is not useful.
@@ -1356,7 +1471,7 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>val</th>
+ <th>val</td>
<td>Value to match</td>
</tr>
</table>
@@ -1370,31 +1485,29 @@
</div>
-<a id="focusable(boolean)"></a>
+<A NAME="focusable(boolean)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">focusable</span>
<span class="normal">(boolean val)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match widgets that are focusable.
Typically, using this search criteria alone is not useful.
@@ -1408,7 +1521,7 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>val</th>
+ <th>val</td>
<td>Value to match</td>
</tr>
</table>
@@ -1422,31 +1535,29 @@
</div>
-<a id="focused(boolean)"></a>
+<A NAME="focused(boolean)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">focused</span>
<span class="normal">(boolean val)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match widgets that have focus.
Typically, using this search criteria alone is not useful.
@@ -1460,7 +1571,7 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>val</th>
+ <th>val</td>
<td>Value to match</td>
</tr>
</table>
@@ -1474,31 +1585,29 @@
</div>
-<a id="fromParent(com.android.uiautomator.core.UiSelector)"></a>
+<A NAME="fromParent(com.android.uiautomator.core.UiSelector)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">fromParent</span>
- <span class="normal">(<a href="UiSelector.html">UiSelector</a> selector)</span>
+ <span class="normal">(<a href="#">UiSelector</a> selector)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Adds a child UiSelector criteria to this selector which is used to
start search from the parent widget.
@@ -1513,31 +1622,29 @@
</div>
-<a id="index(int)"></a>
+<A NAME="index(int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">index</span>
<span class="normal">(int index)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the widget by its node
index in the layout hierarchy.
@@ -1550,7 +1657,7 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>index</th>
+ <th>index</td>
<td>Value to match</td>
</tr>
</table>
@@ -1564,31 +1671,29 @@
</div>
-<a id="instance(int)"></a>
+<A NAME="instance(int)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">instance</span>
<span class="normal">(int instance)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the
widget by its instance number.
@@ -1609,7 +1714,7 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>instance</th>
+ <th>instance</td>
<td>Value to match</td>
</tr>
</table>
@@ -1623,31 +1728,23 @@
</div>
-<a id="longClickable(boolean)"></a>
+<A NAME="longClickable(boolean)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">longClickable</span>
<span class="normal">(boolean val)</span>
</h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match widgets that are long-clickable.
Typically, using this search criteria alone is not useful.
@@ -1661,7 +1758,7 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>val</th>
+ <th>val</td>
<td>Value to match</td>
</tr>
</table>
@@ -1671,45 +1768,43 @@
<ul class="nolist"><li>UiSelector with the specified search criteria</li></ul>
</div>
<div class="jd-tagdata">
- <h5 class="jd-tagtitle">Since</h5>
- <ul class="nolist"><li>Android API Level 17</li></ul>
-</div>
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 17</li></ul>
+ </div>
</div>
</div>
-<a id="packageName(java.lang.String)"></a>
+<A NAME="packageName(java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">packageName</span>
<span class="normal">(String name)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the package name
of the application that contains the widget.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>name</th>
+ <th>name</td>
<td>Value to match</td>
</tr>
</table>
@@ -1723,70 +1818,148 @@
</div>
-<a id="packageNameMatches(java.lang.String)"></a>
+<A NAME="packageNameMatches(java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">packageNameMatches</span>
<span class="normal">(String regex)</span>
</h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the package name
of the application that contains the widget.</p></div>
<div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>regex</td>
+ <td>a regular expression</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
<ul class="nolist"><li>UiSelector with the specified search criteria</li></ul>
</div>
<div class="jd-tagdata">
- <h5 class="jd-tagtitle">Since</h5>
- <ul class="nolist"><li>Android API Level 17</li></ul>
-</div>
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 17</li></ul>
+ </div>
</div>
</div>
-<a id="scrollable(boolean)"></a>
+<A NAME="resourceId(java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
+ </span>
+ <span class="sympad">resourceId</span>
+ <span class="normal">(String id)</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the given resource ID.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>id</td>
+ <td>Value to match</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>UiSelector with the specified search criteria</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="resourceIdMatches(java.lang.String)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
+ </span>
+ <span class="sympad">resourceIdMatches</span>
+ <span class="normal">(String regex)</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the resource ID
+ of the widget, using a regular expression.http://blog.bettersoftwaretesting.com/</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>regex</td>
+ <td>a regular expression</td>
+ </tr>
+ </table>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Returns</h5>
+ <ul class="nolist"><li>UiSelector with the specified search criteria</li></ul>
+ </div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 18</li></ul>
+ </div>
+ </div>
+</div>
+
+
+<A NAME="scrollable(boolean)"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">scrollable</span>
<span class="normal">(boolean val)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match widgets that are scrollable.
Typically, using this search criteria alone is not useful.
@@ -1800,7 +1973,7 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>val</th>
+ <th>val</td>
<td>Value to match</td>
</tr>
</table>
@@ -1814,31 +1987,29 @@
</div>
-<a id="selected(boolean)"></a>
+<A NAME="selected(boolean)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">selected</span>
<span class="normal">(boolean val)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match widgets that
are currently selected.
@@ -1853,7 +2024,7 @@
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>val</th>
+ <th>val</td>
<td>Value to match</td>
</tr>
</table>
@@ -1867,42 +2038,39 @@
</div>
-<a id="text(java.lang.String)"></a>
+<A NAME="text(java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">text</span>
<span class="normal">(String text)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the visible text displayed
- for a widget (for example, the text label to launch an app).
- The text for the widget must match exactly
- with the string in your input argument.
- Matching is case-sensitive.</p></div>
+ <div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the visible text displayed
+ in a widget (for example, the text label to launch an app).
+
+ The text for the element must match exactly with the string in your input
+ argument. Matching is case-sensitive.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>text</th>
+ <th>text</td>
<td>Value to match</td>
</tr>
</table>
@@ -1916,41 +2084,38 @@
</div>
-<a id="textContains(java.lang.String)"></a>
+<A NAME="textContains(java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">textContains</span>
<span class="normal">(String text)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the visible text displayed
- for a widget (for example, the text label to launch an app).
- The text for the widget must contain the string in
- your input argument. Matching is case-sensitive.</p></div>
+ <div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the visible text in a widget
+ where the visible text must contain the string in your input argument.
+
+ The matching is case-sensitive.</p></div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Parameters</h5>
<table class="jd-tagtable">
<tr>
- <th>text</th>
+ <th>text</td>
<td>Value to match</td>
</tr>
</table>
@@ -1964,113 +2129,117 @@
</div>
-<a id="textMatches(java.lang.String)"></a>
+<A NAME="textMatches(java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">textMatches</span>
<span class="normal">(String regex)</span>
</h4>
- <div class="api-level">
- <div>
-
-</div>
-
-
-
- </div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the visible text displayed
- for a widget (for example, the text label to launch an app).
- The text for the widget must match exactly
- with the string in your input argument.</p></div>
+ <div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match the visible text displayed in a layout
+ element, using a regular expression.
+
+ The text in the widget must match exactly with the string in your
+ input argument.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>regex</td>
+ <td>a regular expression</td>
+ </tr>
+ </table>
+ </div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
<ul class="nolist"><li>UiSelector with the specified search criteria</li></ul>
</div>
<div class="jd-tagdata">
- <h5 class="jd-tagtitle">Since</h5>
- <ul class="nolist"><li>Android API Level 17</li></ul>
-</div>
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 17</li></ul>
+ </div>
</div>
</div>
-<a id="textStartsWith(java.lang.String)"></a>
+<A NAME="textStartsWith(java.lang.String)"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
- <a href="UiSelector.html">UiSelector</a>
+ public
+
+
+
+
+ <a href="#">UiSelector</a>
</span>
<span class="sympad">textStartsWith</span>
<span class="normal">(String text)</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
- <div class="jd-tagdata jd-tagdescr"><p>Text property is usually the widget's visible text on the display.
- Adding this to the search criteria indicates that the search performed
- should match a widget with text value starting with the text parameter.
+ <div class="jd-tagdata jd-tagdescr"><p>Set the search criteria to match visible text in a widget that is
+ prefixed by the text parameter.
- The matching will be case-insensitive.</p></div>
+ The matching is case-insensitive.</p></div>
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Parameters</h5>
+ <table class="jd-tagtable">
+ <tr>
+ <th>text</td>
+ <td>Value to match</td>
+ </tr>
+ </table>
+ </div>
<div class="jd-tagdata">
<h5 class="jd-tagtitle">Returns</h5>
- <ul class="nolist"><li>UiSelector with this added search criterion</li></ul>
+ <ul class="nolist"><li>UiSelector with the specified search criteria</li></ul>
</div>
</div>
</div>
-<a id="toString()"></a>
+<A NAME="toString()"></A>
-<div class="jd-details api ">
+<div class="jd-details api">
<h4 class="jd-details-title">
<span class="normal">
- public
-
-
-
-
+ public
+
+
+
+
String
</span>
<span class="sympad">toString</span>
<span class="normal">()</span>
</h4>
<div class="api-level">
- <div>
+ <div></div>
-</div>
-
-
+
</div>
<div class="jd-details-descr">
-
+
<div class="jd-tagdata jd-tagdescr"><p></p></div>
</div>
@@ -2082,7 +2251,36 @@
<!-- ========= METHOD DETAIL ======== -->
+<h2>Protected Methods</h2>
-<!-- ========= END OF CLASS DATA ========= -->
+
+<A NAME="cloneSelector()"></A>
+
+<div class="jd-details api">
+ <h4 class="jd-details-title">
+ <span class="normal">
+ protected
+
+
+
+
+ <a href="#">UiSelector</a>
+ </span>
+ <span class="sympad">cloneSelector</span>
+ <span class="normal">()</span>
+ </h4>
+ <div class="jd-details-descr">
+
+ <div class="jd-tagdata">
+ <h5 class="jd-tagtitle">Since</h5>
+ <ul class="nolist"><li>Android API Level 17</li></ul>
+ </div>
+
+ </div>
+
+
+
+
+
diff --git a/docs/html/tools/help/uiautomator/UiWatcher.jd b/docs/html/tools/help/uiautomator/UiWatcher.jd
index b416fad..9268c35 100644
--- a/docs/html/tools/help/uiautomator/UiWatcher.jd
+++ b/docs/html/tools/help/uiautomator/UiWatcher.jd
@@ -9,9 +9,6 @@
<p>Represents a conditional watcher on the target device. To learn how to register a conditional
watcher, see <code><a href="UiDevice.html#registerWatcher(java.lang.String, com.android.uiautomator.core.UiWatcher)">UiDevice.registerWatcher()</a></code>.
</p>
-
-<div class="jd-descr">
-
<h2>Summary</h2>
<!-- ========== METHOD SUMMARY =========== -->
@@ -75,4 +72,3 @@
</div>
</div>
-</div>
diff --git a/docs/html/tools/help/uiautomator/index.jd b/docs/html/tools/help/uiautomator/index.jd
index e3899d6..4b3c255 100644
--- a/docs/html/tools/help/uiautomator/index.jd
+++ b/docs/html/tools/help/uiautomator/index.jd
@@ -26,7 +26,7 @@
<h2 id="syntax">Syntax</h2>
<p>To run your testcases on the target device, you can use the {@code adb shell} command to invoke the {@code uiautomator} tool. The syntax is:
<pre>
-adb shell uiautomator runtest <jar> -c <test_class_or_method> [options]
+adb shell uiautomator runtest <JARS> -c <CLASSES> [options]
</pre>
</p>
<p>Here’s an example:</p>
@@ -45,19 +45,26 @@
</tr>
<tr>
-<td rowspan="6"><code>runtest</code></td>
-<td><nobr>{@code <jar>}</nobr></td>
-<td><strong>Required</strong>. The {@code <jar>} argument is the name of one or more JAR files that you deployed to the target device which contain your uiautomator testcases. You can list more than one JAR file by using a space as a separator.</td>
+<td rowspan="7"><code>runtest</code></td>
+<td><nobr>{@code <JARS>}</nobr></td>
+<td><strong>Required</strong>. The {@code <JARS>} argument is the name of one or more JAR files that you deployed to the target device which contain your uiautomator testcases. You can list more than one JAR file by using a space as a separator.</td>
</tr>
<tr>
-<td><nobr><code>-c <test_class_or_method> </code></nobr></td>
-<td><strong>Required</strong>. The {@code <test_class_or_method>} argument is a list of one or more specific test classes or test methods from the JARs that you want {@code uiautomator} to run. <p>Each class or method must be fully qualified with the package name, in one of these formats:
+<td><nobr><code>-c <CLASSES> </code></nobr></td>
+<td><strong>Required (API 17 or lower)</strong>.The {@code <CLASSES>}
+argument is a list of test classes or test methods in {@code <JARS>} to run.
+<p>Each class or method must be fully
+qualified with the package name, in one of these formats:
<ul>
<li>{@code package_name.class_name}</li>
<li>{@code package_name.class_name#method_name}</li>
</ul>
-You can list multiple classes or methods by using a space as a separator.</p></td>
+You can list multiple classes or methods by using a space as a separator.</p>
+<p class="note"><strong>Note:</strong>This argument is not required for API 18
+and higher. If not specified, all test cases in {@code <JARS>} will be run.
+</p>
+</td>
</tr>
<tr>
@@ -76,12 +83,16 @@
</tr>
<tr>
-<td><code>dump</code></td>
-<td><code>[file]</code></td>
+<td><code>dump [file]</code></td>
<td>Generate an XML file with a dump of the current UI hierarchy. If a filepath is not specified, by default, the generated dump file is stored on the device in this location {@code /storage/sdcard0/window_dump.xml}.</td>
</tr>
<tr>
+<td><nobr><code>-e outputFormat simple | -s</code></nobr></td>
+<td>Enables less verbose JUnit style output.</td>
+</tr>
+
+<tr>
<td><code>events</code></td>
<td> </td>
<td>Prints out accessibility events to the console until the connection to the device is terminated</td>
@@ -123,6 +134,11 @@
<td>Represents a query for one or more target UI elements on a device screen. </td>
</tr>
+<tr>
+<td><nobr><a href="{@docRoot}tools/help/uiautomator/Configurator.html">{@code com.android.uiautomator.core.Configurator}</a></nobr></td>
+<td>Allows you to set key parameters for running uiautomator tests.</td>
+</tr>
+
</table>
<h3 id="interfaces">Interfaces</h3>
diff --git a/docs/html/tools/tools_toc.cs b/docs/html/tools/tools_toc.cs
index 6389880..c555f98 100644
--- a/docs/html/tools/tools_toc.cs
+++ b/docs/html/tools/tools_toc.cs
@@ -187,6 +187,7 @@
<li class="nav-section">
<div class="nav-section-header"><a href="<?cs var:toroot ?>tools/help/uiautomator/index.html"><span class="en">uiautomator</span></a></div>
<ul>
+ <li><a href="<?cs var:toroot ?>tools/help/uiautomator/Configurator.html"><span class="en">Configurator</span></a></li>
<li><a href="<?cs var:toroot ?>tools/help/uiautomator/IAutomationSupport.html"><span class="en">IAutomationSupport</span></a></li>
<li><a href="<?cs var:toroot ?>tools/help/uiautomator/UiAutomatorTestCase.html"><span class="en">UiAutomatorTestCase</span></a></li>
<li><a href="<?cs var:toroot ?>tools/help/uiautomator/UiCollection.html"><span class="en">UiCollection</span></a></li>
diff --git a/include/android_runtime/android_view_InputQueue.h b/include/android_runtime/android_view_InputQueue.h
index ba2d02d..ed37b0a 100644
--- a/include/android_runtime/android_view_InputQueue.h
+++ b/include/android_runtime/android_view_InputQueue.h
@@ -17,7 +17,7 @@
#ifndef _ANDROID_VIEW_INPUTQUEUE_H
#define _ANDROID_VIEW_INPUTQUEUE_H
-#include <androidfw/Input.h>
+#include <input/Input.h>
#include <utils/Looper.h>
#include <utils/TypeHelpers.h>
#include <utils/Vector.h>
diff --git a/include/androidfw/Input.h b/include/androidfw/Input.h
deleted file mode 100644
index 37ab279..0000000
--- a/include/androidfw/Input.h
+++ /dev/null
@@ -1,622 +0,0 @@
-/*
- * Copyright (C) 2010 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef _ANDROIDFW_INPUT_H
-#define _ANDROIDFW_INPUT_H
-
-/**
- * Native input event structures.
- */
-
-#include <android/input.h>
-#include <utils/Vector.h>
-#include <utils/KeyedVector.h>
-#include <utils/Timers.h>
-#include <utils/RefBase.h>
-#include <utils/String8.h>
-
-#ifdef HAVE_ANDROID_OS
-class SkMatrix;
-#endif
-
-/*
- * Additional private constants not defined in ndk/ui/input.h.
- */
-enum {
- /* Signifies that the key is being predispatched */
- AKEY_EVENT_FLAG_PREDISPATCH = 0x20000000,
-
- /* Private control to determine when an app is tracking a key sequence. */
- AKEY_EVENT_FLAG_START_TRACKING = 0x40000000,
-
- /* Key event is inconsistent with previously sent key events. */
- AKEY_EVENT_FLAG_TAINTED = 0x80000000,
-};
-
-enum {
- /* Motion event is inconsistent with previously sent motion events. */
- AMOTION_EVENT_FLAG_TAINTED = 0x80000000,
-};
-
-enum {
- /* Used when a motion event is not associated with any display.
- * Typically used for non-pointer events. */
- ADISPLAY_ID_NONE = -1,
-
- /* The default display id. */
- ADISPLAY_ID_DEFAULT = 0,
-};
-
-enum {
- /*
- * Indicates that an input device has switches.
- * This input source flag is hidden from the API because switches are only used by the system
- * and applications have no way to interact with them.
- */
- AINPUT_SOURCE_SWITCH = 0x80000000,
-};
-
-/*
- * SystemUiVisibility constants from View.
- */
-enum {
- ASYSTEM_UI_VISIBILITY_STATUS_BAR_VISIBLE = 0,
- ASYSTEM_UI_VISIBILITY_STATUS_BAR_HIDDEN = 0x00000001,
-};
-
-/*
- * Maximum number of pointers supported per motion event.
- * Smallest number of pointers is 1.
- * (We want at least 10 but some touch controllers obstensibly configured for 10 pointers
- * will occasionally emit 11. There is not much harm making this constant bigger.)
- */
-#define MAX_POINTERS 16
-
-/*
- * Maximum pointer id value supported in a motion event.
- * Smallest pointer id is 0.
- * (This is limited by our use of BitSet32 to track pointer assignments.)
- */
-#define MAX_POINTER_ID 31
-
-/*
- * Declare a concrete type for the NDK's input event forward declaration.
- */
-struct AInputEvent {
- virtual ~AInputEvent() { }
-};
-
-/*
- * Declare a concrete type for the NDK's input device forward declaration.
- */
-struct AInputDevice {
- virtual ~AInputDevice() { }
-};
-
-
-namespace android {
-
-#ifdef HAVE_ANDROID_OS
-class Parcel;
-#endif
-
-/*
- * Flags that flow alongside events in the input dispatch system to help with certain
- * policy decisions such as waking from device sleep.
- *
- * These flags are also defined in frameworks/base/core/java/android/view/WindowManagerPolicy.java.
- */
-enum {
- /* These flags originate in RawEvents and are generally set in the key map.
- * NOTE: If you edit these flags, also edit labels in KeycodeLabels.h. */
-
- POLICY_FLAG_WAKE = 0x00000001,
- POLICY_FLAG_WAKE_DROPPED = 0x00000002,
- POLICY_FLAG_SHIFT = 0x00000004,
- POLICY_FLAG_CAPS_LOCK = 0x00000008,
- POLICY_FLAG_ALT = 0x00000010,
- POLICY_FLAG_ALT_GR = 0x00000020,
- POLICY_FLAG_MENU = 0x00000040,
- POLICY_FLAG_LAUNCHER = 0x00000080,
- POLICY_FLAG_VIRTUAL = 0x00000100,
- POLICY_FLAG_FUNCTION = 0x00000200,
-
- POLICY_FLAG_RAW_MASK = 0x0000ffff,
-
- /* These flags are set by the input dispatcher. */
-
- // Indicates that the input event was injected.
- POLICY_FLAG_INJECTED = 0x01000000,
-
- // Indicates that the input event is from a trusted source such as a directly attached
- // input device or an application with system-wide event injection permission.
- POLICY_FLAG_TRUSTED = 0x02000000,
-
- // Indicates that the input event has passed through an input filter.
- POLICY_FLAG_FILTERED = 0x04000000,
-
- // Disables automatic key repeating behavior.
- POLICY_FLAG_DISABLE_KEY_REPEAT = 0x08000000,
-
- /* These flags are set by the input reader policy as it intercepts each event. */
-
- // Indicates that the screen was off when the event was received and the event
- // should wake the device.
- POLICY_FLAG_WOKE_HERE = 0x10000000,
-
- // Indicates that the screen was dim when the event was received and the event
- // should brighten the device.
- POLICY_FLAG_BRIGHT_HERE = 0x20000000,
-
- // Indicates that the event should be dispatched to applications.
- // The input event should still be sent to the InputDispatcher so that it can see all
- // input events received include those that it will not deliver.
- POLICY_FLAG_PASS_TO_USER = 0x40000000,
-};
-
-/*
- * Pointer coordinate data.
- */
-struct PointerCoords {
- enum { MAX_AXES = 14 }; // 14 so that sizeof(PointerCoords) == 64
-
- // Bitfield of axes that are present in this structure.
- uint64_t bits;
-
- // Values of axes that are stored in this structure packed in order by axis id
- // for each axis that is present in the structure according to 'bits'.
- float values[MAX_AXES];
-
- inline void clear() {
- bits = 0;
- }
-
- float getAxisValue(int32_t axis) const;
- status_t setAxisValue(int32_t axis, float value);
-
- void scale(float scale);
-
- inline float getX() const {
- return getAxisValue(AMOTION_EVENT_AXIS_X);
- }
-
- inline float getY() const {
- return getAxisValue(AMOTION_EVENT_AXIS_Y);
- }
-
-#ifdef HAVE_ANDROID_OS
- status_t readFromParcel(Parcel* parcel);
- status_t writeToParcel(Parcel* parcel) const;
-#endif
-
- bool operator==(const PointerCoords& other) const;
- inline bool operator!=(const PointerCoords& other) const {
- return !(*this == other);
- }
-
- void copyFrom(const PointerCoords& other);
-
-private:
- void tooManyAxes(int axis);
-};
-
-/*
- * Pointer property data.
- */
-struct PointerProperties {
- // The id of the pointer.
- int32_t id;
-
- // The pointer tool type.
- int32_t toolType;
-
- inline void clear() {
- id = -1;
- toolType = 0;
- }
-
- bool operator==(const PointerProperties& other) const;
- inline bool operator!=(const PointerProperties& other) const {
- return !(*this == other);
- }
-
- void copyFrom(const PointerProperties& other);
-};
-
-/*
- * Input events.
- */
-class InputEvent : public AInputEvent {
-public:
- virtual ~InputEvent() { }
-
- virtual int32_t getType() const = 0;
-
- inline int32_t getDeviceId() const { return mDeviceId; }
-
- inline int32_t getSource() const { return mSource; }
-
- inline void setSource(int32_t source) { mSource = source; }
-
-protected:
- void initialize(int32_t deviceId, int32_t source);
- void initialize(const InputEvent& from);
-
- int32_t mDeviceId;
- int32_t mSource;
-};
-
-/*
- * Key events.
- */
-class KeyEvent : public InputEvent {
-public:
- virtual ~KeyEvent() { }
-
- virtual int32_t getType() const { return AINPUT_EVENT_TYPE_KEY; }
-
- inline int32_t getAction() const { return mAction; }
-
- inline int32_t getFlags() const { return mFlags; }
-
- inline void setFlags(int32_t flags) { mFlags = flags; }
-
- inline int32_t getKeyCode() const { return mKeyCode; }
-
- inline int32_t getScanCode() const { return mScanCode; }
-
- inline int32_t getMetaState() const { return mMetaState; }
-
- inline int32_t getRepeatCount() const { return mRepeatCount; }
-
- inline nsecs_t getDownTime() const { return mDownTime; }
-
- inline nsecs_t getEventTime() const { return mEventTime; }
-
- // Return true if this event may have a default action implementation.
- static bool hasDefaultAction(int32_t keyCode);
- bool hasDefaultAction() const;
-
- // Return true if this event represents a system key.
- static bool isSystemKey(int32_t keyCode);
- bool isSystemKey() const;
-
- void initialize(
- int32_t deviceId,
- int32_t source,
- int32_t action,
- int32_t flags,
- int32_t keyCode,
- int32_t scanCode,
- int32_t metaState,
- int32_t repeatCount,
- nsecs_t downTime,
- nsecs_t eventTime);
- void initialize(const KeyEvent& from);
-
-protected:
- int32_t mAction;
- int32_t mFlags;
- int32_t mKeyCode;
- int32_t mScanCode;
- int32_t mMetaState;
- int32_t mRepeatCount;
- nsecs_t mDownTime;
- nsecs_t mEventTime;
-};
-
-/*
- * Motion events.
- */
-class MotionEvent : public InputEvent {
-public:
- virtual ~MotionEvent() { }
-
- virtual int32_t getType() const { return AINPUT_EVENT_TYPE_MOTION; }
-
- inline int32_t getAction() const { return mAction; }
-
- inline int32_t getActionMasked() const { return mAction & AMOTION_EVENT_ACTION_MASK; }
-
- inline int32_t getActionIndex() const {
- return (mAction & AMOTION_EVENT_ACTION_POINTER_INDEX_MASK)
- >> AMOTION_EVENT_ACTION_POINTER_INDEX_SHIFT;
- }
-
- inline void setAction(int32_t action) { mAction = action; }
-
- inline int32_t getFlags() const { return mFlags; }
-
- inline void setFlags(int32_t flags) { mFlags = flags; }
-
- inline int32_t getEdgeFlags() const { return mEdgeFlags; }
-
- inline void setEdgeFlags(int32_t edgeFlags) { mEdgeFlags = edgeFlags; }
-
- inline int32_t getMetaState() const { return mMetaState; }
-
- inline void setMetaState(int32_t metaState) { mMetaState = metaState; }
-
- inline int32_t getButtonState() const { return mButtonState; }
-
- inline float getXOffset() const { return mXOffset; }
-
- inline float getYOffset() const { return mYOffset; }
-
- inline float getXPrecision() const { return mXPrecision; }
-
- inline float getYPrecision() const { return mYPrecision; }
-
- inline nsecs_t getDownTime() const { return mDownTime; }
-
- inline void setDownTime(nsecs_t downTime) { mDownTime = downTime; }
-
- inline size_t getPointerCount() const { return mPointerProperties.size(); }
-
- inline const PointerProperties* getPointerProperties(size_t pointerIndex) const {
- return &mPointerProperties[pointerIndex];
- }
-
- inline int32_t getPointerId(size_t pointerIndex) const {
- return mPointerProperties[pointerIndex].id;
- }
-
- inline int32_t getToolType(size_t pointerIndex) const {
- return mPointerProperties[pointerIndex].toolType;
- }
-
- inline nsecs_t getEventTime() const { return mSampleEventTimes[getHistorySize()]; }
-
- const PointerCoords* getRawPointerCoords(size_t pointerIndex) const;
-
- float getRawAxisValue(int32_t axis, size_t pointerIndex) const;
-
- inline float getRawX(size_t pointerIndex) const {
- return getRawAxisValue(AMOTION_EVENT_AXIS_X, pointerIndex);
- }
-
- inline float getRawY(size_t pointerIndex) const {
- return getRawAxisValue(AMOTION_EVENT_AXIS_Y, pointerIndex);
- }
-
- float getAxisValue(int32_t axis, size_t pointerIndex) const;
-
- inline float getX(size_t pointerIndex) const {
- return getAxisValue(AMOTION_EVENT_AXIS_X, pointerIndex);
- }
-
- inline float getY(size_t pointerIndex) const {
- return getAxisValue(AMOTION_EVENT_AXIS_Y, pointerIndex);
- }
-
- inline float getPressure(size_t pointerIndex) const {
- return getAxisValue(AMOTION_EVENT_AXIS_PRESSURE, pointerIndex);
- }
-
- inline float getSize(size_t pointerIndex) const {
- return getAxisValue(AMOTION_EVENT_AXIS_SIZE, pointerIndex);
- }
-
- inline float getTouchMajor(size_t pointerIndex) const {
- return getAxisValue(AMOTION_EVENT_AXIS_TOUCH_MAJOR, pointerIndex);
- }
-
- inline float getTouchMinor(size_t pointerIndex) const {
- return getAxisValue(AMOTION_EVENT_AXIS_TOUCH_MINOR, pointerIndex);
- }
-
- inline float getToolMajor(size_t pointerIndex) const {
- return getAxisValue(AMOTION_EVENT_AXIS_TOOL_MAJOR, pointerIndex);
- }
-
- inline float getToolMinor(size_t pointerIndex) const {
- return getAxisValue(AMOTION_EVENT_AXIS_TOOL_MINOR, pointerIndex);
- }
-
- inline float getOrientation(size_t pointerIndex) const {
- return getAxisValue(AMOTION_EVENT_AXIS_ORIENTATION, pointerIndex);
- }
-
- inline size_t getHistorySize() const { return mSampleEventTimes.size() - 1; }
-
- inline nsecs_t getHistoricalEventTime(size_t historicalIndex) const {
- return mSampleEventTimes[historicalIndex];
- }
-
- const PointerCoords* getHistoricalRawPointerCoords(
- size_t pointerIndex, size_t historicalIndex) const;
-
- float getHistoricalRawAxisValue(int32_t axis, size_t pointerIndex,
- size_t historicalIndex) const;
-
- inline float getHistoricalRawX(size_t pointerIndex, size_t historicalIndex) const {
- return getHistoricalRawAxisValue(
- AMOTION_EVENT_AXIS_X, pointerIndex, historicalIndex);
- }
-
- inline float getHistoricalRawY(size_t pointerIndex, size_t historicalIndex) const {
- return getHistoricalRawAxisValue(
- AMOTION_EVENT_AXIS_Y, pointerIndex, historicalIndex);
- }
-
- float getHistoricalAxisValue(int32_t axis, size_t pointerIndex, size_t historicalIndex) const;
-
- inline float getHistoricalX(size_t pointerIndex, size_t historicalIndex) const {
- return getHistoricalAxisValue(
- AMOTION_EVENT_AXIS_X, pointerIndex, historicalIndex);
- }
-
- inline float getHistoricalY(size_t pointerIndex, size_t historicalIndex) const {
- return getHistoricalAxisValue(
- AMOTION_EVENT_AXIS_Y, pointerIndex, historicalIndex);
- }
-
- inline float getHistoricalPressure(size_t pointerIndex, size_t historicalIndex) const {
- return getHistoricalAxisValue(
- AMOTION_EVENT_AXIS_PRESSURE, pointerIndex, historicalIndex);
- }
-
- inline float getHistoricalSize(size_t pointerIndex, size_t historicalIndex) const {
- return getHistoricalAxisValue(
- AMOTION_EVENT_AXIS_SIZE, pointerIndex, historicalIndex);
- }
-
- inline float getHistoricalTouchMajor(size_t pointerIndex, size_t historicalIndex) const {
- return getHistoricalAxisValue(
- AMOTION_EVENT_AXIS_TOUCH_MAJOR, pointerIndex, historicalIndex);
- }
-
- inline float getHistoricalTouchMinor(size_t pointerIndex, size_t historicalIndex) const {
- return getHistoricalAxisValue(
- AMOTION_EVENT_AXIS_TOUCH_MINOR, pointerIndex, historicalIndex);
- }
-
- inline float getHistoricalToolMajor(size_t pointerIndex, size_t historicalIndex) const {
- return getHistoricalAxisValue(
- AMOTION_EVENT_AXIS_TOOL_MAJOR, pointerIndex, historicalIndex);
- }
-
- inline float getHistoricalToolMinor(size_t pointerIndex, size_t historicalIndex) const {
- return getHistoricalAxisValue(
- AMOTION_EVENT_AXIS_TOOL_MINOR, pointerIndex, historicalIndex);
- }
-
- inline float getHistoricalOrientation(size_t pointerIndex, size_t historicalIndex) const {
- return getHistoricalAxisValue(
- AMOTION_EVENT_AXIS_ORIENTATION, pointerIndex, historicalIndex);
- }
-
- ssize_t findPointerIndex(int32_t pointerId) const;
-
- void initialize(
- int32_t deviceId,
- int32_t source,
- int32_t action,
- int32_t flags,
- int32_t edgeFlags,
- int32_t metaState,
- int32_t buttonState,
- float xOffset,
- float yOffset,
- float xPrecision,
- float yPrecision,
- nsecs_t downTime,
- nsecs_t eventTime,
- size_t pointerCount,
- const PointerProperties* pointerProperties,
- const PointerCoords* pointerCoords);
-
- void copyFrom(const MotionEvent* other, bool keepHistory);
-
- void addSample(
- nsecs_t eventTime,
- const PointerCoords* pointerCoords);
-
- void offsetLocation(float xOffset, float yOffset);
-
- void scale(float scaleFactor);
-
-#ifdef HAVE_ANDROID_OS
- void transform(const SkMatrix* matrix);
-
- status_t readFromParcel(Parcel* parcel);
- status_t writeToParcel(Parcel* parcel) const;
-#endif
-
- static bool isTouchEvent(int32_t source, int32_t action);
- inline bool isTouchEvent() const {
- return isTouchEvent(mSource, mAction);
- }
-
- // Low-level accessors.
- inline const PointerProperties* getPointerProperties() const {
- return mPointerProperties.array();
- }
- inline const nsecs_t* getSampleEventTimes() const { return mSampleEventTimes.array(); }
- inline const PointerCoords* getSamplePointerCoords() const {
- return mSamplePointerCoords.array();
- }
-
-protected:
- int32_t mAction;
- int32_t mFlags;
- int32_t mEdgeFlags;
- int32_t mMetaState;
- int32_t mButtonState;
- float mXOffset;
- float mYOffset;
- float mXPrecision;
- float mYPrecision;
- nsecs_t mDownTime;
- Vector<PointerProperties> mPointerProperties;
- Vector<nsecs_t> mSampleEventTimes;
- Vector<PointerCoords> mSamplePointerCoords;
-};
-
-/*
- * Input event factory.
- */
-class InputEventFactoryInterface {
-protected:
- virtual ~InputEventFactoryInterface() { }
-
-public:
- InputEventFactoryInterface() { }
-
- virtual KeyEvent* createKeyEvent() = 0;
- virtual MotionEvent* createMotionEvent() = 0;
-};
-
-/*
- * A simple input event factory implementation that uses a single preallocated instance
- * of each type of input event that are reused for each request.
- */
-class PreallocatedInputEventFactory : public InputEventFactoryInterface {
-public:
- PreallocatedInputEventFactory() { }
- virtual ~PreallocatedInputEventFactory() { }
-
- virtual KeyEvent* createKeyEvent() { return & mKeyEvent; }
- virtual MotionEvent* createMotionEvent() { return & mMotionEvent; }
-
-private:
- KeyEvent mKeyEvent;
- MotionEvent mMotionEvent;
-};
-
-/*
- * An input event factory implementation that maintains a pool of input events.
- */
-class PooledInputEventFactory : public InputEventFactoryInterface {
-public:
- PooledInputEventFactory(size_t maxPoolSize = 20);
- virtual ~PooledInputEventFactory();
-
- virtual KeyEvent* createKeyEvent();
- virtual MotionEvent* createMotionEvent();
-
- void recycle(InputEvent* event);
-
-private:
- const size_t mMaxPoolSize;
-
- Vector<KeyEvent*> mKeyEventPool;
- Vector<MotionEvent*> mMotionEventPool;
-};
-
-} // namespace android
-
-#endif // _ANDROIDFW_INPUT_H
diff --git a/include/androidfw/InputDevice.h b/include/androidfw/InputDevice.h
deleted file mode 100644
index 45dc2db..0000000
--- a/include/androidfw/InputDevice.h
+++ /dev/null
@@ -1,156 +0,0 @@
-/*
- * Copyright (C) 2012 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef _ANDROIDFW_INPUT_DEVICE_H
-#define _ANDROIDFW_INPUT_DEVICE_H
-
-#include <androidfw/Input.h>
-#include <androidfw/KeyCharacterMap.h>
-
-namespace android {
-
-/*
- * Identifies a device.
- */
-struct InputDeviceIdentifier {
- inline InputDeviceIdentifier() :
- bus(0), vendor(0), product(0), version(0) {
- }
-
- // Information provided by the kernel.
- String8 name;
- String8 location;
- String8 uniqueId;
- uint16_t bus;
- uint16_t vendor;
- uint16_t product;
- uint16_t version;
-
- // A composite input device descriptor string that uniquely identifies the device
- // even across reboots or reconnections. The value of this field is used by
- // upper layers of the input system to associate settings with individual devices.
- // It is hashed from whatever kernel provided information is available.
- // Ideally, the way this value is computed should not change between Android releases
- // because that would invalidate persistent settings that rely on it.
- String8 descriptor;
-};
-
-/*
- * Describes the characteristics and capabilities of an input device.
- */
-class InputDeviceInfo {
-public:
- InputDeviceInfo();
- InputDeviceInfo(const InputDeviceInfo& other);
- ~InputDeviceInfo();
-
- struct MotionRange {
- int32_t axis;
- uint32_t source;
- float min;
- float max;
- float flat;
- float fuzz;
- float resolution;
- };
-
- void initialize(int32_t id, int32_t generation, const InputDeviceIdentifier& identifier,
- const String8& alias, bool isExternal);
-
- inline int32_t getId() const { return mId; }
- inline int32_t getGeneration() const { return mGeneration; }
- inline const InputDeviceIdentifier& getIdentifier() const { return mIdentifier; }
- inline const String8& getAlias() const { return mAlias; }
- inline const String8& getDisplayName() const {
- return mAlias.isEmpty() ? mIdentifier.name : mAlias;
- }
- inline bool isExternal() const { return mIsExternal; }
- inline uint32_t getSources() const { return mSources; }
-
- const MotionRange* getMotionRange(int32_t axis, uint32_t source) const;
-
- void addSource(uint32_t source);
- void addMotionRange(int32_t axis, uint32_t source,
- float min, float max, float flat, float fuzz, float resolution);
- void addMotionRange(const MotionRange& range);
-
- inline void setKeyboardType(int32_t keyboardType) { mKeyboardType = keyboardType; }
- inline int32_t getKeyboardType() const { return mKeyboardType; }
-
- inline void setKeyCharacterMap(const sp<KeyCharacterMap>& value) {
- mKeyCharacterMap = value;
- }
-
- inline sp<KeyCharacterMap> getKeyCharacterMap() const {
- return mKeyCharacterMap;
- }
-
- inline void setVibrator(bool hasVibrator) { mHasVibrator = hasVibrator; }
- inline bool hasVibrator() const { return mHasVibrator; }
-
- inline const Vector<MotionRange>& getMotionRanges() const {
- return mMotionRanges;
- }
-
-private:
- int32_t mId;
- int32_t mGeneration;
- InputDeviceIdentifier mIdentifier;
- String8 mAlias;
- bool mIsExternal;
- uint32_t mSources;
- int32_t mKeyboardType;
- sp<KeyCharacterMap> mKeyCharacterMap;
- bool mHasVibrator;
-
- Vector<MotionRange> mMotionRanges;
-};
-
-/* Types of input device configuration files. */
-enum InputDeviceConfigurationFileType {
- INPUT_DEVICE_CONFIGURATION_FILE_TYPE_CONFIGURATION = 0, /* .idc file */
- INPUT_DEVICE_CONFIGURATION_FILE_TYPE_KEY_LAYOUT = 1, /* .kl file */
- INPUT_DEVICE_CONFIGURATION_FILE_TYPE_KEY_CHARACTER_MAP = 2, /* .kcm file */
-};
-
-/*
- * Gets the path of an input device configuration file, if one is available.
- * Considers both system provided and user installed configuration files.
- *
- * The device identifier is used to construct several default configuration file
- * names to try based on the device name, vendor, product, and version.
- *
- * Returns an empty string if not found.
- */
-extern String8 getInputDeviceConfigurationFilePathByDeviceIdentifier(
- const InputDeviceIdentifier& deviceIdentifier,
- InputDeviceConfigurationFileType type);
-
-/*
- * Gets the path of an input device configuration file, if one is available.
- * Considers both system provided and user installed configuration files.
- *
- * The name is case-sensitive and is used to construct the filename to resolve.
- * All characters except 'a'-'z', 'A'-'Z', '0'-'9', '-', and '_' are replaced by underscores.
- *
- * Returns an empty string if not found.
- */
-extern String8 getInputDeviceConfigurationFilePathByName(
- const String8& name, InputDeviceConfigurationFileType type);
-
-} // namespace android
-
-#endif // _ANDROIDFW_INPUT_DEVICE_H
diff --git a/include/androidfw/InputTransport.h b/include/androidfw/InputTransport.h
deleted file mode 100644
index 8712995..0000000
--- a/include/androidfw/InputTransport.h
+++ /dev/null
@@ -1,443 +0,0 @@
-/*
- * Copyright (C) 2010 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef _ANDROIDFW_INPUT_TRANSPORT_H
-#define _ANDROIDFW_INPUT_TRANSPORT_H
-
-/**
- * Native input transport.
- *
- * The InputChannel provides a mechanism for exchanging InputMessage structures across processes.
- *
- * The InputPublisher and InputConsumer each handle one end-point of an input channel.
- * The InputPublisher is used by the input dispatcher to send events to the application.
- * The InputConsumer is used by the application to receive events from the input dispatcher.
- */
-
-#include <androidfw/Input.h>
-#include <utils/Errors.h>
-#include <utils/Timers.h>
-#include <utils/RefBase.h>
-#include <utils/String8.h>
-#include <utils/Vector.h>
-#include <utils/BitSet.h>
-
-namespace android {
-
-/*
- * Intermediate representation used to send input events and related signals.
- */
-struct InputMessage {
- enum {
- TYPE_KEY = 1,
- TYPE_MOTION = 2,
- TYPE_FINISHED = 3,
- };
-
- struct Header {
- uint32_t type;
- uint32_t padding; // 8 byte alignment for the body that follows
- } header;
-
- union Body {
- struct Key {
- uint32_t seq;
- nsecs_t eventTime;
- int32_t deviceId;
- int32_t source;
- int32_t action;
- int32_t flags;
- int32_t keyCode;
- int32_t scanCode;
- int32_t metaState;
- int32_t repeatCount;
- nsecs_t downTime;
-
- inline size_t size() const {
- return sizeof(Key);
- }
- } key;
-
- struct Motion {
- uint32_t seq;
- nsecs_t eventTime;
- int32_t deviceId;
- int32_t source;
- int32_t action;
- int32_t flags;
- int32_t metaState;
- int32_t buttonState;
- int32_t edgeFlags;
- nsecs_t downTime;
- float xOffset;
- float yOffset;
- float xPrecision;
- float yPrecision;
- size_t pointerCount;
- struct Pointer {
- PointerProperties properties;
- PointerCoords coords;
- } pointers[MAX_POINTERS];
-
- int32_t getActionId() const {
- uint32_t index = (action & AMOTION_EVENT_ACTION_POINTER_INDEX_MASK)
- >> AMOTION_EVENT_ACTION_POINTER_INDEX_SHIFT;
- return pointers[index].properties.id;
- }
-
- inline size_t size() const {
- return sizeof(Motion) - sizeof(Pointer) * MAX_POINTERS
- + sizeof(Pointer) * pointerCount;
- }
- } motion;
-
- struct Finished {
- uint32_t seq;
- bool handled;
-
- inline size_t size() const {
- return sizeof(Finished);
- }
- } finished;
- } body;
-
- bool isValid(size_t actualSize) const;
- size_t size() const;
-};
-
-/*
- * An input channel consists of a local unix domain socket used to send and receive
- * input messages across processes. Each channel has a descriptive name for debugging purposes.
- *
- * Each endpoint has its own InputChannel object that specifies its file descriptor.
- *
- * The input channel is closed when all references to it are released.
- */
-class InputChannel : public RefBase {
-protected:
- virtual ~InputChannel();
-
-public:
- InputChannel(const String8& name, int fd);
-
- /* Creates a pair of input channels.
- *
- * Returns OK on success.
- */
- static status_t openInputChannelPair(const String8& name,
- sp<InputChannel>& outServerChannel, sp<InputChannel>& outClientChannel);
-
- inline String8 getName() const { return mName; }
- inline int getFd() const { return mFd; }
-
- /* Sends a message to the other endpoint.
- *
- * If the channel is full then the message is guaranteed not to have been sent at all.
- * Try again after the consumer has sent a finished signal indicating that it has
- * consumed some of the pending messages from the channel.
- *
- * Returns OK on success.
- * Returns WOULD_BLOCK if the channel is full.
- * Returns DEAD_OBJECT if the channel's peer has been closed.
- * Other errors probably indicate that the channel is broken.
- */
- status_t sendMessage(const InputMessage* msg);
-
- /* Receives a message sent by the other endpoint.
- *
- * If there is no message present, try again after poll() indicates that the fd
- * is readable.
- *
- * Returns OK on success.
- * Returns WOULD_BLOCK if there is no message present.
- * Returns DEAD_OBJECT if the channel's peer has been closed.
- * Other errors probably indicate that the channel is broken.
- */
- status_t receiveMessage(InputMessage* msg);
-
- /* Returns a new object that has a duplicate of this channel's fd. */
- sp<InputChannel> dup() const;
-
-private:
- String8 mName;
- int mFd;
-};
-
-/*
- * Publishes input events to an input channel.
- */
-class InputPublisher {
-public:
- /* Creates a publisher associated with an input channel. */
- explicit InputPublisher(const sp<InputChannel>& channel);
-
- /* Destroys the publisher and releases its input channel. */
- ~InputPublisher();
-
- /* Gets the underlying input channel. */
- inline sp<InputChannel> getChannel() { return mChannel; }
-
- /* Publishes a key event to the input channel.
- *
- * Returns OK on success.
- * Returns WOULD_BLOCK if the channel is full.
- * Returns DEAD_OBJECT if the channel's peer has been closed.
- * Returns BAD_VALUE if seq is 0.
- * Other errors probably indicate that the channel is broken.
- */
- status_t publishKeyEvent(
- uint32_t seq,
- int32_t deviceId,
- int32_t source,
- int32_t action,
- int32_t flags,
- int32_t keyCode,
- int32_t scanCode,
- int32_t metaState,
- int32_t repeatCount,
- nsecs_t downTime,
- nsecs_t eventTime);
-
- /* Publishes a motion event to the input channel.
- *
- * Returns OK on success.
- * Returns WOULD_BLOCK if the channel is full.
- * Returns DEAD_OBJECT if the channel's peer has been closed.
- * Returns BAD_VALUE if seq is 0 or if pointerCount is less than 1 or greater than MAX_POINTERS.
- * Other errors probably indicate that the channel is broken.
- */
- status_t publishMotionEvent(
- uint32_t seq,
- int32_t deviceId,
- int32_t source,
- int32_t action,
- int32_t flags,
- int32_t edgeFlags,
- int32_t metaState,
- int32_t buttonState,
- float xOffset,
- float yOffset,
- float xPrecision,
- float yPrecision,
- nsecs_t downTime,
- nsecs_t eventTime,
- size_t pointerCount,
- const PointerProperties* pointerProperties,
- const PointerCoords* pointerCoords);
-
- /* Receives the finished signal from the consumer in reply to the original dispatch signal.
- * If a signal was received, returns the message sequence number,
- * and whether the consumer handled the message.
- *
- * The returned sequence number is never 0 unless the operation failed.
- *
- * Returns OK on success.
- * Returns WOULD_BLOCK if there is no signal present.
- * Returns DEAD_OBJECT if the channel's peer has been closed.
- * Other errors probably indicate that the channel is broken.
- */
- status_t receiveFinishedSignal(uint32_t* outSeq, bool* outHandled);
-
-private:
- sp<InputChannel> mChannel;
-};
-
-/*
- * Consumes input events from an input channel.
- */
-class InputConsumer {
-public:
- /* Creates a consumer associated with an input channel. */
- explicit InputConsumer(const sp<InputChannel>& channel);
-
- /* Destroys the consumer and releases its input channel. */
- ~InputConsumer();
-
- /* Gets the underlying input channel. */
- inline sp<InputChannel> getChannel() { return mChannel; }
-
- /* Consumes an input event from the input channel and copies its contents into
- * an InputEvent object created using the specified factory.
- *
- * Tries to combine a series of move events into larger batches whenever possible.
- *
- * If consumeBatches is false, then defers consuming pending batched events if it
- * is possible for additional samples to be added to them later. Call hasPendingBatch()
- * to determine whether a pending batch is available to be consumed.
- *
- * If consumeBatches is true, then events are still batched but they are consumed
- * immediately as soon as the input channel is exhausted.
- *
- * The frameTime parameter specifies the time when the current display frame started
- * rendering in the CLOCK_MONOTONIC time base, or -1 if unknown.
- *
- * The returned sequence number is never 0 unless the operation failed.
- *
- * Returns OK on success.
- * Returns WOULD_BLOCK if there is no event present.
- * Returns DEAD_OBJECT if the channel's peer has been closed.
- * Returns NO_MEMORY if the event could not be created.
- * Other errors probably indicate that the channel is broken.
- */
- status_t consume(InputEventFactoryInterface* factory, bool consumeBatches,
- nsecs_t frameTime, uint32_t* outSeq, InputEvent** outEvent);
-
- /* Sends a finished signal to the publisher to inform it that the message
- * with the specified sequence number has finished being process and whether
- * the message was handled by the consumer.
- *
- * Returns OK on success.
- * Returns BAD_VALUE if seq is 0.
- * Other errors probably indicate that the channel is broken.
- */
- status_t sendFinishedSignal(uint32_t seq, bool handled);
-
- /* Returns true if there is a deferred event waiting.
- *
- * Should be called after calling consume() to determine whether the consumer
- * has a deferred event to be processed. Deferred events are somewhat special in
- * that they have already been removed from the input channel. If the input channel
- * becomes empty, the client may need to do extra work to ensure that it processes
- * the deferred event despite the fact that the input channel's file descriptor
- * is not readable.
- *
- * One option is simply to call consume() in a loop until it returns WOULD_BLOCK.
- * This guarantees that all deferred events will be processed.
- *
- * Alternately, the caller can call hasDeferredEvent() to determine whether there is
- * a deferred event waiting and then ensure that its event loop wakes up at least
- * one more time to consume the deferred event.
- */
- bool hasDeferredEvent() const;
-
- /* Returns true if there is a pending batch.
- *
- * Should be called after calling consume() with consumeBatches == false to determine
- * whether consume() should be called again later on with consumeBatches == true.
- */
- bool hasPendingBatch() const;
-
-private:
- // True if touch resampling is enabled.
- const bool mResampleTouch;
-
- // The input channel.
- sp<InputChannel> mChannel;
-
- // The current input message.
- InputMessage mMsg;
-
- // True if mMsg contains a valid input message that was deferred from the previous
- // call to consume and that still needs to be handled.
- bool mMsgDeferred;
-
- // Batched motion events per device and source.
- struct Batch {
- Vector<InputMessage> samples;
- };
- Vector<Batch> mBatches;
-
- // Touch state per device and source, only for sources of class pointer.
- struct History {
- nsecs_t eventTime;
- BitSet32 idBits;
- int32_t idToIndex[MAX_POINTER_ID + 1];
- PointerCoords pointers[MAX_POINTERS];
-
- void initializeFrom(const InputMessage* msg) {
- eventTime = msg->body.motion.eventTime;
- idBits.clear();
- for (size_t i = 0; i < msg->body.motion.pointerCount; i++) {
- uint32_t id = msg->body.motion.pointers[i].properties.id;
- idBits.markBit(id);
- idToIndex[id] = i;
- pointers[i].copyFrom(msg->body.motion.pointers[i].coords);
- }
- }
-
- const PointerCoords& getPointerById(uint32_t id) const {
- return pointers[idToIndex[id]];
- }
- };
- struct TouchState {
- int32_t deviceId;
- int32_t source;
- size_t historyCurrent;
- size_t historySize;
- History history[2];
- History lastResample;
-
- void initialize(int32_t deviceId, int32_t source) {
- this->deviceId = deviceId;
- this->source = source;
- historyCurrent = 0;
- historySize = 0;
- lastResample.eventTime = 0;
- lastResample.idBits.clear();
- }
-
- void addHistory(const InputMessage* msg) {
- historyCurrent ^= 1;
- if (historySize < 2) {
- historySize += 1;
- }
- history[historyCurrent].initializeFrom(msg);
- }
-
- const History* getHistory(size_t index) const {
- return &history[(historyCurrent + index) & 1];
- }
- };
- Vector<TouchState> mTouchStates;
-
- // Chain of batched sequence numbers. When multiple input messages are combined into
- // a batch, we append a record here that associates the last sequence number in the
- // batch with the previous one. When the finished signal is sent, we traverse the
- // chain to individually finish all input messages that were part of the batch.
- struct SeqChain {
- uint32_t seq; // sequence number of batched input message
- uint32_t chain; // sequence number of previous batched input message
- };
- Vector<SeqChain> mSeqChains;
-
- status_t consumeBatch(InputEventFactoryInterface* factory,
- nsecs_t frameTime, uint32_t* outSeq, InputEvent** outEvent);
- status_t consumeSamples(InputEventFactoryInterface* factory,
- Batch& batch, size_t count, uint32_t* outSeq, InputEvent** outEvent);
-
- void updateTouchState(InputMessage* msg);
- void rewriteMessage(const TouchState& state, InputMessage* msg);
- void resampleTouchState(nsecs_t frameTime, MotionEvent* event,
- const InputMessage *next);
-
- ssize_t findBatch(int32_t deviceId, int32_t source) const;
- ssize_t findTouchState(int32_t deviceId, int32_t source) const;
-
- status_t sendUnchainedFinishedSignal(uint32_t seq, bool handled);
-
- static void initializeKeyEvent(KeyEvent* event, const InputMessage* msg);
- static void initializeMotionEvent(MotionEvent* event, const InputMessage* msg);
- static void addSample(MotionEvent* event, const InputMessage* msg);
- static bool canAddSample(const Batch& batch, const InputMessage* msg);
- static ssize_t findSampleNoLaterThan(const Batch& batch, nsecs_t time);
- static bool shouldResampleTool(int32_t toolType);
-
- static bool isTouchResamplingEnabled();
-};
-
-} // namespace android
-
-#endif // _ANDROIDFW_INPUT_TRANSPORT_H
diff --git a/include/androidfw/KeyCharacterMap.h b/include/androidfw/KeyCharacterMap.h
deleted file mode 100644
index 06799f9..0000000
--- a/include/androidfw/KeyCharacterMap.h
+++ /dev/null
@@ -1,257 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef _ANDROIDFW_KEY_CHARACTER_MAP_H
-#define _ANDROIDFW_KEY_CHARACTER_MAP_H
-
-#include <stdint.h>
-
-#if HAVE_ANDROID_OS
-#include <binder/IBinder.h>
-#endif
-
-#include <androidfw/Input.h>
-#include <utils/Errors.h>
-#include <utils/KeyedVector.h>
-#include <utils/Tokenizer.h>
-#include <utils/String8.h>
-#include <utils/Unicode.h>
-#include <utils/RefBase.h>
-
-namespace android {
-
-/**
- * Describes a mapping from Android key codes to characters.
- * Also specifies other functions of the keyboard such as the keyboard type
- * and key modifier semantics.
- *
- * This object is immutable after it has been loaded.
- */
-class KeyCharacterMap : public RefBase {
-public:
- enum KeyboardType {
- KEYBOARD_TYPE_UNKNOWN = 0,
- KEYBOARD_TYPE_NUMERIC = 1,
- KEYBOARD_TYPE_PREDICTIVE = 2,
- KEYBOARD_TYPE_ALPHA = 3,
- KEYBOARD_TYPE_FULL = 4,
- KEYBOARD_TYPE_SPECIAL_FUNCTION = 5,
- KEYBOARD_TYPE_OVERLAY = 6,
- };
-
- enum Format {
- // Base keyboard layout, may contain device-specific options, such as "type" declaration.
- FORMAT_BASE = 0,
- // Overlay keyboard layout, more restrictive, may be published by applications,
- // cannot override device-specific options.
- FORMAT_OVERLAY = 1,
- // Either base or overlay layout ok.
- FORMAT_ANY = 2,
- };
-
- // Substitute key code and meta state for fallback action.
- struct FallbackAction {
- int32_t keyCode;
- int32_t metaState;
- };
-
- /* Loads a key character map from a file. */
- static status_t load(const String8& filename, Format format, sp<KeyCharacterMap>* outMap);
-
- /* Loads a key character map from its string contents. */
- static status_t loadContents(const String8& filename,
- const char* contents, Format format, sp<KeyCharacterMap>* outMap);
-
- /* Combines a base key character map and an overlay. */
- static sp<KeyCharacterMap> combine(const sp<KeyCharacterMap>& base,
- const sp<KeyCharacterMap>& overlay);
-
- /* Returns an empty key character map. */
- static sp<KeyCharacterMap> empty();
-
- /* Gets the keyboard type. */
- int32_t getKeyboardType() const;
-
- /* Gets the primary character for this key as in the label physically printed on it.
- * Returns 0 if none (eg. for non-printing keys). */
- char16_t getDisplayLabel(int32_t keyCode) const;
-
- /* Gets the Unicode character for the number or symbol generated by the key
- * when the keyboard is used as a dialing pad.
- * Returns 0 if no number or symbol is generated.
- */
- char16_t getNumber(int32_t keyCode) const;
-
- /* Gets the Unicode character generated by the key and meta key modifiers.
- * Returns 0 if no character is generated.
- */
- char16_t getCharacter(int32_t keyCode, int32_t metaState) const;
-
- /* Gets the fallback action to use by default if the application does not
- * handle the specified key.
- * Returns true if an action was available, false if none.
- */
- bool getFallbackAction(int32_t keyCode, int32_t metaState,
- FallbackAction* outFallbackAction) const;
-
- /* Gets the first matching Unicode character that can be generated by the key,
- * preferring the one with the specified meta key modifiers.
- * Returns 0 if no matching character is generated.
- */
- char16_t getMatch(int32_t keyCode, const char16_t* chars,
- size_t numChars, int32_t metaState) const;
-
- /* Gets a sequence of key events that could plausibly generate the specified
- * character sequence. Returns false if some of the characters cannot be generated.
- */
- bool getEvents(int32_t deviceId, const char16_t* chars, size_t numChars,
- Vector<KeyEvent>& outEvents) const;
-
- /* Maps a scan code and usage code to a key code, in case this key map overrides
- * the mapping in some way. */
- status_t mapKey(int32_t scanCode, int32_t usageCode, int32_t* outKeyCode) const;
-
-#if HAVE_ANDROID_OS
- /* Reads a key map from a parcel. */
- static sp<KeyCharacterMap> readFromParcel(Parcel* parcel);
-
- /* Writes a key map to a parcel. */
- void writeToParcel(Parcel* parcel) const;
-#endif
-
-protected:
- virtual ~KeyCharacterMap();
-
-private:
- struct Behavior {
- Behavior();
- Behavior(const Behavior& other);
-
- /* The next behavior in the list, or NULL if none. */
- Behavior* next;
-
- /* The meta key modifiers for this behavior. */
- int32_t metaState;
-
- /* The character to insert. */
- char16_t character;
-
- /* The fallback keycode if the key is not handled. */
- int32_t fallbackKeyCode;
- };
-
- struct Key {
- Key();
- Key(const Key& other);
- ~Key();
-
- /* The single character label printed on the key, or 0 if none. */
- char16_t label;
-
- /* The number or symbol character generated by the key, or 0 if none. */
- char16_t number;
-
- /* The list of key behaviors sorted from most specific to least specific
- * meta key binding. */
- Behavior* firstBehavior;
- };
-
- class Parser {
- enum State {
- STATE_TOP = 0,
- STATE_KEY = 1,
- };
-
- enum {
- PROPERTY_LABEL = 1,
- PROPERTY_NUMBER = 2,
- PROPERTY_META = 3,
- };
-
- struct Property {
- inline Property(int32_t property = 0, int32_t metaState = 0) :
- property(property), metaState(metaState) { }
-
- int32_t property;
- int32_t metaState;
- };
-
- KeyCharacterMap* mMap;
- Tokenizer* mTokenizer;
- Format mFormat;
- State mState;
- int32_t mKeyCode;
-
- public:
- Parser(KeyCharacterMap* map, Tokenizer* tokenizer, Format format);
- ~Parser();
- status_t parse();
-
- private:
- status_t parseType();
- status_t parseMap();
- status_t parseMapKey();
- status_t parseKey();
- status_t parseKeyProperty();
- status_t finishKey(Key* key);
- status_t parseModifier(const String8& token, int32_t* outMetaState);
- status_t parseCharacterLiteral(char16_t* outCharacter);
- };
-
- static sp<KeyCharacterMap> sEmpty;
-
- KeyedVector<int32_t, Key*> mKeys;
- int mType;
-
- KeyedVector<int32_t, int32_t> mKeysByScanCode;
- KeyedVector<int32_t, int32_t> mKeysByUsageCode;
-
- KeyCharacterMap();
- KeyCharacterMap(const KeyCharacterMap& other);
-
- bool getKey(int32_t keyCode, const Key** outKey) const;
- bool getKeyBehavior(int32_t keyCode, int32_t metaState,
- const Key** outKey, const Behavior** outBehavior) const;
- static bool matchesMetaState(int32_t eventMetaState, int32_t behaviorMetaState);
-
- bool findKey(char16_t ch, int32_t* outKeyCode, int32_t* outMetaState) const;
-
- static status_t load(Tokenizer* tokenizer, Format format, sp<KeyCharacterMap>* outMap);
-
- static void addKey(Vector<KeyEvent>& outEvents,
- int32_t deviceId, int32_t keyCode, int32_t metaState, bool down, nsecs_t time);
- static void addMetaKeys(Vector<KeyEvent>& outEvents,
- int32_t deviceId, int32_t metaState, bool down, nsecs_t time,
- int32_t* currentMetaState);
- static bool addSingleEphemeralMetaKey(Vector<KeyEvent>& outEvents,
- int32_t deviceId, int32_t metaState, bool down, nsecs_t time,
- int32_t keyCode, int32_t keyMetaState,
- int32_t* currentMetaState);
- static void addDoubleEphemeralMetaKey(Vector<KeyEvent>& outEvents,
- int32_t deviceId, int32_t metaState, bool down, nsecs_t time,
- int32_t leftKeyCode, int32_t leftKeyMetaState,
- int32_t rightKeyCode, int32_t rightKeyMetaState,
- int32_t eitherKeyMetaState,
- int32_t* currentMetaState);
- static void addLockedMetaKey(Vector<KeyEvent>& outEvents,
- int32_t deviceId, int32_t metaState, nsecs_t time,
- int32_t keyCode, int32_t keyMetaState,
- int32_t* currentMetaState);
-};
-
-} // namespace android
-
-#endif // _ANDROIDFW_KEY_CHARACTER_MAP_H
diff --git a/include/androidfw/KeyLayoutMap.h b/include/androidfw/KeyLayoutMap.h
deleted file mode 100644
index e7f22a2..0000000
--- a/include/androidfw/KeyLayoutMap.h
+++ /dev/null
@@ -1,107 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef _ANDROIDFW_KEY_LAYOUT_MAP_H
-#define _ANDROIDFW_KEY_LAYOUT_MAP_H
-
-#include <stdint.h>
-#include <utils/Errors.h>
-#include <utils/KeyedVector.h>
-#include <utils/Tokenizer.h>
-#include <utils/RefBase.h>
-
-namespace android {
-
-struct AxisInfo {
- enum Mode {
- // Axis value is reported directly.
- MODE_NORMAL = 0,
- // Axis value should be inverted before reporting.
- MODE_INVERT = 1,
- // Axis value should be split into two axes
- MODE_SPLIT = 2,
- };
-
- // Axis mode.
- Mode mode;
-
- // Axis id.
- // When split, this is the axis used for values smaller than the split position.
- int32_t axis;
-
- // When split, this is the axis used for values after higher than the split position.
- int32_t highAxis;
-
- // The split value, or 0 if not split.
- int32_t splitValue;
-
- // The flat value, or -1 if none.
- int32_t flatOverride;
-
- AxisInfo() : mode(MODE_NORMAL), axis(-1), highAxis(-1), splitValue(0), flatOverride(-1) {
- }
-};
-
-/**
- * Describes a mapping from keyboard scan codes and joystick axes to Android key codes and axes.
- *
- * This object is immutable after it has been loaded.
- */
-class KeyLayoutMap : public RefBase {
-public:
- static status_t load(const String8& filename, sp<KeyLayoutMap>* outMap);
-
- status_t mapKey(int32_t scanCode, int32_t usageCode,
- int32_t* outKeyCode, uint32_t* outFlags) const;
- status_t findScanCodesForKey(int32_t keyCode, Vector<int32_t>* outScanCodes) const;
-
- status_t mapAxis(int32_t scanCode, AxisInfo* outAxisInfo) const;
-
-protected:
- virtual ~KeyLayoutMap();
-
-private:
- struct Key {
- int32_t keyCode;
- uint32_t flags;
- };
-
- KeyedVector<int32_t, Key> mKeysByScanCode;
- KeyedVector<int32_t, Key> mKeysByUsageCode;
- KeyedVector<int32_t, AxisInfo> mAxes;
-
- KeyLayoutMap();
-
- const Key* getKey(int32_t scanCode, int32_t usageCode) const;
-
- class Parser {
- KeyLayoutMap* mMap;
- Tokenizer* mTokenizer;
-
- public:
- Parser(KeyLayoutMap* map, Tokenizer* tokenizer);
- ~Parser();
- status_t parse();
-
- private:
- status_t parseKey();
- status_t parseAxis();
- };
-};
-
-} // namespace android
-
-#endif // _ANDROIDFW_KEY_LAYOUT_MAP_H
diff --git a/include/androidfw/Keyboard.h b/include/androidfw/Keyboard.h
deleted file mode 100644
index 6537a8f..0000000
--- a/include/androidfw/Keyboard.h
+++ /dev/null
@@ -1,120 +0,0 @@
-/*
- * Copyright (C) 2010 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef _ANDROIDFW_KEYBOARD_H
-#define _ANDROIDFW_KEYBOARD_H
-
-#include <androidfw/Input.h>
-#include <androidfw/InputDevice.h>
-#include <utils/Errors.h>
-#include <utils/String8.h>
-#include <utils/PropertyMap.h>
-
-namespace android {
-
-enum {
- /* Device id of the built in keyboard. */
- DEVICE_ID_BUILT_IN_KEYBOARD = 0,
-
- /* Device id of a generic virtual keyboard with a full layout that can be used
- * to synthesize key events. */
- DEVICE_ID_VIRTUAL_KEYBOARD = -1,
-};
-
-class KeyLayoutMap;
-class KeyCharacterMap;
-
-/**
- * Loads the key layout map and key character map for a keyboard device.
- */
-class KeyMap {
-public:
- String8 keyLayoutFile;
- sp<KeyLayoutMap> keyLayoutMap;
-
- String8 keyCharacterMapFile;
- sp<KeyCharacterMap> keyCharacterMap;
-
- KeyMap();
- ~KeyMap();
-
- status_t load(const InputDeviceIdentifier& deviceIdenfier,
- const PropertyMap* deviceConfiguration);
-
- inline bool haveKeyLayout() const {
- return !keyLayoutFile.isEmpty();
- }
-
- inline bool haveKeyCharacterMap() const {
- return !keyCharacterMapFile.isEmpty();
- }
-
- inline bool isComplete() const {
- return haveKeyLayout() && haveKeyCharacterMap();
- }
-
-private:
- bool probeKeyMap(const InputDeviceIdentifier& deviceIdentifier, const String8& name);
- status_t loadKeyLayout(const InputDeviceIdentifier& deviceIdentifier, const String8& name);
- status_t loadKeyCharacterMap(const InputDeviceIdentifier& deviceIdentifier,
- const String8& name);
- String8 getPath(const InputDeviceIdentifier& deviceIdentifier,
- const String8& name, InputDeviceConfigurationFileType type);
-};
-
-/**
- * Returns true if the keyboard is eligible for use as a built-in keyboard.
- */
-extern bool isEligibleBuiltInKeyboard(const InputDeviceIdentifier& deviceIdentifier,
- const PropertyMap* deviceConfiguration, const KeyMap* keyMap);
-
-/**
- * Gets a key code by its short form label, eg. "HOME".
- * Returns 0 if unknown.
- */
-extern int32_t getKeyCodeByLabel(const char* label);
-
-/**
- * Gets a key flag by its short form label, eg. "WAKE".
- * Returns 0 if unknown.
- */
-extern uint32_t getKeyFlagByLabel(const char* label);
-
-/**
- * Gets a axis by its short form label, eg. "X".
- * Returns -1 if unknown.
- */
-extern int32_t getAxisByLabel(const char* label);
-
-/**
- * Gets a axis label by its id.
- * Returns NULL if unknown.
- */
-extern const char* getAxisLabel(int32_t axisId);
-
-/**
- * Updates a meta state field when a key is pressed or released.
- */
-extern int32_t updateMetaState(int32_t keyCode, bool down, int32_t oldMetaState);
-
-/**
- * Returns true if a key is a meta key like ALT or CAPS_LOCK.
- */
-extern bool isMetaKey(int32_t keyCode);
-
-} // namespace android
-
-#endif // _ANDROIDFW_KEYBOARD_H
diff --git a/include/androidfw/KeycodeLabels.h b/include/androidfw/KeycodeLabels.h
deleted file mode 100644
index 3e12f26..0000000
--- a/include/androidfw/KeycodeLabels.h
+++ /dev/null
@@ -1,321 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef _ANDROIDFW_KEYCODE_LABELS_H
-#define _ANDROIDFW_KEYCODE_LABELS_H
-
-#include <android/keycodes.h>
-
-struct KeycodeLabel {
- const char *literal;
- int value;
-};
-
-static const KeycodeLabel KEYCODES[] = {
- { "SOFT_LEFT", 1 },
- { "SOFT_RIGHT", 2 },
- { "HOME", 3 },
- { "BACK", 4 },
- { "CALL", 5 },
- { "ENDCALL", 6 },
- { "0", 7 },
- { "1", 8 },
- { "2", 9 },
- { "3", 10 },
- { "4", 11 },
- { "5", 12 },
- { "6", 13 },
- { "7", 14 },
- { "8", 15 },
- { "9", 16 },
- { "STAR", 17 },
- { "POUND", 18 },
- { "DPAD_UP", 19 },
- { "DPAD_DOWN", 20 },
- { "DPAD_LEFT", 21 },
- { "DPAD_RIGHT", 22 },
- { "DPAD_CENTER", 23 },
- { "VOLUME_UP", 24 },
- { "VOLUME_DOWN", 25 },
- { "POWER", 26 },
- { "CAMERA", 27 },
- { "CLEAR", 28 },
- { "A", 29 },
- { "B", 30 },
- { "C", 31 },
- { "D", 32 },
- { "E", 33 },
- { "F", 34 },
- { "G", 35 },
- { "H", 36 },
- { "I", 37 },
- { "J", 38 },
- { "K", 39 },
- { "L", 40 },
- { "M", 41 },
- { "N", 42 },
- { "O", 43 },
- { "P", 44 },
- { "Q", 45 },
- { "R", 46 },
- { "S", 47 },
- { "T", 48 },
- { "U", 49 },
- { "V", 50 },
- { "W", 51 },
- { "X", 52 },
- { "Y", 53 },
- { "Z", 54 },
- { "COMMA", 55 },
- { "PERIOD", 56 },
- { "ALT_LEFT", 57 },
- { "ALT_RIGHT", 58 },
- { "SHIFT_LEFT", 59 },
- { "SHIFT_RIGHT", 60 },
- { "TAB", 61 },
- { "SPACE", 62 },
- { "SYM", 63 },
- { "EXPLORER", 64 },
- { "ENVELOPE", 65 },
- { "ENTER", 66 },
- { "DEL", 67 },
- { "GRAVE", 68 },
- { "MINUS", 69 },
- { "EQUALS", 70 },
- { "LEFT_BRACKET", 71 },
- { "RIGHT_BRACKET", 72 },
- { "BACKSLASH", 73 },
- { "SEMICOLON", 74 },
- { "APOSTROPHE", 75 },
- { "SLASH", 76 },
- { "AT", 77 },
- { "NUM", 78 },
- { "HEADSETHOOK", 79 },
- { "FOCUS", 80 },
- { "PLUS", 81 },
- { "MENU", 82 },
- { "NOTIFICATION", 83 },
- { "SEARCH", 84 },
- { "MEDIA_PLAY_PAUSE", 85 },
- { "MEDIA_STOP", 86 },
- { "MEDIA_NEXT", 87 },
- { "MEDIA_PREVIOUS", 88 },
- { "MEDIA_REWIND", 89 },
- { "MEDIA_FAST_FORWARD", 90 },
- { "MUTE", 91 },
- { "PAGE_UP", 92 },
- { "PAGE_DOWN", 93 },
- { "PICTSYMBOLS", 94 },
- { "SWITCH_CHARSET", 95 },
- { "BUTTON_A", 96 },
- { "BUTTON_B", 97 },
- { "BUTTON_C", 98 },
- { "BUTTON_X", 99 },
- { "BUTTON_Y", 100 },
- { "BUTTON_Z", 101 },
- { "BUTTON_L1", 102 },
- { "BUTTON_R1", 103 },
- { "BUTTON_L2", 104 },
- { "BUTTON_R2", 105 },
- { "BUTTON_THUMBL", 106 },
- { "BUTTON_THUMBR", 107 },
- { "BUTTON_START", 108 },
- { "BUTTON_SELECT", 109 },
- { "BUTTON_MODE", 110 },
- { "ESCAPE", 111 },
- { "FORWARD_DEL", 112 },
- { "CTRL_LEFT", 113 },
- { "CTRL_RIGHT", 114 },
- { "CAPS_LOCK", 115 },
- { "SCROLL_LOCK", 116 },
- { "META_LEFT", 117 },
- { "META_RIGHT", 118 },
- { "FUNCTION", 119 },
- { "SYSRQ", 120 },
- { "BREAK", 121 },
- { "MOVE_HOME", 122 },
- { "MOVE_END", 123 },
- { "INSERT", 124 },
- { "FORWARD", 125 },
- { "MEDIA_PLAY", 126 },
- { "MEDIA_PAUSE", 127 },
- { "MEDIA_CLOSE", 128 },
- { "MEDIA_EJECT", 129 },
- { "MEDIA_RECORD", 130 },
- { "F1", 131 },
- { "F2", 132 },
- { "F3", 133 },
- { "F4", 134 },
- { "F5", 135 },
- { "F6", 136 },
- { "F7", 137 },
- { "F8", 138 },
- { "F9", 139 },
- { "F10", 140 },
- { "F11", 141 },
- { "F12", 142 },
- { "NUM_LOCK", 143 },
- { "NUMPAD_0", 144 },
- { "NUMPAD_1", 145 },
- { "NUMPAD_2", 146 },
- { "NUMPAD_3", 147 },
- { "NUMPAD_4", 148 },
- { "NUMPAD_5", 149 },
- { "NUMPAD_6", 150 },
- { "NUMPAD_7", 151 },
- { "NUMPAD_8", 152 },
- { "NUMPAD_9", 153 },
- { "NUMPAD_DIVIDE", 154 },
- { "NUMPAD_MULTIPLY", 155 },
- { "NUMPAD_SUBTRACT", 156 },
- { "NUMPAD_ADD", 157 },
- { "NUMPAD_DOT", 158 },
- { "NUMPAD_COMMA", 159 },
- { "NUMPAD_ENTER", 160 },
- { "NUMPAD_EQUALS", 161 },
- { "NUMPAD_LEFT_PAREN", 162 },
- { "NUMPAD_RIGHT_PAREN", 163 },
- { "VOLUME_MUTE", 164 },
- { "INFO", 165 },
- { "CHANNEL_UP", 166 },
- { "CHANNEL_DOWN", 167 },
- { "ZOOM_IN", 168 },
- { "ZOOM_OUT", 169 },
- { "TV", 170 },
- { "WINDOW", 171 },
- { "GUIDE", 172 },
- { "DVR", 173 },
- { "BOOKMARK", 174 },
- { "CAPTIONS", 175 },
- { "SETTINGS", 176 },
- { "TV_POWER", 177 },
- { "TV_INPUT", 178 },
- { "STB_POWER", 179 },
- { "STB_INPUT", 180 },
- { "AVR_POWER", 181 },
- { "AVR_INPUT", 182 },
- { "PROG_RED", 183 },
- { "PROG_GREEN", 184 },
- { "PROG_YELLOW", 185 },
- { "PROG_BLUE", 186 },
- { "APP_SWITCH", 187 },
- { "BUTTON_1", 188 },
- { "BUTTON_2", 189 },
- { "BUTTON_3", 190 },
- { "BUTTON_4", 191 },
- { "BUTTON_5", 192 },
- { "BUTTON_6", 193 },
- { "BUTTON_7", 194 },
- { "BUTTON_8", 195 },
- { "BUTTON_9", 196 },
- { "BUTTON_10", 197 },
- { "BUTTON_11", 198 },
- { "BUTTON_12", 199 },
- { "BUTTON_13", 200 },
- { "BUTTON_14", 201 },
- { "BUTTON_15", 202 },
- { "BUTTON_16", 203 },
- { "LANGUAGE_SWITCH", 204 },
- { "MANNER_MODE", 205 },
- { "3D_MODE", 206 },
- { "CONTACTS", 207 },
- { "CALENDAR", 208 },
- { "MUSIC", 209 },
- { "CALCULATOR", 210 },
- { "ZENKAKU_HANKAKU", 211 },
- { "EISU", 212 },
- { "MUHENKAN", 213 },
- { "HENKAN", 214 },
- { "KATAKANA_HIRAGANA", 215 },
- { "YEN", 216 },
- { "RO", 217 },
- { "KANA", 218 },
- { "ASSIST", 219 },
- { "BRIGHTNESS_DOWN", 220 },
- { "BRIGHTNESS_UP", 221 },
-
- // NOTE: If you add a new keycode here you must also add it to several other files.
- // Refer to frameworks/base/core/java/android/view/KeyEvent.java for the full list.
-
- { NULL, 0 }
-};
-
-// NOTE: If you edit these flags, also edit policy flags in Input.h.
-static const KeycodeLabel FLAGS[] = {
- { "WAKE", 0x00000001 },
- { "WAKE_DROPPED", 0x00000002 },
- { "SHIFT", 0x00000004 },
- { "CAPS_LOCK", 0x00000008 },
- { "ALT", 0x00000010 },
- { "ALT_GR", 0x00000020 },
- { "MENU", 0x00000040 },
- { "LAUNCHER", 0x00000080 },
- { "VIRTUAL", 0x00000100 },
- { "FUNCTION", 0x00000200 },
- { NULL, 0 }
-};
-
-static const KeycodeLabel AXES[] = {
- { "X", 0 },
- { "Y", 1 },
- { "PRESSURE", 2 },
- { "SIZE", 3 },
- { "TOUCH_MAJOR", 4 },
- { "TOUCH_MINOR", 5 },
- { "TOOL_MAJOR", 6 },
- { "TOOL_MINOR", 7 },
- { "ORIENTATION", 8 },
- { "VSCROLL", 9 },
- { "HSCROLL", 10 },
- { "Z", 11 },
- { "RX", 12 },
- { "RY", 13 },
- { "RZ", 14 },
- { "HAT_X", 15 },
- { "HAT_Y", 16 },
- { "LTRIGGER", 17 },
- { "RTRIGGER", 18 },
- { "THROTTLE", 19 },
- { "RUDDER", 20 },
- { "WHEEL", 21 },
- { "GAS", 22 },
- { "BRAKE", 23 },
- { "DISTANCE", 24 },
- { "TILT", 25 },
- { "GENERIC_1", 32 },
- { "GENERIC_2", 33 },
- { "GENERIC_3", 34 },
- { "GENERIC_4", 35 },
- { "GENERIC_5", 36 },
- { "GENERIC_6", 37 },
- { "GENERIC_7", 38 },
- { "GENERIC_8", 39 },
- { "GENERIC_9", 40 },
- { "GENERIC_10", 41 },
- { "GENERIC_11", 42 },
- { "GENERIC_12", 43 },
- { "GENERIC_13", 44 },
- { "GENERIC_14", 45 },
- { "GENERIC_15", 46 },
- { "GENERIC_16", 47 },
-
- // NOTE: If you add a new axis here you must also add it to several other files.
- // Refer to frameworks/base/core/java/android/view/MotionEvent.java for the full list.
-
- { NULL, -1 }
-};
-
-#endif // _ANDROIDFW_KEYCODE_LABELS_H
diff --git a/include/androidfw/ResourceTypes.h b/include/androidfw/ResourceTypes.h
index ccccc2e..a305fc3 100644
--- a/include/androidfw/ResourceTypes.h
+++ b/include/androidfw/ResourceTypes.h
@@ -1553,10 +1553,8 @@
static bool getIdmapInfo(const void* idmap, size_t size,
uint32_t* pOriginalCrc, uint32_t* pOverlayCrc);
-#ifdef STATIC_ANDROIDFW_FOR_TOOLS
void print(bool inclValues) const;
static String8 normalizeForOutput(const char* input);
-#endif
private:
struct Header;
diff --git a/include/androidfw/VelocityControl.h b/include/androidfw/VelocityControl.h
deleted file mode 100644
index 84e0444..0000000
--- a/include/androidfw/VelocityControl.h
+++ /dev/null
@@ -1,107 +0,0 @@
-/*
- * Copyright (C) 2012 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef _ANDROIDFW_VELOCITY_CONTROL_H
-#define _ANDROIDFW_VELOCITY_CONTROL_H
-
-#include <androidfw/Input.h>
-#include <androidfw/VelocityTracker.h>
-#include <utils/Timers.h>
-
-namespace android {
-
-/*
- * Specifies parameters that govern pointer or wheel acceleration.
- */
-struct VelocityControlParameters {
- // A scale factor that is multiplied with the raw velocity deltas
- // prior to applying any other velocity control factors. The scale
- // factor should be used to adapt the input device resolution
- // (eg. counts per inch) to the output device resolution (eg. pixels per inch).
- //
- // Must be a positive value.
- // Default is 1.0 (no scaling).
- float scale;
-
- // The scaled speed at which acceleration begins to be applied.
- // This value establishes the upper bound of a low speed regime for
- // small precise motions that are performed without any acceleration.
- //
- // Must be a non-negative value.
- // Default is 0.0 (no low threshold).
- float lowThreshold;
-
- // The scaled speed at which maximum acceleration is applied.
- // The difference between highThreshold and lowThreshold controls
- // the range of speeds over which the acceleration factor is interpolated.
- // The wider the range, the smoother the acceleration.
- //
- // Must be a non-negative value greater than or equal to lowThreshold.
- // Default is 0.0 (no high threshold).
- float highThreshold;
-
- // The acceleration factor.
- // When the speed is above the low speed threshold, the velocity will scaled
- // by an interpolated value between 1.0 and this amount.
- //
- // Must be a positive greater than or equal to 1.0.
- // Default is 1.0 (no acceleration).
- float acceleration;
-
- VelocityControlParameters() :
- scale(1.0f), lowThreshold(0.0f), highThreshold(0.0f), acceleration(1.0f) {
- }
-
- VelocityControlParameters(float scale, float lowThreshold,
- float highThreshold, float acceleration) :
- scale(scale), lowThreshold(lowThreshold),
- highThreshold(highThreshold), acceleration(acceleration) {
- }
-};
-
-/*
- * Implements mouse pointer and wheel speed control and acceleration.
- */
-class VelocityControl {
-public:
- VelocityControl();
-
- /* Sets the various parameters. */
- void setParameters(const VelocityControlParameters& parameters);
-
- /* Resets the current movement counters to zero.
- * This has the effect of nullifying any acceleration. */
- void reset();
-
- /* Translates a raw movement delta into an appropriately
- * scaled / accelerated delta based on the current velocity. */
- void move(nsecs_t eventTime, float* deltaX, float* deltaY);
-
-private:
- // If no movements are received within this amount of time,
- // we assume the movement has stopped and reset the movement counters.
- static const nsecs_t STOP_TIME = 500 * 1000000; // 500 ms
-
- VelocityControlParameters mParameters;
-
- nsecs_t mLastMovementTime;
- VelocityTracker::Position mRawPosition;
- VelocityTracker mVelocityTracker;
-};
-
-} // namespace android
-
-#endif // _ANDROIDFW_VELOCITY_CONTROL_H
diff --git a/include/androidfw/VelocityTracker.h b/include/androidfw/VelocityTracker.h
deleted file mode 100644
index 8c24219..0000000
--- a/include/androidfw/VelocityTracker.h
+++ /dev/null
@@ -1,269 +0,0 @@
-/*
- * Copyright (C) 2012 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef _ANDROIDFW_VELOCITY_TRACKER_H
-#define _ANDROIDFW_VELOCITY_TRACKER_H
-
-#include <androidfw/Input.h>
-#include <utils/Timers.h>
-#include <utils/BitSet.h>
-
-namespace android {
-
-class VelocityTrackerStrategy;
-
-/*
- * Calculates the velocity of pointer movements over time.
- */
-class VelocityTracker {
-public:
- struct Position {
- float x, y;
- };
-
- struct Estimator {
- static const size_t MAX_DEGREE = 4;
-
- // Estimator time base.
- nsecs_t time;
-
- // Polynomial coefficients describing motion in X and Y.
- float xCoeff[MAX_DEGREE + 1], yCoeff[MAX_DEGREE + 1];
-
- // Polynomial degree (number of coefficients), or zero if no information is
- // available.
- uint32_t degree;
-
- // Confidence (coefficient of determination), between 0 (no fit) and 1 (perfect fit).
- float confidence;
-
- inline void clear() {
- time = 0;
- degree = 0;
- confidence = 0;
- for (size_t i = 0; i <= MAX_DEGREE; i++) {
- xCoeff[i] = 0;
- yCoeff[i] = 0;
- }
- }
- };
-
- // Creates a velocity tracker using the specified strategy.
- // If strategy is NULL, uses the default strategy for the platform.
- VelocityTracker(const char* strategy = NULL);
-
- ~VelocityTracker();
-
- // Resets the velocity tracker state.
- void clear();
-
- // Resets the velocity tracker state for specific pointers.
- // Call this method when some pointers have changed and may be reusing
- // an id that was assigned to a different pointer earlier.
- void clearPointers(BitSet32 idBits);
-
- // Adds movement information for a set of pointers.
- // The idBits bitfield specifies the pointer ids of the pointers whose positions
- // are included in the movement.
- // The positions array contains position information for each pointer in order by
- // increasing id. Its size should be equal to the number of one bits in idBits.
- void addMovement(nsecs_t eventTime, BitSet32 idBits, const Position* positions);
-
- // Adds movement information for all pointers in a MotionEvent, including historical samples.
- void addMovement(const MotionEvent* event);
-
- // Gets the velocity of the specified pointer id in position units per second.
- // Returns false and sets the velocity components to zero if there is
- // insufficient movement information for the pointer.
- bool getVelocity(uint32_t id, float* outVx, float* outVy) const;
-
- // Gets an estimator for the recent movements of the specified pointer id.
- // Returns false and clears the estimator if there is no information available
- // about the pointer.
- bool getEstimator(uint32_t id, Estimator* outEstimator) const;
-
- // Gets the active pointer id, or -1 if none.
- inline int32_t getActivePointerId() const { return mActivePointerId; }
-
- // Gets a bitset containing all pointer ids from the most recent movement.
- inline BitSet32 getCurrentPointerIdBits() const { return mCurrentPointerIdBits; }
-
-private:
- static const char* DEFAULT_STRATEGY;
-
- nsecs_t mLastEventTime;
- BitSet32 mCurrentPointerIdBits;
- int32_t mActivePointerId;
- VelocityTrackerStrategy* mStrategy;
-
- bool configureStrategy(const char* strategy);
-
- static VelocityTrackerStrategy* createStrategy(const char* strategy);
-};
-
-
-/*
- * Implements a particular velocity tracker algorithm.
- */
-class VelocityTrackerStrategy {
-protected:
- VelocityTrackerStrategy() { }
-
-public:
- virtual ~VelocityTrackerStrategy() { }
-
- virtual void clear() = 0;
- virtual void clearPointers(BitSet32 idBits) = 0;
- virtual void addMovement(nsecs_t eventTime, BitSet32 idBits,
- const VelocityTracker::Position* positions) = 0;
- virtual bool getEstimator(uint32_t id, VelocityTracker::Estimator* outEstimator) const = 0;
-};
-
-
-/*
- * Velocity tracker algorithm based on least-squares linear regression.
- */
-class LeastSquaresVelocityTrackerStrategy : public VelocityTrackerStrategy {
-public:
- enum Weighting {
- // No weights applied. All data points are equally reliable.
- WEIGHTING_NONE,
-
- // Weight by time delta. Data points clustered together are weighted less.
- WEIGHTING_DELTA,
-
- // Weight such that points within a certain horizon are weighed more than those
- // outside of that horizon.
- WEIGHTING_CENTRAL,
-
- // Weight such that points older than a certain amount are weighed less.
- WEIGHTING_RECENT,
- };
-
- // Degree must be no greater than Estimator::MAX_DEGREE.
- LeastSquaresVelocityTrackerStrategy(uint32_t degree, Weighting weighting = WEIGHTING_NONE);
- virtual ~LeastSquaresVelocityTrackerStrategy();
-
- virtual void clear();
- virtual void clearPointers(BitSet32 idBits);
- virtual void addMovement(nsecs_t eventTime, BitSet32 idBits,
- const VelocityTracker::Position* positions);
- virtual bool getEstimator(uint32_t id, VelocityTracker::Estimator* outEstimator) const;
-
-private:
- // Sample horizon.
- // We don't use too much history by default since we want to react to quick
- // changes in direction.
- static const nsecs_t HORIZON = 100 * 1000000; // 100 ms
-
- // Number of samples to keep.
- static const uint32_t HISTORY_SIZE = 20;
-
- struct Movement {
- nsecs_t eventTime;
- BitSet32 idBits;
- VelocityTracker::Position positions[MAX_POINTERS];
-
- inline const VelocityTracker::Position& getPosition(uint32_t id) const {
- return positions[idBits.getIndexOfBit(id)];
- }
- };
-
- float chooseWeight(uint32_t index) const;
-
- const uint32_t mDegree;
- const Weighting mWeighting;
- uint32_t mIndex;
- Movement mMovements[HISTORY_SIZE];
-};
-
-
-/*
- * Velocity tracker algorithm that uses an IIR filter.
- */
-class IntegratingVelocityTrackerStrategy : public VelocityTrackerStrategy {
-public:
- // Degree must be 1 or 2.
- IntegratingVelocityTrackerStrategy(uint32_t degree);
- ~IntegratingVelocityTrackerStrategy();
-
- virtual void clear();
- virtual void clearPointers(BitSet32 idBits);
- virtual void addMovement(nsecs_t eventTime, BitSet32 idBits,
- const VelocityTracker::Position* positions);
- virtual bool getEstimator(uint32_t id, VelocityTracker::Estimator* outEstimator) const;
-
-private:
- // Current state estimate for a particular pointer.
- struct State {
- nsecs_t updateTime;
- uint32_t degree;
-
- float xpos, xvel, xaccel;
- float ypos, yvel, yaccel;
- };
-
- const uint32_t mDegree;
- BitSet32 mPointerIdBits;
- State mPointerState[MAX_POINTER_ID + 1];
-
- void initState(State& state, nsecs_t eventTime, float xpos, float ypos) const;
- void updateState(State& state, nsecs_t eventTime, float xpos, float ypos) const;
- void populateEstimator(const State& state, VelocityTracker::Estimator* outEstimator) const;
-};
-
-
-/*
- * Velocity tracker strategy used prior to ICS.
- */
-class LegacyVelocityTrackerStrategy : public VelocityTrackerStrategy {
-public:
- LegacyVelocityTrackerStrategy();
- virtual ~LegacyVelocityTrackerStrategy();
-
- virtual void clear();
- virtual void clearPointers(BitSet32 idBits);
- virtual void addMovement(nsecs_t eventTime, BitSet32 idBits,
- const VelocityTracker::Position* positions);
- virtual bool getEstimator(uint32_t id, VelocityTracker::Estimator* outEstimator) const;
-
-private:
- // Oldest sample to consider when calculating the velocity.
- static const nsecs_t HORIZON = 200 * 1000000; // 100 ms
-
- // Number of samples to keep.
- static const uint32_t HISTORY_SIZE = 20;
-
- // The minimum duration between samples when estimating velocity.
- static const nsecs_t MIN_DURATION = 10 * 1000000; // 10 ms
-
- struct Movement {
- nsecs_t eventTime;
- BitSet32 idBits;
- VelocityTracker::Position positions[MAX_POINTERS];
-
- inline const VelocityTracker::Position& getPosition(uint32_t id) const {
- return positions[idBits.getIndexOfBit(id)];
- }
- };
-
- uint32_t mIndex;
- Movement mMovements[HISTORY_SIZE];
-};
-
-} // namespace android
-
-#endif // _ANDROIDFW_VELOCITY_TRACKER_H
diff --git a/include/androidfw/VirtualKeyMap.h b/include/androidfw/VirtualKeyMap.h
deleted file mode 100644
index dd3ad1e9..0000000
--- a/include/androidfw/VirtualKeyMap.h
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- * Copyright (C) 2010 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef _ANDROIDFW_VIRTUAL_KEY_MAP_H
-#define _ANDROIDFW_VIRTUAL_KEY_MAP_H
-
-#include <stdint.h>
-
-#include <androidfw/Input.h>
-#include <utils/Errors.h>
-#include <utils/KeyedVector.h>
-#include <utils/Tokenizer.h>
-#include <utils/String8.h>
-#include <utils/Unicode.h>
-
-namespace android {
-
-/* Describes a virtual key. */
-struct VirtualKeyDefinition {
- int32_t scanCode;
-
- // configured position data, specified in display coords
- int32_t centerX;
- int32_t centerY;
- int32_t width;
- int32_t height;
-};
-
-
-/**
- * Describes a collection of virtual keys on a touch screen in terms of
- * virtual scan codes and hit rectangles.
- *
- * This object is immutable after it has been loaded.
- */
-class VirtualKeyMap {
-public:
- ~VirtualKeyMap();
-
- static status_t load(const String8& filename, VirtualKeyMap** outMap);
-
- inline const Vector<VirtualKeyDefinition>& getVirtualKeys() const {
- return mVirtualKeys;
- }
-
-private:
- class Parser {
- VirtualKeyMap* mMap;
- Tokenizer* mTokenizer;
-
- public:
- Parser(VirtualKeyMap* map, Tokenizer* tokenizer);
- ~Parser();
- status_t parse();
-
- private:
- bool consumeFieldDelimiterAndSkipWhitespace();
- bool parseNextIntField(int32_t* outValue);
- };
-
- Vector<VirtualKeyDefinition> mVirtualKeys;
-
- VirtualKeyMap();
-};
-
-} // namespace android
-
-#endif // _ANDROIDFW_KEY_CHARACTER_MAP_H
diff --git a/libs/androidfw/Android.mk b/libs/androidfw/Android.mk
index c06b144..4e126b8 100644
--- a/libs/androidfw/Android.mk
+++ b/libs/androidfw/Android.mk
@@ -14,11 +14,10 @@
LOCAL_PATH:= $(call my-dir)
-# libandroidfw is partially built for the host (used by build time keymap validation tool)
+# libandroidfw is partially built for the host (used by obbtool and others)
# These files are common to host and target builds.
-# formerly in libutils
-commonUtilsSources:= \
+commonSources := \
Asset.cpp \
AssetDir.cpp \
AssetManager.cpp \
@@ -30,26 +29,21 @@
ZipFileRO.cpp \
ZipUtils.cpp
-# formerly in libui
-commonUiSources:= \
- Input.cpp \
- InputDevice.cpp \
- Keyboard.cpp \
- KeyCharacterMap.cpp \
- KeyLayoutMap.cpp \
- VelocityControl.cpp \
- VirtualKeyMap.cpp
+deviceSources := \
+ $(commonSources) \
+ BackupData.cpp \
+ BackupHelpers.cpp \
+ CursorWindow.cpp
-commonSources:= \
- $(commonUtilsSources) \
- $(commonUiSources)
+hostSources := \
+ $(commonSources)
# For the host
# =====================================================
include $(CLEAR_VARS)
-LOCAL_SRC_FILES:= $(commonSources)
+LOCAL_SRC_FILES:= $(hostSources)
LOCAL_MODULE:= libandroidfw
@@ -68,24 +62,16 @@
include $(CLEAR_VARS)
-LOCAL_SRC_FILES:= \
- $(commonSources) \
- BackupData.cpp \
- BackupHelpers.cpp \
- CursorWindow.cpp \
- InputTransport.cpp \
- VelocityTracker.cpp
+LOCAL_SRC_FILES:= $(deviceSources)
LOCAL_SHARED_LIBRARIES := \
+ libbinder \
liblog \
libcutils \
libutils \
- libbinder \
- libskia \
libz
LOCAL_C_INCLUDES := \
- external/skia/include/core \
external/icu4c/common \
external/zlib
@@ -96,21 +82,6 @@
include $(BUILD_SHARED_LIBRARY)
-ifeq ($(TARGET_OS),linux)
-include $(CLEAR_VARS)
-LOCAL_CFLAGS += -DSTATIC_ANDROIDFW_FOR_TOOLS
-LOCAL_C_INCLUDES += \
- external/skia/include/core \
- external/zlib \
- external/icu4c/common \
- bionic/libc/private
-LOCAL_LDLIBS := -lrt -ldl -lpthread
-LOCAL_MODULE := libandroidfw
-LOCAL_SRC_FILES := $(commonUtilsSources) BackupData.cpp BackupHelpers.cpp
-include $(BUILD_STATIC_LIBRARY)
-endif
-
-
# Include subdirectory makefiles
# ============================================================
diff --git a/libs/androidfw/CursorWindow.cpp b/libs/androidfw/CursorWindow.cpp
index 047a4c8..0f54edb 100644
--- a/libs/androidfw/CursorWindow.cpp
+++ b/libs/androidfw/CursorWindow.cpp
@@ -17,8 +17,9 @@
#undef LOG_TAG
#define LOG_TAG "CursorWindow"
-#include <utils/Log.h>
#include <androidfw/CursorWindow.h>
+#include <binder/Parcel.h>
+#include <utils/Log.h>
#include <cutils/ashmem.h>
#include <sys/mman.h>
diff --git a/libs/androidfw/Input.cpp b/libs/androidfw/Input.cpp
deleted file mode 100644
index eca692a..0000000
--- a/libs/androidfw/Input.cpp
+++ /dev/null
@@ -1,634 +0,0 @@
-/*
- * Copyright (C) 2010 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#define LOG_TAG "Input"
-//#define LOG_NDEBUG 0
-
-#include <math.h>
-#include <limits.h>
-
-#include <androidfw/Input.h>
-
-#ifdef HAVE_ANDROID_OS
-#include <binder/Parcel.h>
-
-#include "SkPoint.h"
-#include "SkMatrix.h"
-#include "SkScalar.h"
-#endif
-
-namespace android {
-
-// --- InputEvent ---
-
-void InputEvent::initialize(int32_t deviceId, int32_t source) {
- mDeviceId = deviceId;
- mSource = source;
-}
-
-void InputEvent::initialize(const InputEvent& from) {
- mDeviceId = from.mDeviceId;
- mSource = from.mSource;
-}
-
-// --- KeyEvent ---
-
-bool KeyEvent::hasDefaultAction(int32_t keyCode) {
- switch (keyCode) {
- case AKEYCODE_HOME:
- case AKEYCODE_BACK:
- case AKEYCODE_CALL:
- case AKEYCODE_ENDCALL:
- case AKEYCODE_VOLUME_UP:
- case AKEYCODE_VOLUME_DOWN:
- case AKEYCODE_VOLUME_MUTE:
- case AKEYCODE_POWER:
- case AKEYCODE_CAMERA:
- case AKEYCODE_HEADSETHOOK:
- case AKEYCODE_MENU:
- case AKEYCODE_NOTIFICATION:
- case AKEYCODE_FOCUS:
- case AKEYCODE_SEARCH:
- case AKEYCODE_MEDIA_PLAY:
- case AKEYCODE_MEDIA_PAUSE:
- case AKEYCODE_MEDIA_PLAY_PAUSE:
- case AKEYCODE_MEDIA_STOP:
- case AKEYCODE_MEDIA_NEXT:
- case AKEYCODE_MEDIA_PREVIOUS:
- case AKEYCODE_MEDIA_REWIND:
- case AKEYCODE_MEDIA_RECORD:
- case AKEYCODE_MEDIA_FAST_FORWARD:
- case AKEYCODE_MUTE:
- case AKEYCODE_BRIGHTNESS_DOWN:
- case AKEYCODE_BRIGHTNESS_UP:
- return true;
- }
-
- return false;
-}
-
-bool KeyEvent::hasDefaultAction() const {
- return hasDefaultAction(getKeyCode());
-}
-
-bool KeyEvent::isSystemKey(int32_t keyCode) {
- switch (keyCode) {
- case AKEYCODE_MENU:
- case AKEYCODE_SOFT_RIGHT:
- case AKEYCODE_HOME:
- case AKEYCODE_BACK:
- case AKEYCODE_CALL:
- case AKEYCODE_ENDCALL:
- case AKEYCODE_VOLUME_UP:
- case AKEYCODE_VOLUME_DOWN:
- case AKEYCODE_VOLUME_MUTE:
- case AKEYCODE_MUTE:
- case AKEYCODE_POWER:
- case AKEYCODE_HEADSETHOOK:
- case AKEYCODE_MEDIA_PLAY:
- case AKEYCODE_MEDIA_PAUSE:
- case AKEYCODE_MEDIA_PLAY_PAUSE:
- case AKEYCODE_MEDIA_STOP:
- case AKEYCODE_MEDIA_NEXT:
- case AKEYCODE_MEDIA_PREVIOUS:
- case AKEYCODE_MEDIA_REWIND:
- case AKEYCODE_MEDIA_RECORD:
- case AKEYCODE_MEDIA_FAST_FORWARD:
- case AKEYCODE_CAMERA:
- case AKEYCODE_FOCUS:
- case AKEYCODE_SEARCH:
- case AKEYCODE_BRIGHTNESS_DOWN:
- case AKEYCODE_BRIGHTNESS_UP:
- return true;
- }
-
- return false;
-}
-
-bool KeyEvent::isSystemKey() const {
- return isSystemKey(getKeyCode());
-}
-
-void KeyEvent::initialize(
- int32_t deviceId,
- int32_t source,
- int32_t action,
- int32_t flags,
- int32_t keyCode,
- int32_t scanCode,
- int32_t metaState,
- int32_t repeatCount,
- nsecs_t downTime,
- nsecs_t eventTime) {
- InputEvent::initialize(deviceId, source);
- mAction = action;
- mFlags = flags;
- mKeyCode = keyCode;
- mScanCode = scanCode;
- mMetaState = metaState;
- mRepeatCount = repeatCount;
- mDownTime = downTime;
- mEventTime = eventTime;
-}
-
-void KeyEvent::initialize(const KeyEvent& from) {
- InputEvent::initialize(from);
- mAction = from.mAction;
- mFlags = from.mFlags;
- mKeyCode = from.mKeyCode;
- mScanCode = from.mScanCode;
- mMetaState = from.mMetaState;
- mRepeatCount = from.mRepeatCount;
- mDownTime = from.mDownTime;
- mEventTime = from.mEventTime;
-}
-
-
-// --- PointerCoords ---
-
-float PointerCoords::getAxisValue(int32_t axis) const {
- if (axis < 0 || axis > 63) {
- return 0;
- }
-
- uint64_t axisBit = 1LL << axis;
- if (!(bits & axisBit)) {
- return 0;
- }
- uint32_t index = __builtin_popcountll(bits & (axisBit - 1LL));
- return values[index];
-}
-
-status_t PointerCoords::setAxisValue(int32_t axis, float value) {
- if (axis < 0 || axis > 63) {
- return NAME_NOT_FOUND;
- }
-
- uint64_t axisBit = 1LL << axis;
- uint32_t index = __builtin_popcountll(bits & (axisBit - 1LL));
- if (!(bits & axisBit)) {
- if (value == 0) {
- return OK; // axes with value 0 do not need to be stored
- }
- uint32_t count = __builtin_popcountll(bits);
- if (count >= MAX_AXES) {
- tooManyAxes(axis);
- return NO_MEMORY;
- }
- bits |= axisBit;
- for (uint32_t i = count; i > index; i--) {
- values[i] = values[i - 1];
- }
- }
- values[index] = value;
- return OK;
-}
-
-static inline void scaleAxisValue(PointerCoords& c, int axis, float scaleFactor) {
- float value = c.getAxisValue(axis);
- if (value != 0) {
- c.setAxisValue(axis, value * scaleFactor);
- }
-}
-
-void PointerCoords::scale(float scaleFactor) {
- // No need to scale pressure or size since they are normalized.
- // No need to scale orientation since it is meaningless to do so.
- scaleAxisValue(*this, AMOTION_EVENT_AXIS_X, scaleFactor);
- scaleAxisValue(*this, AMOTION_EVENT_AXIS_Y, scaleFactor);
- scaleAxisValue(*this, AMOTION_EVENT_AXIS_TOUCH_MAJOR, scaleFactor);
- scaleAxisValue(*this, AMOTION_EVENT_AXIS_TOUCH_MINOR, scaleFactor);
- scaleAxisValue(*this, AMOTION_EVENT_AXIS_TOOL_MAJOR, scaleFactor);
- scaleAxisValue(*this, AMOTION_EVENT_AXIS_TOOL_MINOR, scaleFactor);
-}
-
-#ifdef HAVE_ANDROID_OS
-status_t PointerCoords::readFromParcel(Parcel* parcel) {
- bits = parcel->readInt64();
-
- uint32_t count = __builtin_popcountll(bits);
- if (count > MAX_AXES) {
- return BAD_VALUE;
- }
-
- for (uint32_t i = 0; i < count; i++) {
- values[i] = parcel->readFloat();
- }
- return OK;
-}
-
-status_t PointerCoords::writeToParcel(Parcel* parcel) const {
- parcel->writeInt64(bits);
-
- uint32_t count = __builtin_popcountll(bits);
- for (uint32_t i = 0; i < count; i++) {
- parcel->writeFloat(values[i]);
- }
- return OK;
-}
-#endif
-
-void PointerCoords::tooManyAxes(int axis) {
- ALOGW("Could not set value for axis %d because the PointerCoords structure is full and "
- "cannot contain more than %d axis values.", axis, int(MAX_AXES));
-}
-
-bool PointerCoords::operator==(const PointerCoords& other) const {
- if (bits != other.bits) {
- return false;
- }
- uint32_t count = __builtin_popcountll(bits);
- for (uint32_t i = 0; i < count; i++) {
- if (values[i] != other.values[i]) {
- return false;
- }
- }
- return true;
-}
-
-void PointerCoords::copyFrom(const PointerCoords& other) {
- bits = other.bits;
- uint32_t count = __builtin_popcountll(bits);
- for (uint32_t i = 0; i < count; i++) {
- values[i] = other.values[i];
- }
-}
-
-
-// --- PointerProperties ---
-
-bool PointerProperties::operator==(const PointerProperties& other) const {
- return id == other.id
- && toolType == other.toolType;
-}
-
-void PointerProperties::copyFrom(const PointerProperties& other) {
- id = other.id;
- toolType = other.toolType;
-}
-
-
-// --- MotionEvent ---
-
-void MotionEvent::initialize(
- int32_t deviceId,
- int32_t source,
- int32_t action,
- int32_t flags,
- int32_t edgeFlags,
- int32_t metaState,
- int32_t buttonState,
- float xOffset,
- float yOffset,
- float xPrecision,
- float yPrecision,
- nsecs_t downTime,
- nsecs_t eventTime,
- size_t pointerCount,
- const PointerProperties* pointerProperties,
- const PointerCoords* pointerCoords) {
- InputEvent::initialize(deviceId, source);
- mAction = action;
- mFlags = flags;
- mEdgeFlags = edgeFlags;
- mMetaState = metaState;
- mButtonState = buttonState;
- mXOffset = xOffset;
- mYOffset = yOffset;
- mXPrecision = xPrecision;
- mYPrecision = yPrecision;
- mDownTime = downTime;
- mPointerProperties.clear();
- mPointerProperties.appendArray(pointerProperties, pointerCount);
- mSampleEventTimes.clear();
- mSamplePointerCoords.clear();
- addSample(eventTime, pointerCoords);
-}
-
-void MotionEvent::copyFrom(const MotionEvent* other, bool keepHistory) {
- InputEvent::initialize(other->mDeviceId, other->mSource);
- mAction = other->mAction;
- mFlags = other->mFlags;
- mEdgeFlags = other->mEdgeFlags;
- mMetaState = other->mMetaState;
- mButtonState = other->mButtonState;
- mXOffset = other->mXOffset;
- mYOffset = other->mYOffset;
- mXPrecision = other->mXPrecision;
- mYPrecision = other->mYPrecision;
- mDownTime = other->mDownTime;
- mPointerProperties = other->mPointerProperties;
-
- if (keepHistory) {
- mSampleEventTimes = other->mSampleEventTimes;
- mSamplePointerCoords = other->mSamplePointerCoords;
- } else {
- mSampleEventTimes.clear();
- mSampleEventTimes.push(other->getEventTime());
- mSamplePointerCoords.clear();
- size_t pointerCount = other->getPointerCount();
- size_t historySize = other->getHistorySize();
- mSamplePointerCoords.appendArray(other->mSamplePointerCoords.array()
- + (historySize * pointerCount), pointerCount);
- }
-}
-
-void MotionEvent::addSample(
- int64_t eventTime,
- const PointerCoords* pointerCoords) {
- mSampleEventTimes.push(eventTime);
- mSamplePointerCoords.appendArray(pointerCoords, getPointerCount());
-}
-
-const PointerCoords* MotionEvent::getRawPointerCoords(size_t pointerIndex) const {
- return &mSamplePointerCoords[getHistorySize() * getPointerCount() + pointerIndex];
-}
-
-float MotionEvent::getRawAxisValue(int32_t axis, size_t pointerIndex) const {
- return getRawPointerCoords(pointerIndex)->getAxisValue(axis);
-}
-
-float MotionEvent::getAxisValue(int32_t axis, size_t pointerIndex) const {
- float value = getRawPointerCoords(pointerIndex)->getAxisValue(axis);
- switch (axis) {
- case AMOTION_EVENT_AXIS_X:
- return value + mXOffset;
- case AMOTION_EVENT_AXIS_Y:
- return value + mYOffset;
- }
- return value;
-}
-
-const PointerCoords* MotionEvent::getHistoricalRawPointerCoords(
- size_t pointerIndex, size_t historicalIndex) const {
- return &mSamplePointerCoords[historicalIndex * getPointerCount() + pointerIndex];
-}
-
-float MotionEvent::getHistoricalRawAxisValue(int32_t axis, size_t pointerIndex,
- size_t historicalIndex) const {
- return getHistoricalRawPointerCoords(pointerIndex, historicalIndex)->getAxisValue(axis);
-}
-
-float MotionEvent::getHistoricalAxisValue(int32_t axis, size_t pointerIndex,
- size_t historicalIndex) const {
- float value = getHistoricalRawPointerCoords(pointerIndex, historicalIndex)->getAxisValue(axis);
- switch (axis) {
- case AMOTION_EVENT_AXIS_X:
- return value + mXOffset;
- case AMOTION_EVENT_AXIS_Y:
- return value + mYOffset;
- }
- return value;
-}
-
-ssize_t MotionEvent::findPointerIndex(int32_t pointerId) const {
- size_t pointerCount = mPointerProperties.size();
- for (size_t i = 0; i < pointerCount; i++) {
- if (mPointerProperties.itemAt(i).id == pointerId) {
- return i;
- }
- }
- return -1;
-}
-
-void MotionEvent::offsetLocation(float xOffset, float yOffset) {
- mXOffset += xOffset;
- mYOffset += yOffset;
-}
-
-void MotionEvent::scale(float scaleFactor) {
- mXOffset *= scaleFactor;
- mYOffset *= scaleFactor;
- mXPrecision *= scaleFactor;
- mYPrecision *= scaleFactor;
-
- size_t numSamples = mSamplePointerCoords.size();
- for (size_t i = 0; i < numSamples; i++) {
- mSamplePointerCoords.editItemAt(i).scale(scaleFactor);
- }
-}
-
-#ifdef HAVE_ANDROID_OS
-static inline float transformAngle(const SkMatrix* matrix, float angleRadians) {
- // Construct and transform a vector oriented at the specified clockwise angle from vertical.
- // Coordinate system: down is increasing Y, right is increasing X.
- SkPoint vector;
- vector.fX = SkFloatToScalar(sinf(angleRadians));
- vector.fY = SkFloatToScalar(-cosf(angleRadians));
- matrix->mapVectors(& vector, 1);
-
- // Derive the transformed vector's clockwise angle from vertical.
- float result = atan2f(SkScalarToFloat(vector.fX), SkScalarToFloat(-vector.fY));
- if (result < - M_PI_2) {
- result += M_PI;
- } else if (result > M_PI_2) {
- result -= M_PI;
- }
- return result;
-}
-
-void MotionEvent::transform(const SkMatrix* matrix) {
- float oldXOffset = mXOffset;
- float oldYOffset = mYOffset;
-
- // The tricky part of this implementation is to preserve the value of
- // rawX and rawY. So we apply the transformation to the first point
- // then derive an appropriate new X/Y offset that will preserve rawX and rawY.
- SkPoint point;
- float rawX = getRawX(0);
- float rawY = getRawY(0);
- matrix->mapXY(SkFloatToScalar(rawX + oldXOffset), SkFloatToScalar(rawY + oldYOffset),
- & point);
- float newX = SkScalarToFloat(point.fX);
- float newY = SkScalarToFloat(point.fY);
- float newXOffset = newX - rawX;
- float newYOffset = newY - rawY;
-
- mXOffset = newXOffset;
- mYOffset = newYOffset;
-
- // Apply the transformation to all samples.
- size_t numSamples = mSamplePointerCoords.size();
- for (size_t i = 0; i < numSamples; i++) {
- PointerCoords& c = mSamplePointerCoords.editItemAt(i);
- float x = c.getAxisValue(AMOTION_EVENT_AXIS_X) + oldXOffset;
- float y = c.getAxisValue(AMOTION_EVENT_AXIS_Y) + oldYOffset;
- matrix->mapXY(SkFloatToScalar(x), SkFloatToScalar(y), &point);
- c.setAxisValue(AMOTION_EVENT_AXIS_X, SkScalarToFloat(point.fX) - newXOffset);
- c.setAxisValue(AMOTION_EVENT_AXIS_Y, SkScalarToFloat(point.fY) - newYOffset);
-
- float orientation = c.getAxisValue(AMOTION_EVENT_AXIS_ORIENTATION);
- c.setAxisValue(AMOTION_EVENT_AXIS_ORIENTATION, transformAngle(matrix, orientation));
- }
-}
-
-status_t MotionEvent::readFromParcel(Parcel* parcel) {
- size_t pointerCount = parcel->readInt32();
- size_t sampleCount = parcel->readInt32();
- if (pointerCount == 0 || pointerCount > MAX_POINTERS || sampleCount == 0) {
- return BAD_VALUE;
- }
-
- mDeviceId = parcel->readInt32();
- mSource = parcel->readInt32();
- mAction = parcel->readInt32();
- mFlags = parcel->readInt32();
- mEdgeFlags = parcel->readInt32();
- mMetaState = parcel->readInt32();
- mButtonState = parcel->readInt32();
- mXOffset = parcel->readFloat();
- mYOffset = parcel->readFloat();
- mXPrecision = parcel->readFloat();
- mYPrecision = parcel->readFloat();
- mDownTime = parcel->readInt64();
-
- mPointerProperties.clear();
- mPointerProperties.setCapacity(pointerCount);
- mSampleEventTimes.clear();
- mSampleEventTimes.setCapacity(sampleCount);
- mSamplePointerCoords.clear();
- mSamplePointerCoords.setCapacity(sampleCount * pointerCount);
-
- for (size_t i = 0; i < pointerCount; i++) {
- mPointerProperties.push();
- PointerProperties& properties = mPointerProperties.editTop();
- properties.id = parcel->readInt32();
- properties.toolType = parcel->readInt32();
- }
-
- while (sampleCount-- > 0) {
- mSampleEventTimes.push(parcel->readInt64());
- for (size_t i = 0; i < pointerCount; i++) {
- mSamplePointerCoords.push();
- status_t status = mSamplePointerCoords.editTop().readFromParcel(parcel);
- if (status) {
- return status;
- }
- }
- }
- return OK;
-}
-
-status_t MotionEvent::writeToParcel(Parcel* parcel) const {
- size_t pointerCount = mPointerProperties.size();
- size_t sampleCount = mSampleEventTimes.size();
-
- parcel->writeInt32(pointerCount);
- parcel->writeInt32(sampleCount);
-
- parcel->writeInt32(mDeviceId);
- parcel->writeInt32(mSource);
- parcel->writeInt32(mAction);
- parcel->writeInt32(mFlags);
- parcel->writeInt32(mEdgeFlags);
- parcel->writeInt32(mMetaState);
- parcel->writeInt32(mButtonState);
- parcel->writeFloat(mXOffset);
- parcel->writeFloat(mYOffset);
- parcel->writeFloat(mXPrecision);
- parcel->writeFloat(mYPrecision);
- parcel->writeInt64(mDownTime);
-
- for (size_t i = 0; i < pointerCount; i++) {
- const PointerProperties& properties = mPointerProperties.itemAt(i);
- parcel->writeInt32(properties.id);
- parcel->writeInt32(properties.toolType);
- }
-
- const PointerCoords* pc = mSamplePointerCoords.array();
- for (size_t h = 0; h < sampleCount; h++) {
- parcel->writeInt64(mSampleEventTimes.itemAt(h));
- for (size_t i = 0; i < pointerCount; i++) {
- status_t status = (pc++)->writeToParcel(parcel);
- if (status) {
- return status;
- }
- }
- }
- return OK;
-}
-#endif
-
-bool MotionEvent::isTouchEvent(int32_t source, int32_t action) {
- if (source & AINPUT_SOURCE_CLASS_POINTER) {
- // Specifically excludes HOVER_MOVE and SCROLL.
- switch (action & AMOTION_EVENT_ACTION_MASK) {
- case AMOTION_EVENT_ACTION_DOWN:
- case AMOTION_EVENT_ACTION_MOVE:
- case AMOTION_EVENT_ACTION_UP:
- case AMOTION_EVENT_ACTION_POINTER_DOWN:
- case AMOTION_EVENT_ACTION_POINTER_UP:
- case AMOTION_EVENT_ACTION_CANCEL:
- case AMOTION_EVENT_ACTION_OUTSIDE:
- return true;
- }
- }
- return false;
-}
-
-
-// --- PooledInputEventFactory ---
-
-PooledInputEventFactory::PooledInputEventFactory(size_t maxPoolSize) :
- mMaxPoolSize(maxPoolSize) {
-}
-
-PooledInputEventFactory::~PooledInputEventFactory() {
- for (size_t i = 0; i < mKeyEventPool.size(); i++) {
- delete mKeyEventPool.itemAt(i);
- }
- for (size_t i = 0; i < mMotionEventPool.size(); i++) {
- delete mMotionEventPool.itemAt(i);
- }
-}
-
-KeyEvent* PooledInputEventFactory::createKeyEvent() {
- if (!mKeyEventPool.isEmpty()) {
- KeyEvent* event = mKeyEventPool.top();
- mKeyEventPool.pop();
- return event;
- }
- return new KeyEvent();
-}
-
-MotionEvent* PooledInputEventFactory::createMotionEvent() {
- if (!mMotionEventPool.isEmpty()) {
- MotionEvent* event = mMotionEventPool.top();
- mMotionEventPool.pop();
- return event;
- }
- return new MotionEvent();
-}
-
-void PooledInputEventFactory::recycle(InputEvent* event) {
- switch (event->getType()) {
- case AINPUT_EVENT_TYPE_KEY:
- if (mKeyEventPool.size() < mMaxPoolSize) {
- mKeyEventPool.push(static_cast<KeyEvent*>(event));
- return;
- }
- break;
- case AINPUT_EVENT_TYPE_MOTION:
- if (mMotionEventPool.size() < mMaxPoolSize) {
- mMotionEventPool.push(static_cast<MotionEvent*>(event));
- return;
- }
- break;
- }
- delete event;
-}
-
-} // namespace android
diff --git a/libs/androidfw/InputDevice.cpp b/libs/androidfw/InputDevice.cpp
deleted file mode 100644
index f742052..0000000
--- a/libs/androidfw/InputDevice.cpp
+++ /dev/null
@@ -1,184 +0,0 @@
-/*
- * Copyright (C) 2012 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#define LOG_TAG "InputDevice"
-
-#include <stdlib.h>
-#include <unistd.h>
-#include <ctype.h>
-
-#include <androidfw/InputDevice.h>
-
-namespace android {
-
-static const char* CONFIGURATION_FILE_DIR[] = {
- "idc/",
- "keylayout/",
- "keychars/",
-};
-
-static const char* CONFIGURATION_FILE_EXTENSION[] = {
- ".idc",
- ".kl",
- ".kcm",
-};
-
-static bool isValidNameChar(char ch) {
- return isascii(ch) && (isdigit(ch) || isalpha(ch) || ch == '-' || ch == '_');
-}
-
-static void appendInputDeviceConfigurationFileRelativePath(String8& path,
- const String8& name, InputDeviceConfigurationFileType type) {
- path.append(CONFIGURATION_FILE_DIR[type]);
- for (size_t i = 0; i < name.length(); i++) {
- char ch = name[i];
- if (!isValidNameChar(ch)) {
- ch = '_';
- }
- path.append(&ch, 1);
- }
- path.append(CONFIGURATION_FILE_EXTENSION[type]);
-}
-
-String8 getInputDeviceConfigurationFilePathByDeviceIdentifier(
- const InputDeviceIdentifier& deviceIdentifier,
- InputDeviceConfigurationFileType type) {
- if (deviceIdentifier.vendor !=0 && deviceIdentifier.product != 0) {
- if (deviceIdentifier.version != 0) {
- // Try vendor product version.
- String8 versionPath(getInputDeviceConfigurationFilePathByName(
- String8::format("Vendor_%04x_Product_%04x_Version_%04x",
- deviceIdentifier.vendor, deviceIdentifier.product,
- deviceIdentifier.version),
- type));
- if (!versionPath.isEmpty()) {
- return versionPath;
- }
- }
-
- // Try vendor product.
- String8 productPath(getInputDeviceConfigurationFilePathByName(
- String8::format("Vendor_%04x_Product_%04x",
- deviceIdentifier.vendor, deviceIdentifier.product),
- type));
- if (!productPath.isEmpty()) {
- return productPath;
- }
- }
-
- // Try device name.
- return getInputDeviceConfigurationFilePathByName(deviceIdentifier.name, type);
-}
-
-String8 getInputDeviceConfigurationFilePathByName(
- const String8& name, InputDeviceConfigurationFileType type) {
- // Search system repository.
- String8 path;
- path.setTo(getenv("ANDROID_ROOT"));
- path.append("/usr/");
- appendInputDeviceConfigurationFileRelativePath(path, name, type);
-#if DEBUG_PROBE
- ALOGD("Probing for system provided input device configuration file: path='%s'", path.string());
-#endif
- if (!access(path.string(), R_OK)) {
-#if DEBUG_PROBE
- ALOGD("Found");
-#endif
- return path;
- }
-
- // Search user repository.
- // TODO Should only look here if not in safe mode.
- path.setTo(getenv("ANDROID_DATA"));
- path.append("/system/devices/");
- appendInputDeviceConfigurationFileRelativePath(path, name, type);
-#if DEBUG_PROBE
- ALOGD("Probing for system user input device configuration file: path='%s'", path.string());
-#endif
- if (!access(path.string(), R_OK)) {
-#if DEBUG_PROBE
- ALOGD("Found");
-#endif
- return path;
- }
-
- // Not found.
-#if DEBUG_PROBE
- ALOGD("Probe failed to find input device configuration file: name='%s', type=%d",
- name.string(), type);
-#endif
- return String8();
-}
-
-
-// --- InputDeviceInfo ---
-
-InputDeviceInfo::InputDeviceInfo() {
- initialize(-1, -1, InputDeviceIdentifier(), String8(), false);
-}
-
-InputDeviceInfo::InputDeviceInfo(const InputDeviceInfo& other) :
- mId(other.mId), mGeneration(other.mGeneration), mIdentifier(other.mIdentifier),
- mAlias(other.mAlias), mIsExternal(other.mIsExternal), mSources(other.mSources),
- mKeyboardType(other.mKeyboardType),
- mKeyCharacterMap(other.mKeyCharacterMap),
- mHasVibrator(other.mHasVibrator),
- mMotionRanges(other.mMotionRanges) {
-}
-
-InputDeviceInfo::~InputDeviceInfo() {
-}
-
-void InputDeviceInfo::initialize(int32_t id, int32_t generation,
- const InputDeviceIdentifier& identifier, const String8& alias, bool isExternal) {
- mId = id;
- mGeneration = generation;
- mIdentifier = identifier;
- mAlias = alias;
- mIsExternal = isExternal;
- mSources = 0;
- mKeyboardType = AINPUT_KEYBOARD_TYPE_NONE;
- mHasVibrator = false;
- mMotionRanges.clear();
-}
-
-const InputDeviceInfo::MotionRange* InputDeviceInfo::getMotionRange(
- int32_t axis, uint32_t source) const {
- size_t numRanges = mMotionRanges.size();
- for (size_t i = 0; i < numRanges; i++) {
- const MotionRange& range = mMotionRanges.itemAt(i);
- if (range.axis == axis && range.source == source) {
- return ⦥
- }
- }
- return NULL;
-}
-
-void InputDeviceInfo::addSource(uint32_t source) {
- mSources |= source;
-}
-
-void InputDeviceInfo::addMotionRange(int32_t axis, uint32_t source, float min, float max,
- float flat, float fuzz, float resolution) {
- MotionRange range = { axis, source, min, max, flat, fuzz, resolution };
- mMotionRanges.add(range);
-}
-
-void InputDeviceInfo::addMotionRange(const MotionRange& range) {
- mMotionRanges.add(range);
-}
-
-} // namespace android
diff --git a/libs/androidfw/InputTransport.cpp b/libs/androidfw/InputTransport.cpp
deleted file mode 100644
index cfbc923..0000000
--- a/libs/androidfw/InputTransport.cpp
+++ /dev/null
@@ -1,957 +0,0 @@
-//
-// Copyright 2010 The Android Open Source Project
-//
-// Provides a shared memory transport for input events.
-//
-#define LOG_TAG "InputTransport"
-
-//#define LOG_NDEBUG 0
-
-// Log debug messages about channel messages (send message, receive message)
-#define DEBUG_CHANNEL_MESSAGES 0
-
-// Log debug messages whenever InputChannel objects are created/destroyed
-#define DEBUG_CHANNEL_LIFECYCLE 0
-
-// Log debug messages about transport actions
-#define DEBUG_TRANSPORT_ACTIONS 0
-
-// Log debug messages about touch event resampling
-#define DEBUG_RESAMPLING 0
-
-
-#include <cutils/log.h>
-#include <cutils/properties.h>
-#include <errno.h>
-#include <fcntl.h>
-#include <androidfw/InputTransport.h>
-#include <unistd.h>
-#include <sys/types.h>
-#include <sys/socket.h>
-#include <math.h>
-
-
-namespace android {
-
-// Socket buffer size. The default is typically about 128KB, which is much larger than
-// we really need. So we make it smaller. It just needs to be big enough to hold
-// a few dozen large multi-finger motion events in the case where an application gets
-// behind processing touches.
-static const size_t SOCKET_BUFFER_SIZE = 32 * 1024;
-
-// Nanoseconds per milliseconds.
-static const nsecs_t NANOS_PER_MS = 1000000;
-
-// Latency added during resampling. A few milliseconds doesn't hurt much but
-// reduces the impact of mispredicted touch positions.
-static const nsecs_t RESAMPLE_LATENCY = 5 * NANOS_PER_MS;
-
-// Minimum time difference between consecutive samples before attempting to resample.
-static const nsecs_t RESAMPLE_MIN_DELTA = 2 * NANOS_PER_MS;
-
-// Maximum time to predict forward from the last known state, to avoid predicting too
-// far into the future. This time is further bounded by 50% of the last time delta.
-static const nsecs_t RESAMPLE_MAX_PREDICTION = 8 * NANOS_PER_MS;
-
-template<typename T>
-inline static T min(const T& a, const T& b) {
- return a < b ? a : b;
-}
-
-inline static float lerp(float a, float b, float alpha) {
- return a + alpha * (b - a);
-}
-
-// --- InputMessage ---
-
-bool InputMessage::isValid(size_t actualSize) const {
- if (size() == actualSize) {
- switch (header.type) {
- case TYPE_KEY:
- return true;
- case TYPE_MOTION:
- return body.motion.pointerCount > 0
- && body.motion.pointerCount <= MAX_POINTERS;
- case TYPE_FINISHED:
- return true;
- }
- }
- return false;
-}
-
-size_t InputMessage::size() const {
- switch (header.type) {
- case TYPE_KEY:
- return sizeof(Header) + body.key.size();
- case TYPE_MOTION:
- return sizeof(Header) + body.motion.size();
- case TYPE_FINISHED:
- return sizeof(Header) + body.finished.size();
- }
- return sizeof(Header);
-}
-
-
-// --- InputChannel ---
-
-InputChannel::InputChannel(const String8& name, int fd) :
- mName(name), mFd(fd) {
-#if DEBUG_CHANNEL_LIFECYCLE
- ALOGD("Input channel constructed: name='%s', fd=%d",
- mName.string(), fd);
-#endif
-
- int result = fcntl(mFd, F_SETFL, O_NONBLOCK);
- LOG_ALWAYS_FATAL_IF(result != 0, "channel '%s' ~ Could not make socket "
- "non-blocking. errno=%d", mName.string(), errno);
-}
-
-InputChannel::~InputChannel() {
-#if DEBUG_CHANNEL_LIFECYCLE
- ALOGD("Input channel destroyed: name='%s', fd=%d",
- mName.string(), mFd);
-#endif
-
- ::close(mFd);
-}
-
-status_t InputChannel::openInputChannelPair(const String8& name,
- sp<InputChannel>& outServerChannel, sp<InputChannel>& outClientChannel) {
- int sockets[2];
- if (socketpair(AF_UNIX, SOCK_SEQPACKET, 0, sockets)) {
- status_t result = -errno;
- ALOGE("channel '%s' ~ Could not create socket pair. errno=%d",
- name.string(), errno);
- outServerChannel.clear();
- outClientChannel.clear();
- return result;
- }
-
- int bufferSize = SOCKET_BUFFER_SIZE;
- setsockopt(sockets[0], SOL_SOCKET, SO_SNDBUF, &bufferSize, sizeof(bufferSize));
- setsockopt(sockets[0], SOL_SOCKET, SO_RCVBUF, &bufferSize, sizeof(bufferSize));
- setsockopt(sockets[1], SOL_SOCKET, SO_SNDBUF, &bufferSize, sizeof(bufferSize));
- setsockopt(sockets[1], SOL_SOCKET, SO_RCVBUF, &bufferSize, sizeof(bufferSize));
-
- String8 serverChannelName = name;
- serverChannelName.append(" (server)");
- outServerChannel = new InputChannel(serverChannelName, sockets[0]);
-
- String8 clientChannelName = name;
- clientChannelName.append(" (client)");
- outClientChannel = new InputChannel(clientChannelName, sockets[1]);
- return OK;
-}
-
-status_t InputChannel::sendMessage(const InputMessage* msg) {
- size_t msgLength = msg->size();
- ssize_t nWrite;
- do {
- nWrite = ::send(mFd, msg, msgLength, MSG_DONTWAIT | MSG_NOSIGNAL);
- } while (nWrite == -1 && errno == EINTR);
-
- if (nWrite < 0) {
- int error = errno;
-#if DEBUG_CHANNEL_MESSAGES
- ALOGD("channel '%s' ~ error sending message of type %d, errno=%d", mName.string(),
- msg->header.type, error);
-#endif
- if (error == EAGAIN || error == EWOULDBLOCK) {
- return WOULD_BLOCK;
- }
- if (error == EPIPE || error == ENOTCONN || error == ECONNREFUSED || error == ECONNRESET) {
- return DEAD_OBJECT;
- }
- return -error;
- }
-
- if (size_t(nWrite) != msgLength) {
-#if DEBUG_CHANNEL_MESSAGES
- ALOGD("channel '%s' ~ error sending message type %d, send was incomplete",
- mName.string(), msg->header.type);
-#endif
- return DEAD_OBJECT;
- }
-
-#if DEBUG_CHANNEL_MESSAGES
- ALOGD("channel '%s' ~ sent message of type %d", mName.string(), msg->header.type);
-#endif
- return OK;
-}
-
-status_t InputChannel::receiveMessage(InputMessage* msg) {
- ssize_t nRead;
- do {
- nRead = ::recv(mFd, msg, sizeof(InputMessage), MSG_DONTWAIT);
- } while (nRead == -1 && errno == EINTR);
-
- if (nRead < 0) {
- int error = errno;
-#if DEBUG_CHANNEL_MESSAGES
- ALOGD("channel '%s' ~ receive message failed, errno=%d", mName.string(), errno);
-#endif
- if (error == EAGAIN || error == EWOULDBLOCK) {
- return WOULD_BLOCK;
- }
- if (error == EPIPE || error == ENOTCONN || error == ECONNREFUSED) {
- return DEAD_OBJECT;
- }
- return -error;
- }
-
- if (nRead == 0) { // check for EOF
-#if DEBUG_CHANNEL_MESSAGES
- ALOGD("channel '%s' ~ receive message failed because peer was closed", mName.string());
-#endif
- return DEAD_OBJECT;
- }
-
- if (!msg->isValid(nRead)) {
-#if DEBUG_CHANNEL_MESSAGES
- ALOGD("channel '%s' ~ received invalid message", mName.string());
-#endif
- return BAD_VALUE;
- }
-
-#if DEBUG_CHANNEL_MESSAGES
- ALOGD("channel '%s' ~ received message of type %d", mName.string(), msg->header.type);
-#endif
- return OK;
-}
-
-sp<InputChannel> InputChannel::dup() const {
- int fd = ::dup(getFd());
- return fd >= 0 ? new InputChannel(getName(), fd) : NULL;
-}
-
-
-// --- InputPublisher ---
-
-InputPublisher::InputPublisher(const sp<InputChannel>& channel) :
- mChannel(channel) {
-}
-
-InputPublisher::~InputPublisher() {
-}
-
-status_t InputPublisher::publishKeyEvent(
- uint32_t seq,
- int32_t deviceId,
- int32_t source,
- int32_t action,
- int32_t flags,
- int32_t keyCode,
- int32_t scanCode,
- int32_t metaState,
- int32_t repeatCount,
- nsecs_t downTime,
- nsecs_t eventTime) {
-#if DEBUG_TRANSPORT_ACTIONS
- ALOGD("channel '%s' publisher ~ publishKeyEvent: seq=%u, deviceId=%d, source=0x%x, "
- "action=0x%x, flags=0x%x, keyCode=%d, scanCode=%d, metaState=0x%x, repeatCount=%d,"
- "downTime=%lld, eventTime=%lld",
- mChannel->getName().string(), seq,
- deviceId, source, action, flags, keyCode, scanCode, metaState, repeatCount,
- downTime, eventTime);
-#endif
-
- if (!seq) {
- ALOGE("Attempted to publish a key event with sequence number 0.");
- return BAD_VALUE;
- }
-
- InputMessage msg;
- msg.header.type = InputMessage::TYPE_KEY;
- msg.body.key.seq = seq;
- msg.body.key.deviceId = deviceId;
- msg.body.key.source = source;
- msg.body.key.action = action;
- msg.body.key.flags = flags;
- msg.body.key.keyCode = keyCode;
- msg.body.key.scanCode = scanCode;
- msg.body.key.metaState = metaState;
- msg.body.key.repeatCount = repeatCount;
- msg.body.key.downTime = downTime;
- msg.body.key.eventTime = eventTime;
- return mChannel->sendMessage(&msg);
-}
-
-status_t InputPublisher::publishMotionEvent(
- uint32_t seq,
- int32_t deviceId,
- int32_t source,
- int32_t action,
- int32_t flags,
- int32_t edgeFlags,
- int32_t metaState,
- int32_t buttonState,
- float xOffset,
- float yOffset,
- float xPrecision,
- float yPrecision,
- nsecs_t downTime,
- nsecs_t eventTime,
- size_t pointerCount,
- const PointerProperties* pointerProperties,
- const PointerCoords* pointerCoords) {
-#if DEBUG_TRANSPORT_ACTIONS
- ALOGD("channel '%s' publisher ~ publishMotionEvent: seq=%u, deviceId=%d, source=0x%x, "
- "action=0x%x, flags=0x%x, edgeFlags=0x%x, metaState=0x%x, buttonState=0x%x, "
- "xOffset=%f, yOffset=%f, "
- "xPrecision=%f, yPrecision=%f, downTime=%lld, eventTime=%lld, "
- "pointerCount=%d",
- mChannel->getName().string(), seq,
- deviceId, source, action, flags, edgeFlags, metaState, buttonState,
- xOffset, yOffset, xPrecision, yPrecision, downTime, eventTime, pointerCount);
-#endif
-
- if (!seq) {
- ALOGE("Attempted to publish a motion event with sequence number 0.");
- return BAD_VALUE;
- }
-
- if (pointerCount > MAX_POINTERS || pointerCount < 1) {
- ALOGE("channel '%s' publisher ~ Invalid number of pointers provided: %d.",
- mChannel->getName().string(), pointerCount);
- return BAD_VALUE;
- }
-
- InputMessage msg;
- msg.header.type = InputMessage::TYPE_MOTION;
- msg.body.motion.seq = seq;
- msg.body.motion.deviceId = deviceId;
- msg.body.motion.source = source;
- msg.body.motion.action = action;
- msg.body.motion.flags = flags;
- msg.body.motion.edgeFlags = edgeFlags;
- msg.body.motion.metaState = metaState;
- msg.body.motion.buttonState = buttonState;
- msg.body.motion.xOffset = xOffset;
- msg.body.motion.yOffset = yOffset;
- msg.body.motion.xPrecision = xPrecision;
- msg.body.motion.yPrecision = yPrecision;
- msg.body.motion.downTime = downTime;
- msg.body.motion.eventTime = eventTime;
- msg.body.motion.pointerCount = pointerCount;
- for (size_t i = 0; i < pointerCount; i++) {
- msg.body.motion.pointers[i].properties.copyFrom(pointerProperties[i]);
- msg.body.motion.pointers[i].coords.copyFrom(pointerCoords[i]);
- }
- return mChannel->sendMessage(&msg);
-}
-
-status_t InputPublisher::receiveFinishedSignal(uint32_t* outSeq, bool* outHandled) {
-#if DEBUG_TRANSPORT_ACTIONS
- ALOGD("channel '%s' publisher ~ receiveFinishedSignal",
- mChannel->getName().string());
-#endif
-
- InputMessage msg;
- status_t result = mChannel->receiveMessage(&msg);
- if (result) {
- *outSeq = 0;
- *outHandled = false;
- return result;
- }
- if (msg.header.type != InputMessage::TYPE_FINISHED) {
- ALOGE("channel '%s' publisher ~ Received unexpected message of type %d from consumer",
- mChannel->getName().string(), msg.header.type);
- return UNKNOWN_ERROR;
- }
- *outSeq = msg.body.finished.seq;
- *outHandled = msg.body.finished.handled;
- return OK;
-}
-
-// --- InputConsumer ---
-
-InputConsumer::InputConsumer(const sp<InputChannel>& channel) :
- mResampleTouch(isTouchResamplingEnabled()),
- mChannel(channel), mMsgDeferred(false) {
-}
-
-InputConsumer::~InputConsumer() {
-}
-
-bool InputConsumer::isTouchResamplingEnabled() {
- char value[PROPERTY_VALUE_MAX];
- int length = property_get("debug.inputconsumer.resample", value, NULL);
- if (length > 0) {
- if (!strcmp("0", value)) {
- return false;
- }
- if (strcmp("1", value)) {
- ALOGD("Unrecognized property value for 'debug.inputconsumer.resample'. "
- "Use '1' or '0'.");
- }
- }
- return true;
-}
-
-status_t InputConsumer::consume(InputEventFactoryInterface* factory,
- bool consumeBatches, nsecs_t frameTime, uint32_t* outSeq, InputEvent** outEvent) {
-#if DEBUG_TRANSPORT_ACTIONS
- ALOGD("channel '%s' consumer ~ consume: consumeBatches=%s, frameTime=%lld",
- mChannel->getName().string(), consumeBatches ? "true" : "false", frameTime);
-#endif
-
- *outSeq = 0;
- *outEvent = NULL;
-
- // Fetch the next input message.
- // Loop until an event can be returned or no additional events are received.
- while (!*outEvent) {
- if (mMsgDeferred) {
- // mMsg contains a valid input message from the previous call to consume
- // that has not yet been processed.
- mMsgDeferred = false;
- } else {
- // Receive a fresh message.
- status_t result = mChannel->receiveMessage(&mMsg);
- if (result) {
- // Consume the next batched event unless batches are being held for later.
- if (consumeBatches || result != WOULD_BLOCK) {
- result = consumeBatch(factory, frameTime, outSeq, outEvent);
- if (*outEvent) {
-#if DEBUG_TRANSPORT_ACTIONS
- ALOGD("channel '%s' consumer ~ consumed batch event, seq=%u",
- mChannel->getName().string(), *outSeq);
-#endif
- break;
- }
- }
- return result;
- }
- }
-
- switch (mMsg.header.type) {
- case InputMessage::TYPE_KEY: {
- KeyEvent* keyEvent = factory->createKeyEvent();
- if (!keyEvent) return NO_MEMORY;
-
- initializeKeyEvent(keyEvent, &mMsg);
- *outSeq = mMsg.body.key.seq;
- *outEvent = keyEvent;
-#if DEBUG_TRANSPORT_ACTIONS
- ALOGD("channel '%s' consumer ~ consumed key event, seq=%u",
- mChannel->getName().string(), *outSeq);
-#endif
- break;
- }
-
- case AINPUT_EVENT_TYPE_MOTION: {
- ssize_t batchIndex = findBatch(mMsg.body.motion.deviceId, mMsg.body.motion.source);
- if (batchIndex >= 0) {
- Batch& batch = mBatches.editItemAt(batchIndex);
- if (canAddSample(batch, &mMsg)) {
- batch.samples.push(mMsg);
-#if DEBUG_TRANSPORT_ACTIONS
- ALOGD("channel '%s' consumer ~ appended to batch event",
- mChannel->getName().string());
-#endif
- break;
- } else {
- // We cannot append to the batch in progress, so we need to consume
- // the previous batch right now and defer the new message until later.
- mMsgDeferred = true;
- status_t result = consumeSamples(factory,
- batch, batch.samples.size(), outSeq, outEvent);
- mBatches.removeAt(batchIndex);
- if (result) {
- return result;
- }
-#if DEBUG_TRANSPORT_ACTIONS
- ALOGD("channel '%s' consumer ~ consumed batch event and "
- "deferred current event, seq=%u",
- mChannel->getName().string(), *outSeq);
-#endif
- break;
- }
- }
-
- // Start a new batch if needed.
- if (mMsg.body.motion.action == AMOTION_EVENT_ACTION_MOVE
- || mMsg.body.motion.action == AMOTION_EVENT_ACTION_HOVER_MOVE) {
- mBatches.push();
- Batch& batch = mBatches.editTop();
- batch.samples.push(mMsg);
-#if DEBUG_TRANSPORT_ACTIONS
- ALOGD("channel '%s' consumer ~ started batch event",
- mChannel->getName().string());
-#endif
- break;
- }
-
- MotionEvent* motionEvent = factory->createMotionEvent();
- if (! motionEvent) return NO_MEMORY;
-
- updateTouchState(&mMsg);
- initializeMotionEvent(motionEvent, &mMsg);
- *outSeq = mMsg.body.motion.seq;
- *outEvent = motionEvent;
-#if DEBUG_TRANSPORT_ACTIONS
- ALOGD("channel '%s' consumer ~ consumed motion event, seq=%u",
- mChannel->getName().string(), *outSeq);
-#endif
- break;
- }
-
- default:
- ALOGE("channel '%s' consumer ~ Received unexpected message of type %d",
- mChannel->getName().string(), mMsg.header.type);
- return UNKNOWN_ERROR;
- }
- }
- return OK;
-}
-
-status_t InputConsumer::consumeBatch(InputEventFactoryInterface* factory,
- nsecs_t frameTime, uint32_t* outSeq, InputEvent** outEvent) {
- status_t result;
- for (size_t i = mBatches.size(); i-- > 0; ) {
- Batch& batch = mBatches.editItemAt(i);
- if (frameTime < 0) {
- result = consumeSamples(factory, batch, batch.samples.size(),
- outSeq, outEvent);
- mBatches.removeAt(i);
- return result;
- }
-
- nsecs_t sampleTime = frameTime - RESAMPLE_LATENCY;
- ssize_t split = findSampleNoLaterThan(batch, sampleTime);
- if (split < 0) {
- continue;
- }
-
- result = consumeSamples(factory, batch, split + 1, outSeq, outEvent);
- const InputMessage* next;
- if (batch.samples.isEmpty()) {
- mBatches.removeAt(i);
- next = NULL;
- } else {
- next = &batch.samples.itemAt(0);
- }
- if (!result) {
- resampleTouchState(sampleTime, static_cast<MotionEvent*>(*outEvent), next);
- }
- return result;
- }
-
- return WOULD_BLOCK;
-}
-
-status_t InputConsumer::consumeSamples(InputEventFactoryInterface* factory,
- Batch& batch, size_t count, uint32_t* outSeq, InputEvent** outEvent) {
- MotionEvent* motionEvent = factory->createMotionEvent();
- if (! motionEvent) return NO_MEMORY;
-
- uint32_t chain = 0;
- for (size_t i = 0; i < count; i++) {
- InputMessage& msg = batch.samples.editItemAt(i);
- updateTouchState(&msg);
- if (i) {
- SeqChain seqChain;
- seqChain.seq = msg.body.motion.seq;
- seqChain.chain = chain;
- mSeqChains.push(seqChain);
- addSample(motionEvent, &msg);
- } else {
- initializeMotionEvent(motionEvent, &msg);
- }
- chain = msg.body.motion.seq;
- }
- batch.samples.removeItemsAt(0, count);
-
- *outSeq = chain;
- *outEvent = motionEvent;
- return OK;
-}
-
-void InputConsumer::updateTouchState(InputMessage* msg) {
- if (!mResampleTouch ||
- !(msg->body.motion.source & AINPUT_SOURCE_CLASS_POINTER)) {
- return;
- }
-
- int32_t deviceId = msg->body.motion.deviceId;
- int32_t source = msg->body.motion.source;
- nsecs_t eventTime = msg->body.motion.eventTime;
-
- // Update the touch state history to incorporate the new input message.
- // If the message is in the past relative to the most recently produced resampled
- // touch, then use the resampled time and coordinates instead.
- switch (msg->body.motion.action & AMOTION_EVENT_ACTION_MASK) {
- case AMOTION_EVENT_ACTION_DOWN: {
- ssize_t index = findTouchState(deviceId, source);
- if (index < 0) {
- mTouchStates.push();
- index = mTouchStates.size() - 1;
- }
- TouchState& touchState = mTouchStates.editItemAt(index);
- touchState.initialize(deviceId, source);
- touchState.addHistory(msg);
- break;
- }
-
- case AMOTION_EVENT_ACTION_MOVE: {
- ssize_t index = findTouchState(deviceId, source);
- if (index >= 0) {
- TouchState& touchState = mTouchStates.editItemAt(index);
- touchState.addHistory(msg);
- if (eventTime < touchState.lastResample.eventTime) {
- rewriteMessage(touchState, msg);
- } else {
- touchState.lastResample.idBits.clear();
- }
- }
- break;
- }
-
- case AMOTION_EVENT_ACTION_POINTER_DOWN: {
- ssize_t index = findTouchState(deviceId, source);
- if (index >= 0) {
- TouchState& touchState = mTouchStates.editItemAt(index);
- touchState.lastResample.idBits.clearBit(msg->body.motion.getActionId());
- rewriteMessage(touchState, msg);
- }
- break;
- }
-
- case AMOTION_EVENT_ACTION_POINTER_UP: {
- ssize_t index = findTouchState(deviceId, source);
- if (index >= 0) {
- TouchState& touchState = mTouchStates.editItemAt(index);
- rewriteMessage(touchState, msg);
- touchState.lastResample.idBits.clearBit(msg->body.motion.getActionId());
- }
- break;
- }
-
- case AMOTION_EVENT_ACTION_SCROLL: {
- ssize_t index = findTouchState(deviceId, source);
- if (index >= 0) {
- const TouchState& touchState = mTouchStates.itemAt(index);
- rewriteMessage(touchState, msg);
- }
- break;
- }
-
- case AMOTION_EVENT_ACTION_UP:
- case AMOTION_EVENT_ACTION_CANCEL: {
- ssize_t index = findTouchState(deviceId, source);
- if (index >= 0) {
- const TouchState& touchState = mTouchStates.itemAt(index);
- rewriteMessage(touchState, msg);
- mTouchStates.removeAt(index);
- }
- break;
- }
- }
-}
-
-void InputConsumer::rewriteMessage(const TouchState& state, InputMessage* msg) {
- for (size_t i = 0; i < msg->body.motion.pointerCount; i++) {
- uint32_t id = msg->body.motion.pointers[i].properties.id;
- if (state.lastResample.idBits.hasBit(id)) {
- PointerCoords& msgCoords = msg->body.motion.pointers[i].coords;
- const PointerCoords& resampleCoords = state.lastResample.getPointerById(id);
-#if DEBUG_RESAMPLING
- ALOGD("[%d] - rewrite (%0.3f, %0.3f), old (%0.3f, %0.3f)", id,
- resampleCoords.getAxisValue(AMOTION_EVENT_AXIS_X),
- resampleCoords.getAxisValue(AMOTION_EVENT_AXIS_Y),
- msgCoords.getAxisValue(AMOTION_EVENT_AXIS_X),
- msgCoords.getAxisValue(AMOTION_EVENT_AXIS_Y));
-#endif
- msgCoords.setAxisValue(AMOTION_EVENT_AXIS_X, resampleCoords.getX());
- msgCoords.setAxisValue(AMOTION_EVENT_AXIS_Y, resampleCoords.getY());
- }
- }
-}
-
-void InputConsumer::resampleTouchState(nsecs_t sampleTime, MotionEvent* event,
- const InputMessage* next) {
- if (!mResampleTouch
- || !(event->getSource() & AINPUT_SOURCE_CLASS_POINTER)
- || event->getAction() != AMOTION_EVENT_ACTION_MOVE) {
- return;
- }
-
- ssize_t index = findTouchState(event->getDeviceId(), event->getSource());
- if (index < 0) {
-#if DEBUG_RESAMPLING
- ALOGD("Not resampled, no touch state for device.");
-#endif
- return;
- }
-
- TouchState& touchState = mTouchStates.editItemAt(index);
- if (touchState.historySize < 1) {
-#if DEBUG_RESAMPLING
- ALOGD("Not resampled, no history for device.");
-#endif
- return;
- }
-
- // Ensure that the current sample has all of the pointers that need to be reported.
- const History* current = touchState.getHistory(0);
- size_t pointerCount = event->getPointerCount();
- for (size_t i = 0; i < pointerCount; i++) {
- uint32_t id = event->getPointerId(i);
- if (!current->idBits.hasBit(id)) {
-#if DEBUG_RESAMPLING
- ALOGD("Not resampled, missing id %d", id);
-#endif
- return;
- }
- }
-
- // Find the data to use for resampling.
- const History* other;
- History future;
- float alpha;
- if (next) {
- // Interpolate between current sample and future sample.
- // So current->eventTime <= sampleTime <= future.eventTime.
- future.initializeFrom(next);
- other = &future;
- nsecs_t delta = future.eventTime - current->eventTime;
- if (delta < RESAMPLE_MIN_DELTA) {
-#if DEBUG_RESAMPLING
- ALOGD("Not resampled, delta time is %lld ns.", delta);
-#endif
- return;
- }
- alpha = float(sampleTime - current->eventTime) / delta;
- } else if (touchState.historySize >= 2) {
- // Extrapolate future sample using current sample and past sample.
- // So other->eventTime <= current->eventTime <= sampleTime.
- other = touchState.getHistory(1);
- nsecs_t delta = current->eventTime - other->eventTime;
- if (delta < RESAMPLE_MIN_DELTA) {
-#if DEBUG_RESAMPLING
- ALOGD("Not resampled, delta time is %lld ns.", delta);
-#endif
- return;
- }
- nsecs_t maxPredict = current->eventTime + min(delta / 2, RESAMPLE_MAX_PREDICTION);
- if (sampleTime > maxPredict) {
-#if DEBUG_RESAMPLING
- ALOGD("Sample time is too far in the future, adjusting prediction "
- "from %lld to %lld ns.",
- sampleTime - current->eventTime, maxPredict - current->eventTime);
-#endif
- sampleTime = maxPredict;
- }
- alpha = float(current->eventTime - sampleTime) / delta;
- } else {
-#if DEBUG_RESAMPLING
- ALOGD("Not resampled, insufficient data.");
-#endif
- return;
- }
-
- // Resample touch coordinates.
- touchState.lastResample.eventTime = sampleTime;
- touchState.lastResample.idBits.clear();
- for (size_t i = 0; i < pointerCount; i++) {
- uint32_t id = event->getPointerId(i);
- touchState.lastResample.idToIndex[id] = i;
- touchState.lastResample.idBits.markBit(id);
- PointerCoords& resampledCoords = touchState.lastResample.pointers[i];
- const PointerCoords& currentCoords = current->getPointerById(id);
- if (other->idBits.hasBit(id)
- && shouldResampleTool(event->getToolType(i))) {
- const PointerCoords& otherCoords = other->getPointerById(id);
- resampledCoords.copyFrom(currentCoords);
- resampledCoords.setAxisValue(AMOTION_EVENT_AXIS_X,
- lerp(currentCoords.getX(), otherCoords.getX(), alpha));
- resampledCoords.setAxisValue(AMOTION_EVENT_AXIS_Y,
- lerp(currentCoords.getY(), otherCoords.getY(), alpha));
-#if DEBUG_RESAMPLING
- ALOGD("[%d] - out (%0.3f, %0.3f), cur (%0.3f, %0.3f), "
- "other (%0.3f, %0.3f), alpha %0.3f",
- id, resampledCoords.getX(), resampledCoords.getY(),
- currentCoords.getX(), currentCoords.getY(),
- otherCoords.getX(), otherCoords.getY(),
- alpha);
-#endif
- } else {
- resampledCoords.copyFrom(currentCoords);
-#if DEBUG_RESAMPLING
- ALOGD("[%d] - out (%0.3f, %0.3f), cur (%0.3f, %0.3f)",
- id, resampledCoords.getX(), resampledCoords.getY(),
- currentCoords.getX(), currentCoords.getY());
-#endif
- }
- }
-
- event->addSample(sampleTime, touchState.lastResample.pointers);
-}
-
-bool InputConsumer::shouldResampleTool(int32_t toolType) {
- return toolType == AMOTION_EVENT_TOOL_TYPE_FINGER
- || toolType == AMOTION_EVENT_TOOL_TYPE_UNKNOWN;
-}
-
-status_t InputConsumer::sendFinishedSignal(uint32_t seq, bool handled) {
-#if DEBUG_TRANSPORT_ACTIONS
- ALOGD("channel '%s' consumer ~ sendFinishedSignal: seq=%u, handled=%s",
- mChannel->getName().string(), seq, handled ? "true" : "false");
-#endif
-
- if (!seq) {
- ALOGE("Attempted to send a finished signal with sequence number 0.");
- return BAD_VALUE;
- }
-
- // Send finished signals for the batch sequence chain first.
- size_t seqChainCount = mSeqChains.size();
- if (seqChainCount) {
- uint32_t currentSeq = seq;
- uint32_t chainSeqs[seqChainCount];
- size_t chainIndex = 0;
- for (size_t i = seqChainCount; i-- > 0; ) {
- const SeqChain& seqChain = mSeqChains.itemAt(i);
- if (seqChain.seq == currentSeq) {
- currentSeq = seqChain.chain;
- chainSeqs[chainIndex++] = currentSeq;
- mSeqChains.removeAt(i);
- }
- }
- status_t status = OK;
- while (!status && chainIndex-- > 0) {
- status = sendUnchainedFinishedSignal(chainSeqs[chainIndex], handled);
- }
- if (status) {
- // An error occurred so at least one signal was not sent, reconstruct the chain.
- do {
- SeqChain seqChain;
- seqChain.seq = chainIndex != 0 ? chainSeqs[chainIndex - 1] : seq;
- seqChain.chain = chainSeqs[chainIndex];
- mSeqChains.push(seqChain);
- } while (chainIndex-- > 0);
- return status;
- }
- }
-
- // Send finished signal for the last message in the batch.
- return sendUnchainedFinishedSignal(seq, handled);
-}
-
-status_t InputConsumer::sendUnchainedFinishedSignal(uint32_t seq, bool handled) {
- InputMessage msg;
- msg.header.type = InputMessage::TYPE_FINISHED;
- msg.body.finished.seq = seq;
- msg.body.finished.handled = handled;
- return mChannel->sendMessage(&msg);
-}
-
-bool InputConsumer::hasDeferredEvent() const {
- return mMsgDeferred;
-}
-
-bool InputConsumer::hasPendingBatch() const {
- return !mBatches.isEmpty();
-}
-
-ssize_t InputConsumer::findBatch(int32_t deviceId, int32_t source) const {
- for (size_t i = 0; i < mBatches.size(); i++) {
- const Batch& batch = mBatches.itemAt(i);
- const InputMessage& head = batch.samples.itemAt(0);
- if (head.body.motion.deviceId == deviceId && head.body.motion.source == source) {
- return i;
- }
- }
- return -1;
-}
-
-ssize_t InputConsumer::findTouchState(int32_t deviceId, int32_t source) const {
- for (size_t i = 0; i < mTouchStates.size(); i++) {
- const TouchState& touchState = mTouchStates.itemAt(i);
- if (touchState.deviceId == deviceId && touchState.source == source) {
- return i;
- }
- }
- return -1;
-}
-
-void InputConsumer::initializeKeyEvent(KeyEvent* event, const InputMessage* msg) {
- event->initialize(
- msg->body.key.deviceId,
- msg->body.key.source,
- msg->body.key.action,
- msg->body.key.flags,
- msg->body.key.keyCode,
- msg->body.key.scanCode,
- msg->body.key.metaState,
- msg->body.key.repeatCount,
- msg->body.key.downTime,
- msg->body.key.eventTime);
-}
-
-void InputConsumer::initializeMotionEvent(MotionEvent* event, const InputMessage* msg) {
- size_t pointerCount = msg->body.motion.pointerCount;
- PointerProperties pointerProperties[pointerCount];
- PointerCoords pointerCoords[pointerCount];
- for (size_t i = 0; i < pointerCount; i++) {
- pointerProperties[i].copyFrom(msg->body.motion.pointers[i].properties);
- pointerCoords[i].copyFrom(msg->body.motion.pointers[i].coords);
- }
-
- event->initialize(
- msg->body.motion.deviceId,
- msg->body.motion.source,
- msg->body.motion.action,
- msg->body.motion.flags,
- msg->body.motion.edgeFlags,
- msg->body.motion.metaState,
- msg->body.motion.buttonState,
- msg->body.motion.xOffset,
- msg->body.motion.yOffset,
- msg->body.motion.xPrecision,
- msg->body.motion.yPrecision,
- msg->body.motion.downTime,
- msg->body.motion.eventTime,
- pointerCount,
- pointerProperties,
- pointerCoords);
-}
-
-void InputConsumer::addSample(MotionEvent* event, const InputMessage* msg) {
- size_t pointerCount = msg->body.motion.pointerCount;
- PointerCoords pointerCoords[pointerCount];
- for (size_t i = 0; i < pointerCount; i++) {
- pointerCoords[i].copyFrom(msg->body.motion.pointers[i].coords);
- }
-
- event->setMetaState(event->getMetaState() | msg->body.motion.metaState);
- event->addSample(msg->body.motion.eventTime, pointerCoords);
-}
-
-bool InputConsumer::canAddSample(const Batch& batch, const InputMessage *msg) {
- const InputMessage& head = batch.samples.itemAt(0);
- size_t pointerCount = msg->body.motion.pointerCount;
- if (head.body.motion.pointerCount != pointerCount
- || head.body.motion.action != msg->body.motion.action) {
- return false;
- }
- for (size_t i = 0; i < pointerCount; i++) {
- if (head.body.motion.pointers[i].properties
- != msg->body.motion.pointers[i].properties) {
- return false;
- }
- }
- return true;
-}
-
-ssize_t InputConsumer::findSampleNoLaterThan(const Batch& batch, nsecs_t time) {
- size_t numSamples = batch.samples.size();
- size_t index = 0;
- while (index < numSamples
- && batch.samples.itemAt(index).body.motion.eventTime <= time) {
- index += 1;
- }
- return ssize_t(index) - 1;
-}
-
-} // namespace android
diff --git a/libs/androidfw/KeyCharacterMap.cpp b/libs/androidfw/KeyCharacterMap.cpp
deleted file mode 100644
index 36cb6e1..0000000
--- a/libs/androidfw/KeyCharacterMap.cpp
+++ /dev/null
@@ -1,1153 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#define LOG_TAG "KeyCharacterMap"
-
-#include <stdlib.h>
-#include <string.h>
-#include <android/keycodes.h>
-#include <androidfw/Keyboard.h>
-#include <androidfw/KeyCharacterMap.h>
-
-#if HAVE_ANDROID_OS
-#include <binder/Parcel.h>
-#endif
-
-#include <utils/Log.h>
-#include <utils/Errors.h>
-#include <utils/Tokenizer.h>
-#include <utils/Timers.h>
-
-// Enables debug output for the parser.
-#define DEBUG_PARSER 0
-
-// Enables debug output for parser performance.
-#define DEBUG_PARSER_PERFORMANCE 0
-
-// Enables debug output for mapping.
-#define DEBUG_MAPPING 0
-
-
-namespace android {
-
-static const char* WHITESPACE = " \t\r";
-static const char* WHITESPACE_OR_PROPERTY_DELIMITER = " \t\r,:";
-
-struct Modifier {
- const char* label;
- int32_t metaState;
-};
-static const Modifier modifiers[] = {
- { "shift", AMETA_SHIFT_ON },
- { "lshift", AMETA_SHIFT_LEFT_ON },
- { "rshift", AMETA_SHIFT_RIGHT_ON },
- { "alt", AMETA_ALT_ON },
- { "lalt", AMETA_ALT_LEFT_ON },
- { "ralt", AMETA_ALT_RIGHT_ON },
- { "ctrl", AMETA_CTRL_ON },
- { "lctrl", AMETA_CTRL_LEFT_ON },
- { "rctrl", AMETA_CTRL_RIGHT_ON },
- { "meta", AMETA_META_ON },
- { "lmeta", AMETA_META_LEFT_ON },
- { "rmeta", AMETA_META_RIGHT_ON },
- { "sym", AMETA_SYM_ON },
- { "fn", AMETA_FUNCTION_ON },
- { "capslock", AMETA_CAPS_LOCK_ON },
- { "numlock", AMETA_NUM_LOCK_ON },
- { "scrolllock", AMETA_SCROLL_LOCK_ON },
-};
-
-#if DEBUG_MAPPING
-static String8 toString(const char16_t* chars, size_t numChars) {
- String8 result;
- for (size_t i = 0; i < numChars; i++) {
- result.appendFormat(i == 0 ? "%d" : ", %d", chars[i]);
- }
- return result;
-}
-#endif
-
-
-// --- KeyCharacterMap ---
-
-sp<KeyCharacterMap> KeyCharacterMap::sEmpty = new KeyCharacterMap();
-
-KeyCharacterMap::KeyCharacterMap() :
- mType(KEYBOARD_TYPE_UNKNOWN) {
-}
-
-KeyCharacterMap::KeyCharacterMap(const KeyCharacterMap& other) :
- RefBase(), mType(other.mType), mKeysByScanCode(other.mKeysByScanCode),
- mKeysByUsageCode(other.mKeysByUsageCode) {
- for (size_t i = 0; i < other.mKeys.size(); i++) {
- mKeys.add(other.mKeys.keyAt(i), new Key(*other.mKeys.valueAt(i)));
- }
-}
-
-KeyCharacterMap::~KeyCharacterMap() {
- for (size_t i = 0; i < mKeys.size(); i++) {
- Key* key = mKeys.editValueAt(i);
- delete key;
- }
-}
-
-status_t KeyCharacterMap::load(const String8& filename,
- Format format, sp<KeyCharacterMap>* outMap) {
- outMap->clear();
-
- Tokenizer* tokenizer;
- status_t status = Tokenizer::open(filename, &tokenizer);
- if (status) {
- ALOGE("Error %d opening key character map file %s.", status, filename.string());
- } else {
- status = load(tokenizer, format, outMap);
- delete tokenizer;
- }
- return status;
-}
-
-status_t KeyCharacterMap::loadContents(const String8& filename, const char* contents,
- Format format, sp<KeyCharacterMap>* outMap) {
- outMap->clear();
-
- Tokenizer* tokenizer;
- status_t status = Tokenizer::fromContents(filename, contents, &tokenizer);
- if (status) {
- ALOGE("Error %d opening key character map.", status);
- } else {
- status = load(tokenizer, format, outMap);
- delete tokenizer;
- }
- return status;
-}
-
-status_t KeyCharacterMap::load(Tokenizer* tokenizer,
- Format format, sp<KeyCharacterMap>* outMap) {
- status_t status = OK;
- sp<KeyCharacterMap> map = new KeyCharacterMap();
- if (!map.get()) {
- ALOGE("Error allocating key character map.");
- status = NO_MEMORY;
- } else {
-#if DEBUG_PARSER_PERFORMANCE
- nsecs_t startTime = systemTime(SYSTEM_TIME_MONOTONIC);
-#endif
- Parser parser(map.get(), tokenizer, format);
- status = parser.parse();
-#if DEBUG_PARSER_PERFORMANCE
- nsecs_t elapsedTime = systemTime(SYSTEM_TIME_MONOTONIC) - startTime;
- ALOGD("Parsed key character map file '%s' %d lines in %0.3fms.",
- tokenizer->getFilename().string(), tokenizer->getLineNumber(),
- elapsedTime / 1000000.0);
-#endif
- if (!status) {
- *outMap = map;
- }
- }
- return status;
-}
-
-sp<KeyCharacterMap> KeyCharacterMap::combine(const sp<KeyCharacterMap>& base,
- const sp<KeyCharacterMap>& overlay) {
- if (overlay == NULL) {
- return base;
- }
- if (base == NULL) {
- return overlay;
- }
-
- sp<KeyCharacterMap> map = new KeyCharacterMap(*base.get());
- for (size_t i = 0; i < overlay->mKeys.size(); i++) {
- int32_t keyCode = overlay->mKeys.keyAt(i);
- Key* key = overlay->mKeys.valueAt(i);
- ssize_t oldIndex = map->mKeys.indexOfKey(keyCode);
- if (oldIndex >= 0) {
- delete map->mKeys.valueAt(oldIndex);
- map->mKeys.editValueAt(oldIndex) = new Key(*key);
- } else {
- map->mKeys.add(keyCode, new Key(*key));
- }
- }
-
- for (size_t i = 0; i < overlay->mKeysByScanCode.size(); i++) {
- map->mKeysByScanCode.replaceValueFor(overlay->mKeysByScanCode.keyAt(i),
- overlay->mKeysByScanCode.valueAt(i));
- }
-
- for (size_t i = 0; i < overlay->mKeysByUsageCode.size(); i++) {
- map->mKeysByUsageCode.replaceValueFor(overlay->mKeysByUsageCode.keyAt(i),
- overlay->mKeysByUsageCode.valueAt(i));
- }
- return map;
-}
-
-sp<KeyCharacterMap> KeyCharacterMap::empty() {
- return sEmpty;
-}
-
-int32_t KeyCharacterMap::getKeyboardType() const {
- return mType;
-}
-
-char16_t KeyCharacterMap::getDisplayLabel(int32_t keyCode) const {
- char16_t result = 0;
- const Key* key;
- if (getKey(keyCode, &key)) {
- result = key->label;
- }
-#if DEBUG_MAPPING
- ALOGD("getDisplayLabel: keyCode=%d ~ Result %d.", keyCode, result);
-#endif
- return result;
-}
-
-char16_t KeyCharacterMap::getNumber(int32_t keyCode) const {
- char16_t result = 0;
- const Key* key;
- if (getKey(keyCode, &key)) {
- result = key->number;
- }
-#if DEBUG_MAPPING
- ALOGD("getNumber: keyCode=%d ~ Result %d.", keyCode, result);
-#endif
- return result;
-}
-
-char16_t KeyCharacterMap::getCharacter(int32_t keyCode, int32_t metaState) const {
- char16_t result = 0;
- const Key* key;
- const Behavior* behavior;
- if (getKeyBehavior(keyCode, metaState, &key, &behavior)) {
- result = behavior->character;
- }
-#if DEBUG_MAPPING
- ALOGD("getCharacter: keyCode=%d, metaState=0x%08x ~ Result %d.", keyCode, metaState, result);
-#endif
- return result;
-}
-
-bool KeyCharacterMap::getFallbackAction(int32_t keyCode, int32_t metaState,
- FallbackAction* outFallbackAction) const {
- outFallbackAction->keyCode = 0;
- outFallbackAction->metaState = 0;
-
- bool result = false;
- const Key* key;
- const Behavior* behavior;
- if (getKeyBehavior(keyCode, metaState, &key, &behavior)) {
- if (behavior->fallbackKeyCode) {
- outFallbackAction->keyCode = behavior->fallbackKeyCode;
- outFallbackAction->metaState = metaState & ~behavior->metaState;
- result = true;
- }
- }
-#if DEBUG_MAPPING
- ALOGD("getFallbackKeyCode: keyCode=%d, metaState=0x%08x ~ Result %s, "
- "fallback keyCode=%d, fallback metaState=0x%08x.",
- keyCode, metaState, result ? "true" : "false",
- outFallbackAction->keyCode, outFallbackAction->metaState);
-#endif
- return result;
-}
-
-char16_t KeyCharacterMap::getMatch(int32_t keyCode, const char16_t* chars, size_t numChars,
- int32_t metaState) const {
- char16_t result = 0;
- const Key* key;
- if (getKey(keyCode, &key)) {
- // Try to find the most general behavior that maps to this character.
- // For example, the base key behavior will usually be last in the list.
- // However, if we find a perfect meta state match for one behavior then use that one.
- for (const Behavior* behavior = key->firstBehavior; behavior; behavior = behavior->next) {
- if (behavior->character) {
- for (size_t i = 0; i < numChars; i++) {
- if (behavior->character == chars[i]) {
- result = behavior->character;
- if ((behavior->metaState & metaState) == behavior->metaState) {
- goto ExactMatch;
- }
- break;
- }
- }
- }
- }
- ExactMatch: ;
- }
-#if DEBUG_MAPPING
- ALOGD("getMatch: keyCode=%d, chars=[%s], metaState=0x%08x ~ Result %d.",
- keyCode, toString(chars, numChars).string(), metaState, result);
-#endif
- return result;
-}
-
-bool KeyCharacterMap::getEvents(int32_t deviceId, const char16_t* chars, size_t numChars,
- Vector<KeyEvent>& outEvents) const {
- nsecs_t now = systemTime(SYSTEM_TIME_MONOTONIC);
-
- for (size_t i = 0; i < numChars; i++) {
- int32_t keyCode, metaState;
- char16_t ch = chars[i];
- if (!findKey(ch, &keyCode, &metaState)) {
-#if DEBUG_MAPPING
- ALOGD("getEvents: deviceId=%d, chars=[%s] ~ Failed to find mapping for character %d.",
- deviceId, toString(chars, numChars).string(), ch);
-#endif
- return false;
- }
-
- int32_t currentMetaState = 0;
- addMetaKeys(outEvents, deviceId, metaState, true, now, ¤tMetaState);
- addKey(outEvents, deviceId, keyCode, currentMetaState, true, now);
- addKey(outEvents, deviceId, keyCode, currentMetaState, false, now);
- addMetaKeys(outEvents, deviceId, metaState, false, now, ¤tMetaState);
- }
-#if DEBUG_MAPPING
- ALOGD("getEvents: deviceId=%d, chars=[%s] ~ Generated %d events.",
- deviceId, toString(chars, numChars).string(), int32_t(outEvents.size()));
- for (size_t i = 0; i < outEvents.size(); i++) {
- ALOGD(" Key: keyCode=%d, metaState=0x%08x, %s.",
- outEvents[i].getKeyCode(), outEvents[i].getMetaState(),
- outEvents[i].getAction() == AKEY_EVENT_ACTION_DOWN ? "down" : "up");
- }
-#endif
- return true;
-}
-
-status_t KeyCharacterMap::mapKey(int32_t scanCode, int32_t usageCode, int32_t* outKeyCode) const {
- if (usageCode) {
- ssize_t index = mKeysByUsageCode.indexOfKey(usageCode);
- if (index >= 0) {
-#if DEBUG_MAPPING
- ALOGD("mapKey: scanCode=%d, usageCode=0x%08x ~ Result keyCode=%d.",
- scanCode, usageCode, *outKeyCode);
-#endif
- *outKeyCode = mKeysByUsageCode.valueAt(index);
- return OK;
- }
- }
- if (scanCode) {
- ssize_t index = mKeysByScanCode.indexOfKey(scanCode);
- if (index >= 0) {
-#if DEBUG_MAPPING
- ALOGD("mapKey: scanCode=%d, usageCode=0x%08x ~ Result keyCode=%d.",
- scanCode, usageCode, *outKeyCode);
-#endif
- *outKeyCode = mKeysByScanCode.valueAt(index);
- return OK;
- }
- }
-
-#if DEBUG_MAPPING
- ALOGD("mapKey: scanCode=%d, usageCode=0x%08x ~ Failed.", scanCode, usageCode);
-#endif
- *outKeyCode = AKEYCODE_UNKNOWN;
- return NAME_NOT_FOUND;
-}
-
-bool KeyCharacterMap::getKey(int32_t keyCode, const Key** outKey) const {
- ssize_t index = mKeys.indexOfKey(keyCode);
- if (index >= 0) {
- *outKey = mKeys.valueAt(index);
- return true;
- }
- return false;
-}
-
-bool KeyCharacterMap::getKeyBehavior(int32_t keyCode, int32_t metaState,
- const Key** outKey, const Behavior** outBehavior) const {
- const Key* key;
- if (getKey(keyCode, &key)) {
- const Behavior* behavior = key->firstBehavior;
- while (behavior) {
- if (matchesMetaState(metaState, behavior->metaState)) {
- *outKey = key;
- *outBehavior = behavior;
- return true;
- }
- behavior = behavior->next;
- }
- }
- return false;
-}
-
-bool KeyCharacterMap::matchesMetaState(int32_t eventMetaState, int32_t behaviorMetaState) {
- // Behavior must have at least the set of meta states specified.
- // And if the key event has CTRL, ALT or META then the behavior must exactly
- // match those, taking into account that a behavior can specify that it handles
- // one, both or either of a left/right modifier pair.
- if ((eventMetaState & behaviorMetaState) == behaviorMetaState) {
- const int32_t EXACT_META_STATES =
- AMETA_CTRL_ON | AMETA_CTRL_LEFT_ON | AMETA_CTRL_RIGHT_ON
- | AMETA_ALT_ON | AMETA_ALT_LEFT_ON | AMETA_ALT_RIGHT_ON
- | AMETA_META_ON | AMETA_META_LEFT_ON | AMETA_META_RIGHT_ON;
- int32_t unmatchedMetaState = eventMetaState & ~behaviorMetaState & EXACT_META_STATES;
- if (behaviorMetaState & AMETA_CTRL_ON) {
- unmatchedMetaState &= ~(AMETA_CTRL_LEFT_ON | AMETA_CTRL_RIGHT_ON);
- } else if (behaviorMetaState & (AMETA_CTRL_LEFT_ON | AMETA_CTRL_RIGHT_ON)) {
- unmatchedMetaState &= ~AMETA_CTRL_ON;
- }
- if (behaviorMetaState & AMETA_ALT_ON) {
- unmatchedMetaState &= ~(AMETA_ALT_LEFT_ON | AMETA_ALT_RIGHT_ON);
- } else if (behaviorMetaState & (AMETA_ALT_LEFT_ON | AMETA_ALT_RIGHT_ON)) {
- unmatchedMetaState &= ~AMETA_ALT_ON;
- }
- if (behaviorMetaState & AMETA_META_ON) {
- unmatchedMetaState &= ~(AMETA_META_LEFT_ON | AMETA_META_RIGHT_ON);
- } else if (behaviorMetaState & (AMETA_META_LEFT_ON | AMETA_META_RIGHT_ON)) {
- unmatchedMetaState &= ~AMETA_META_ON;
- }
- return !unmatchedMetaState;
- }
- return false;
-}
-
-bool KeyCharacterMap::findKey(char16_t ch, int32_t* outKeyCode, int32_t* outMetaState) const {
- if (!ch) {
- return false;
- }
-
- for (size_t i = 0; i < mKeys.size(); i++) {
- const Key* key = mKeys.valueAt(i);
-
- // Try to find the most general behavior that maps to this character.
- // For example, the base key behavior will usually be last in the list.
- const Behavior* found = NULL;
- for (const Behavior* behavior = key->firstBehavior; behavior; behavior = behavior->next) {
- if (behavior->character == ch) {
- found = behavior;
- }
- }
- if (found) {
- *outKeyCode = mKeys.keyAt(i);
- *outMetaState = found->metaState;
- return true;
- }
- }
- return false;
-}
-
-void KeyCharacterMap::addKey(Vector<KeyEvent>& outEvents,
- int32_t deviceId, int32_t keyCode, int32_t metaState, bool down, nsecs_t time) {
- outEvents.push();
- KeyEvent& event = outEvents.editTop();
- event.initialize(deviceId, AINPUT_SOURCE_KEYBOARD,
- down ? AKEY_EVENT_ACTION_DOWN : AKEY_EVENT_ACTION_UP,
- 0, keyCode, 0, metaState, 0, time, time);
-}
-
-void KeyCharacterMap::addMetaKeys(Vector<KeyEvent>& outEvents,
- int32_t deviceId, int32_t metaState, bool down, nsecs_t time,
- int32_t* currentMetaState) {
- // Add and remove meta keys symmetrically.
- if (down) {
- addLockedMetaKey(outEvents, deviceId, metaState, time,
- AKEYCODE_CAPS_LOCK, AMETA_CAPS_LOCK_ON, currentMetaState);
- addLockedMetaKey(outEvents, deviceId, metaState, time,
- AKEYCODE_NUM_LOCK, AMETA_NUM_LOCK_ON, currentMetaState);
- addLockedMetaKey(outEvents, deviceId, metaState, time,
- AKEYCODE_SCROLL_LOCK, AMETA_SCROLL_LOCK_ON, currentMetaState);
-
- addDoubleEphemeralMetaKey(outEvents, deviceId, metaState, true, time,
- AKEYCODE_SHIFT_LEFT, AMETA_SHIFT_LEFT_ON,
- AKEYCODE_SHIFT_RIGHT, AMETA_SHIFT_RIGHT_ON,
- AMETA_SHIFT_ON, currentMetaState);
- addDoubleEphemeralMetaKey(outEvents, deviceId, metaState, true, time,
- AKEYCODE_ALT_LEFT, AMETA_ALT_LEFT_ON,
- AKEYCODE_ALT_RIGHT, AMETA_ALT_RIGHT_ON,
- AMETA_ALT_ON, currentMetaState);
- addDoubleEphemeralMetaKey(outEvents, deviceId, metaState, true, time,
- AKEYCODE_CTRL_LEFT, AMETA_CTRL_LEFT_ON,
- AKEYCODE_CTRL_RIGHT, AMETA_CTRL_RIGHT_ON,
- AMETA_CTRL_ON, currentMetaState);
- addDoubleEphemeralMetaKey(outEvents, deviceId, metaState, true, time,
- AKEYCODE_META_LEFT, AMETA_META_LEFT_ON,
- AKEYCODE_META_RIGHT, AMETA_META_RIGHT_ON,
- AMETA_META_ON, currentMetaState);
-
- addSingleEphemeralMetaKey(outEvents, deviceId, metaState, true, time,
- AKEYCODE_SYM, AMETA_SYM_ON, currentMetaState);
- addSingleEphemeralMetaKey(outEvents, deviceId, metaState, true, time,
- AKEYCODE_FUNCTION, AMETA_FUNCTION_ON, currentMetaState);
- } else {
- addSingleEphemeralMetaKey(outEvents, deviceId, metaState, false, time,
- AKEYCODE_FUNCTION, AMETA_FUNCTION_ON, currentMetaState);
- addSingleEphemeralMetaKey(outEvents, deviceId, metaState, false, time,
- AKEYCODE_SYM, AMETA_SYM_ON, currentMetaState);
-
- addDoubleEphemeralMetaKey(outEvents, deviceId, metaState, false, time,
- AKEYCODE_META_LEFT, AMETA_META_LEFT_ON,
- AKEYCODE_META_RIGHT, AMETA_META_RIGHT_ON,
- AMETA_META_ON, currentMetaState);
- addDoubleEphemeralMetaKey(outEvents, deviceId, metaState, false, time,
- AKEYCODE_CTRL_LEFT, AMETA_CTRL_LEFT_ON,
- AKEYCODE_CTRL_RIGHT, AMETA_CTRL_RIGHT_ON,
- AMETA_CTRL_ON, currentMetaState);
- addDoubleEphemeralMetaKey(outEvents, deviceId, metaState, false, time,
- AKEYCODE_ALT_LEFT, AMETA_ALT_LEFT_ON,
- AKEYCODE_ALT_RIGHT, AMETA_ALT_RIGHT_ON,
- AMETA_ALT_ON, currentMetaState);
- addDoubleEphemeralMetaKey(outEvents, deviceId, metaState, false, time,
- AKEYCODE_SHIFT_LEFT, AMETA_SHIFT_LEFT_ON,
- AKEYCODE_SHIFT_RIGHT, AMETA_SHIFT_RIGHT_ON,
- AMETA_SHIFT_ON, currentMetaState);
-
- addLockedMetaKey(outEvents, deviceId, metaState, time,
- AKEYCODE_SCROLL_LOCK, AMETA_SCROLL_LOCK_ON, currentMetaState);
- addLockedMetaKey(outEvents, deviceId, metaState, time,
- AKEYCODE_NUM_LOCK, AMETA_NUM_LOCK_ON, currentMetaState);
- addLockedMetaKey(outEvents, deviceId, metaState, time,
- AKEYCODE_CAPS_LOCK, AMETA_CAPS_LOCK_ON, currentMetaState);
- }
-}
-
-bool KeyCharacterMap::addSingleEphemeralMetaKey(Vector<KeyEvent>& outEvents,
- int32_t deviceId, int32_t metaState, bool down, nsecs_t time,
- int32_t keyCode, int32_t keyMetaState,
- int32_t* currentMetaState) {
- if ((metaState & keyMetaState) == keyMetaState) {
- *currentMetaState = updateMetaState(keyCode, down, *currentMetaState);
- addKey(outEvents, deviceId, keyCode, *currentMetaState, down, time);
- return true;
- }
- return false;
-}
-
-void KeyCharacterMap::addDoubleEphemeralMetaKey(Vector<KeyEvent>& outEvents,
- int32_t deviceId, int32_t metaState, bool down, nsecs_t time,
- int32_t leftKeyCode, int32_t leftKeyMetaState,
- int32_t rightKeyCode, int32_t rightKeyMetaState,
- int32_t eitherKeyMetaState,
- int32_t* currentMetaState) {
- bool specific = false;
- specific |= addSingleEphemeralMetaKey(outEvents, deviceId, metaState, down, time,
- leftKeyCode, leftKeyMetaState, currentMetaState);
- specific |= addSingleEphemeralMetaKey(outEvents, deviceId, metaState, down, time,
- rightKeyCode, rightKeyMetaState, currentMetaState);
-
- if (!specific) {
- addSingleEphemeralMetaKey(outEvents, deviceId, metaState, down, time,
- leftKeyCode, eitherKeyMetaState, currentMetaState);
- }
-}
-
-void KeyCharacterMap::addLockedMetaKey(Vector<KeyEvent>& outEvents,
- int32_t deviceId, int32_t metaState, nsecs_t time,
- int32_t keyCode, int32_t keyMetaState,
- int32_t* currentMetaState) {
- if ((metaState & keyMetaState) == keyMetaState) {
- *currentMetaState = updateMetaState(keyCode, true, *currentMetaState);
- addKey(outEvents, deviceId, keyCode, *currentMetaState, true, time);
- *currentMetaState = updateMetaState(keyCode, false, *currentMetaState);
- addKey(outEvents, deviceId, keyCode, *currentMetaState, false, time);
- }
-}
-
-#if HAVE_ANDROID_OS
-sp<KeyCharacterMap> KeyCharacterMap::readFromParcel(Parcel* parcel) {
- sp<KeyCharacterMap> map = new KeyCharacterMap();
- map->mType = parcel->readInt32();
- size_t numKeys = parcel->readInt32();
- if (parcel->errorCheck()) {
- return NULL;
- }
-
- for (size_t i = 0; i < numKeys; i++) {
- int32_t keyCode = parcel->readInt32();
- char16_t label = parcel->readInt32();
- char16_t number = parcel->readInt32();
- if (parcel->errorCheck()) {
- return NULL;
- }
-
- Key* key = new Key();
- key->label = label;
- key->number = number;
- map->mKeys.add(keyCode, key);
-
- Behavior* lastBehavior = NULL;
- while (parcel->readInt32()) {
- int32_t metaState = parcel->readInt32();
- char16_t character = parcel->readInt32();
- int32_t fallbackKeyCode = parcel->readInt32();
- if (parcel->errorCheck()) {
- return NULL;
- }
-
- Behavior* behavior = new Behavior();
- behavior->metaState = metaState;
- behavior->character = character;
- behavior->fallbackKeyCode = fallbackKeyCode;
- if (lastBehavior) {
- lastBehavior->next = behavior;
- } else {
- key->firstBehavior = behavior;
- }
- lastBehavior = behavior;
- }
-
- if (parcel->errorCheck()) {
- return NULL;
- }
- }
- return map;
-}
-
-void KeyCharacterMap::writeToParcel(Parcel* parcel) const {
- parcel->writeInt32(mType);
-
- size_t numKeys = mKeys.size();
- parcel->writeInt32(numKeys);
- for (size_t i = 0; i < numKeys; i++) {
- int32_t keyCode = mKeys.keyAt(i);
- const Key* key = mKeys.valueAt(i);
- parcel->writeInt32(keyCode);
- parcel->writeInt32(key->label);
- parcel->writeInt32(key->number);
- for (const Behavior* behavior = key->firstBehavior; behavior != NULL;
- behavior = behavior->next) {
- parcel->writeInt32(1);
- parcel->writeInt32(behavior->metaState);
- parcel->writeInt32(behavior->character);
- parcel->writeInt32(behavior->fallbackKeyCode);
- }
- parcel->writeInt32(0);
- }
-}
-#endif
-
-
-// --- KeyCharacterMap::Key ---
-
-KeyCharacterMap::Key::Key() :
- label(0), number(0), firstBehavior(NULL) {
-}
-
-KeyCharacterMap::Key::Key(const Key& other) :
- label(other.label), number(other.number),
- firstBehavior(other.firstBehavior ? new Behavior(*other.firstBehavior) : NULL) {
-}
-
-KeyCharacterMap::Key::~Key() {
- Behavior* behavior = firstBehavior;
- while (behavior) {
- Behavior* next = behavior->next;
- delete behavior;
- behavior = next;
- }
-}
-
-
-// --- KeyCharacterMap::Behavior ---
-
-KeyCharacterMap::Behavior::Behavior() :
- next(NULL), metaState(0), character(0), fallbackKeyCode(0) {
-}
-
-KeyCharacterMap::Behavior::Behavior(const Behavior& other) :
- next(other.next ? new Behavior(*other.next) : NULL),
- metaState(other.metaState), character(other.character),
- fallbackKeyCode(other.fallbackKeyCode) {
-}
-
-
-// --- KeyCharacterMap::Parser ---
-
-KeyCharacterMap::Parser::Parser(KeyCharacterMap* map, Tokenizer* tokenizer, Format format) :
- mMap(map), mTokenizer(tokenizer), mFormat(format), mState(STATE_TOP) {
-}
-
-KeyCharacterMap::Parser::~Parser() {
-}
-
-status_t KeyCharacterMap::Parser::parse() {
- while (!mTokenizer->isEof()) {
-#if DEBUG_PARSER
- ALOGD("Parsing %s: '%s'.", mTokenizer->getLocation().string(),
- mTokenizer->peekRemainderOfLine().string());
-#endif
-
- mTokenizer->skipDelimiters(WHITESPACE);
-
- if (!mTokenizer->isEol() && mTokenizer->peekChar() != '#') {
- switch (mState) {
- case STATE_TOP: {
- String8 keywordToken = mTokenizer->nextToken(WHITESPACE);
- if (keywordToken == "type") {
- mTokenizer->skipDelimiters(WHITESPACE);
- status_t status = parseType();
- if (status) return status;
- } else if (keywordToken == "map") {
- mTokenizer->skipDelimiters(WHITESPACE);
- status_t status = parseMap();
- if (status) return status;
- } else if (keywordToken == "key") {
- mTokenizer->skipDelimiters(WHITESPACE);
- status_t status = parseKey();
- if (status) return status;
- } else {
- ALOGE("%s: Expected keyword, got '%s'.", mTokenizer->getLocation().string(),
- keywordToken.string());
- return BAD_VALUE;
- }
- break;
- }
-
- case STATE_KEY: {
- status_t status = parseKeyProperty();
- if (status) return status;
- break;
- }
- }
-
- mTokenizer->skipDelimiters(WHITESPACE);
- if (!mTokenizer->isEol() && mTokenizer->peekChar() != '#') {
- ALOGE("%s: Expected end of line or trailing comment, got '%s'.",
- mTokenizer->getLocation().string(),
- mTokenizer->peekRemainderOfLine().string());
- return BAD_VALUE;
- }
- }
-
- mTokenizer->nextLine();
- }
-
- if (mState != STATE_TOP) {
- ALOGE("%s: Unterminated key description at end of file.",
- mTokenizer->getLocation().string());
- return BAD_VALUE;
- }
-
- if (mMap->mType == KEYBOARD_TYPE_UNKNOWN) {
- ALOGE("%s: Keyboard layout missing required keyboard 'type' declaration.",
- mTokenizer->getLocation().string());
- return BAD_VALUE;
- }
-
- if (mFormat == FORMAT_BASE) {
- if (mMap->mType == KEYBOARD_TYPE_OVERLAY) {
- ALOGE("%s: Base keyboard layout must specify a keyboard 'type' other than 'OVERLAY'.",
- mTokenizer->getLocation().string());
- return BAD_VALUE;
- }
- } else if (mFormat == FORMAT_OVERLAY) {
- if (mMap->mType != KEYBOARD_TYPE_OVERLAY) {
- ALOGE("%s: Overlay keyboard layout missing required keyboard "
- "'type OVERLAY' declaration.",
- mTokenizer->getLocation().string());
- return BAD_VALUE;
- }
- }
-
- return NO_ERROR;
-}
-
-status_t KeyCharacterMap::Parser::parseType() {
- if (mMap->mType != KEYBOARD_TYPE_UNKNOWN) {
- ALOGE("%s: Duplicate keyboard 'type' declaration.",
- mTokenizer->getLocation().string());
- return BAD_VALUE;
- }
-
- KeyboardType type;
- String8 typeToken = mTokenizer->nextToken(WHITESPACE);
- if (typeToken == "NUMERIC") {
- type = KEYBOARD_TYPE_NUMERIC;
- } else if (typeToken == "PREDICTIVE") {
- type = KEYBOARD_TYPE_PREDICTIVE;
- } else if (typeToken == "ALPHA") {
- type = KEYBOARD_TYPE_ALPHA;
- } else if (typeToken == "FULL") {
- type = KEYBOARD_TYPE_FULL;
- } else if (typeToken == "SPECIAL_FUNCTION") {
- type = KEYBOARD_TYPE_SPECIAL_FUNCTION;
- } else if (typeToken == "OVERLAY") {
- type = KEYBOARD_TYPE_OVERLAY;
- } else {
- ALOGE("%s: Expected keyboard type label, got '%s'.", mTokenizer->getLocation().string(),
- typeToken.string());
- return BAD_VALUE;
- }
-
-#if DEBUG_PARSER
- ALOGD("Parsed type: type=%d.", type);
-#endif
- mMap->mType = type;
- return NO_ERROR;
-}
-
-status_t KeyCharacterMap::Parser::parseMap() {
- String8 keywordToken = mTokenizer->nextToken(WHITESPACE);
- if (keywordToken == "key") {
- mTokenizer->skipDelimiters(WHITESPACE);
- return parseMapKey();
- }
- ALOGE("%s: Expected keyword after 'map', got '%s'.", mTokenizer->getLocation().string(),
- keywordToken.string());
- return BAD_VALUE;
-}
-
-status_t KeyCharacterMap::Parser::parseMapKey() {
- String8 codeToken = mTokenizer->nextToken(WHITESPACE);
- bool mapUsage = false;
- if (codeToken == "usage") {
- mapUsage = true;
- mTokenizer->skipDelimiters(WHITESPACE);
- codeToken = mTokenizer->nextToken(WHITESPACE);
- }
-
- char* end;
- int32_t code = int32_t(strtol(codeToken.string(), &end, 0));
- if (*end) {
- ALOGE("%s: Expected key %s number, got '%s'.", mTokenizer->getLocation().string(),
- mapUsage ? "usage" : "scan code", codeToken.string());
- return BAD_VALUE;
- }
- KeyedVector<int32_t, int32_t>& map =
- mapUsage ? mMap->mKeysByUsageCode : mMap->mKeysByScanCode;
- if (map.indexOfKey(code) >= 0) {
- ALOGE("%s: Duplicate entry for key %s '%s'.", mTokenizer->getLocation().string(),
- mapUsage ? "usage" : "scan code", codeToken.string());
- return BAD_VALUE;
- }
-
- mTokenizer->skipDelimiters(WHITESPACE);
- String8 keyCodeToken = mTokenizer->nextToken(WHITESPACE);
- int32_t keyCode = getKeyCodeByLabel(keyCodeToken.string());
- if (!keyCode) {
- ALOGE("%s: Expected key code label, got '%s'.", mTokenizer->getLocation().string(),
- keyCodeToken.string());
- return BAD_VALUE;
- }
-
-#if DEBUG_PARSER
- ALOGD("Parsed map key %s: code=%d, keyCode=%d.",
- mapUsage ? "usage" : "scan code", code, keyCode);
-#endif
- map.add(code, keyCode);
- return NO_ERROR;
-}
-
-status_t KeyCharacterMap::Parser::parseKey() {
- String8 keyCodeToken = mTokenizer->nextToken(WHITESPACE);
- int32_t keyCode = getKeyCodeByLabel(keyCodeToken.string());
- if (!keyCode) {
- ALOGE("%s: Expected key code label, got '%s'.", mTokenizer->getLocation().string(),
- keyCodeToken.string());
- return BAD_VALUE;
- }
- if (mMap->mKeys.indexOfKey(keyCode) >= 0) {
- ALOGE("%s: Duplicate entry for key code '%s'.", mTokenizer->getLocation().string(),
- keyCodeToken.string());
- return BAD_VALUE;
- }
-
- mTokenizer->skipDelimiters(WHITESPACE);
- String8 openBraceToken = mTokenizer->nextToken(WHITESPACE);
- if (openBraceToken != "{") {
- ALOGE("%s: Expected '{' after key code label, got '%s'.",
- mTokenizer->getLocation().string(), openBraceToken.string());
- return BAD_VALUE;
- }
-
-#if DEBUG_PARSER
- ALOGD("Parsed beginning of key: keyCode=%d.", keyCode);
-#endif
- mKeyCode = keyCode;
- mMap->mKeys.add(keyCode, new Key());
- mState = STATE_KEY;
- return NO_ERROR;
-}
-
-status_t KeyCharacterMap::Parser::parseKeyProperty() {
- Key* key = mMap->mKeys.valueFor(mKeyCode);
- String8 token = mTokenizer->nextToken(WHITESPACE_OR_PROPERTY_DELIMITER);
- if (token == "}") {
- mState = STATE_TOP;
- return finishKey(key);
- }
-
- Vector<Property> properties;
-
- // Parse all comma-delimited property names up to the first colon.
- for (;;) {
- if (token == "label") {
- properties.add(Property(PROPERTY_LABEL));
- } else if (token == "number") {
- properties.add(Property(PROPERTY_NUMBER));
- } else {
- int32_t metaState;
- status_t status = parseModifier(token, &metaState);
- if (status) {
- ALOGE("%s: Expected a property name or modifier, got '%s'.",
- mTokenizer->getLocation().string(), token.string());
- return status;
- }
- properties.add(Property(PROPERTY_META, metaState));
- }
-
- mTokenizer->skipDelimiters(WHITESPACE);
- if (!mTokenizer->isEol()) {
- char ch = mTokenizer->nextChar();
- if (ch == ':') {
- break;
- } else if (ch == ',') {
- mTokenizer->skipDelimiters(WHITESPACE);
- token = mTokenizer->nextToken(WHITESPACE_OR_PROPERTY_DELIMITER);
- continue;
- }
- }
-
- ALOGE("%s: Expected ',' or ':' after property name.",
- mTokenizer->getLocation().string());
- return BAD_VALUE;
- }
-
- // Parse behavior after the colon.
- mTokenizer->skipDelimiters(WHITESPACE);
-
- Behavior behavior;
- bool haveCharacter = false;
- bool haveFallback = false;
-
- do {
- char ch = mTokenizer->peekChar();
- if (ch == '\'') {
- char16_t character;
- status_t status = parseCharacterLiteral(&character);
- if (status || !character) {
- ALOGE("%s: Invalid character literal for key.",
- mTokenizer->getLocation().string());
- return BAD_VALUE;
- }
- if (haveCharacter) {
- ALOGE("%s: Cannot combine multiple character literals or 'none'.",
- mTokenizer->getLocation().string());
- return BAD_VALUE;
- }
- behavior.character = character;
- haveCharacter = true;
- } else {
- token = mTokenizer->nextToken(WHITESPACE);
- if (token == "none") {
- if (haveCharacter) {
- ALOGE("%s: Cannot combine multiple character literals or 'none'.",
- mTokenizer->getLocation().string());
- return BAD_VALUE;
- }
- haveCharacter = true;
- } else if (token == "fallback") {
- mTokenizer->skipDelimiters(WHITESPACE);
- token = mTokenizer->nextToken(WHITESPACE);
- int32_t keyCode = getKeyCodeByLabel(token.string());
- if (!keyCode) {
- ALOGE("%s: Invalid key code label for fallback behavior, got '%s'.",
- mTokenizer->getLocation().string(),
- token.string());
- return BAD_VALUE;
- }
- if (haveFallback) {
- ALOGE("%s: Cannot combine multiple fallback key codes.",
- mTokenizer->getLocation().string());
- return BAD_VALUE;
- }
- behavior.fallbackKeyCode = keyCode;
- haveFallback = true;
- } else {
- ALOGE("%s: Expected a key behavior after ':'.",
- mTokenizer->getLocation().string());
- return BAD_VALUE;
- }
- }
-
- mTokenizer->skipDelimiters(WHITESPACE);
- } while (!mTokenizer->isEol() && mTokenizer->peekChar() != '#');
-
- // Add the behavior.
- for (size_t i = 0; i < properties.size(); i++) {
- const Property& property = properties.itemAt(i);
- switch (property.property) {
- case PROPERTY_LABEL:
- if (key->label) {
- ALOGE("%s: Duplicate label for key.",
- mTokenizer->getLocation().string());
- return BAD_VALUE;
- }
- key->label = behavior.character;
-#if DEBUG_PARSER
- ALOGD("Parsed key label: keyCode=%d, label=%d.", mKeyCode, key->label);
-#endif
- break;
- case PROPERTY_NUMBER:
- if (key->number) {
- ALOGE("%s: Duplicate number for key.",
- mTokenizer->getLocation().string());
- return BAD_VALUE;
- }
- key->number = behavior.character;
-#if DEBUG_PARSER
- ALOGD("Parsed key number: keyCode=%d, number=%d.", mKeyCode, key->number);
-#endif
- break;
- case PROPERTY_META: {
- for (Behavior* b = key->firstBehavior; b; b = b->next) {
- if (b->metaState == property.metaState) {
- ALOGE("%s: Duplicate key behavior for modifier.",
- mTokenizer->getLocation().string());
- return BAD_VALUE;
- }
- }
- Behavior* newBehavior = new Behavior(behavior);
- newBehavior->metaState = property.metaState;
- newBehavior->next = key->firstBehavior;
- key->firstBehavior = newBehavior;
-#if DEBUG_PARSER
- ALOGD("Parsed key meta: keyCode=%d, meta=0x%x, char=%d, fallback=%d.", mKeyCode,
- newBehavior->metaState, newBehavior->character, newBehavior->fallbackKeyCode);
-#endif
- break;
- }
- }
- }
- return NO_ERROR;
-}
-
-status_t KeyCharacterMap::Parser::finishKey(Key* key) {
- // Fill in default number property.
- if (!key->number) {
- char16_t digit = 0;
- char16_t symbol = 0;
- for (Behavior* b = key->firstBehavior; b; b = b->next) {
- char16_t ch = b->character;
- if (ch) {
- if (ch >= '0' && ch <= '9') {
- digit = ch;
- } else if (ch == '(' || ch == ')' || ch == '#' || ch == '*'
- || ch == '-' || ch == '+' || ch == ',' || ch == '.'
- || ch == '\'' || ch == ':' || ch == ';' || ch == '/') {
- symbol = ch;
- }
- }
- }
- key->number = digit ? digit : symbol;
- }
- return NO_ERROR;
-}
-
-status_t KeyCharacterMap::Parser::parseModifier(const String8& token, int32_t* outMetaState) {
- if (token == "base") {
- *outMetaState = 0;
- return NO_ERROR;
- }
-
- int32_t combinedMeta = 0;
-
- const char* str = token.string();
- const char* start = str;
- for (const char* cur = str; ; cur++) {
- char ch = *cur;
- if (ch == '+' || ch == '\0') {
- size_t len = cur - start;
- int32_t metaState = 0;
- for (size_t i = 0; i < sizeof(modifiers) / sizeof(Modifier); i++) {
- if (strlen(modifiers[i].label) == len
- && strncmp(modifiers[i].label, start, len) == 0) {
- metaState = modifiers[i].metaState;
- break;
- }
- }
- if (!metaState) {
- return BAD_VALUE;
- }
- if (combinedMeta & metaState) {
- ALOGE("%s: Duplicate modifier combination '%s'.",
- mTokenizer->getLocation().string(), token.string());
- return BAD_VALUE;
- }
-
- combinedMeta |= metaState;
- start = cur + 1;
-
- if (ch == '\0') {
- break;
- }
- }
- }
- *outMetaState = combinedMeta;
- return NO_ERROR;
-}
-
-status_t KeyCharacterMap::Parser::parseCharacterLiteral(char16_t* outCharacter) {
- char ch = mTokenizer->nextChar();
- if (ch != '\'') {
- goto Error;
- }
-
- ch = mTokenizer->nextChar();
- if (ch == '\\') {
- // Escape sequence.
- ch = mTokenizer->nextChar();
- if (ch == 'n') {
- *outCharacter = '\n';
- } else if (ch == 't') {
- *outCharacter = '\t';
- } else if (ch == '\\') {
- *outCharacter = '\\';
- } else if (ch == '\'') {
- *outCharacter = '\'';
- } else if (ch == '"') {
- *outCharacter = '"';
- } else if (ch == 'u') {
- *outCharacter = 0;
- for (int i = 0; i < 4; i++) {
- ch = mTokenizer->nextChar();
- int digit;
- if (ch >= '0' && ch <= '9') {
- digit = ch - '0';
- } else if (ch >= 'A' && ch <= 'F') {
- digit = ch - 'A' + 10;
- } else if (ch >= 'a' && ch <= 'f') {
- digit = ch - 'a' + 10;
- } else {
- goto Error;
- }
- *outCharacter = (*outCharacter << 4) | digit;
- }
- } else {
- goto Error;
- }
- } else if (ch >= 32 && ch <= 126 && ch != '\'') {
- // ASCII literal character.
- *outCharacter = ch;
- } else {
- goto Error;
- }
-
- ch = mTokenizer->nextChar();
- if (ch != '\'') {
- goto Error;
- }
-
- // Ensure that we consumed the entire token.
- if (mTokenizer->nextToken(WHITESPACE).isEmpty()) {
- return NO_ERROR;
- }
-
-Error:
- ALOGE("%s: Malformed character literal.", mTokenizer->getLocation().string());
- return BAD_VALUE;
-}
-
-} // namespace android
diff --git a/libs/androidfw/KeyLayoutMap.cpp b/libs/androidfw/KeyLayoutMap.cpp
deleted file mode 100644
index ae14f23..0000000
--- a/libs/androidfw/KeyLayoutMap.cpp
+++ /dev/null
@@ -1,366 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#define LOG_TAG "KeyLayoutMap"
-
-#include <stdlib.h>
-#include <android/keycodes.h>
-#include <androidfw/Keyboard.h>
-#include <androidfw/KeyLayoutMap.h>
-#include <utils/Log.h>
-#include <utils/Errors.h>
-#include <utils/Tokenizer.h>
-#include <utils/Timers.h>
-
-// Enables debug output for the parser.
-#define DEBUG_PARSER 0
-
-// Enables debug output for parser performance.
-#define DEBUG_PARSER_PERFORMANCE 0
-
-// Enables debug output for mapping.
-#define DEBUG_MAPPING 0
-
-
-namespace android {
-
-static const char* WHITESPACE = " \t\r";
-
-// --- KeyLayoutMap ---
-
-KeyLayoutMap::KeyLayoutMap() {
-}
-
-KeyLayoutMap::~KeyLayoutMap() {
-}
-
-status_t KeyLayoutMap::load(const String8& filename, sp<KeyLayoutMap>* outMap) {
- outMap->clear();
-
- Tokenizer* tokenizer;
- status_t status = Tokenizer::open(filename, &tokenizer);
- if (status) {
- ALOGE("Error %d opening key layout map file %s.", status, filename.string());
- } else {
- sp<KeyLayoutMap> map = new KeyLayoutMap();
- if (!map.get()) {
- ALOGE("Error allocating key layout map.");
- status = NO_MEMORY;
- } else {
-#if DEBUG_PARSER_PERFORMANCE
- nsecs_t startTime = systemTime(SYSTEM_TIME_MONOTONIC);
-#endif
- Parser parser(map.get(), tokenizer);
- status = parser.parse();
-#if DEBUG_PARSER_PERFORMANCE
- nsecs_t elapsedTime = systemTime(SYSTEM_TIME_MONOTONIC) - startTime;
- ALOGD("Parsed key layout map file '%s' %d lines in %0.3fms.",
- tokenizer->getFilename().string(), tokenizer->getLineNumber(),
- elapsedTime / 1000000.0);
-#endif
- if (!status) {
- *outMap = map;
- }
- }
- delete tokenizer;
- }
- return status;
-}
-
-status_t KeyLayoutMap::mapKey(int32_t scanCode, int32_t usageCode,
- int32_t* outKeyCode, uint32_t* outFlags) const {
- const Key* key = getKey(scanCode, usageCode);
- if (!key) {
-#if DEBUG_MAPPING
- ALOGD("mapKey: scanCode=%d, usageCode=0x%08x ~ Failed.", scanCode, usageCode);
-#endif
- *outKeyCode = AKEYCODE_UNKNOWN;
- *outFlags = 0;
- return NAME_NOT_FOUND;
- }
-
- *outKeyCode = key->keyCode;
- *outFlags = key->flags;
-
-#if DEBUG_MAPPING
- ALOGD("mapKey: scanCode=%d, usageCode=0x%08x ~ Result keyCode=%d, outFlags=0x%08x.",
- scanCode, usageCode, *outKeyCode, *outFlags);
-#endif
- return NO_ERROR;
-}
-
-const KeyLayoutMap::Key* KeyLayoutMap::getKey(int32_t scanCode, int32_t usageCode) const {
- if (usageCode) {
- ssize_t index = mKeysByUsageCode.indexOfKey(usageCode);
- if (index >= 0) {
- return &mKeysByUsageCode.valueAt(index);
- }
- }
- if (scanCode) {
- ssize_t index = mKeysByScanCode.indexOfKey(scanCode);
- if (index >= 0) {
- return &mKeysByScanCode.valueAt(index);
- }
- }
- return NULL;
-}
-
-status_t KeyLayoutMap::findScanCodesForKey(int32_t keyCode, Vector<int32_t>* outScanCodes) const {
- const size_t N = mKeysByScanCode.size();
- for (size_t i=0; i<N; i++) {
- if (mKeysByScanCode.valueAt(i).keyCode == keyCode) {
- outScanCodes->add(mKeysByScanCode.keyAt(i));
- }
- }
- return NO_ERROR;
-}
-
-status_t KeyLayoutMap::mapAxis(int32_t scanCode, AxisInfo* outAxisInfo) const {
- ssize_t index = mAxes.indexOfKey(scanCode);
- if (index < 0) {
-#if DEBUG_MAPPING
- ALOGD("mapAxis: scanCode=%d ~ Failed.", scanCode);
-#endif
- return NAME_NOT_FOUND;
- }
-
- *outAxisInfo = mAxes.valueAt(index);
-
-#if DEBUG_MAPPING
- ALOGD("mapAxis: scanCode=%d ~ Result mode=%d, axis=%d, highAxis=%d, "
- "splitValue=%d, flatOverride=%d.",
- scanCode,
- outAxisInfo->mode, outAxisInfo->axis, outAxisInfo->highAxis,
- outAxisInfo->splitValue, outAxisInfo->flatOverride);
-#endif
- return NO_ERROR;
-}
-
-
-// --- KeyLayoutMap::Parser ---
-
-KeyLayoutMap::Parser::Parser(KeyLayoutMap* map, Tokenizer* tokenizer) :
- mMap(map), mTokenizer(tokenizer) {
-}
-
-KeyLayoutMap::Parser::~Parser() {
-}
-
-status_t KeyLayoutMap::Parser::parse() {
- while (!mTokenizer->isEof()) {
-#if DEBUG_PARSER
- ALOGD("Parsing %s: '%s'.", mTokenizer->getLocation().string(),
- mTokenizer->peekRemainderOfLine().string());
-#endif
-
- mTokenizer->skipDelimiters(WHITESPACE);
-
- if (!mTokenizer->isEol() && mTokenizer->peekChar() != '#') {
- String8 keywordToken = mTokenizer->nextToken(WHITESPACE);
- if (keywordToken == "key") {
- mTokenizer->skipDelimiters(WHITESPACE);
- status_t status = parseKey();
- if (status) return status;
- } else if (keywordToken == "axis") {
- mTokenizer->skipDelimiters(WHITESPACE);
- status_t status = parseAxis();
- if (status) return status;
- } else {
- ALOGE("%s: Expected keyword, got '%s'.", mTokenizer->getLocation().string(),
- keywordToken.string());
- return BAD_VALUE;
- }
-
- mTokenizer->skipDelimiters(WHITESPACE);
- if (!mTokenizer->isEol() && mTokenizer->peekChar() != '#') {
- ALOGE("%s: Expected end of line or trailing comment, got '%s'.",
- mTokenizer->getLocation().string(),
- mTokenizer->peekRemainderOfLine().string());
- return BAD_VALUE;
- }
- }
-
- mTokenizer->nextLine();
- }
- return NO_ERROR;
-}
-
-status_t KeyLayoutMap::Parser::parseKey() {
- String8 codeToken = mTokenizer->nextToken(WHITESPACE);
- bool mapUsage = false;
- if (codeToken == "usage") {
- mapUsage = true;
- mTokenizer->skipDelimiters(WHITESPACE);
- codeToken = mTokenizer->nextToken(WHITESPACE);
- }
-
- char* end;
- int32_t code = int32_t(strtol(codeToken.string(), &end, 0));
- if (*end) {
- ALOGE("%s: Expected key %s number, got '%s'.", mTokenizer->getLocation().string(),
- mapUsage ? "usage" : "scan code", codeToken.string());
- return BAD_VALUE;
- }
- KeyedVector<int32_t, Key>& map =
- mapUsage ? mMap->mKeysByUsageCode : mMap->mKeysByScanCode;
- if (map.indexOfKey(code) >= 0) {
- ALOGE("%s: Duplicate entry for key %s '%s'.", mTokenizer->getLocation().string(),
- mapUsage ? "usage" : "scan code", codeToken.string());
- return BAD_VALUE;
- }
-
- mTokenizer->skipDelimiters(WHITESPACE);
- String8 keyCodeToken = mTokenizer->nextToken(WHITESPACE);
- int32_t keyCode = getKeyCodeByLabel(keyCodeToken.string());
- if (!keyCode) {
- ALOGE("%s: Expected key code label, got '%s'.", mTokenizer->getLocation().string(),
- keyCodeToken.string());
- return BAD_VALUE;
- }
-
- uint32_t flags = 0;
- for (;;) {
- mTokenizer->skipDelimiters(WHITESPACE);
- if (mTokenizer->isEol() || mTokenizer->peekChar() == '#') break;
-
- String8 flagToken = mTokenizer->nextToken(WHITESPACE);
- uint32_t flag = getKeyFlagByLabel(flagToken.string());
- if (!flag) {
- ALOGE("%s: Expected key flag label, got '%s'.", mTokenizer->getLocation().string(),
- flagToken.string());
- return BAD_VALUE;
- }
- if (flags & flag) {
- ALOGE("%s: Duplicate key flag '%s'.", mTokenizer->getLocation().string(),
- flagToken.string());
- return BAD_VALUE;
- }
- flags |= flag;
- }
-
-#if DEBUG_PARSER
- ALOGD("Parsed key %s: code=%d, keyCode=%d, flags=0x%08x.",
- mapUsage ? "usage" : "scan code", code, keyCode, flags);
-#endif
- Key key;
- key.keyCode = keyCode;
- key.flags = flags;
- map.add(code, key);
- return NO_ERROR;
-}
-
-status_t KeyLayoutMap::Parser::parseAxis() {
- String8 scanCodeToken = mTokenizer->nextToken(WHITESPACE);
- char* end;
- int32_t scanCode = int32_t(strtol(scanCodeToken.string(), &end, 0));
- if (*end) {
- ALOGE("%s: Expected axis scan code number, got '%s'.", mTokenizer->getLocation().string(),
- scanCodeToken.string());
- return BAD_VALUE;
- }
- if (mMap->mAxes.indexOfKey(scanCode) >= 0) {
- ALOGE("%s: Duplicate entry for axis scan code '%s'.", mTokenizer->getLocation().string(),
- scanCodeToken.string());
- return BAD_VALUE;
- }
-
- AxisInfo axisInfo;
-
- mTokenizer->skipDelimiters(WHITESPACE);
- String8 token = mTokenizer->nextToken(WHITESPACE);
- if (token == "invert") {
- axisInfo.mode = AxisInfo::MODE_INVERT;
-
- mTokenizer->skipDelimiters(WHITESPACE);
- String8 axisToken = mTokenizer->nextToken(WHITESPACE);
- axisInfo.axis = getAxisByLabel(axisToken.string());
- if (axisInfo.axis < 0) {
- ALOGE("%s: Expected inverted axis label, got '%s'.",
- mTokenizer->getLocation().string(), axisToken.string());
- return BAD_VALUE;
- }
- } else if (token == "split") {
- axisInfo.mode = AxisInfo::MODE_SPLIT;
-
- mTokenizer->skipDelimiters(WHITESPACE);
- String8 splitToken = mTokenizer->nextToken(WHITESPACE);
- axisInfo.splitValue = int32_t(strtol(splitToken.string(), &end, 0));
- if (*end) {
- ALOGE("%s: Expected split value, got '%s'.",
- mTokenizer->getLocation().string(), splitToken.string());
- return BAD_VALUE;
- }
-
- mTokenizer->skipDelimiters(WHITESPACE);
- String8 lowAxisToken = mTokenizer->nextToken(WHITESPACE);
- axisInfo.axis = getAxisByLabel(lowAxisToken.string());
- if (axisInfo.axis < 0) {
- ALOGE("%s: Expected low axis label, got '%s'.",
- mTokenizer->getLocation().string(), lowAxisToken.string());
- return BAD_VALUE;
- }
-
- mTokenizer->skipDelimiters(WHITESPACE);
- String8 highAxisToken = mTokenizer->nextToken(WHITESPACE);
- axisInfo.highAxis = getAxisByLabel(highAxisToken.string());
- if (axisInfo.highAxis < 0) {
- ALOGE("%s: Expected high axis label, got '%s'.",
- mTokenizer->getLocation().string(), highAxisToken.string());
- return BAD_VALUE;
- }
- } else {
- axisInfo.axis = getAxisByLabel(token.string());
- if (axisInfo.axis < 0) {
- ALOGE("%s: Expected axis label, 'split' or 'invert', got '%s'.",
- mTokenizer->getLocation().string(), token.string());
- return BAD_VALUE;
- }
- }
-
- for (;;) {
- mTokenizer->skipDelimiters(WHITESPACE);
- if (mTokenizer->isEol() || mTokenizer->peekChar() == '#') {
- break;
- }
- String8 keywordToken = mTokenizer->nextToken(WHITESPACE);
- if (keywordToken == "flat") {
- mTokenizer->skipDelimiters(WHITESPACE);
- String8 flatToken = mTokenizer->nextToken(WHITESPACE);
- axisInfo.flatOverride = int32_t(strtol(flatToken.string(), &end, 0));
- if (*end) {
- ALOGE("%s: Expected flat value, got '%s'.",
- mTokenizer->getLocation().string(), flatToken.string());
- return BAD_VALUE;
- }
- } else {
- ALOGE("%s: Expected keyword 'flat', got '%s'.",
- mTokenizer->getLocation().string(), keywordToken.string());
- return BAD_VALUE;
- }
- }
-
-#if DEBUG_PARSER
- ALOGD("Parsed axis: scanCode=%d, mode=%d, axis=%d, highAxis=%d, "
- "splitValue=%d, flatOverride=%d.",
- scanCode,
- axisInfo.mode, axisInfo.axis, axisInfo.highAxis,
- axisInfo.splitValue, axisInfo.flatOverride);
-#endif
- mMap->mAxes.add(scanCode, axisInfo);
- return NO_ERROR;
-}
-
-};
diff --git a/libs/androidfw/Keyboard.cpp b/libs/androidfw/Keyboard.cpp
deleted file mode 100644
index 26a4e6a..0000000
--- a/libs/androidfw/Keyboard.cpp
+++ /dev/null
@@ -1,297 +0,0 @@
-/*
- * Copyright (C) 2010 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#define LOG_TAG "Keyboard"
-
-#include <stdlib.h>
-#include <unistd.h>
-#include <limits.h>
-
-#include <androidfw/Keyboard.h>
-#include <androidfw/KeycodeLabels.h>
-#include <androidfw/KeyLayoutMap.h>
-#include <androidfw/KeyCharacterMap.h>
-#include <androidfw/InputDevice.h>
-#include <utils/Errors.h>
-#include <utils/Log.h>
-
-namespace android {
-
-// --- KeyMap ---
-
-KeyMap::KeyMap() {
-}
-
-KeyMap::~KeyMap() {
-}
-
-status_t KeyMap::load(const InputDeviceIdentifier& deviceIdenfifier,
- const PropertyMap* deviceConfiguration) {
- // Use the configured key layout if available.
- if (deviceConfiguration) {
- String8 keyLayoutName;
- if (deviceConfiguration->tryGetProperty(String8("keyboard.layout"),
- keyLayoutName)) {
- status_t status = loadKeyLayout(deviceIdenfifier, keyLayoutName);
- if (status == NAME_NOT_FOUND) {
- ALOGE("Configuration for keyboard device '%s' requested keyboard layout '%s' but "
- "it was not found.",
- deviceIdenfifier.name.string(), keyLayoutName.string());
- }
- }
-
- String8 keyCharacterMapName;
- if (deviceConfiguration->tryGetProperty(String8("keyboard.characterMap"),
- keyCharacterMapName)) {
- status_t status = loadKeyCharacterMap(deviceIdenfifier, keyCharacterMapName);
- if (status == NAME_NOT_FOUND) {
- ALOGE("Configuration for keyboard device '%s' requested keyboard character "
- "map '%s' but it was not found.",
- deviceIdenfifier.name.string(), keyLayoutName.string());
- }
- }
-
- if (isComplete()) {
- return OK;
- }
- }
-
- // Try searching by device identifier.
- if (probeKeyMap(deviceIdenfifier, String8::empty())) {
- return OK;
- }
-
- // Fall back on the Generic key map.
- // TODO Apply some additional heuristics here to figure out what kind of
- // generic key map to use (US English, etc.) for typical external keyboards.
- if (probeKeyMap(deviceIdenfifier, String8("Generic"))) {
- return OK;
- }
-
- // Try the Virtual key map as a last resort.
- if (probeKeyMap(deviceIdenfifier, String8("Virtual"))) {
- return OK;
- }
-
- // Give up!
- ALOGE("Could not determine key map for device '%s' and no default key maps were found!",
- deviceIdenfifier.name.string());
- return NAME_NOT_FOUND;
-}
-
-bool KeyMap::probeKeyMap(const InputDeviceIdentifier& deviceIdentifier,
- const String8& keyMapName) {
- if (!haveKeyLayout()) {
- loadKeyLayout(deviceIdentifier, keyMapName);
- }
- if (!haveKeyCharacterMap()) {
- loadKeyCharacterMap(deviceIdentifier, keyMapName);
- }
- return isComplete();
-}
-
-status_t KeyMap::loadKeyLayout(const InputDeviceIdentifier& deviceIdentifier,
- const String8& name) {
- String8 path(getPath(deviceIdentifier, name,
- INPUT_DEVICE_CONFIGURATION_FILE_TYPE_KEY_LAYOUT));
- if (path.isEmpty()) {
- return NAME_NOT_FOUND;
- }
-
- status_t status = KeyLayoutMap::load(path, &keyLayoutMap);
- if (status) {
- return status;
- }
-
- keyLayoutFile.setTo(path);
- return OK;
-}
-
-status_t KeyMap::loadKeyCharacterMap(const InputDeviceIdentifier& deviceIdentifier,
- const String8& name) {
- String8 path(getPath(deviceIdentifier, name,
- INPUT_DEVICE_CONFIGURATION_FILE_TYPE_KEY_CHARACTER_MAP));
- if (path.isEmpty()) {
- return NAME_NOT_FOUND;
- }
-
- status_t status = KeyCharacterMap::load(path,
- KeyCharacterMap::FORMAT_BASE, &keyCharacterMap);
- if (status) {
- return status;
- }
-
- keyCharacterMapFile.setTo(path);
- return OK;
-}
-
-String8 KeyMap::getPath(const InputDeviceIdentifier& deviceIdentifier,
- const String8& name, InputDeviceConfigurationFileType type) {
- return name.isEmpty()
- ? getInputDeviceConfigurationFilePathByDeviceIdentifier(deviceIdentifier, type)
- : getInputDeviceConfigurationFilePathByName(name, type);
-}
-
-
-// --- Global functions ---
-
-bool isEligibleBuiltInKeyboard(const InputDeviceIdentifier& deviceIdentifier,
- const PropertyMap* deviceConfiguration, const KeyMap* keyMap) {
- if (!keyMap->haveKeyCharacterMap()
- || keyMap->keyCharacterMap->getKeyboardType()
- == KeyCharacterMap::KEYBOARD_TYPE_SPECIAL_FUNCTION) {
- return false;
- }
-
- if (deviceConfiguration) {
- bool builtIn = false;
- if (deviceConfiguration->tryGetProperty(String8("keyboard.builtIn"), builtIn)
- && builtIn) {
- return true;
- }
- }
-
- return strstr(deviceIdentifier.name.string(), "-keypad");
-}
-
-static int lookupValueByLabel(const char* literal, const KeycodeLabel *list) {
- while (list->literal) {
- if (strcmp(literal, list->literal) == 0) {
- return list->value;
- }
- list++;
- }
- return list->value;
-}
-
-static const char* lookupLabelByValue(int value, const KeycodeLabel *list) {
- while (list->literal) {
- if (list->value == value) {
- return list->literal;
- }
- list++;
- }
- return NULL;
-}
-
-int32_t getKeyCodeByLabel(const char* label) {
- return int32_t(lookupValueByLabel(label, KEYCODES));
-}
-
-uint32_t getKeyFlagByLabel(const char* label) {
- return uint32_t(lookupValueByLabel(label, FLAGS));
-}
-
-int32_t getAxisByLabel(const char* label) {
- return int32_t(lookupValueByLabel(label, AXES));
-}
-
-const char* getAxisLabel(int32_t axisId) {
- return lookupLabelByValue(axisId, AXES);
-}
-
-static int32_t setEphemeralMetaState(int32_t mask, bool down, int32_t oldMetaState) {
- int32_t newMetaState;
- if (down) {
- newMetaState = oldMetaState | mask;
- } else {
- newMetaState = oldMetaState &
- ~(mask | AMETA_ALT_ON | AMETA_SHIFT_ON | AMETA_CTRL_ON | AMETA_META_ON);
- }
-
- if (newMetaState & (AMETA_ALT_LEFT_ON | AMETA_ALT_RIGHT_ON)) {
- newMetaState |= AMETA_ALT_ON;
- }
-
- if (newMetaState & (AMETA_SHIFT_LEFT_ON | AMETA_SHIFT_RIGHT_ON)) {
- newMetaState |= AMETA_SHIFT_ON;
- }
-
- if (newMetaState & (AMETA_CTRL_LEFT_ON | AMETA_CTRL_RIGHT_ON)) {
- newMetaState |= AMETA_CTRL_ON;
- }
-
- if (newMetaState & (AMETA_META_LEFT_ON | AMETA_META_RIGHT_ON)) {
- newMetaState |= AMETA_META_ON;
- }
- return newMetaState;
-}
-
-static int32_t toggleLockedMetaState(int32_t mask, bool down, int32_t oldMetaState) {
- if (down) {
- return oldMetaState;
- } else {
- return oldMetaState ^ mask;
- }
-}
-
-int32_t updateMetaState(int32_t keyCode, bool down, int32_t oldMetaState) {
- int32_t mask;
- switch (keyCode) {
- case AKEYCODE_ALT_LEFT:
- return setEphemeralMetaState(AMETA_ALT_LEFT_ON, down, oldMetaState);
- case AKEYCODE_ALT_RIGHT:
- return setEphemeralMetaState(AMETA_ALT_RIGHT_ON, down, oldMetaState);
- case AKEYCODE_SHIFT_LEFT:
- return setEphemeralMetaState(AMETA_SHIFT_LEFT_ON, down, oldMetaState);
- case AKEYCODE_SHIFT_RIGHT:
- return setEphemeralMetaState(AMETA_SHIFT_RIGHT_ON, down, oldMetaState);
- case AKEYCODE_SYM:
- return setEphemeralMetaState(AMETA_SYM_ON, down, oldMetaState);
- case AKEYCODE_FUNCTION:
- return setEphemeralMetaState(AMETA_FUNCTION_ON, down, oldMetaState);
- case AKEYCODE_CTRL_LEFT:
- return setEphemeralMetaState(AMETA_CTRL_LEFT_ON, down, oldMetaState);
- case AKEYCODE_CTRL_RIGHT:
- return setEphemeralMetaState(AMETA_CTRL_RIGHT_ON, down, oldMetaState);
- case AKEYCODE_META_LEFT:
- return setEphemeralMetaState(AMETA_META_LEFT_ON, down, oldMetaState);
- case AKEYCODE_META_RIGHT:
- return setEphemeralMetaState(AMETA_META_RIGHT_ON, down, oldMetaState);
- case AKEYCODE_CAPS_LOCK:
- return toggleLockedMetaState(AMETA_CAPS_LOCK_ON, down, oldMetaState);
- case AKEYCODE_NUM_LOCK:
- return toggleLockedMetaState(AMETA_NUM_LOCK_ON, down, oldMetaState);
- case AKEYCODE_SCROLL_LOCK:
- return toggleLockedMetaState(AMETA_SCROLL_LOCK_ON, down, oldMetaState);
- default:
- return oldMetaState;
- }
-}
-
-bool isMetaKey(int32_t keyCode) {
- switch (keyCode) {
- case AKEYCODE_ALT_LEFT:
- case AKEYCODE_ALT_RIGHT:
- case AKEYCODE_SHIFT_LEFT:
- case AKEYCODE_SHIFT_RIGHT:
- case AKEYCODE_SYM:
- case AKEYCODE_FUNCTION:
- case AKEYCODE_CTRL_LEFT:
- case AKEYCODE_CTRL_RIGHT:
- case AKEYCODE_META_LEFT:
- case AKEYCODE_META_RIGHT:
- case AKEYCODE_CAPS_LOCK:
- case AKEYCODE_NUM_LOCK:
- case AKEYCODE_SCROLL_LOCK:
- return true;
- default:
- return false;
- }
-}
-
-
-} // namespace android
diff --git a/libs/androidfw/ResourceTypes.cpp b/libs/androidfw/ResourceTypes.cpp
index e31246f..1128e02 100644
--- a/libs/androidfw/ResourceTypes.cpp
+++ b/libs/androidfw/ResourceTypes.cpp
@@ -5323,13 +5323,12 @@
}
-#ifdef STATIC_ANDROIDFW_FOR_TOOLS
#define CHAR16_TO_CSTR(c16, len) (String8(String16(c16,len)).string())
#define CHAR16_ARRAY_EQ(constant, var, len) \
((len == (sizeof(constant)/sizeof(constant[0]))) && (0 == memcmp((var), (constant), (len))))
-void print_complex(uint32_t complex, bool isFraction)
+static void print_complex(uint32_t complex, bool isFraction)
{
const float MANTISSA_MULT =
1.0f / (1<<Res_value::COMPLEX_MANTISSA_SHIFT);
@@ -5620,6 +5619,4 @@
}
}
-#endif // STATIC_ANDROIDFW_FOR_TOOLS
-
} // namespace android
diff --git a/libs/androidfw/VelocityControl.cpp b/libs/androidfw/VelocityControl.cpp
deleted file mode 100644
index cde2b76..0000000
--- a/libs/androidfw/VelocityControl.cpp
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * Copyright (C) 2012 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#define LOG_TAG "VelocityControl"
-//#define LOG_NDEBUG 0
-
-// Log debug messages about acceleration.
-#define DEBUG_ACCELERATION 0
-
-#include <math.h>
-#include <limits.h>
-
-#include <androidfw/VelocityControl.h>
-#include <utils/BitSet.h>
-#include <utils/Timers.h>
-
-namespace android {
-
-// --- VelocityControl ---
-
-const nsecs_t VelocityControl::STOP_TIME;
-
-VelocityControl::VelocityControl() {
- reset();
-}
-
-void VelocityControl::setParameters(const VelocityControlParameters& parameters) {
- mParameters = parameters;
- reset();
-}
-
-void VelocityControl::reset() {
- mLastMovementTime = LLONG_MIN;
- mRawPosition.x = 0;
- mRawPosition.y = 0;
- mVelocityTracker.clear();
-}
-
-void VelocityControl::move(nsecs_t eventTime, float* deltaX, float* deltaY) {
- if ((deltaX && *deltaX) || (deltaY && *deltaY)) {
- if (eventTime >= mLastMovementTime + STOP_TIME) {
-#if DEBUG_ACCELERATION
- ALOGD("VelocityControl: stopped, last movement was %0.3fms ago",
- (eventTime - mLastMovementTime) * 0.000001f);
-#endif
- reset();
- }
-
- mLastMovementTime = eventTime;
- if (deltaX) {
- mRawPosition.x += *deltaX;
- }
- if (deltaY) {
- mRawPosition.y += *deltaY;
- }
- mVelocityTracker.addMovement(eventTime, BitSet32(BitSet32::valueForBit(0)), &mRawPosition);
-
- float vx, vy;
- float scale = mParameters.scale;
- if (mVelocityTracker.getVelocity(0, &vx, &vy)) {
- float speed = hypotf(vx, vy) * scale;
- if (speed >= mParameters.highThreshold) {
- // Apply full acceleration above the high speed threshold.
- scale *= mParameters.acceleration;
- } else if (speed > mParameters.lowThreshold) {
- // Linearly interpolate the acceleration to apply between the low and high
- // speed thresholds.
- scale *= 1 + (speed - mParameters.lowThreshold)
- / (mParameters.highThreshold - mParameters.lowThreshold)
- * (mParameters.acceleration - 1);
- }
-
-#if DEBUG_ACCELERATION
- ALOGD("VelocityControl(%0.3f, %0.3f, %0.3f, %0.3f): "
- "vx=%0.3f, vy=%0.3f, speed=%0.3f, accel=%0.3f",
- mParameters.scale, mParameters.lowThreshold, mParameters.highThreshold,
- mParameters.acceleration,
- vx, vy, speed, scale / mParameters.scale);
-#endif
- } else {
-#if DEBUG_ACCELERATION
- ALOGD("VelocityControl(%0.3f, %0.3f, %0.3f, %0.3f): unknown velocity",
- mParameters.scale, mParameters.lowThreshold, mParameters.highThreshold,
- mParameters.acceleration);
-#endif
- }
-
- if (deltaX) {
- *deltaX *= scale;
- }
- if (deltaY) {
- *deltaY *= scale;
- }
- }
-}
-
-} // namespace android
diff --git a/libs/androidfw/VelocityTracker.cpp b/libs/androidfw/VelocityTracker.cpp
deleted file mode 100644
index f48ec62..0000000
--- a/libs/androidfw/VelocityTracker.cpp
+++ /dev/null
@@ -1,928 +0,0 @@
-/*
- * Copyright (C) 2012 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#define LOG_TAG "VelocityTracker"
-//#define LOG_NDEBUG 0
-
-// Log debug messages about velocity tracking.
-#define DEBUG_VELOCITY 0
-
-// Log debug messages about the progress of the algorithm itself.
-#define DEBUG_STRATEGY 0
-
-#include <math.h>
-#include <limits.h>
-
-#include <androidfw/VelocityTracker.h>
-#include <utils/BitSet.h>
-#include <utils/String8.h>
-#include <utils/Timers.h>
-
-#include <cutils/properties.h>
-
-namespace android {
-
-// Nanoseconds per milliseconds.
-static const nsecs_t NANOS_PER_MS = 1000000;
-
-// Threshold for determining that a pointer has stopped moving.
-// Some input devices do not send ACTION_MOVE events in the case where a pointer has
-// stopped. We need to detect this case so that we can accurately predict the
-// velocity after the pointer starts moving again.
-static const nsecs_t ASSUME_POINTER_STOPPED_TIME = 40 * NANOS_PER_MS;
-
-
-static float vectorDot(const float* a, const float* b, uint32_t m) {
- float r = 0;
- while (m--) {
- r += *(a++) * *(b++);
- }
- return r;
-}
-
-static float vectorNorm(const float* a, uint32_t m) {
- float r = 0;
- while (m--) {
- float t = *(a++);
- r += t * t;
- }
- return sqrtf(r);
-}
-
-#if DEBUG_STRATEGY || DEBUG_VELOCITY
-static String8 vectorToString(const float* a, uint32_t m) {
- String8 str;
- str.append("[");
- while (m--) {
- str.appendFormat(" %f", *(a++));
- if (m) {
- str.append(",");
- }
- }
- str.append(" ]");
- return str;
-}
-
-static String8 matrixToString(const float* a, uint32_t m, uint32_t n, bool rowMajor) {
- String8 str;
- str.append("[");
- for (size_t i = 0; i < m; i++) {
- if (i) {
- str.append(",");
- }
- str.append(" [");
- for (size_t j = 0; j < n; j++) {
- if (j) {
- str.append(",");
- }
- str.appendFormat(" %f", a[rowMajor ? i * n + j : j * m + i]);
- }
- str.append(" ]");
- }
- str.append(" ]");
- return str;
-}
-#endif
-
-
-// --- VelocityTracker ---
-
-// The default velocity tracker strategy.
-// Although other strategies are available for testing and comparison purposes,
-// this is the strategy that applications will actually use. Be very careful
-// when adjusting the default strategy because it can dramatically affect
-// (often in a bad way) the user experience.
-const char* VelocityTracker::DEFAULT_STRATEGY = "lsq2";
-
-VelocityTracker::VelocityTracker(const char* strategy) :
- mLastEventTime(0), mCurrentPointerIdBits(0), mActivePointerId(-1) {
- char value[PROPERTY_VALUE_MAX];
-
- // Allow the default strategy to be overridden using a system property for debugging.
- if (!strategy) {
- int length = property_get("debug.velocitytracker.strategy", value, NULL);
- if (length > 0) {
- strategy = value;
- } else {
- strategy = DEFAULT_STRATEGY;
- }
- }
-
- // Configure the strategy.
- if (!configureStrategy(strategy)) {
- ALOGD("Unrecognized velocity tracker strategy name '%s'.", strategy);
- if (!configureStrategy(DEFAULT_STRATEGY)) {
- LOG_ALWAYS_FATAL("Could not create the default velocity tracker strategy '%s'!",
- strategy);
- }
- }
-}
-
-VelocityTracker::~VelocityTracker() {
- delete mStrategy;
-}
-
-bool VelocityTracker::configureStrategy(const char* strategy) {
- mStrategy = createStrategy(strategy);
- return mStrategy != NULL;
-}
-
-VelocityTrackerStrategy* VelocityTracker::createStrategy(const char* strategy) {
- if (!strcmp("lsq1", strategy)) {
- // 1st order least squares. Quality: POOR.
- // Frequently underfits the touch data especially when the finger accelerates
- // or changes direction. Often underestimates velocity. The direction
- // is overly influenced by historical touch points.
- return new LeastSquaresVelocityTrackerStrategy(1);
- }
- if (!strcmp("lsq2", strategy)) {
- // 2nd order least squares. Quality: VERY GOOD.
- // Pretty much ideal, but can be confused by certain kinds of touch data,
- // particularly if the panel has a tendency to generate delayed,
- // duplicate or jittery touch coordinates when the finger is released.
- return new LeastSquaresVelocityTrackerStrategy(2);
- }
- if (!strcmp("lsq3", strategy)) {
- // 3rd order least squares. Quality: UNUSABLE.
- // Frequently overfits the touch data yielding wildly divergent estimates
- // of the velocity when the finger is released.
- return new LeastSquaresVelocityTrackerStrategy(3);
- }
- if (!strcmp("wlsq2-delta", strategy)) {
- // 2nd order weighted least squares, delta weighting. Quality: EXPERIMENTAL
- return new LeastSquaresVelocityTrackerStrategy(2,
- LeastSquaresVelocityTrackerStrategy::WEIGHTING_DELTA);
- }
- if (!strcmp("wlsq2-central", strategy)) {
- // 2nd order weighted least squares, central weighting. Quality: EXPERIMENTAL
- return new LeastSquaresVelocityTrackerStrategy(2,
- LeastSquaresVelocityTrackerStrategy::WEIGHTING_CENTRAL);
- }
- if (!strcmp("wlsq2-recent", strategy)) {
- // 2nd order weighted least squares, recent weighting. Quality: EXPERIMENTAL
- return new LeastSquaresVelocityTrackerStrategy(2,
- LeastSquaresVelocityTrackerStrategy::WEIGHTING_RECENT);
- }
- if (!strcmp("int1", strategy)) {
- // 1st order integrating filter. Quality: GOOD.
- // Not as good as 'lsq2' because it cannot estimate acceleration but it is
- // more tolerant of errors. Like 'lsq1', this strategy tends to underestimate
- // the velocity of a fling but this strategy tends to respond to changes in
- // direction more quickly and accurately.
- return new IntegratingVelocityTrackerStrategy(1);
- }
- if (!strcmp("int2", strategy)) {
- // 2nd order integrating filter. Quality: EXPERIMENTAL.
- // For comparison purposes only. Unlike 'int1' this strategy can compensate
- // for acceleration but it typically overestimates the effect.
- return new IntegratingVelocityTrackerStrategy(2);
- }
- if (!strcmp("legacy", strategy)) {
- // Legacy velocity tracker algorithm. Quality: POOR.
- // For comparison purposes only. This algorithm is strongly influenced by
- // old data points, consistently underestimates velocity and takes a very long
- // time to adjust to changes in direction.
- return new LegacyVelocityTrackerStrategy();
- }
- return NULL;
-}
-
-void VelocityTracker::clear() {
- mCurrentPointerIdBits.clear();
- mActivePointerId = -1;
-
- mStrategy->clear();
-}
-
-void VelocityTracker::clearPointers(BitSet32 idBits) {
- BitSet32 remainingIdBits(mCurrentPointerIdBits.value & ~idBits.value);
- mCurrentPointerIdBits = remainingIdBits;
-
- if (mActivePointerId >= 0 && idBits.hasBit(mActivePointerId)) {
- mActivePointerId = !remainingIdBits.isEmpty() ? remainingIdBits.firstMarkedBit() : -1;
- }
-
- mStrategy->clearPointers(idBits);
-}
-
-void VelocityTracker::addMovement(nsecs_t eventTime, BitSet32 idBits, const Position* positions) {
- while (idBits.count() > MAX_POINTERS) {
- idBits.clearLastMarkedBit();
- }
-
- if ((mCurrentPointerIdBits.value & idBits.value)
- && eventTime >= mLastEventTime + ASSUME_POINTER_STOPPED_TIME) {
-#if DEBUG_VELOCITY
- ALOGD("VelocityTracker: stopped for %0.3f ms, clearing state.",
- (eventTime - mLastEventTime) * 0.000001f);
-#endif
- // We have not received any movements for too long. Assume that all pointers
- // have stopped.
- mStrategy->clear();
- }
- mLastEventTime = eventTime;
-
- mCurrentPointerIdBits = idBits;
- if (mActivePointerId < 0 || !idBits.hasBit(mActivePointerId)) {
- mActivePointerId = idBits.isEmpty() ? -1 : idBits.firstMarkedBit();
- }
-
- mStrategy->addMovement(eventTime, idBits, positions);
-
-#if DEBUG_VELOCITY
- ALOGD("VelocityTracker: addMovement eventTime=%lld, idBits=0x%08x, activePointerId=%d",
- eventTime, idBits.value, mActivePointerId);
- for (BitSet32 iterBits(idBits); !iterBits.isEmpty(); ) {
- uint32_t id = iterBits.firstMarkedBit();
- uint32_t index = idBits.getIndexOfBit(id);
- iterBits.clearBit(id);
- Estimator estimator;
- getEstimator(id, &estimator);
- ALOGD(" %d: position (%0.3f, %0.3f), "
- "estimator (degree=%d, xCoeff=%s, yCoeff=%s, confidence=%f)",
- id, positions[index].x, positions[index].y,
- int(estimator.degree),
- vectorToString(estimator.xCoeff, estimator.degree + 1).string(),
- vectorToString(estimator.yCoeff, estimator.degree + 1).string(),
- estimator.confidence);
- }
-#endif
-}
-
-void VelocityTracker::addMovement(const MotionEvent* event) {
- int32_t actionMasked = event->getActionMasked();
-
- switch (actionMasked) {
- case AMOTION_EVENT_ACTION_DOWN:
- case AMOTION_EVENT_ACTION_HOVER_ENTER:
- // Clear all pointers on down before adding the new movement.
- clear();
- break;
- case AMOTION_EVENT_ACTION_POINTER_DOWN: {
- // Start a new movement trace for a pointer that just went down.
- // We do this on down instead of on up because the client may want to query the
- // final velocity for a pointer that just went up.
- BitSet32 downIdBits;
- downIdBits.markBit(event->getPointerId(event->getActionIndex()));
- clearPointers(downIdBits);
- break;
- }
- case AMOTION_EVENT_ACTION_MOVE:
- case AMOTION_EVENT_ACTION_HOVER_MOVE:
- break;
- default:
- // Ignore all other actions because they do not convey any new information about
- // pointer movement. We also want to preserve the last known velocity of the pointers.
- // Note that ACTION_UP and ACTION_POINTER_UP always report the last known position
- // of the pointers that went up. ACTION_POINTER_UP does include the new position of
- // pointers that remained down but we will also receive an ACTION_MOVE with this
- // information if any of them actually moved. Since we don't know how many pointers
- // will be going up at once it makes sense to just wait for the following ACTION_MOVE
- // before adding the movement.
- return;
- }
-
- size_t pointerCount = event->getPointerCount();
- if (pointerCount > MAX_POINTERS) {
- pointerCount = MAX_POINTERS;
- }
-
- BitSet32 idBits;
- for (size_t i = 0; i < pointerCount; i++) {
- idBits.markBit(event->getPointerId(i));
- }
-
- uint32_t pointerIndex[MAX_POINTERS];
- for (size_t i = 0; i < pointerCount; i++) {
- pointerIndex[i] = idBits.getIndexOfBit(event->getPointerId(i));
- }
-
- nsecs_t eventTime;
- Position positions[pointerCount];
-
- size_t historySize = event->getHistorySize();
- for (size_t h = 0; h < historySize; h++) {
- eventTime = event->getHistoricalEventTime(h);
- for (size_t i = 0; i < pointerCount; i++) {
- uint32_t index = pointerIndex[i];
- positions[index].x = event->getHistoricalX(i, h);
- positions[index].y = event->getHistoricalY(i, h);
- }
- addMovement(eventTime, idBits, positions);
- }
-
- eventTime = event->getEventTime();
- for (size_t i = 0; i < pointerCount; i++) {
- uint32_t index = pointerIndex[i];
- positions[index].x = event->getX(i);
- positions[index].y = event->getY(i);
- }
- addMovement(eventTime, idBits, positions);
-}
-
-bool VelocityTracker::getVelocity(uint32_t id, float* outVx, float* outVy) const {
- Estimator estimator;
- if (getEstimator(id, &estimator) && estimator.degree >= 1) {
- *outVx = estimator.xCoeff[1];
- *outVy = estimator.yCoeff[1];
- return true;
- }
- *outVx = 0;
- *outVy = 0;
- return false;
-}
-
-bool VelocityTracker::getEstimator(uint32_t id, Estimator* outEstimator) const {
- return mStrategy->getEstimator(id, outEstimator);
-}
-
-
-// --- LeastSquaresVelocityTrackerStrategy ---
-
-const nsecs_t LeastSquaresVelocityTrackerStrategy::HORIZON;
-const uint32_t LeastSquaresVelocityTrackerStrategy::HISTORY_SIZE;
-
-LeastSquaresVelocityTrackerStrategy::LeastSquaresVelocityTrackerStrategy(
- uint32_t degree, Weighting weighting) :
- mDegree(degree), mWeighting(weighting) {
- clear();
-}
-
-LeastSquaresVelocityTrackerStrategy::~LeastSquaresVelocityTrackerStrategy() {
-}
-
-void LeastSquaresVelocityTrackerStrategy::clear() {
- mIndex = 0;
- mMovements[0].idBits.clear();
-}
-
-void LeastSquaresVelocityTrackerStrategy::clearPointers(BitSet32 idBits) {
- BitSet32 remainingIdBits(mMovements[mIndex].idBits.value & ~idBits.value);
- mMovements[mIndex].idBits = remainingIdBits;
-}
-
-void LeastSquaresVelocityTrackerStrategy::addMovement(nsecs_t eventTime, BitSet32 idBits,
- const VelocityTracker::Position* positions) {
- if (++mIndex == HISTORY_SIZE) {
- mIndex = 0;
- }
-
- Movement& movement = mMovements[mIndex];
- movement.eventTime = eventTime;
- movement.idBits = idBits;
- uint32_t count = idBits.count();
- for (uint32_t i = 0; i < count; i++) {
- movement.positions[i] = positions[i];
- }
-}
-
-/**
- * Solves a linear least squares problem to obtain a N degree polynomial that fits
- * the specified input data as nearly as possible.
- *
- * Returns true if a solution is found, false otherwise.
- *
- * The input consists of two vectors of data points X and Y with indices 0..m-1
- * along with a weight vector W of the same size.
- *
- * The output is a vector B with indices 0..n that describes a polynomial
- * that fits the data, such the sum of W[i] * W[i] * abs(Y[i] - (B[0] + B[1] X[i]
- * + B[2] X[i]^2 ... B[n] X[i]^n)) for all i between 0 and m-1 is minimized.
- *
- * Accordingly, the weight vector W should be initialized by the caller with the
- * reciprocal square root of the variance of the error in each input data point.
- * In other words, an ideal choice for W would be W[i] = 1 / var(Y[i]) = 1 / stddev(Y[i]).
- * The weights express the relative importance of each data point. If the weights are
- * all 1, then the data points are considered to be of equal importance when fitting
- * the polynomial. It is a good idea to choose weights that diminish the importance
- * of data points that may have higher than usual error margins.
- *
- * Errors among data points are assumed to be independent. W is represented here
- * as a vector although in the literature it is typically taken to be a diagonal matrix.
- *
- * That is to say, the function that generated the input data can be approximated
- * by y(x) ~= B[0] + B[1] x + B[2] x^2 + ... + B[n] x^n.
- *
- * The coefficient of determination (R^2) is also returned to describe the goodness
- * of fit of the model for the given data. It is a value between 0 and 1, where 1
- * indicates perfect correspondence.
- *
- * This function first expands the X vector to a m by n matrix A such that
- * A[i][0] = 1, A[i][1] = X[i], A[i][2] = X[i]^2, ..., A[i][n] = X[i]^n, then
- * multiplies it by w[i]./
- *
- * Then it calculates the QR decomposition of A yielding an m by m orthonormal matrix Q
- * and an m by n upper triangular matrix R. Because R is upper triangular (lower
- * part is all zeroes), we can simplify the decomposition into an m by n matrix
- * Q1 and a n by n matrix R1 such that A = Q1 R1.
- *
- * Finally we solve the system of linear equations given by R1 B = (Qtranspose W Y)
- * to find B.
- *
- * For efficiency, we lay out A and Q column-wise in memory because we frequently
- * operate on the column vectors. Conversely, we lay out R row-wise.
- *
- * http://en.wikipedia.org/wiki/Numerical_methods_for_linear_least_squares
- * http://en.wikipedia.org/wiki/Gram-Schmidt
- */
-static bool solveLeastSquares(const float* x, const float* y,
- const float* w, uint32_t m, uint32_t n, float* outB, float* outDet) {
-#if DEBUG_STRATEGY
- ALOGD("solveLeastSquares: m=%d, n=%d, x=%s, y=%s, w=%s", int(m), int(n),
- vectorToString(x, m).string(), vectorToString(y, m).string(),
- vectorToString(w, m).string());
-#endif
-
- // Expand the X vector to a matrix A, pre-multiplied by the weights.
- float a[n][m]; // column-major order
- for (uint32_t h = 0; h < m; h++) {
- a[0][h] = w[h];
- for (uint32_t i = 1; i < n; i++) {
- a[i][h] = a[i - 1][h] * x[h];
- }
- }
-#if DEBUG_STRATEGY
- ALOGD(" - a=%s", matrixToString(&a[0][0], m, n, false /*rowMajor*/).string());
-#endif
-
- // Apply the Gram-Schmidt process to A to obtain its QR decomposition.
- float q[n][m]; // orthonormal basis, column-major order
- float r[n][n]; // upper triangular matrix, row-major order
- for (uint32_t j = 0; j < n; j++) {
- for (uint32_t h = 0; h < m; h++) {
- q[j][h] = a[j][h];
- }
- for (uint32_t i = 0; i < j; i++) {
- float dot = vectorDot(&q[j][0], &q[i][0], m);
- for (uint32_t h = 0; h < m; h++) {
- q[j][h] -= dot * q[i][h];
- }
- }
-
- float norm = vectorNorm(&q[j][0], m);
- if (norm < 0.000001f) {
- // vectors are linearly dependent or zero so no solution
-#if DEBUG_STRATEGY
- ALOGD(" - no solution, norm=%f", norm);
-#endif
- return false;
- }
-
- float invNorm = 1.0f / norm;
- for (uint32_t h = 0; h < m; h++) {
- q[j][h] *= invNorm;
- }
- for (uint32_t i = 0; i < n; i++) {
- r[j][i] = i < j ? 0 : vectorDot(&q[j][0], &a[i][0], m);
- }
- }
-#if DEBUG_STRATEGY
- ALOGD(" - q=%s", matrixToString(&q[0][0], m, n, false /*rowMajor*/).string());
- ALOGD(" - r=%s", matrixToString(&r[0][0], n, n, true /*rowMajor*/).string());
-
- // calculate QR, if we factored A correctly then QR should equal A
- float qr[n][m];
- for (uint32_t h = 0; h < m; h++) {
- for (uint32_t i = 0; i < n; i++) {
- qr[i][h] = 0;
- for (uint32_t j = 0; j < n; j++) {
- qr[i][h] += q[j][h] * r[j][i];
- }
- }
- }
- ALOGD(" - qr=%s", matrixToString(&qr[0][0], m, n, false /*rowMajor*/).string());
-#endif
-
- // Solve R B = Qt W Y to find B. This is easy because R is upper triangular.
- // We just work from bottom-right to top-left calculating B's coefficients.
- float wy[m];
- for (uint32_t h = 0; h < m; h++) {
- wy[h] = y[h] * w[h];
- }
- for (uint32_t i = n; i-- != 0; ) {
- outB[i] = vectorDot(&q[i][0], wy, m);
- for (uint32_t j = n - 1; j > i; j--) {
- outB[i] -= r[i][j] * outB[j];
- }
- outB[i] /= r[i][i];
- }
-#if DEBUG_STRATEGY
- ALOGD(" - b=%s", vectorToString(outB, n).string());
-#endif
-
- // Calculate the coefficient of determination as 1 - (SSerr / SStot) where
- // SSerr is the residual sum of squares (variance of the error),
- // and SStot is the total sum of squares (variance of the data) where each
- // has been weighted.
- float ymean = 0;
- for (uint32_t h = 0; h < m; h++) {
- ymean += y[h];
- }
- ymean /= m;
-
- float sserr = 0;
- float sstot = 0;
- for (uint32_t h = 0; h < m; h++) {
- float err = y[h] - outB[0];
- float term = 1;
- for (uint32_t i = 1; i < n; i++) {
- term *= x[h];
- err -= term * outB[i];
- }
- sserr += w[h] * w[h] * err * err;
- float var = y[h] - ymean;
- sstot += w[h] * w[h] * var * var;
- }
- *outDet = sstot > 0.000001f ? 1.0f - (sserr / sstot) : 1;
-#if DEBUG_STRATEGY
- ALOGD(" - sserr=%f", sserr);
- ALOGD(" - sstot=%f", sstot);
- ALOGD(" - det=%f", *outDet);
-#endif
- return true;
-}
-
-bool LeastSquaresVelocityTrackerStrategy::getEstimator(uint32_t id,
- VelocityTracker::Estimator* outEstimator) const {
- outEstimator->clear();
-
- // Iterate over movement samples in reverse time order and collect samples.
- float x[HISTORY_SIZE];
- float y[HISTORY_SIZE];
- float w[HISTORY_SIZE];
- float time[HISTORY_SIZE];
- uint32_t m = 0;
- uint32_t index = mIndex;
- const Movement& newestMovement = mMovements[mIndex];
- do {
- const Movement& movement = mMovements[index];
- if (!movement.idBits.hasBit(id)) {
- break;
- }
-
- nsecs_t age = newestMovement.eventTime - movement.eventTime;
- if (age > HORIZON) {
- break;
- }
-
- const VelocityTracker::Position& position = movement.getPosition(id);
- x[m] = position.x;
- y[m] = position.y;
- w[m] = chooseWeight(index);
- time[m] = -age * 0.000000001f;
- index = (index == 0 ? HISTORY_SIZE : index) - 1;
- } while (++m < HISTORY_SIZE);
-
- if (m == 0) {
- return false; // no data
- }
-
- // Calculate a least squares polynomial fit.
- uint32_t degree = mDegree;
- if (degree > m - 1) {
- degree = m - 1;
- }
- if (degree >= 1) {
- float xdet, ydet;
- uint32_t n = degree + 1;
- if (solveLeastSquares(time, x, w, m, n, outEstimator->xCoeff, &xdet)
- && solveLeastSquares(time, y, w, m, n, outEstimator->yCoeff, &ydet)) {
- outEstimator->time = newestMovement.eventTime;
- outEstimator->degree = degree;
- outEstimator->confidence = xdet * ydet;
-#if DEBUG_STRATEGY
- ALOGD("estimate: degree=%d, xCoeff=%s, yCoeff=%s, confidence=%f",
- int(outEstimator->degree),
- vectorToString(outEstimator->xCoeff, n).string(),
- vectorToString(outEstimator->yCoeff, n).string(),
- outEstimator->confidence);
-#endif
- return true;
- }
- }
-
- // No velocity data available for this pointer, but we do have its current position.
- outEstimator->xCoeff[0] = x[0];
- outEstimator->yCoeff[0] = y[0];
- outEstimator->time = newestMovement.eventTime;
- outEstimator->degree = 0;
- outEstimator->confidence = 1;
- return true;
-}
-
-float LeastSquaresVelocityTrackerStrategy::chooseWeight(uint32_t index) const {
- switch (mWeighting) {
- case WEIGHTING_DELTA: {
- // Weight points based on how much time elapsed between them and the next
- // point so that points that "cover" a shorter time span are weighed less.
- // delta 0ms: 0.5
- // delta 10ms: 1.0
- if (index == mIndex) {
- return 1.0f;
- }
- uint32_t nextIndex = (index + 1) % HISTORY_SIZE;
- float deltaMillis = (mMovements[nextIndex].eventTime- mMovements[index].eventTime)
- * 0.000001f;
- if (deltaMillis < 0) {
- return 0.5f;
- }
- if (deltaMillis < 10) {
- return 0.5f + deltaMillis * 0.05;
- }
- return 1.0f;
- }
-
- case WEIGHTING_CENTRAL: {
- // Weight points based on their age, weighing very recent and very old points less.
- // age 0ms: 0.5
- // age 10ms: 1.0
- // age 50ms: 1.0
- // age 60ms: 0.5
- float ageMillis = (mMovements[mIndex].eventTime - mMovements[index].eventTime)
- * 0.000001f;
- if (ageMillis < 0) {
- return 0.5f;
- }
- if (ageMillis < 10) {
- return 0.5f + ageMillis * 0.05;
- }
- if (ageMillis < 50) {
- return 1.0f;
- }
- if (ageMillis < 60) {
- return 0.5f + (60 - ageMillis) * 0.05;
- }
- return 0.5f;
- }
-
- case WEIGHTING_RECENT: {
- // Weight points based on their age, weighing older points less.
- // age 0ms: 1.0
- // age 50ms: 1.0
- // age 100ms: 0.5
- float ageMillis = (mMovements[mIndex].eventTime - mMovements[index].eventTime)
- * 0.000001f;
- if (ageMillis < 50) {
- return 1.0f;
- }
- if (ageMillis < 100) {
- return 0.5f + (100 - ageMillis) * 0.01f;
- }
- return 0.5f;
- }
-
- case WEIGHTING_NONE:
- default:
- return 1.0f;
- }
-}
-
-
-// --- IntegratingVelocityTrackerStrategy ---
-
-IntegratingVelocityTrackerStrategy::IntegratingVelocityTrackerStrategy(uint32_t degree) :
- mDegree(degree) {
-}
-
-IntegratingVelocityTrackerStrategy::~IntegratingVelocityTrackerStrategy() {
-}
-
-void IntegratingVelocityTrackerStrategy::clear() {
- mPointerIdBits.clear();
-}
-
-void IntegratingVelocityTrackerStrategy::clearPointers(BitSet32 idBits) {
- mPointerIdBits.value &= ~idBits.value;
-}
-
-void IntegratingVelocityTrackerStrategy::addMovement(nsecs_t eventTime, BitSet32 idBits,
- const VelocityTracker::Position* positions) {
- uint32_t index = 0;
- for (BitSet32 iterIdBits(idBits); !iterIdBits.isEmpty();) {
- uint32_t id = iterIdBits.clearFirstMarkedBit();
- State& state = mPointerState[id];
- const VelocityTracker::Position& position = positions[index++];
- if (mPointerIdBits.hasBit(id)) {
- updateState(state, eventTime, position.x, position.y);
- } else {
- initState(state, eventTime, position.x, position.y);
- }
- }
-
- mPointerIdBits = idBits;
-}
-
-bool IntegratingVelocityTrackerStrategy::getEstimator(uint32_t id,
- VelocityTracker::Estimator* outEstimator) const {
- outEstimator->clear();
-
- if (mPointerIdBits.hasBit(id)) {
- const State& state = mPointerState[id];
- populateEstimator(state, outEstimator);
- return true;
- }
-
- return false;
-}
-
-void IntegratingVelocityTrackerStrategy::initState(State& state,
- nsecs_t eventTime, float xpos, float ypos) const {
- state.updateTime = eventTime;
- state.degree = 0;
-
- state.xpos = xpos;
- state.xvel = 0;
- state.xaccel = 0;
- state.ypos = ypos;
- state.yvel = 0;
- state.yaccel = 0;
-}
-
-void IntegratingVelocityTrackerStrategy::updateState(State& state,
- nsecs_t eventTime, float xpos, float ypos) const {
- const nsecs_t MIN_TIME_DELTA = 2 * NANOS_PER_MS;
- const float FILTER_TIME_CONSTANT = 0.010f; // 10 milliseconds
-
- if (eventTime <= state.updateTime + MIN_TIME_DELTA) {
- return;
- }
-
- float dt = (eventTime - state.updateTime) * 0.000000001f;
- state.updateTime = eventTime;
-
- float xvel = (xpos - state.xpos) / dt;
- float yvel = (ypos - state.ypos) / dt;
- if (state.degree == 0) {
- state.xvel = xvel;
- state.yvel = yvel;
- state.degree = 1;
- } else {
- float alpha = dt / (FILTER_TIME_CONSTANT + dt);
- if (mDegree == 1) {
- state.xvel += (xvel - state.xvel) * alpha;
- state.yvel += (yvel - state.yvel) * alpha;
- } else {
- float xaccel = (xvel - state.xvel) / dt;
- float yaccel = (yvel - state.yvel) / dt;
- if (state.degree == 1) {
- state.xaccel = xaccel;
- state.yaccel = yaccel;
- state.degree = 2;
- } else {
- state.xaccel += (xaccel - state.xaccel) * alpha;
- state.yaccel += (yaccel - state.yaccel) * alpha;
- }
- state.xvel += (state.xaccel * dt) * alpha;
- state.yvel += (state.yaccel * dt) * alpha;
- }
- }
- state.xpos = xpos;
- state.ypos = ypos;
-}
-
-void IntegratingVelocityTrackerStrategy::populateEstimator(const State& state,
- VelocityTracker::Estimator* outEstimator) const {
- outEstimator->time = state.updateTime;
- outEstimator->confidence = 1.0f;
- outEstimator->degree = state.degree;
- outEstimator->xCoeff[0] = state.xpos;
- outEstimator->xCoeff[1] = state.xvel;
- outEstimator->xCoeff[2] = state.xaccel / 2;
- outEstimator->yCoeff[0] = state.ypos;
- outEstimator->yCoeff[1] = state.yvel;
- outEstimator->yCoeff[2] = state.yaccel / 2;
-}
-
-
-// --- LegacyVelocityTrackerStrategy ---
-
-const nsecs_t LegacyVelocityTrackerStrategy::HORIZON;
-const uint32_t LegacyVelocityTrackerStrategy::HISTORY_SIZE;
-const nsecs_t LegacyVelocityTrackerStrategy::MIN_DURATION;
-
-LegacyVelocityTrackerStrategy::LegacyVelocityTrackerStrategy() {
- clear();
-}
-
-LegacyVelocityTrackerStrategy::~LegacyVelocityTrackerStrategy() {
-}
-
-void LegacyVelocityTrackerStrategy::clear() {
- mIndex = 0;
- mMovements[0].idBits.clear();
-}
-
-void LegacyVelocityTrackerStrategy::clearPointers(BitSet32 idBits) {
- BitSet32 remainingIdBits(mMovements[mIndex].idBits.value & ~idBits.value);
- mMovements[mIndex].idBits = remainingIdBits;
-}
-
-void LegacyVelocityTrackerStrategy::addMovement(nsecs_t eventTime, BitSet32 idBits,
- const VelocityTracker::Position* positions) {
- if (++mIndex == HISTORY_SIZE) {
- mIndex = 0;
- }
-
- Movement& movement = mMovements[mIndex];
- movement.eventTime = eventTime;
- movement.idBits = idBits;
- uint32_t count = idBits.count();
- for (uint32_t i = 0; i < count; i++) {
- movement.positions[i] = positions[i];
- }
-}
-
-bool LegacyVelocityTrackerStrategy::getEstimator(uint32_t id,
- VelocityTracker::Estimator* outEstimator) const {
- outEstimator->clear();
-
- const Movement& newestMovement = mMovements[mIndex];
- if (!newestMovement.idBits.hasBit(id)) {
- return false; // no data
- }
-
- // Find the oldest sample that contains the pointer and that is not older than HORIZON.
- nsecs_t minTime = newestMovement.eventTime - HORIZON;
- uint32_t oldestIndex = mIndex;
- uint32_t numTouches = 1;
- do {
- uint32_t nextOldestIndex = (oldestIndex == 0 ? HISTORY_SIZE : oldestIndex) - 1;
- const Movement& nextOldestMovement = mMovements[nextOldestIndex];
- if (!nextOldestMovement.idBits.hasBit(id)
- || nextOldestMovement.eventTime < minTime) {
- break;
- }
- oldestIndex = nextOldestIndex;
- } while (++numTouches < HISTORY_SIZE);
-
- // Calculate an exponentially weighted moving average of the velocity estimate
- // at different points in time measured relative to the oldest sample.
- // This is essentially an IIR filter. Newer samples are weighted more heavily
- // than older samples. Samples at equal time points are weighted more or less
- // equally.
- //
- // One tricky problem is that the sample data may be poorly conditioned.
- // Sometimes samples arrive very close together in time which can cause us to
- // overestimate the velocity at that time point. Most samples might be measured
- // 16ms apart but some consecutive samples could be only 0.5sm apart because
- // the hardware or driver reports them irregularly or in bursts.
- float accumVx = 0;
- float accumVy = 0;
- uint32_t index = oldestIndex;
- uint32_t samplesUsed = 0;
- const Movement& oldestMovement = mMovements[oldestIndex];
- const VelocityTracker::Position& oldestPosition = oldestMovement.getPosition(id);
- nsecs_t lastDuration = 0;
-
- while (numTouches-- > 1) {
- if (++index == HISTORY_SIZE) {
- index = 0;
- }
- const Movement& movement = mMovements[index];
- nsecs_t duration = movement.eventTime - oldestMovement.eventTime;
-
- // If the duration between samples is small, we may significantly overestimate
- // the velocity. Consequently, we impose a minimum duration constraint on the
- // samples that we include in the calculation.
- if (duration >= MIN_DURATION) {
- const VelocityTracker::Position& position = movement.getPosition(id);
- float scale = 1000000000.0f / duration; // one over time delta in seconds
- float vx = (position.x - oldestPosition.x) * scale;
- float vy = (position.y - oldestPosition.y) * scale;
- accumVx = (accumVx * lastDuration + vx * duration) / (duration + lastDuration);
- accumVy = (accumVy * lastDuration + vy * duration) / (duration + lastDuration);
- lastDuration = duration;
- samplesUsed += 1;
- }
- }
-
- // Report velocity.
- const VelocityTracker::Position& newestPosition = newestMovement.getPosition(id);
- outEstimator->time = newestMovement.eventTime;
- outEstimator->confidence = 1;
- outEstimator->xCoeff[0] = newestPosition.x;
- outEstimator->yCoeff[0] = newestPosition.y;
- if (samplesUsed) {
- outEstimator->xCoeff[1] = accumVx;
- outEstimator->yCoeff[1] = accumVy;
- outEstimator->degree = 1;
- } else {
- outEstimator->degree = 0;
- }
- return true;
-}
-
-} // namespace android
diff --git a/libs/androidfw/VirtualKeyMap.cpp b/libs/androidfw/VirtualKeyMap.cpp
deleted file mode 100644
index 2ba1673..0000000
--- a/libs/androidfw/VirtualKeyMap.cpp
+++ /dev/null
@@ -1,171 +0,0 @@
-/*
- * Copyright (C) 2010 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#define LOG_TAG "VirtualKeyMap"
-
-#include <stdlib.h>
-#include <string.h>
-#include <androidfw/VirtualKeyMap.h>
-#include <utils/Log.h>
-#include <utils/Errors.h>
-#include <utils/Tokenizer.h>
-#include <utils/Timers.h>
-
-// Enables debug output for the parser.
-#define DEBUG_PARSER 0
-
-// Enables debug output for parser performance.
-#define DEBUG_PARSER_PERFORMANCE 0
-
-
-namespace android {
-
-static const char* WHITESPACE = " \t\r";
-static const char* WHITESPACE_OR_FIELD_DELIMITER = " \t\r:";
-
-
-// --- VirtualKeyMap ---
-
-VirtualKeyMap::VirtualKeyMap() {
-}
-
-VirtualKeyMap::~VirtualKeyMap() {
-}
-
-status_t VirtualKeyMap::load(const String8& filename, VirtualKeyMap** outMap) {
- *outMap = NULL;
-
- Tokenizer* tokenizer;
- status_t status = Tokenizer::open(filename, &tokenizer);
- if (status) {
- ALOGE("Error %d opening virtual key map file %s.", status, filename.string());
- } else {
- VirtualKeyMap* map = new VirtualKeyMap();
- if (!map) {
- ALOGE("Error allocating virtual key map.");
- status = NO_MEMORY;
- } else {
-#if DEBUG_PARSER_PERFORMANCE
- nsecs_t startTime = systemTime(SYSTEM_TIME_MONOTONIC);
-#endif
- Parser parser(map, tokenizer);
- status = parser.parse();
-#if DEBUG_PARSER_PERFORMANCE
- nsecs_t elapsedTime = systemTime(SYSTEM_TIME_MONOTONIC) - startTime;
- ALOGD("Parsed key character map file '%s' %d lines in %0.3fms.",
- tokenizer->getFilename().string(), tokenizer->getLineNumber(),
- elapsedTime / 1000000.0);
-#endif
- if (status) {
- delete map;
- } else {
- *outMap = map;
- }
- }
- delete tokenizer;
- }
- return status;
-}
-
-
-// --- VirtualKeyMap::Parser ---
-
-VirtualKeyMap::Parser::Parser(VirtualKeyMap* map, Tokenizer* tokenizer) :
- mMap(map), mTokenizer(tokenizer) {
-}
-
-VirtualKeyMap::Parser::~Parser() {
-}
-
-status_t VirtualKeyMap::Parser::parse() {
- while (!mTokenizer->isEof()) {
-#if DEBUG_PARSER
- ALOGD("Parsing %s: '%s'.", mTokenizer->getLocation().string(),
- mTokenizer->peekRemainderOfLine().string());
-#endif
-
- mTokenizer->skipDelimiters(WHITESPACE);
-
- if (!mTokenizer->isEol() && mTokenizer->peekChar() != '#') {
- // Multiple keys can appear on one line or they can be broken up across multiple lines.
- do {
- String8 token = mTokenizer->nextToken(WHITESPACE_OR_FIELD_DELIMITER);
- if (token != "0x01") {
- ALOGE("%s: Unknown virtual key type, expected 0x01.",
- mTokenizer->getLocation().string());
- return BAD_VALUE;
- }
-
- VirtualKeyDefinition defn;
- bool success = parseNextIntField(&defn.scanCode)
- && parseNextIntField(&defn.centerX)
- && parseNextIntField(&defn.centerY)
- && parseNextIntField(&defn.width)
- && parseNextIntField(&defn.height);
- if (!success) {
- ALOGE("%s: Expected 5 colon-delimited integers in virtual key definition.",
- mTokenizer->getLocation().string());
- return BAD_VALUE;
- }
-
-#if DEBUG_PARSER
- ALOGD("Parsed virtual key: scanCode=%d, centerX=%d, centerY=%d, "
- "width=%d, height=%d",
- defn.scanCode, defn.centerX, defn.centerY, defn.width, defn.height);
-#endif
- mMap->mVirtualKeys.push(defn);
- } while (consumeFieldDelimiterAndSkipWhitespace());
-
- if (!mTokenizer->isEol()) {
- ALOGE("%s: Expected end of line, got '%s'.",
- mTokenizer->getLocation().string(),
- mTokenizer->peekRemainderOfLine().string());
- return BAD_VALUE;
- }
- }
-
- mTokenizer->nextLine();
- }
-
- return NO_ERROR;
-}
-
-bool VirtualKeyMap::Parser::consumeFieldDelimiterAndSkipWhitespace() {
- mTokenizer->skipDelimiters(WHITESPACE);
- if (mTokenizer->peekChar() == ':') {
- mTokenizer->nextChar();
- mTokenizer->skipDelimiters(WHITESPACE);
- return true;
- }
- return false;
-}
-
-bool VirtualKeyMap::Parser::parseNextIntField(int32_t* outValue) {
- if (!consumeFieldDelimiterAndSkipWhitespace()) {
- return false;
- }
-
- String8 token = mTokenizer->nextToken(WHITESPACE_OR_FIELD_DELIMITER);
- char* end;
- *outValue = strtol(token.string(), &end, 0);
- if (token.isEmpty() || *end != '\0') {
- ALOGE("Expected an integer, got '%s'.", token.string());
- return false;
- }
- return true;
-}
-
-} // namespace android
diff --git a/libs/androidfw/tests/Android.mk b/libs/androidfw/tests/Android.mk
index 6be7c5b..0522212 100644
--- a/libs/androidfw/tests/Android.mk
+++ b/libs/androidfw/tests/Android.mk
@@ -4,9 +4,6 @@
# Build the unit tests.
test_src_files := \
- InputChannel_test.cpp \
- InputEvent_test.cpp \
- InputPublisherAndConsumer_test.cpp \
ObbFile_test.cpp \
ZipFileRO_test.cpp
@@ -14,10 +11,8 @@
libandroidfw \
libcutils \
libutils \
- libbinder \
libui \
- libstlport \
- libskia
+ libstlport
static_libraries := \
libgtest \
diff --git a/libs/androidfw/tests/InputChannel_test.cpp b/libs/androidfw/tests/InputChannel_test.cpp
deleted file mode 100644
index 7fff8af..0000000
--- a/libs/androidfw/tests/InputChannel_test.cpp
+++ /dev/null
@@ -1,158 +0,0 @@
-/*
- * Copyright (C) 2010 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <androidfw/InputTransport.h>
-#include <utils/Timers.h>
-#include <utils/StopWatch.h>
-#include <utils/StrongPointer.h>
-#include <gtest/gtest.h>
-#include <unistd.h>
-#include <time.h>
-#include <errno.h>
-
-#include "TestHelpers.h"
-
-namespace android {
-
-class InputChannelTest : public testing::Test {
-protected:
- virtual void SetUp() { }
- virtual void TearDown() { }
-};
-
-
-TEST_F(InputChannelTest, ConstructorAndDestructor_TakesOwnershipOfFileDescriptors) {
- // Our purpose here is to verify that the input channel destructor closes the
- // file descriptor provided to it. One easy way is to provide it with one end
- // of a pipe and to check for EPIPE on the other end after the channel is destroyed.
- Pipe pipe;
-
- sp<InputChannel> inputChannel = new InputChannel(String8("channel name"), pipe.sendFd);
-
- EXPECT_STREQ("channel name", inputChannel->getName().string())
- << "channel should have provided name";
- EXPECT_EQ(pipe.sendFd, inputChannel->getFd())
- << "channel should have provided fd";
-
- inputChannel.clear(); // destroys input channel
-
- EXPECT_EQ(-EPIPE, pipe.readSignal())
- << "channel should have closed fd when destroyed";
-
- // clean up fds of Pipe endpoints that were closed so we don't try to close them again
- pipe.sendFd = -1;
-}
-
-TEST_F(InputChannelTest, OpenInputChannelPair_ReturnsAPairOfConnectedChannels) {
- sp<InputChannel> serverChannel, clientChannel;
-
- status_t result = InputChannel::openInputChannelPair(String8("channel name"),
- serverChannel, clientChannel);
-
- ASSERT_EQ(OK, result)
- << "should have successfully opened a channel pair";
-
- // Name
- EXPECT_STREQ("channel name (server)", serverChannel->getName().string())
- << "server channel should have suffixed name";
- EXPECT_STREQ("channel name (client)", clientChannel->getName().string())
- << "client channel should have suffixed name";
-
- // Server->Client communication
- InputMessage serverMsg;
- memset(&serverMsg, 0, sizeof(InputMessage));
- serverMsg.header.type = InputMessage::TYPE_KEY;
- serverMsg.body.key.action = AKEY_EVENT_ACTION_DOWN;
- EXPECT_EQ(OK, serverChannel->sendMessage(&serverMsg))
- << "server channel should be able to send message to client channel";
-
- InputMessage clientMsg;
- EXPECT_EQ(OK, clientChannel->receiveMessage(&clientMsg))
- << "client channel should be able to receive message from server channel";
- EXPECT_EQ(serverMsg.header.type, clientMsg.header.type)
- << "client channel should receive the correct message from server channel";
- EXPECT_EQ(serverMsg.body.key.action, clientMsg.body.key.action)
- << "client channel should receive the correct message from server channel";
-
- // Client->Server communication
- InputMessage clientReply;
- memset(&clientReply, 0, sizeof(InputMessage));
- clientReply.header.type = InputMessage::TYPE_FINISHED;
- clientReply.body.finished.seq = 0x11223344;
- clientReply.body.finished.handled = true;
- EXPECT_EQ(OK, clientChannel->sendMessage(&clientReply))
- << "client channel should be able to send message to server channel";
-
- InputMessage serverReply;
- EXPECT_EQ(OK, serverChannel->receiveMessage(&serverReply))
- << "server channel should be able to receive message from client channel";
- EXPECT_EQ(clientReply.header.type, serverReply.header.type)
- << "server channel should receive the correct message from client channel";
- EXPECT_EQ(clientReply.body.finished.seq, serverReply.body.finished.seq)
- << "server channel should receive the correct message from client channel";
- EXPECT_EQ(clientReply.body.finished.handled, serverReply.body.finished.handled)
- << "server channel should receive the correct message from client channel";
-}
-
-TEST_F(InputChannelTest, ReceiveSignal_WhenNoSignalPresent_ReturnsAnError) {
- sp<InputChannel> serverChannel, clientChannel;
-
- status_t result = InputChannel::openInputChannelPair(String8("channel name"),
- serverChannel, clientChannel);
-
- ASSERT_EQ(OK, result)
- << "should have successfully opened a channel pair";
-
- InputMessage msg;
- EXPECT_EQ(WOULD_BLOCK, clientChannel->receiveMessage(&msg))
- << "receiveMessage should have returned WOULD_BLOCK";
-}
-
-TEST_F(InputChannelTest, ReceiveSignal_WhenPeerClosed_ReturnsAnError) {
- sp<InputChannel> serverChannel, clientChannel;
-
- status_t result = InputChannel::openInputChannelPair(String8("channel name"),
- serverChannel, clientChannel);
-
- ASSERT_EQ(OK, result)
- << "should have successfully opened a channel pair";
-
- serverChannel.clear(); // close server channel
-
- InputMessage msg;
- EXPECT_EQ(DEAD_OBJECT, clientChannel->receiveMessage(&msg))
- << "receiveMessage should have returned DEAD_OBJECT";
-}
-
-TEST_F(InputChannelTest, SendSignal_WhenPeerClosed_ReturnsAnError) {
- sp<InputChannel> serverChannel, clientChannel;
-
- status_t result = InputChannel::openInputChannelPair(String8("channel name"),
- serverChannel, clientChannel);
-
- ASSERT_EQ(OK, result)
- << "should have successfully opened a channel pair";
-
- serverChannel.clear(); // close server channel
-
- InputMessage msg;
- msg.header.type = InputMessage::TYPE_KEY;
- EXPECT_EQ(DEAD_OBJECT, clientChannel->sendMessage(&msg))
- << "sendMessage should have returned DEAD_OBJECT";
-}
-
-
-} // namespace android
diff --git a/libs/androidfw/tests/InputEvent_test.cpp b/libs/androidfw/tests/InputEvent_test.cpp
deleted file mode 100644
index e9164d1..0000000
--- a/libs/androidfw/tests/InputEvent_test.cpp
+++ /dev/null
@@ -1,581 +0,0 @@
-/*
- * Copyright (C) 2011 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <androidfw/Input.h>
-#include <gtest/gtest.h>
-#include <binder/Parcel.h>
-
-#include <math.h>
-#include <core/SkMatrix.h>
-
-namespace android {
-
-class BaseTest : public testing::Test {
-protected:
- virtual void SetUp() { }
- virtual void TearDown() { }
-};
-
-// --- PointerCoordsTest ---
-
-class PointerCoordsTest : public BaseTest {
-};
-
-TEST_F(PointerCoordsTest, ClearSetsBitsToZero) {
- PointerCoords coords;
- coords.clear();
-
- ASSERT_EQ(0ULL, coords.bits);
-}
-
-TEST_F(PointerCoordsTest, AxisValues) {
- float* valuePtr;
- PointerCoords coords;
- coords.clear();
-
- // Check invariants when no axes are present.
- ASSERT_EQ(0, coords.getAxisValue(0))
- << "getAxisValue should return zero because axis is not present";
- ASSERT_EQ(0, coords.getAxisValue(1))
- << "getAxisValue should return zero because axis is not present";
-
- // Set first axis.
- ASSERT_EQ(OK, coords.setAxisValue(1, 5));
- ASSERT_EQ(0x00000002ULL, coords.bits);
- ASSERT_EQ(5, coords.values[0]);
-
- ASSERT_EQ(0, coords.getAxisValue(0))
- << "getAxisValue should return zero because axis is not present";
- ASSERT_EQ(5, coords.getAxisValue(1))
- << "getAxisValue should return value of axis";
-
- // Set an axis with a higher id than all others. (appending value at the end)
- ASSERT_EQ(OK, coords.setAxisValue(3, 2));
- ASSERT_EQ(0x0000000aULL, coords.bits);
- ASSERT_EQ(5, coords.values[0]);
- ASSERT_EQ(2, coords.values[1]);
-
- ASSERT_EQ(0, coords.getAxisValue(0))
- << "getAxisValue should return zero because axis is not present";
- ASSERT_EQ(5, coords.getAxisValue(1))
- << "getAxisValue should return value of axis";
- ASSERT_EQ(0, coords.getAxisValue(2))
- << "getAxisValue should return zero because axis is not present";
- ASSERT_EQ(2, coords.getAxisValue(3))
- << "getAxisValue should return value of axis";
-
- // Set an axis with an id lower than all others. (prepending value at beginning)
- ASSERT_EQ(OK, coords.setAxisValue(0, 4));
- ASSERT_EQ(0x0000000bULL, coords.bits);
- ASSERT_EQ(4, coords.values[0]);
- ASSERT_EQ(5, coords.values[1]);
- ASSERT_EQ(2, coords.values[2]);
-
- ASSERT_EQ(4, coords.getAxisValue(0))
- << "getAxisValue should return value of axis";
- ASSERT_EQ(5, coords.getAxisValue(1))
- << "getAxisValue should return value of axis";
- ASSERT_EQ(0, coords.getAxisValue(2))
- << "getAxisValue should return zero because axis is not present";
- ASSERT_EQ(2, coords.getAxisValue(3))
- << "getAxisValue should return value of axis";
-
- // Set an axis with an id between the others. (inserting value in the middle)
- ASSERT_EQ(OK, coords.setAxisValue(2, 1));
- ASSERT_EQ(0x0000000fULL, coords.bits);
- ASSERT_EQ(4, coords.values[0]);
- ASSERT_EQ(5, coords.values[1]);
- ASSERT_EQ(1, coords.values[2]);
- ASSERT_EQ(2, coords.values[3]);
-
- ASSERT_EQ(4, coords.getAxisValue(0))
- << "getAxisValue should return value of axis";
- ASSERT_EQ(5, coords.getAxisValue(1))
- << "getAxisValue should return value of axis";
- ASSERT_EQ(1, coords.getAxisValue(2))
- << "getAxisValue should return value of axis";
- ASSERT_EQ(2, coords.getAxisValue(3))
- << "getAxisValue should return value of axis";
-
- // Set an existing axis value in place.
- ASSERT_EQ(OK, coords.setAxisValue(1, 6));
- ASSERT_EQ(0x0000000fULL, coords.bits);
- ASSERT_EQ(4, coords.values[0]);
- ASSERT_EQ(6, coords.values[1]);
- ASSERT_EQ(1, coords.values[2]);
- ASSERT_EQ(2, coords.values[3]);
-
- ASSERT_EQ(4, coords.getAxisValue(0))
- << "getAxisValue should return value of axis";
- ASSERT_EQ(6, coords.getAxisValue(1))
- << "getAxisValue should return value of axis";
- ASSERT_EQ(1, coords.getAxisValue(2))
- << "getAxisValue should return value of axis";
- ASSERT_EQ(2, coords.getAxisValue(3))
- << "getAxisValue should return value of axis";
-
- // Set maximum number of axes.
- for (size_t axis = 4; axis < PointerCoords::MAX_AXES; axis++) {
- ASSERT_EQ(OK, coords.setAxisValue(axis, axis));
- }
- ASSERT_EQ(PointerCoords::MAX_AXES, __builtin_popcountll(coords.bits));
-
- // Try to set one more axis beyond maximum number.
- // Ensure bits are unchanged.
- ASSERT_EQ(NO_MEMORY, coords.setAxisValue(PointerCoords::MAX_AXES, 100));
- ASSERT_EQ(PointerCoords::MAX_AXES, __builtin_popcountll(coords.bits));
-}
-
-TEST_F(PointerCoordsTest, Parcel) {
- Parcel parcel;
-
- PointerCoords inCoords;
- inCoords.clear();
- PointerCoords outCoords;
-
- // Round trip with empty coords.
- inCoords.writeToParcel(&parcel);
- parcel.setDataPosition(0);
- outCoords.readFromParcel(&parcel);
-
- ASSERT_EQ(0ULL, outCoords.bits);
-
- // Round trip with some values.
- parcel.freeData();
- inCoords.setAxisValue(2, 5);
- inCoords.setAxisValue(5, 8);
-
- inCoords.writeToParcel(&parcel);
- parcel.setDataPosition(0);
- outCoords.readFromParcel(&parcel);
-
- ASSERT_EQ(outCoords.bits, inCoords.bits);
- ASSERT_EQ(outCoords.values[0], inCoords.values[0]);
- ASSERT_EQ(outCoords.values[1], inCoords.values[1]);
-}
-
-
-// --- KeyEventTest ---
-
-class KeyEventTest : public BaseTest {
-};
-
-TEST_F(KeyEventTest, Properties) {
- KeyEvent event;
-
- // Initialize and get properties.
- const nsecs_t ARBITRARY_DOWN_TIME = 1;
- const nsecs_t ARBITRARY_EVENT_TIME = 2;
- event.initialize(2, AINPUT_SOURCE_GAMEPAD, AKEY_EVENT_ACTION_DOWN,
- AKEY_EVENT_FLAG_FROM_SYSTEM, AKEYCODE_BUTTON_X, 121,
- AMETA_ALT_ON, 1, ARBITRARY_DOWN_TIME, ARBITRARY_EVENT_TIME);
-
- ASSERT_EQ(AINPUT_EVENT_TYPE_KEY, event.getType());
- ASSERT_EQ(2, event.getDeviceId());
- ASSERT_EQ(AINPUT_SOURCE_GAMEPAD, event.getSource());
- ASSERT_EQ(AKEY_EVENT_ACTION_DOWN, event.getAction());
- ASSERT_EQ(AKEY_EVENT_FLAG_FROM_SYSTEM, event.getFlags());
- ASSERT_EQ(AKEYCODE_BUTTON_X, event.getKeyCode());
- ASSERT_EQ(121, event.getScanCode());
- ASSERT_EQ(AMETA_ALT_ON, event.getMetaState());
- ASSERT_EQ(1, event.getRepeatCount());
- ASSERT_EQ(ARBITRARY_DOWN_TIME, event.getDownTime());
- ASSERT_EQ(ARBITRARY_EVENT_TIME, event.getEventTime());
-
- // Set source.
- event.setSource(AINPUT_SOURCE_JOYSTICK);
- ASSERT_EQ(AINPUT_SOURCE_JOYSTICK, event.getSource());
-}
-
-
-// --- MotionEventTest ---
-
-class MotionEventTest : public BaseTest {
-protected:
- static const nsecs_t ARBITRARY_DOWN_TIME;
- static const nsecs_t ARBITRARY_EVENT_TIME;
- static const float X_OFFSET;
- static const float Y_OFFSET;
-
- void initializeEventWithHistory(MotionEvent* event);
- void assertEqualsEventWithHistory(const MotionEvent* event);
-};
-
-const nsecs_t MotionEventTest::ARBITRARY_DOWN_TIME = 1;
-const nsecs_t MotionEventTest::ARBITRARY_EVENT_TIME = 2;
-const float MotionEventTest::X_OFFSET = 1.0f;
-const float MotionEventTest::Y_OFFSET = 1.1f;
-
-void MotionEventTest::initializeEventWithHistory(MotionEvent* event) {
- PointerProperties pointerProperties[2];
- pointerProperties[0].clear();
- pointerProperties[0].id = 1;
- pointerProperties[0].toolType = AMOTION_EVENT_TOOL_TYPE_FINGER;
- pointerProperties[1].clear();
- pointerProperties[1].id = 2;
- pointerProperties[1].toolType = AMOTION_EVENT_TOOL_TYPE_STYLUS;
-
- PointerCoords pointerCoords[2];
- pointerCoords[0].clear();
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_X, 10);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_Y, 11);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_PRESSURE, 12);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_SIZE, 13);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_TOUCH_MAJOR, 14);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_TOUCH_MINOR, 15);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_TOOL_MAJOR, 16);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_TOOL_MINOR, 17);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_ORIENTATION, 18);
- pointerCoords[1].clear();
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_X, 20);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_Y, 21);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_PRESSURE, 22);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_SIZE, 23);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_TOUCH_MAJOR, 24);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_TOUCH_MINOR, 25);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_TOOL_MAJOR, 26);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_TOOL_MINOR, 27);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_ORIENTATION, 28);
- event->initialize(2, AINPUT_SOURCE_TOUCHSCREEN, AMOTION_EVENT_ACTION_MOVE,
- AMOTION_EVENT_FLAG_WINDOW_IS_OBSCURED,
- AMOTION_EVENT_EDGE_FLAG_TOP, AMETA_ALT_ON, AMOTION_EVENT_BUTTON_PRIMARY,
- X_OFFSET, Y_OFFSET, 2.0f, 2.1f,
- ARBITRARY_DOWN_TIME, ARBITRARY_EVENT_TIME,
- 2, pointerProperties, pointerCoords);
-
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_X, 110);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_Y, 111);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_PRESSURE, 112);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_SIZE, 113);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_TOUCH_MAJOR, 114);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_TOUCH_MINOR, 115);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_TOOL_MAJOR, 116);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_TOOL_MINOR, 117);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_ORIENTATION, 118);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_X, 120);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_Y, 121);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_PRESSURE, 122);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_SIZE, 123);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_TOUCH_MAJOR, 124);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_TOUCH_MINOR, 125);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_TOOL_MAJOR, 126);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_TOOL_MINOR, 127);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_ORIENTATION, 128);
- event->addSample(ARBITRARY_EVENT_TIME + 1, pointerCoords);
-
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_X, 210);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_Y, 211);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_PRESSURE, 212);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_SIZE, 213);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_TOUCH_MAJOR, 214);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_TOUCH_MINOR, 215);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_TOOL_MAJOR, 216);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_TOOL_MINOR, 217);
- pointerCoords[0].setAxisValue(AMOTION_EVENT_AXIS_ORIENTATION, 218);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_X, 220);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_Y, 221);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_PRESSURE, 222);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_SIZE, 223);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_TOUCH_MAJOR, 224);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_TOUCH_MINOR, 225);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_TOOL_MAJOR, 226);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_TOOL_MINOR, 227);
- pointerCoords[1].setAxisValue(AMOTION_EVENT_AXIS_ORIENTATION, 228);
- event->addSample(ARBITRARY_EVENT_TIME + 2, pointerCoords);
-}
-
-void MotionEventTest::assertEqualsEventWithHistory(const MotionEvent* event) {
- // Check properties.
- ASSERT_EQ(AINPUT_EVENT_TYPE_MOTION, event->getType());
- ASSERT_EQ(2, event->getDeviceId());
- ASSERT_EQ(AINPUT_SOURCE_TOUCHSCREEN, event->getSource());
- ASSERT_EQ(AMOTION_EVENT_ACTION_MOVE, event->getAction());
- ASSERT_EQ(AMOTION_EVENT_FLAG_WINDOW_IS_OBSCURED, event->getFlags());
- ASSERT_EQ(AMOTION_EVENT_EDGE_FLAG_TOP, event->getEdgeFlags());
- ASSERT_EQ(AMETA_ALT_ON, event->getMetaState());
- ASSERT_EQ(AMOTION_EVENT_BUTTON_PRIMARY, event->getButtonState());
- ASSERT_EQ(X_OFFSET, event->getXOffset());
- ASSERT_EQ(Y_OFFSET, event->getYOffset());
- ASSERT_EQ(2.0f, event->getXPrecision());
- ASSERT_EQ(2.1f, event->getYPrecision());
- ASSERT_EQ(ARBITRARY_DOWN_TIME, event->getDownTime());
-
- ASSERT_EQ(2U, event->getPointerCount());
- ASSERT_EQ(1, event->getPointerId(0));
- ASSERT_EQ(AMOTION_EVENT_TOOL_TYPE_FINGER, event->getToolType(0));
- ASSERT_EQ(2, event->getPointerId(1));
- ASSERT_EQ(AMOTION_EVENT_TOOL_TYPE_STYLUS, event->getToolType(1));
-
- ASSERT_EQ(2U, event->getHistorySize());
-
- // Check data.
- ASSERT_EQ(ARBITRARY_EVENT_TIME, event->getHistoricalEventTime(0));
- ASSERT_EQ(ARBITRARY_EVENT_TIME + 1, event->getHistoricalEventTime(1));
- ASSERT_EQ(ARBITRARY_EVENT_TIME + 2, event->getEventTime());
-
- ASSERT_EQ(11, event->getHistoricalRawPointerCoords(0, 0)->
- getAxisValue(AMOTION_EVENT_AXIS_Y));
- ASSERT_EQ(21, event->getHistoricalRawPointerCoords(1, 0)->
- getAxisValue(AMOTION_EVENT_AXIS_Y));
- ASSERT_EQ(111, event->getHistoricalRawPointerCoords(0, 1)->
- getAxisValue(AMOTION_EVENT_AXIS_Y));
- ASSERT_EQ(121, event->getHistoricalRawPointerCoords(1, 1)->
- getAxisValue(AMOTION_EVENT_AXIS_Y));
- ASSERT_EQ(211, event->getRawPointerCoords(0)->
- getAxisValue(AMOTION_EVENT_AXIS_Y));
- ASSERT_EQ(221, event->getRawPointerCoords(1)->
- getAxisValue(AMOTION_EVENT_AXIS_Y));
-
- ASSERT_EQ(11, event->getHistoricalRawAxisValue(AMOTION_EVENT_AXIS_Y, 0, 0));
- ASSERT_EQ(21, event->getHistoricalRawAxisValue(AMOTION_EVENT_AXIS_Y, 1, 0));
- ASSERT_EQ(111, event->getHistoricalRawAxisValue(AMOTION_EVENT_AXIS_Y, 0, 1));
- ASSERT_EQ(121, event->getHistoricalRawAxisValue(AMOTION_EVENT_AXIS_Y, 1, 1));
- ASSERT_EQ(211, event->getRawAxisValue(AMOTION_EVENT_AXIS_Y, 0));
- ASSERT_EQ(221, event->getRawAxisValue(AMOTION_EVENT_AXIS_Y, 1));
-
- ASSERT_EQ(10, event->getHistoricalRawX(0, 0));
- ASSERT_EQ(20, event->getHistoricalRawX(1, 0));
- ASSERT_EQ(110, event->getHistoricalRawX(0, 1));
- ASSERT_EQ(120, event->getHistoricalRawX(1, 1));
- ASSERT_EQ(210, event->getRawX(0));
- ASSERT_EQ(220, event->getRawX(1));
-
- ASSERT_EQ(11, event->getHistoricalRawY(0, 0));
- ASSERT_EQ(21, event->getHistoricalRawY(1, 0));
- ASSERT_EQ(111, event->getHistoricalRawY(0, 1));
- ASSERT_EQ(121, event->getHistoricalRawY(1, 1));
- ASSERT_EQ(211, event->getRawY(0));
- ASSERT_EQ(221, event->getRawY(1));
-
- ASSERT_EQ(X_OFFSET + 10, event->getHistoricalX(0, 0));
- ASSERT_EQ(X_OFFSET + 20, event->getHistoricalX(1, 0));
- ASSERT_EQ(X_OFFSET + 110, event->getHistoricalX(0, 1));
- ASSERT_EQ(X_OFFSET + 120, event->getHistoricalX(1, 1));
- ASSERT_EQ(X_OFFSET + 210, event->getX(0));
- ASSERT_EQ(X_OFFSET + 220, event->getX(1));
-
- ASSERT_EQ(Y_OFFSET + 11, event->getHistoricalY(0, 0));
- ASSERT_EQ(Y_OFFSET + 21, event->getHistoricalY(1, 0));
- ASSERT_EQ(Y_OFFSET + 111, event->getHistoricalY(0, 1));
- ASSERT_EQ(Y_OFFSET + 121, event->getHistoricalY(1, 1));
- ASSERT_EQ(Y_OFFSET + 211, event->getY(0));
- ASSERT_EQ(Y_OFFSET + 221, event->getY(1));
-
- ASSERT_EQ(12, event->getHistoricalPressure(0, 0));
- ASSERT_EQ(22, event->getHistoricalPressure(1, 0));
- ASSERT_EQ(112, event->getHistoricalPressure(0, 1));
- ASSERT_EQ(122, event->getHistoricalPressure(1, 1));
- ASSERT_EQ(212, event->getPressure(0));
- ASSERT_EQ(222, event->getPressure(1));
-
- ASSERT_EQ(13, event->getHistoricalSize(0, 0));
- ASSERT_EQ(23, event->getHistoricalSize(1, 0));
- ASSERT_EQ(113, event->getHistoricalSize(0, 1));
- ASSERT_EQ(123, event->getHistoricalSize(1, 1));
- ASSERT_EQ(213, event->getSize(0));
- ASSERT_EQ(223, event->getSize(1));
-
- ASSERT_EQ(14, event->getHistoricalTouchMajor(0, 0));
- ASSERT_EQ(24, event->getHistoricalTouchMajor(1, 0));
- ASSERT_EQ(114, event->getHistoricalTouchMajor(0, 1));
- ASSERT_EQ(124, event->getHistoricalTouchMajor(1, 1));
- ASSERT_EQ(214, event->getTouchMajor(0));
- ASSERT_EQ(224, event->getTouchMajor(1));
-
- ASSERT_EQ(15, event->getHistoricalTouchMinor(0, 0));
- ASSERT_EQ(25, event->getHistoricalTouchMinor(1, 0));
- ASSERT_EQ(115, event->getHistoricalTouchMinor(0, 1));
- ASSERT_EQ(125, event->getHistoricalTouchMinor(1, 1));
- ASSERT_EQ(215, event->getTouchMinor(0));
- ASSERT_EQ(225, event->getTouchMinor(1));
-
- ASSERT_EQ(16, event->getHistoricalToolMajor(0, 0));
- ASSERT_EQ(26, event->getHistoricalToolMajor(1, 0));
- ASSERT_EQ(116, event->getHistoricalToolMajor(0, 1));
- ASSERT_EQ(126, event->getHistoricalToolMajor(1, 1));
- ASSERT_EQ(216, event->getToolMajor(0));
- ASSERT_EQ(226, event->getToolMajor(1));
-
- ASSERT_EQ(17, event->getHistoricalToolMinor(0, 0));
- ASSERT_EQ(27, event->getHistoricalToolMinor(1, 0));
- ASSERT_EQ(117, event->getHistoricalToolMinor(0, 1));
- ASSERT_EQ(127, event->getHistoricalToolMinor(1, 1));
- ASSERT_EQ(217, event->getToolMinor(0));
- ASSERT_EQ(227, event->getToolMinor(1));
-
- ASSERT_EQ(18, event->getHistoricalOrientation(0, 0));
- ASSERT_EQ(28, event->getHistoricalOrientation(1, 0));
- ASSERT_EQ(118, event->getHistoricalOrientation(0, 1));
- ASSERT_EQ(128, event->getHistoricalOrientation(1, 1));
- ASSERT_EQ(218, event->getOrientation(0));
- ASSERT_EQ(228, event->getOrientation(1));
-}
-
-TEST_F(MotionEventTest, Properties) {
- MotionEvent event;
-
- // Initialize, add samples and check properties.
- initializeEventWithHistory(&event);
- ASSERT_NO_FATAL_FAILURE(assertEqualsEventWithHistory(&event));
-
- // Set source.
- event.setSource(AINPUT_SOURCE_JOYSTICK);
- ASSERT_EQ(AINPUT_SOURCE_JOYSTICK, event.getSource());
-
- // Set action.
- event.setAction(AMOTION_EVENT_ACTION_CANCEL);
- ASSERT_EQ(AMOTION_EVENT_ACTION_CANCEL, event.getAction());
-
- // Set meta state.
- event.setMetaState(AMETA_CTRL_ON);
- ASSERT_EQ(AMETA_CTRL_ON, event.getMetaState());
-}
-
-TEST_F(MotionEventTest, CopyFrom_KeepHistory) {
- MotionEvent event;
- initializeEventWithHistory(&event);
-
- MotionEvent copy;
- copy.copyFrom(&event, true /*keepHistory*/);
-
- ASSERT_NO_FATAL_FAILURE(assertEqualsEventWithHistory(&event));
-}
-
-TEST_F(MotionEventTest, CopyFrom_DoNotKeepHistory) {
- MotionEvent event;
- initializeEventWithHistory(&event);
-
- MotionEvent copy;
- copy.copyFrom(&event, false /*keepHistory*/);
-
- ASSERT_EQ(event.getPointerCount(), copy.getPointerCount());
- ASSERT_EQ(0U, copy.getHistorySize());
-
- ASSERT_EQ(event.getPointerId(0), copy.getPointerId(0));
- ASSERT_EQ(event.getPointerId(1), copy.getPointerId(1));
-
- ASSERT_EQ(event.getEventTime(), copy.getEventTime());
-
- ASSERT_EQ(event.getX(0), copy.getX(0));
-}
-
-TEST_F(MotionEventTest, OffsetLocation) {
- MotionEvent event;
- initializeEventWithHistory(&event);
-
- event.offsetLocation(5.0f, -2.0f);
-
- ASSERT_EQ(X_OFFSET + 5.0f, event.getXOffset());
- ASSERT_EQ(Y_OFFSET - 2.0f, event.getYOffset());
-}
-
-TEST_F(MotionEventTest, Scale) {
- MotionEvent event;
- initializeEventWithHistory(&event);
-
- event.scale(2.0f);
-
- ASSERT_EQ(X_OFFSET * 2, event.getXOffset());
- ASSERT_EQ(Y_OFFSET * 2, event.getYOffset());
-
- ASSERT_EQ(210 * 2, event.getRawX(0));
- ASSERT_EQ(211 * 2, event.getRawY(0));
- ASSERT_EQ((X_OFFSET + 210) * 2, event.getX(0));
- ASSERT_EQ((Y_OFFSET + 211) * 2, event.getY(0));
- ASSERT_EQ(212, event.getPressure(0));
- ASSERT_EQ(213, event.getSize(0));
- ASSERT_EQ(214 * 2, event.getTouchMajor(0));
- ASSERT_EQ(215 * 2, event.getTouchMinor(0));
- ASSERT_EQ(216 * 2, event.getToolMajor(0));
- ASSERT_EQ(217 * 2, event.getToolMinor(0));
- ASSERT_EQ(218, event.getOrientation(0));
-}
-
-TEST_F(MotionEventTest, Parcel) {
- Parcel parcel;
-
- MotionEvent inEvent;
- initializeEventWithHistory(&inEvent);
- MotionEvent outEvent;
-
- // Round trip.
- inEvent.writeToParcel(&parcel);
- parcel.setDataPosition(0);
- outEvent.readFromParcel(&parcel);
-
- ASSERT_NO_FATAL_FAILURE(assertEqualsEventWithHistory(&outEvent));
-}
-
-TEST_F(MotionEventTest, Transform) {
- // Generate some points on a circle.
- // Each point 'i' is a point on a circle of radius ROTATION centered at (3,2) at an angle
- // of ARC * i degrees clockwise relative to the Y axis.
- // The geometrical representation is irrelevant to the test, it's just easy to generate
- // and check rotation. We set the orientation to the same angle.
- // Coordinate system: down is increasing Y, right is increasing X.
- const float PI_180 = float(M_PI / 180);
- const float RADIUS = 10;
- const float ARC = 36;
- const float ROTATION = ARC * 2;
-
- const size_t pointerCount = 11;
- PointerProperties pointerProperties[pointerCount];
- PointerCoords pointerCoords[pointerCount];
- for (size_t i = 0; i < pointerCount; i++) {
- float angle = float(i * ARC * PI_180);
- pointerProperties[i].clear();
- pointerProperties[i].id = i;
- pointerCoords[i].clear();
- pointerCoords[i].setAxisValue(AMOTION_EVENT_AXIS_X, sinf(angle) * RADIUS + 3);
- pointerCoords[i].setAxisValue(AMOTION_EVENT_AXIS_Y, -cosf(angle) * RADIUS + 2);
- pointerCoords[i].setAxisValue(AMOTION_EVENT_AXIS_ORIENTATION, angle);
- }
- MotionEvent event;
- event.initialize(0, 0, AMOTION_EVENT_ACTION_MOVE, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, pointerCount, pointerProperties, pointerCoords);
- float originalRawX = 0 + 3;
- float originalRawY = -RADIUS + 2;
-
- // Check original raw X and Y assumption.
- ASSERT_NEAR(originalRawX, event.getRawX(0), 0.001);
- ASSERT_NEAR(originalRawY, event.getRawY(0), 0.001);
-
- // Now translate the motion event so the circle's origin is at (0,0).
- event.offsetLocation(-3, -2);
-
- // Offsetting the location should preserve the raw X and Y of the first point.
- ASSERT_NEAR(originalRawX, event.getRawX(0), 0.001);
- ASSERT_NEAR(originalRawY, event.getRawY(0), 0.001);
-
- // Apply a rotation about the origin by ROTATION degrees clockwise.
- SkMatrix matrix;
- matrix.setRotate(ROTATION);
- event.transform(&matrix);
-
- // Check the points.
- for (size_t i = 0; i < pointerCount; i++) {
- float angle = float((i * ARC + ROTATION) * PI_180);
- ASSERT_NEAR(sinf(angle) * RADIUS, event.getX(i), 0.001);
- ASSERT_NEAR(-cosf(angle) * RADIUS, event.getY(i), 0.001);
- ASSERT_NEAR(tanf(angle), tanf(event.getOrientation(i)), 0.1);
- }
-
- // Applying the transformation should preserve the raw X and Y of the first point.
- ASSERT_NEAR(originalRawX, event.getRawX(0), 0.001);
- ASSERT_NEAR(originalRawY, event.getRawY(0), 0.001);
-}
-
-} // namespace android
diff --git a/libs/androidfw/tests/InputPublisherAndConsumer_test.cpp b/libs/androidfw/tests/InputPublisherAndConsumer_test.cpp
deleted file mode 100644
index f45774b..0000000
--- a/libs/androidfw/tests/InputPublisherAndConsumer_test.cpp
+++ /dev/null
@@ -1,287 +0,0 @@
-/*
- * Copyright (C) 2010 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <androidfw/InputTransport.h>
-#include <utils/Timers.h>
-#include <utils/StopWatch.h>
-#include <gtest/gtest.h>
-#include <unistd.h>
-#include <time.h>
-#include <sys/mman.h>
-#include <cutils/ashmem.h>
-
-#include "TestHelpers.h"
-
-namespace android {
-
-class InputPublisherAndConsumerTest : public testing::Test {
-protected:
- sp<InputChannel> serverChannel, clientChannel;
- InputPublisher* mPublisher;
- InputConsumer* mConsumer;
- PreallocatedInputEventFactory mEventFactory;
-
- virtual void SetUp() {
- status_t result = InputChannel::openInputChannelPair(String8("channel name"),
- serverChannel, clientChannel);
-
- mPublisher = new InputPublisher(serverChannel);
- mConsumer = new InputConsumer(clientChannel);
- }
-
- virtual void TearDown() {
- if (mPublisher) {
- delete mPublisher;
- mPublisher = NULL;
- }
-
- if (mConsumer) {
- delete mConsumer;
- mConsumer = NULL;
- }
-
- serverChannel.clear();
- clientChannel.clear();
- }
-
- void PublishAndConsumeKeyEvent();
- void PublishAndConsumeMotionEvent();
-};
-
-TEST_F(InputPublisherAndConsumerTest, GetChannel_ReturnsTheChannel) {
- EXPECT_EQ(serverChannel.get(), mPublisher->getChannel().get());
- EXPECT_EQ(clientChannel.get(), mConsumer->getChannel().get());
-}
-
-void InputPublisherAndConsumerTest::PublishAndConsumeKeyEvent() {
- status_t status;
-
- const uint32_t seq = 15;
- const int32_t deviceId = 1;
- const int32_t source = AINPUT_SOURCE_KEYBOARD;
- const int32_t action = AKEY_EVENT_ACTION_DOWN;
- const int32_t flags = AKEY_EVENT_FLAG_FROM_SYSTEM;
- const int32_t keyCode = AKEYCODE_ENTER;
- const int32_t scanCode = 13;
- const int32_t metaState = AMETA_ALT_LEFT_ON | AMETA_ALT_ON;
- const int32_t repeatCount = 1;
- const nsecs_t downTime = 3;
- const nsecs_t eventTime = 4;
-
- status = mPublisher->publishKeyEvent(seq, deviceId, source, action, flags,
- keyCode, scanCode, metaState, repeatCount, downTime, eventTime);
- ASSERT_EQ(OK, status)
- << "publisher publishKeyEvent should return OK";
-
- uint32_t consumeSeq;
- InputEvent* event;
- status = mConsumer->consume(&mEventFactory, true /*consumeBatches*/, -1, &consumeSeq, &event);
- ASSERT_EQ(OK, status)
- << "consumer consume should return OK";
-
- ASSERT_TRUE(event != NULL)
- << "consumer should have returned non-NULL event";
- ASSERT_EQ(AINPUT_EVENT_TYPE_KEY, event->getType())
- << "consumer should have returned a key event";
-
- KeyEvent* keyEvent = static_cast<KeyEvent*>(event);
- EXPECT_EQ(seq, consumeSeq);
- EXPECT_EQ(deviceId, keyEvent->getDeviceId());
- EXPECT_EQ(source, keyEvent->getSource());
- EXPECT_EQ(action, keyEvent->getAction());
- EXPECT_EQ(flags, keyEvent->getFlags());
- EXPECT_EQ(keyCode, keyEvent->getKeyCode());
- EXPECT_EQ(scanCode, keyEvent->getScanCode());
- EXPECT_EQ(metaState, keyEvent->getMetaState());
- EXPECT_EQ(repeatCount, keyEvent->getRepeatCount());
- EXPECT_EQ(downTime, keyEvent->getDownTime());
- EXPECT_EQ(eventTime, keyEvent->getEventTime());
-
- status = mConsumer->sendFinishedSignal(seq, true);
- ASSERT_EQ(OK, status)
- << "consumer sendFinishedSignal should return OK";
-
- uint32_t finishedSeq = 0;
- bool handled = false;
- status = mPublisher->receiveFinishedSignal(&finishedSeq, &handled);
- ASSERT_EQ(OK, status)
- << "publisher receiveFinishedSignal should return OK";
- ASSERT_EQ(seq, finishedSeq)
- << "publisher receiveFinishedSignal should have returned the original sequence number";
- ASSERT_TRUE(handled)
- << "publisher receiveFinishedSignal should have set handled to consumer's reply";
-}
-
-void InputPublisherAndConsumerTest::PublishAndConsumeMotionEvent() {
- status_t status;
-
- const uint32_t seq = 15;
- const int32_t deviceId = 1;
- const int32_t source = AINPUT_SOURCE_TOUCHSCREEN;
- const int32_t action = AMOTION_EVENT_ACTION_MOVE;
- const int32_t flags = AMOTION_EVENT_FLAG_WINDOW_IS_OBSCURED;
- const int32_t edgeFlags = AMOTION_EVENT_EDGE_FLAG_TOP;
- const int32_t metaState = AMETA_ALT_LEFT_ON | AMETA_ALT_ON;
- const int32_t buttonState = AMOTION_EVENT_BUTTON_PRIMARY;
- const float xOffset = -10;
- const float yOffset = -20;
- const float xPrecision = 0.25;
- const float yPrecision = 0.5;
- const nsecs_t downTime = 3;
- const size_t pointerCount = 3;
- const nsecs_t eventTime = 4;
- PointerProperties pointerProperties[pointerCount];
- PointerCoords pointerCoords[pointerCount];
- for (size_t i = 0; i < pointerCount; i++) {
- pointerProperties[i].clear();
- pointerProperties[i].id = (i + 2) % pointerCount;
- pointerProperties[i].toolType = AMOTION_EVENT_TOOL_TYPE_FINGER;
-
- pointerCoords[i].clear();
- pointerCoords[i].setAxisValue(AMOTION_EVENT_AXIS_X, 100 * i);
- pointerCoords[i].setAxisValue(AMOTION_EVENT_AXIS_Y, 200 * i);
- pointerCoords[i].setAxisValue(AMOTION_EVENT_AXIS_PRESSURE, 0.5 * i);
- pointerCoords[i].setAxisValue(AMOTION_EVENT_AXIS_SIZE, 0.7 * i);
- pointerCoords[i].setAxisValue(AMOTION_EVENT_AXIS_TOUCH_MAJOR, 1.5 * i);
- pointerCoords[i].setAxisValue(AMOTION_EVENT_AXIS_TOUCH_MINOR, 1.7 * i);
- pointerCoords[i].setAxisValue(AMOTION_EVENT_AXIS_TOOL_MAJOR, 2.5 * i);
- pointerCoords[i].setAxisValue(AMOTION_EVENT_AXIS_TOOL_MAJOR, 2.7 * i);
- pointerCoords[i].setAxisValue(AMOTION_EVENT_AXIS_ORIENTATION, 3.5 * i);
- }
-
- status = mPublisher->publishMotionEvent(seq, deviceId, source, action, flags, edgeFlags,
- metaState, buttonState, xOffset, yOffset, xPrecision, yPrecision,
- downTime, eventTime, pointerCount,
- pointerProperties, pointerCoords);
- ASSERT_EQ(OK, status)
- << "publisher publishMotionEvent should return OK";
-
- uint32_t consumeSeq;
- InputEvent* event;
- status = mConsumer->consume(&mEventFactory, true /*consumeBatches*/, -1, &consumeSeq, &event);
- ASSERT_EQ(OK, status)
- << "consumer consume should return OK";
-
- ASSERT_TRUE(event != NULL)
- << "consumer should have returned non-NULL event";
- ASSERT_EQ(AINPUT_EVENT_TYPE_MOTION, event->getType())
- << "consumer should have returned a motion event";
-
- MotionEvent* motionEvent = static_cast<MotionEvent*>(event);
- EXPECT_EQ(seq, consumeSeq);
- EXPECT_EQ(deviceId, motionEvent->getDeviceId());
- EXPECT_EQ(source, motionEvent->getSource());
- EXPECT_EQ(action, motionEvent->getAction());
- EXPECT_EQ(flags, motionEvent->getFlags());
- EXPECT_EQ(edgeFlags, motionEvent->getEdgeFlags());
- EXPECT_EQ(metaState, motionEvent->getMetaState());
- EXPECT_EQ(buttonState, motionEvent->getButtonState());
- EXPECT_EQ(xPrecision, motionEvent->getXPrecision());
- EXPECT_EQ(yPrecision, motionEvent->getYPrecision());
- EXPECT_EQ(downTime, motionEvent->getDownTime());
- EXPECT_EQ(eventTime, motionEvent->getEventTime());
- EXPECT_EQ(pointerCount, motionEvent->getPointerCount());
- EXPECT_EQ(0U, motionEvent->getHistorySize());
-
- for (size_t i = 0; i < pointerCount; i++) {
- SCOPED_TRACE(i);
- EXPECT_EQ(pointerProperties[i].id, motionEvent->getPointerId(i));
- EXPECT_EQ(pointerProperties[i].toolType, motionEvent->getToolType(i));
-
- EXPECT_EQ(pointerCoords[i].getAxisValue(AMOTION_EVENT_AXIS_X),
- motionEvent->getRawX(i));
- EXPECT_EQ(pointerCoords[i].getAxisValue(AMOTION_EVENT_AXIS_Y),
- motionEvent->getRawY(i));
- EXPECT_EQ(pointerCoords[i].getAxisValue(AMOTION_EVENT_AXIS_X) + xOffset,
- motionEvent->getX(i));
- EXPECT_EQ(pointerCoords[i].getAxisValue(AMOTION_EVENT_AXIS_Y) + yOffset,
- motionEvent->getY(i));
- EXPECT_EQ(pointerCoords[i].getAxisValue(AMOTION_EVENT_AXIS_PRESSURE),
- motionEvent->getPressure(i));
- EXPECT_EQ(pointerCoords[i].getAxisValue(AMOTION_EVENT_AXIS_SIZE),
- motionEvent->getSize(i));
- EXPECT_EQ(pointerCoords[i].getAxisValue(AMOTION_EVENT_AXIS_TOUCH_MAJOR),
- motionEvent->getTouchMajor(i));
- EXPECT_EQ(pointerCoords[i].getAxisValue(AMOTION_EVENT_AXIS_TOUCH_MINOR),
- motionEvent->getTouchMinor(i));
- EXPECT_EQ(pointerCoords[i].getAxisValue(AMOTION_EVENT_AXIS_TOOL_MAJOR),
- motionEvent->getToolMajor(i));
- EXPECT_EQ(pointerCoords[i].getAxisValue(AMOTION_EVENT_AXIS_TOOL_MINOR),
- motionEvent->getToolMinor(i));
- EXPECT_EQ(pointerCoords[i].getAxisValue(AMOTION_EVENT_AXIS_ORIENTATION),
- motionEvent->getOrientation(i));
- }
-
- status = mConsumer->sendFinishedSignal(seq, false);
- ASSERT_EQ(OK, status)
- << "consumer sendFinishedSignal should return OK";
-
- uint32_t finishedSeq = 0;
- bool handled = true;
- status = mPublisher->receiveFinishedSignal(&finishedSeq, &handled);
- ASSERT_EQ(OK, status)
- << "publisher receiveFinishedSignal should return OK";
- ASSERT_EQ(seq, finishedSeq)
- << "publisher receiveFinishedSignal should have returned the original sequence number";
- ASSERT_FALSE(handled)
- << "publisher receiveFinishedSignal should have set handled to consumer's reply";
-}
-
-TEST_F(InputPublisherAndConsumerTest, PublishKeyEvent_EndToEnd) {
- ASSERT_NO_FATAL_FAILURE(PublishAndConsumeKeyEvent());
-}
-
-TEST_F(InputPublisherAndConsumerTest, PublishMotionEvent_EndToEnd) {
- ASSERT_NO_FATAL_FAILURE(PublishAndConsumeMotionEvent());
-}
-
-TEST_F(InputPublisherAndConsumerTest, PublishMotionEvent_WhenPointerCountLessThan1_ReturnsError) {
- status_t status;
- const size_t pointerCount = 0;
- PointerProperties pointerProperties[pointerCount];
- PointerCoords pointerCoords[pointerCount];
-
- status = mPublisher->publishMotionEvent(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- pointerCount, pointerProperties, pointerCoords);
- ASSERT_EQ(BAD_VALUE, status)
- << "publisher publishMotionEvent should return BAD_VALUE";
-}
-
-TEST_F(InputPublisherAndConsumerTest, PublishMotionEvent_WhenPointerCountGreaterThanMax_ReturnsError) {
- status_t status;
- const size_t pointerCount = MAX_POINTERS + 1;
- PointerProperties pointerProperties[pointerCount];
- PointerCoords pointerCoords[pointerCount];
- for (size_t i = 0; i < pointerCount; i++) {
- pointerProperties[i].clear();
- pointerCoords[i].clear();
- }
-
- status = mPublisher->publishMotionEvent(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- pointerCount, pointerProperties, pointerCoords);
- ASSERT_EQ(BAD_VALUE, status)
- << "publisher publishMotionEvent should return BAD_VALUE";
-}
-
-TEST_F(InputPublisherAndConsumerTest, PublishMultipleEvents_EndToEnd) {
- ASSERT_NO_FATAL_FAILURE(PublishAndConsumeMotionEvent());
- ASSERT_NO_FATAL_FAILURE(PublishAndConsumeKeyEvent());
- ASSERT_NO_FATAL_FAILURE(PublishAndConsumeMotionEvent());
- ASSERT_NO_FATAL_FAILURE(PublishAndConsumeMotionEvent());
- ASSERT_NO_FATAL_FAILURE(PublishAndConsumeKeyEvent());
-}
-
-} // namespace android
diff --git a/libs/androidfw/tests/TestHelpers.h b/libs/androidfw/tests/TestHelpers.h
deleted file mode 100644
index d8e985e..0000000
--- a/libs/androidfw/tests/TestHelpers.h
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- * Copyright (C) 2010 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef TESTHELPERS_H
-#define TESTHELPERS_H
-
-#include <utils/threads.h>
-
-namespace android {
-
-class Pipe {
-public:
- int sendFd;
- int receiveFd;
-
- Pipe() {
- int fds[2];
- ::pipe(fds);
-
- receiveFd = fds[0];
- sendFd = fds[1];
- }
-
- ~Pipe() {
- if (sendFd != -1) {
- ::close(sendFd);
- }
-
- if (receiveFd != -1) {
- ::close(receiveFd);
- }
- }
-
- status_t writeSignal() {
- ssize_t nWritten = ::write(sendFd, "*", 1);
- return nWritten == 1 ? 0 : -errno;
- }
-
- status_t readSignal() {
- char buf[1];
- ssize_t nRead = ::read(receiveFd, buf, 1);
- return nRead == 1 ? 0 : nRead == 0 ? -EPIPE : -errno;
- }
-};
-
-class DelayedTask : public Thread {
- int mDelayMillis;
-
-public:
- DelayedTask(int delayMillis) : mDelayMillis(delayMillis) { }
-
-protected:
- virtual ~DelayedTask() { }
-
- virtual void doTask() = 0;
-
- virtual bool threadLoop() {
- usleep(mDelayMillis * 1000);
- doTask();
- return false;
- }
-};
-
-} // namespace android
-
-#endif // TESTHELPERS_H
diff --git a/media/jni/Android.mk b/media/jni/Android.mk
index 01b3174..63a61e2 100644
--- a/media/jni/Android.mk
+++ b/media/jni/Android.mk
@@ -57,6 +57,8 @@
frameworks/av/media/libstagefright/codecs/amrnb/common/include \
frameworks/av/media/mtp \
frameworks/native/include/media/openmax \
+ $(call include-path-for, libhardware)/hardware \
+ system/media/camera/include \
$(PV_INCLUDES) \
$(JNI_H_INCLUDE) \
$(call include-path-for, corecg graphics)
diff --git a/media/jni/android_media_ImageReader.cpp b/media/jni/android_media_ImageReader.cpp
index bdb07a6..7866df4 100644
--- a/media/jni/android_media_ImageReader.cpp
+++ b/media/jni/android_media_ImageReader.cpp
@@ -24,6 +24,7 @@
#include <gui/CpuConsumer.h>
#include <gui/Surface.h>
+#include <camera3.h>
#include <android_runtime/AndroidRuntime.h>
#include <android_runtime/android_view_Surface.h>
@@ -268,6 +269,29 @@
return format;
}
+static uint32_t Image_getJpegSize(CpuConsumer::LockedBuffer* buffer)
+{
+ ALOG_ASSERT(buffer != NULL, "Input buffer is NULL!!!");
+ uint32_t size = 0;
+ uint32_t width = buffer->width;
+ uint8_t* jpegBuffer = buffer->data;
+
+ // First check for JPEG transport header at the end of the buffer
+ uint8_t* header = jpegBuffer + (width - sizeof(struct camera3_jpeg_blob));
+ struct camera3_jpeg_blob *blob = (struct camera3_jpeg_blob*)(header);
+ if (blob->jpeg_blob_id == CAMERA3_JPEG_BLOB_ID) {
+ size = blob->jpeg_size;
+ ALOGV("%s: Jpeg size = %d", __FUNCTION__, size);
+ }
+
+ // failed to find size, default to whole buffer
+ if (size == 0) {
+ size = width;
+ }
+
+ return size;
+}
+
static void Image_getLockedBufferInfo(JNIEnv* env, CpuConsumer::LockedBuffer* buffer, int idx,
uint8_t **base, uint32_t *size)
{
@@ -353,7 +377,7 @@
ALOG_ASSERT(buffer->height == 1, "JPEG should has height value %d", buffer->height);
pData = buffer->data;
- dataSize = buffer->width;
+ dataSize = Image_getJpegSize(buffer);
break;
case HAL_PIXEL_FORMAT_RAW_SENSOR:
// Single plane 16bpp bayer data.
@@ -624,8 +648,17 @@
// Check if the producer buffer configurations match what ImageReader configured.
// We want to fail for the very first image because this case is too bad.
- int outputWidth = buffer->crop.getWidth() + 1;
- int outputHeight = buffer->crop.getHeight() + 1;
+ int outputWidth = buffer->width;
+ int outputHeight = buffer->height;
+
+ // Correct with/height when crop is set.
+ if (buffer->crop.getWidth() > 0) {
+ outputWidth = buffer->crop.getWidth() + 1;
+ }
+ if (buffer->crop.getHeight() > 0) {
+ outputHeight = buffer->crop.getHeight() + 1;
+ }
+
int imageReaderWidth = ctx->getBufferWidth();
int imageReaderHeight = ctx->getBufferHeight();
if ((imageReaderWidth != outputWidth) ||
diff --git a/native/android/Android.mk b/native/android/Android.mk
index 207cc4b..cda38e0 100644
--- a/native/android/Android.mk
+++ b/native/android/Android.mk
@@ -20,6 +20,7 @@
liblog \
libcutils \
libandroidfw \
+ libinput \
libutils \
libbinder \
libui \
diff --git a/native/android/input.cpp b/native/android/input.cpp
index f6ea576..e9d08b4 100644
--- a/native/android/input.cpp
+++ b/native/android/input.cpp
@@ -18,8 +18,8 @@
#include <utils/Log.h>
#include <android/input.h>
-#include <androidfw/Input.h>
-#include <androidfw/InputTransport.h>
+#include <input/Input.h>
+#include <input/InputTransport.h>
#include <utils/Looper.h>
#include <utils/RefBase.h>
#include <utils/Vector.h>
diff --git a/packages/DocumentsUI/AndroidManifest.xml b/packages/DocumentsUI/AndroidManifest.xml
index 84c5474..ae11a8c 100644
--- a/packages/DocumentsUI/AndroidManifest.xml
+++ b/packages/DocumentsUI/AndroidManifest.xml
@@ -7,14 +7,26 @@
<activity
android:name=".DocumentsActivity"
android:finishOnCloseSystemDialogs="true"
- android:excludeFromRecents="true">
+ android:excludeFromRecents="true"
+ android:theme="@android:style/Theme.Holo.Light">
<intent-filter android:priority="100">
<action android:name="android.intent.action.OPEN_DOCUMENT" />
<category android:name="android.intent.category.DEFAULT" />
+ <data android:mimeType="*/*" />
</intent-filter>
<intent-filter android:priority="100">
<action android:name="android.intent.action.CREATE_DOCUMENT" />
<category android:name="android.intent.category.DEFAULT" />
+ <data android:mimeType="*/*" />
+ </intent-filter>
+ </activity>
+
+ <!-- TODO: remove when we have real clients -->
+ <activity android:name=".TestActivity">
+ <intent-filter>
+ <action android:name="android.intent.action.MAIN" />
+ <category android:name="android.intent.category.DEFAULT" />
+ <category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
diff --git a/packages/DocumentsUI/res/drawable-hdpi/ic_dir.png b/packages/DocumentsUI/res/drawable-hdpi/ic_dir.png
new file mode 100644
index 0000000..d02534f
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-hdpi/ic_dir.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-hdpi/ic_menu_create_dir.png b/packages/DocumentsUI/res/drawable-hdpi/ic_menu_create_dir.png
new file mode 100644
index 0000000..6eb31f1
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-hdpi/ic_menu_create_dir.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-hdpi/ic_menu_grid.png b/packages/DocumentsUI/res/drawable-hdpi/ic_menu_grid.png
new file mode 100644
index 0000000..d1326e5
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-hdpi/ic_menu_grid.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-hdpi/ic_menu_list.png b/packages/DocumentsUI/res/drawable-hdpi/ic_menu_list.png
new file mode 100644
index 0000000..e03e345
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-hdpi/ic_menu_list.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-hdpi/ic_menu_sort.png b/packages/DocumentsUI/res/drawable-hdpi/ic_menu_sort.png
new file mode 100644
index 0000000..680d482
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-hdpi/ic_menu_sort.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable/item_background.xml b/packages/DocumentsUI/res/drawable/item_background.xml
new file mode 100644
index 0000000..4fb32fc
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable/item_background.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2013 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:state_activated="true" android:state_pressed="true" android:drawable="@*android:drawable/list_activated_holo" />
+ <item android:state_activated="true" android:drawable="@*android:drawable/list_activated_holo" />
+ <item android:state_focused="true" android:state_enabled="false" android:state_pressed="true" android:drawable="@*android:drawable/list_selector_disabled_holo_light" />
+ <item android:state_focused="true" android:state_enabled="false" android:drawable="@*android:drawable/list_selector_disabled_holo_light" />
+ <item android:state_focused="true" android:state_pressed="true" android:drawable="@*android:drawable/list_selector_background_transition_holo_light" />
+ <item android:state_focused="false" android:state_pressed="true" android:drawable="@*android:drawable/list_selector_background_transition_holo_light" />
+ <item android:state_focused="true" android:drawable="@*android:drawable/list_focused_holo" />
+ <item android:drawable="@android:color/transparent" />
+</selector>
diff --git a/packages/DocumentsUI/res/layout/activity.xml b/packages/DocumentsUI/res/layout/activity.xml
new file mode 100644
index 0000000..f96d459
--- /dev/null
+++ b/packages/DocumentsUI/res/layout/activity.xml
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2013 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:orientation="vertical">
+
+ <FrameLayout
+ android:id="@+id/directory"
+ android:layout_width="match_parent"
+ android:layout_height="0dip"
+ android:layout_weight="1" />
+
+ <FrameLayout
+ android:id="@+id/save"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content" />
+
+</LinearLayout>
diff --git a/packages/DocumentsUI/res/layout/fragment_backend.xml b/packages/DocumentsUI/res/layout/fragment_backend.xml
new file mode 100644
index 0000000..2648de2
--- /dev/null
+++ b/packages/DocumentsUI/res/layout/fragment_backend.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2013 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent">
+
+ <GridView
+ android:id="@+id/grid"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:listSelector="@android:color/transparent"
+ android:paddingTop="?android:attr/listPreferredItemPaddingStart"
+ android:paddingStart="?android:attr/listPreferredItemPaddingStart" />
+
+</FrameLayout>
diff --git a/packages/DocumentsUI/res/layout/fragment_directory.xml b/packages/DocumentsUI/res/layout/fragment_directory.xml
new file mode 100644
index 0000000..638ac92
--- /dev/null
+++ b/packages/DocumentsUI/res/layout/fragment_directory.xml
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2013 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent">
+
+ <ListView
+ android:id="@+id/list"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:listSelector="@android:color/transparent" />
+
+ <GridView
+ android:id="@+id/grid"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:listSelector="@android:color/transparent"
+ android:paddingTop="?android:attr/listPreferredItemPaddingStart"
+ android:paddingStart="?android:attr/listPreferredItemPaddingStart" />
+
+</FrameLayout>
diff --git a/packages/DocumentsUI/res/layout/fragment_save.xml b/packages/DocumentsUI/res/layout/fragment_save.xml
new file mode 100644
index 0000000..85c48b1
--- /dev/null
+++ b/packages/DocumentsUI/res/layout/fragment_save.xml
@@ -0,0 +1,51 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2013 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:orientation="horizontal"
+ android:gravity="center_vertical"
+ android:background="@color/chip"
+ android:minHeight="?android:attr/listPreferredItemHeightSmall">
+
+ <ImageView
+ android:id="@android:id/icon"
+ android:layout_width="24dp"
+ android:layout_height="24dp"
+ android:layout_marginStart="8dp"
+ android:layout_marginEnd="8dp"
+ android:scaleType="centerInside"
+ android:contentDescription="@null" />
+
+ <EditText
+ android:id="@android:id/title"
+ android:layout_width="0dip"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:singleLine="true" />
+
+ <Button
+ android:id="@android:id/button1"
+ android:layout_width="wrap_content"
+ android:layout_height="match_parent"
+ android:background="?android:attr/selectableItemBackground"
+ android:text="@string/menu_save"
+ android:textAllCaps="true"
+ android:textAppearance="?android:attr/textAppearanceSmall"
+ android:padding="8dp" />
+
+</LinearLayout>
diff --git a/packages/DocumentsUI/res/layout/item_backend.xml b/packages/DocumentsUI/res/layout/item_backend.xml
new file mode 100644
index 0000000..6ec7566
--- /dev/null
+++ b/packages/DocumentsUI/res/layout/item_backend.xml
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2013 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:paddingBottom="?android:attr/listPreferredItemPaddingEnd"
+ android:paddingEnd="?android:attr/listPreferredItemPaddingEnd">
+
+ <FrameLayout
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:background="@color/chip"
+ android:foreground="?android:attr/selectableItemBackground"
+ android:duplicateParentState="true">
+
+ <LinearLayout
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:padding="8dp"
+ android:orientation="horizontal">
+
+ <ImageView
+ android:id="@android:id/icon"
+ android:layout_width="24dip"
+ android:layout_height="24dip"
+ android:layout_marginEnd="8dp"
+ android:scaleType="centerInside"
+ android:contentDescription="@null" />
+
+ <TextView
+ android:id="@android:id/text1"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_gravity="center_vertical"
+ android:singleLine="true"
+ android:ellipsize="marquee"
+ android:textAppearance="?android:attr/textAppearanceSmall"
+ android:textAlignment="viewStart" />
+
+ </LinearLayout>
+
+ </FrameLayout>
+
+</FrameLayout>
diff --git a/packages/DocumentsUI/res/layout/item_doc_grid.xml b/packages/DocumentsUI/res/layout/item_doc_grid.xml
new file mode 100644
index 0000000..caa9db6
--- /dev/null
+++ b/packages/DocumentsUI/res/layout/item_doc_grid.xml
@@ -0,0 +1,60 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2013 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="140dip"
+ android:paddingBottom="?android:attr/listPreferredItemPaddingEnd"
+ android:paddingEnd="?android:attr/listPreferredItemPaddingEnd">
+
+ <FrameLayout
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:background="@color/chip"
+ android:foreground="@drawable/item_background"
+ android:duplicateParentState="true">
+
+ <GridLayout
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:columnCount="1">
+
+ <ImageView
+ android:id="@android:id/icon"
+ android:layout_width="match_parent"
+ android:layout_height="0dip"
+ android:layout_gravity="fill_vertical"
+ android:background="#bbb"
+ android:scaleType="centerInside"
+ android:contentDescription="@null" />
+
+ <TextView
+ android:id="@android:id/title"
+ android:layout_width="match_parent"
+ android:layout_marginStart="8dip"
+ android:layout_marginEnd="8dip"
+ android:layout_marginTop="8dip"
+ android:layout_marginBottom="8dip"
+ android:singleLine="true"
+ android:ellipsize="marquee"
+ android:textAppearance="?android:attr/textAppearanceSmall"
+ android:textAlignment="viewStart" />
+
+ </GridLayout>
+
+ </FrameLayout>
+
+</FrameLayout>
diff --git a/packages/DocumentsUI/res/layout/item_doc_list.xml b/packages/DocumentsUI/res/layout/item_doc_list.xml
new file mode 100644
index 0000000..39e55be
--- /dev/null
+++ b/packages/DocumentsUI/res/layout/item_doc_list.xml
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2013 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<GridLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:background="@drawable/item_background"
+ android:minHeight="?android:attr/listPreferredItemHeight"
+ android:paddingStart="?android:attr/listPreferredItemPaddingStart"
+ android:paddingEnd="?android:attr/listPreferredItemPaddingEnd"
+ android:paddingTop="8dip"
+ android:paddingBottom="8dip"
+ android:columnCount="3">
+
+ <ImageView
+ android:id="@android:id/icon"
+ android:layout_width="@android:dimen/app_icon_size"
+ android:layout_height="@android:dimen/app_icon_size"
+ android:layout_rowSpan="2"
+ android:layout_marginEnd="8dip"
+ android:scaleType="centerInside"
+ android:contentDescription="@null" />
+
+ <TextView
+ android:id="@android:id/title"
+ android:layout_width="0dip"
+ android:layout_gravity="fill_horizontal"
+ android:layout_marginTop="2dip"
+ android:layout_columnSpan="2"
+ android:singleLine="true"
+ android:ellipsize="marquee"
+ android:textAppearance="?android:attr/textAppearanceMedium"
+ android:textAlignment="viewStart" />
+
+ <ImageView
+ android:id="@android:id/icon1"
+ android:layout_width="24dip"
+ android:layout_height="24dip"
+ android:layout_marginEnd="8dip"
+ android:visibility="gone"
+ android:scaleType="centerInside"
+ android:contentDescription="@null" />
+
+ <TextView
+ android:id="@android:id/summary"
+ android:layout_marginTop="2dip"
+ android:textAppearance="?android:attr/textAppearanceSmall" />
+
+</GridLayout>
diff --git a/packages/DocumentsUI/res/menu/activity.xml b/packages/DocumentsUI/res/menu/activity.xml
new file mode 100644
index 0000000..bf7c161
--- /dev/null
+++ b/packages/DocumentsUI/res/menu/activity.xml
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2013 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<menu xmlns:android="http://schemas.android.com/apk/res/android">
+ <item
+ android:id="@+id/menu_create_dir"
+ android:title="@string/menu_create_dir"
+ android:icon="@drawable/ic_menu_create_dir"
+ android:showAsAction="always" />
+</menu>
diff --git a/packages/DocumentsUI/res/menu/directory.xml b/packages/DocumentsUI/res/menu/directory.xml
new file mode 100644
index 0000000..c1fa228
--- /dev/null
+++ b/packages/DocumentsUI/res/menu/directory.xml
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2013 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<menu xmlns:android="http://schemas.android.com/apk/res/android">
+ <item
+ android:id="@+id/menu_grid"
+ android:title="@string/menu_grid"
+ android:icon="@drawable/ic_menu_grid"
+ android:showAsAction="ifRoom" />
+ <item
+ android:id="@+id/menu_list"
+ android:title="@string/menu_list"
+ android:icon="@drawable/ic_menu_list"
+ android:showAsAction="ifRoom" />
+ <item
+ android:id="@+id/menu_sort"
+ android:title="@string/menu_sort"
+ android:icon="@drawable/ic_menu_sort"
+ android:showAsAction="ifRoom" />
+</menu>
diff --git a/packages/DocumentsUI/res/menu/mode_directory.xml b/packages/DocumentsUI/res/menu/mode_directory.xml
new file mode 100644
index 0000000..6b6d7e91
--- /dev/null
+++ b/packages/DocumentsUI/res/menu/mode_directory.xml
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2013 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<menu xmlns:android="http://schemas.android.com/apk/res/android">
+ <item
+ android:id="@+id/menu_open"
+ android:title="@string/menu_open"
+ android:showAsAction="always" />
+</menu>
diff --git a/packages/DocumentsUI/res/values/colors.xml b/packages/DocumentsUI/res/values/colors.xml
new file mode 100644
index 0000000..ff3e999
--- /dev/null
+++ b/packages/DocumentsUI/res/values/colors.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2013 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<resources>
+ <color name="chip">#ddd</color>
+</resources>
diff --git a/packages/DocumentsUI/res/values/dimens.xml b/packages/DocumentsUI/res/values/dimens.xml
new file mode 100644
index 0000000..e5c4138
--- /dev/null
+++ b/packages/DocumentsUI/res/values/dimens.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2013 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<resources>
+ <dimen name="grid_width">180dp</dimen>
+</resources>
diff --git a/packages/DocumentsUI/res/values/strings.xml b/packages/DocumentsUI/res/values/strings.xml
index 89f6496..6ae2d12 100644
--- a/packages/DocumentsUI/res/values/strings.xml
+++ b/packages/DocumentsUI/res/values/strings.xml
@@ -14,6 +14,23 @@
limitations under the License.
-->
-<resources>
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<string name="app_label">Documents</string>
+
+ <string name="title_open">Open</string>
+ <string name="title_save">Save</string>
+
+ <string name="menu_create_dir">Create folder</string>
+ <string name="menu_grid">Grid view</string>
+ <string name="menu_list">List view</string>
+ <string name="menu_sort">Sort by</string>
+
+ <string name="menu_open">Open</string>
+ <string name="menu_save">Save</string>
+
+ <string name="mode_selected_count"><xliff:g id="count" example="3">%1$d</xliff:g> selected</string>
+
+ <string name="sort_name">Name</string>
+ <string name="sort_date">Date modified</string>
+
</resources>
diff --git a/packages/DocumentsUI/src/com/android/documentsui/BackendFragment.java b/packages/DocumentsUI/src/com/android/documentsui/BackendFragment.java
new file mode 100644
index 0000000..2980e23
--- /dev/null
+++ b/packages/DocumentsUI/src/com/android/documentsui/BackendFragment.java
@@ -0,0 +1,119 @@
+/*
+ * Copyright (C) 2013 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.documentsui;
+
+import android.app.Fragment;
+import android.app.FragmentManager;
+import android.app.FragmentTransaction;
+import android.content.Context;
+import android.content.pm.PackageManager;
+import android.content.pm.ProviderInfo;
+import android.os.Bundle;
+import android.provider.DocumentsContract;
+import android.view.LayoutInflater;
+import android.view.View;
+import android.view.ViewGroup;
+import android.widget.AdapterView;
+import android.widget.AdapterView.OnItemClickListener;
+import android.widget.ArrayAdapter;
+import android.widget.GridView;
+import android.widget.ImageView;
+import android.widget.TextView;
+
+import com.google.android.collect.Lists;
+
+import java.util.List;
+
+/**
+ * Display all known storage backends.
+ */
+public class BackendFragment extends Fragment {
+
+ // TODO: handle multiple accounts from single backend
+
+ private GridView mGridView;
+ private BackendAdapter mAdapter;
+
+ public static void show(FragmentManager fm) {
+ final BackendFragment fragment = new BackendFragment();
+
+ final FragmentTransaction ft = fm.beginTransaction();
+ ft.replace(R.id.directory, fragment);
+ ft.setBreadCrumbTitle("TOP");
+ ft.commitAllowingStateLoss();
+ }
+
+ @Override
+ public View onCreateView(
+ LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
+ final Context context = inflater.getContext();
+
+ // Gather known storage providers
+ final List<ProviderInfo> providers = context.getPackageManager()
+ .queryContentProviders(null, -1, PackageManager.GET_META_DATA);
+ final List<ProviderInfo> backends = Lists.newArrayList();
+ for (ProviderInfo info : providers) {
+ if (info.metaData != null
+ && info.metaData.containsKey(DocumentsContract.META_DATA_DOCUMENT_PROVIDER)) {
+ backends.add(info);
+ }
+ }
+
+ final View view = inflater.inflate(R.layout.fragment_backend, container, false);
+
+ mGridView = (GridView) view.findViewById(R.id.grid);
+ mGridView.setOnItemClickListener(mItemListener);
+
+ mAdapter = new BackendAdapter(context, backends);
+ mGridView.setAdapter(mAdapter);
+ mGridView.setNumColumns(GridView.AUTO_FIT);
+
+ return view;
+ }
+
+ private OnItemClickListener mItemListener = new OnItemClickListener() {
+ @Override
+ public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
+ final ProviderInfo info = mAdapter.getItem(position);
+ ((DocumentsActivity) getActivity()).onBackendPicked(info);
+ }
+ };
+
+ public static class BackendAdapter extends ArrayAdapter<ProviderInfo> {
+ public BackendAdapter(Context context, List<ProviderInfo> list) {
+ super(context, android.R.layout.simple_list_item_1, list);
+ }
+
+ @Override
+ public View getView(int position, View convertView, ViewGroup parent) {
+ if (convertView == null) {
+ convertView = LayoutInflater.from(parent.getContext())
+ .inflate(R.layout.item_backend, parent, false);
+ }
+
+ final ImageView icon = (ImageView) convertView.findViewById(android.R.id.icon);
+ final TextView text1 = (TextView) convertView.findViewById(android.R.id.text1);
+
+ final PackageManager pm = parent.getContext().getPackageManager();
+ final ProviderInfo info = getItem(position);
+ icon.setImageDrawable(info.loadIcon(pm));
+ text1.setText(info.loadLabel(pm));
+
+ return convertView;
+ }
+ }
+}
diff --git a/packages/DocumentsUI/src/com/android/documentsui/ColumnAdapter.java b/packages/DocumentsUI/src/com/android/documentsui/ColumnAdapter.java
new file mode 100644
index 0000000..092b5db
--- /dev/null
+++ b/packages/DocumentsUI/src/com/android/documentsui/ColumnAdapter.java
@@ -0,0 +1,139 @@
+/*
+ * Copyright (C) 2013 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.documentsui;
+
+import android.database.DataSetObserver;
+import android.view.View;
+import android.view.ViewGroup;
+import android.widget.BaseAdapter;
+import android.widget.LinearLayout;
+import android.widget.ListAdapter;
+import android.widget.ListView;
+
+import com.android.internal.util.Preconditions;
+
+/**
+ * Adapter that wraps an existing adapter, presenting its contents in multiple
+ * equally-sized horizontal columns.
+ */
+public class ColumnAdapter extends BaseAdapter {
+ private final ListAdapter mWrapped;
+ private final OnItemClickListener mListener;
+
+ private int mColumns = 1;
+
+ public interface OnItemClickListener {
+ public void onItemClick(ListAdapter adapter, int position);
+ }
+
+ public ColumnAdapter(ListAdapter wrapped, OnItemClickListener listener) {
+ mWrapped = Preconditions.checkNotNull(wrapped);
+ mListener = Preconditions.checkNotNull(listener);
+
+ if (!wrapped.areAllItemsEnabled()) {
+ throw new IllegalStateException("All items must be enabled");
+ }
+ if (wrapped.getViewTypeCount() > 1) {
+ throw new IllegalStateException("All items must be identical");
+ }
+ }
+
+ public static void prepare(ListView list) {
+ list.setItemsCanFocus(true);
+ }
+
+ public void setColumns(int columns) {
+ mColumns = columns;
+ notifyDataSetChanged();
+ }
+
+ private View.OnClickListener mItemListener = new View.OnClickListener() {
+ @Override
+ public void onClick(View v) {
+ final int position = (Integer) v.getTag();
+ mListener.onItemClick(mWrapped, position);
+ }
+ };
+
+ @Override
+ public int getCount() {
+ return (mWrapped.getCount() + mColumns - 1) / mColumns;
+ }
+
+ @Override
+ public Object getItem(int position) {
+ return position;
+ }
+
+ @Override
+ public long getItemId(int position) {
+ return position;
+ }
+
+ @Override
+ public View getView(int position, View convertView, ViewGroup parent) {
+ if (convertView == null) {
+ convertView = new LinearLayout(parent.getContext());
+ }
+
+ final LinearLayout.LayoutParams params = new LinearLayout.LayoutParams(
+ 0, LinearLayout.LayoutParams.WRAP_CONTENT);
+ params.weight = 1f / mColumns;
+
+ final LinearLayout row = (LinearLayout) convertView;
+ final int first = position * mColumns;
+ final int last = mWrapped.getCount() - 1;
+
+ for (int i = 0; i < mColumns; i++) {
+ View convertItem = null;
+ if (i < row.getChildCount()) {
+ convertItem = row.getChildAt(i);
+ }
+
+ final int pos = first + i;
+ final int validPos = Math.min(pos, last);
+ final View item = mWrapped.getView(validPos, convertItem, row);
+ item.setTag(validPos);
+ item.setOnClickListener(mItemListener);
+ item.setFocusable(true);
+
+ if (pos == validPos) {
+ item.setVisibility(View.VISIBLE);
+ } else {
+ item.setVisibility(View.INVISIBLE);
+ }
+
+ if (convertItem == null) {
+ row.addView(item, params);
+ }
+ }
+
+ return convertView;
+ }
+
+ @Override
+ public void registerDataSetObserver(DataSetObserver observer) {
+ super.registerDataSetObserver(observer);
+ mWrapped.registerDataSetObserver(observer);
+ }
+
+ @Override
+ public void unregisterDataSetObserver(DataSetObserver observer) {
+ super.unregisterDataSetObserver(observer);
+ mWrapped.unregisterDataSetObserver(observer);
+ }
+}
diff --git a/packages/DocumentsUI/src/com/android/documentsui/DirectoryFragment.java b/packages/DocumentsUI/src/com/android/documentsui/DirectoryFragment.java
index d43abde..531eaf3 100644
--- a/packages/DocumentsUI/src/com/android/documentsui/DirectoryFragment.java
+++ b/packages/DocumentsUI/src/com/android/documentsui/DirectoryFragment.java
@@ -16,35 +16,72 @@
package com.android.documentsui;
+import android.app.AlertDialog;
+import android.app.Dialog;
+import android.app.DialogFragment;
+import android.app.Fragment;
import android.app.FragmentManager;
import android.app.FragmentTransaction;
-import android.app.ListFragment;
import android.app.LoaderManager.LoaderCallbacks;
import android.content.Context;
import android.content.CursorLoader;
+import android.content.DialogInterface;
+import android.content.DialogInterface.OnClickListener;
import android.content.Loader;
import android.database.Cursor;
import android.net.Uri;
import android.os.Bundle;
import android.provider.DocumentsContract;
import android.provider.DocumentsContract.DocumentColumns;
+import android.text.format.DateUtils;
+import android.util.SparseBooleanArray;
+import android.view.ActionMode;
import android.view.LayoutInflater;
+import android.view.Menu;
+import android.view.MenuInflater;
+import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
+import android.widget.AbsListView;
+import android.widget.AbsListView.MultiChoiceModeListener;
+import android.widget.AdapterView;
+import android.widget.AdapterView.OnItemClickListener;
import android.widget.CursorAdapter;
+import android.widget.GridView;
import android.widget.ImageView;
import android.widget.ListView;
import android.widget.TextView;
-public class DirectoryFragment extends ListFragment {
+import com.android.documentsui.DocumentsActivity.DisplayState;
+import com.android.documentsui.DocumentsActivity.Document;
+import com.google.android.collect.Lists;
+
+import java.util.ArrayList;
+
+/**
+ * Display the documents inside a single directory.
+ */
+public class DirectoryFragment extends Fragment {
+
+ // TODO: show storage backend in item views when requested
+
+ private static final String TAG_SORT = "sort";
+
+ private ListView mListView;
+ private GridView mGridView;
+
+ private AbsListView mCurrentView;
+
private DocumentsAdapter mAdapter;
private LoaderCallbacks<Cursor> mCallbacks;
+ private int mFlags;
+
private static final String EXTRA_URI = "uri";
private static final int LOADER_DOCUMENTS = 2;
- public static void show(FragmentManager fm, Uri uri, CharSequence title) {
+ public static void show(FragmentManager fm, Uri uri, String displayName) {
final Bundle args = new Bundle();
args.putParcelable(EXTRA_URI, uri);
@@ -52,25 +89,55 @@
fragment.setArguments(args);
final FragmentTransaction ft = fm.beginTransaction();
- ft.replace(android.R.id.content, fragment);
- ft.addToBackStack(title.toString());
- ft.setBreadCrumbTitle(title);
+ ft.replace(R.id.directory, fragment);
+ ft.addToBackStack(displayName);
+ ft.setBreadCrumbTitle(displayName);
ft.commitAllowingStateLoss();
}
@Override
+ public void onCreate(Bundle savedInstanceState) {
+ super.onCreate(savedInstanceState);
+ setHasOptionsMenu(true);
+ }
+
+ @Override
public View onCreateView(
LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
final Context context = inflater.getContext();
+ final View view = inflater.inflate(R.layout.fragment_directory, container, false);
+
+ mListView = (ListView) view.findViewById(R.id.list);
+ mListView.setOnItemClickListener(mItemListener);
+ mListView.setMultiChoiceModeListener(mMultiListener);
+
+ mGridView = (GridView) view.findViewById(R.id.grid);
+ mGridView.setOnItemClickListener(mItemListener);
+ mGridView.setMultiChoiceModeListener(mMultiListener);
+
mAdapter = new DocumentsAdapter(context);
- setListAdapter(mAdapter);
+ updateMode();
+
+ // TODO: migrate flags query to loader
+ final Uri uri = getArguments().getParcelable(EXTRA_URI);
+ mFlags = getDocumentFlags(context, uri);
mCallbacks = new LoaderCallbacks<Cursor>() {
@Override
public Loader<Cursor> onCreateLoader(int id, Bundle args) {
- final Uri uri = args.getParcelable(EXTRA_URI);
- return new CursorLoader(context, uri, null, null, null, null);
+ final DisplayState state = getDisplayState(DirectoryFragment.this);
+ final String sortOrder;
+ if (state.sortBy == DisplayState.SORT_BY_NAME) {
+ sortOrder = DocumentColumns.DISPLAY_NAME + " ASC";
+ } else if (state.sortBy == DisplayState.SORT_BY_DATE) {
+ sortOrder = DocumentColumns.LAST_MODIFIED + " DESC";
+ } else {
+ sortOrder = null;
+ }
+
+ final Uri contentsUri = DocumentsContract.buildContentsUri(uri);
+ return new CursorLoader(context, contentsUri, null, null, null, sortOrder);
}
@Override
@@ -84,13 +151,17 @@
}
};
- return super.onCreateView(inflater, container, savedInstanceState);
+ return view;
}
@Override
public void onStart() {
super.onStart();
getLoaderManager().restartLoader(LOADER_DOCUMENTS, getArguments(), mCallbacks);
+
+ // TODO: clean up tracking of current directory
+ final Uri uri = getArguments().getParcelable(EXTRA_URI);
+ ((DocumentsActivity) getActivity()).onDirectoryChanged(uri, mFlags);
}
@Override
@@ -100,26 +171,148 @@
}
@Override
- public void onListItemClick(ListView l, View v, int position, long id) {
- final Cursor cursor = (Cursor) mAdapter.getItem(position);
- final String guid = getCursorString(cursor, DocumentColumns.GUID);
- final String mimeType = getCursorString(cursor, DocumentColumns.MIME_TYPE);
+ public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {
+ super.onCreateOptionsMenu(menu, inflater);
+ inflater.inflate(R.menu.directory, menu);
+ }
- final Uri uri = getArguments().getParcelable(EXTRA_URI);
- final Uri childUri = DocumentsContract.buildDocumentUri(uri.getAuthority(), guid);
+ @Override
+ public void onPrepareOptionsMenu(Menu menu) {
+ super.onPrepareOptionsMenu(menu);
+ final DisplayState state = getDisplayState(this);
+ menu.findItem(R.id.menu_grid).setVisible(state.mode != DisplayState.MODE_GRID);
+ menu.findItem(R.id.menu_list).setVisible(state.mode != DisplayState.MODE_LIST);
+ }
- if (DocumentsContract.MIME_TYPE_DIRECTORY.equals(mimeType)) {
- // Nested directory picked, recurse using new fragment
- final Uri childContentsUri = DocumentsContract.buildContentsUri(childUri);
- final String displayName = cursor.getString(
- cursor.getColumnIndex(DocumentColumns.DISPLAY_NAME));
- DirectoryFragment.show(getFragmentManager(), childContentsUri, displayName);
+ @Override
+ public boolean onOptionsItemSelected(MenuItem item) {
+ final DisplayState state = getDisplayState(this);
+ final int id = item.getItemId();
+ if (id == R.id.menu_grid) {
+ state.mode = DisplayState.MODE_GRID;
+ updateMode();
+ getFragmentManager().invalidateOptionsMenu();
+ return true;
+ } else if (id == R.id.menu_list) {
+ state.mode = DisplayState.MODE_LIST;
+ updateMode();
+ getFragmentManager().invalidateOptionsMenu();
+ return true;
+ } else if (id == R.id.menu_sort) {
+ SortFragment.show(this);
+ return true;
} else {
- // Explicit file picked, return
- ((DocumentsActivity) getActivity()).onDocumentPicked(childUri);
+ return super.onOptionsItemSelected(item);
}
}
+ private void updateMode() {
+ final DisplayState state = getDisplayState(this);
+
+ mListView.setVisibility(state.mode == DisplayState.MODE_LIST ? View.VISIBLE : View.GONE);
+ mGridView.setVisibility(state.mode == DisplayState.MODE_GRID ? View.VISIBLE : View.GONE);
+
+ final int choiceMode;
+ if (state.allowMultiple) {
+ choiceMode = ListView.CHOICE_MODE_MULTIPLE_MODAL;
+ } else {
+ choiceMode = ListView.CHOICE_MODE_NONE;
+ }
+
+ if (state.mode == DisplayState.MODE_GRID) {
+ mListView.setAdapter(null);
+ mListView.setChoiceMode(ListView.CHOICE_MODE_NONE);
+ mGridView.setAdapter(mAdapter);
+ mGridView.setColumnWidth(getResources().getDimensionPixelSize(R.dimen.grid_width));
+ mGridView.setNumColumns(GridView.AUTO_FIT);
+ mGridView.setChoiceMode(choiceMode);
+ mCurrentView = mGridView;
+ } else if (state.mode == DisplayState.MODE_LIST) {
+ mGridView.setAdapter(null);
+ mGridView.setChoiceMode(ListView.CHOICE_MODE_NONE);
+ mListView.setAdapter(mAdapter);
+ mListView.setChoiceMode(choiceMode);
+ mCurrentView = mListView;
+ } else {
+ throw new IllegalStateException();
+ }
+ }
+
+ private void updateSortBy() {
+ getLoaderManager().restartLoader(LOADER_DOCUMENTS, getArguments(), mCallbacks);
+ }
+
+ private OnItemClickListener mItemListener = new OnItemClickListener() {
+ @Override
+ public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
+ final Cursor cursor = (Cursor) mAdapter.getItem(position);
+ final Uri uri = getArguments().getParcelable(EXTRA_URI);
+ final Document doc = Document.fromCursor(uri.getAuthority(), cursor);
+ ((DocumentsActivity) getActivity()).onDocumentPicked(doc);
+ }
+ };
+
+ private MultiChoiceModeListener mMultiListener = new MultiChoiceModeListener() {
+ @Override
+ public boolean onCreateActionMode(ActionMode mode, Menu menu) {
+ mode.getMenuInflater().inflate(R.menu.mode_directory, menu);
+ return true;
+ }
+
+ @Override
+ public boolean onPrepareActionMode(ActionMode mode, Menu menu) {
+ return true;
+ }
+
+ @Override
+ public boolean onActionItemClicked(ActionMode mode, MenuItem item) {
+ if (item.getItemId() == R.id.menu_open) {
+ final Uri uri = getArguments().getParcelable(EXTRA_URI);
+ final SparseBooleanArray checked = mCurrentView.getCheckedItemPositions();
+ final ArrayList<Document> docs = Lists.newArrayList();
+
+ final int size = checked.size();
+ for (int i = 0; i < size; i++) {
+ if (checked.valueAt(i)) {
+ final Cursor cursor = (Cursor) mAdapter.getItem(checked.keyAt(i));
+ docs.add(Document.fromCursor(uri.getAuthority(), cursor));
+ }
+ }
+
+ ((DocumentsActivity) getActivity()).onDocumentsPicked(docs);
+ return true;
+ } else {
+ return false;
+ }
+ }
+
+ @Override
+ public void onDestroyActionMode(ActionMode mode) {
+ // ignored
+ }
+
+ @Override
+ public void onItemCheckedStateChanged(
+ ActionMode mode, int position, long id, boolean checked) {
+ if (checked) {
+ final Cursor cursor = (Cursor) mAdapter.getItem(position);
+ final String mimeType = getCursorString(cursor, DocumentColumns.MIME_TYPE);
+
+ // Directories cannot be checked
+ if (DocumentsContract.MIME_TYPE_DIRECTORY.equals(mimeType)) {
+ mCurrentView.setItemChecked(position, false);
+ }
+ }
+
+ mode.setTitle(getResources()
+ .getString(R.string.mode_selected_count, mCurrentView.getCheckedItemCount()));
+ }
+ };
+
+ private static DisplayState getDisplayState(Fragment fragment) {
+ return ((DocumentsActivity) fragment.getActivity()).getDisplayState();
+ }
+
private class DocumentsAdapter extends CursorAdapter {
public DocumentsAdapter(Context context) {
super(context, null, false);
@@ -127,8 +320,15 @@
@Override
public View newView(Context context, Cursor cursor, ViewGroup parent) {
- return LayoutInflater.from(context)
- .inflate(com.android.internal.R.layout.preference, parent, false);
+ final LayoutInflater inflater = LayoutInflater.from(context);
+ final DisplayState state = getDisplayState(DirectoryFragment.this);
+ if (state.mode == DisplayState.MODE_LIST) {
+ return inflater.inflate(R.layout.item_doc_list, parent, false);
+ } else if (state.mode == DisplayState.MODE_GRID) {
+ return inflater.inflate(R.layout.item_doc_grid, parent, false);
+ } else {
+ throw new IllegalStateException();
+ }
}
@Override
@@ -137,12 +337,10 @@
final TextView summary = (TextView) view.findViewById(android.R.id.summary);
final ImageView icon = (ImageView) view.findViewById(android.R.id.icon);
- icon.setMaxWidth(128);
- icon.setMaxHeight(128);
-
final String guid = getCursorString(cursor, DocumentColumns.GUID);
final String displayName = getCursorString(cursor, DocumentColumns.DISPLAY_NAME);
final String mimeType = getCursorString(cursor, DocumentColumns.MIME_TYPE);
+ final long lastModified = getCursorLong(cursor, DocumentColumns.LAST_MODIFIED);
final int flags = getCursorInt(cursor, DocumentColumns.FLAGS);
if ((flags & DocumentsContract.FLAG_SUPPORTS_THUMBNAIL) != 0) {
@@ -150,19 +348,71 @@
final Uri childUri = DocumentsContract.buildDocumentUri(uri.getAuthority(), guid);
icon.setImageURI(childUri);
} else {
- icon.setImageURI(null);
+ icon.setImageDrawable(DocumentsActivity.resolveDocumentIcon(context, mimeType));
}
title.setText(displayName);
- summary.setText(mimeType);
+ if (summary != null) {
+ summary.setText(DateUtils.getRelativeTimeSpanString(lastModified));
+ }
}
}
-
- private static String getCursorString(Cursor cursor, String columnName) {
+
+ public static class SortFragment extends DialogFragment {
+ public static void show(DirectoryFragment parent) {
+ if (!parent.isAdded()) return;
+
+ final SortFragment dialog = new SortFragment();
+ dialog.setTargetFragment(parent, 0);
+ dialog.show(parent.getFragmentManager(), TAG_SORT);
+ }
+
+ @Override
+ public Dialog onCreateDialog(Bundle savedInstanceState) {
+ final Context context = getActivity();
+ final DisplayState state = getDisplayState(this);
+
+ final AlertDialog.Builder builder = new AlertDialog.Builder(context);
+ builder.setTitle(R.string.menu_sort);
+ builder.setSingleChoiceItems(new CharSequence[] {
+ getText(R.string.sort_name),
+ getText(R.string.sort_date),
+ }, state.sortBy, new OnClickListener() {
+ @Override
+ public void onClick(DialogInterface dialog, int which) {
+ state.sortBy = which;
+ ((DirectoryFragment) getTargetFragment()).updateSortBy();
+ dismiss();
+ }
+ });
+
+ return builder.create();
+ }
+ }
+
+ private static int getDocumentFlags(Context context, Uri uri) {
+ final Cursor cursor = context.getContentResolver().query(uri, new String[] {
+ DocumentColumns.FLAGS }, null, null, null);
+ try {
+ if (cursor.moveToFirst()) {
+ return getCursorInt(cursor, DocumentColumns.FLAGS);
+ } else {
+ return 0;
+ }
+ } finally {
+ cursor.close();
+ }
+ }
+
+ public static String getCursorString(Cursor cursor, String columnName) {
return cursor.getString(cursor.getColumnIndex(columnName));
}
- private static int getCursorInt(Cursor cursor, String columnName) {
+ public static long getCursorLong(Cursor cursor, String columnName) {
+ return cursor.getLong(cursor.getColumnIndex(columnName));
+ }
+
+ public static int getCursorInt(Cursor cursor, String columnName) {
return cursor.getInt(cursor.getColumnIndex(columnName));
}
}
diff --git a/packages/DocumentsUI/src/com/android/documentsui/DocumentsActivity.java b/packages/DocumentsUI/src/com/android/documentsui/DocumentsActivity.java
index 196776b..c45d2b4 100644
--- a/packages/DocumentsUI/src/com/android/documentsui/DocumentsActivity.java
+++ b/packages/DocumentsUI/src/com/android/documentsui/DocumentsActivity.java
@@ -16,49 +16,276 @@
package com.android.documentsui;
+import static com.android.documentsui.DirectoryFragment.getCursorString;
+
+import android.app.ActionBar;
+import android.app.ActionBar.OnNavigationListener;
import android.app.Activity;
import android.app.FragmentManager;
-import android.app.FragmentTransaction;
-import android.app.ListFragment;
+import android.app.FragmentManager.BackStackEntry;
+import android.app.FragmentManager.OnBackStackChangedListener;
+import android.content.ClipData;
+import android.content.ContentResolver;
import android.content.Context;
import android.content.Intent;
import android.content.pm.PackageManager;
import android.content.pm.ProviderInfo;
+import android.content.pm.ResolveInfo;
+import android.database.Cursor;
+import android.graphics.drawable.Drawable;
import android.net.Uri;
import android.os.Bundle;
import android.provider.DocumentsContract;
+import android.provider.DocumentsContract.DocumentColumns;
import android.util.Log;
import android.view.LayoutInflater;
+import android.view.Menu;
+import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
-import android.widget.ArrayAdapter;
-import android.widget.ListView;
+import android.widget.BaseAdapter;
+import android.widget.TextView;
-import com.google.android.collect.Lists;
-
-import java.util.ArrayList;
+import java.util.Arrays;
import java.util.List;
public class DocumentsActivity extends Activity {
private static final String TAG = "Documents";
+ // TODO: fragment to show recently opened documents
+ // TODO: pull actionbar icon from current backend
+
+ private static final int ACTION_OPEN = 1;
+ private static final int ACTION_CREATE = 2;
+
+ private int mAction;
+ private String[] mAcceptMimes;
+
+ private final DisplayState mDisplayState = new DisplayState();
+
+ private boolean mIgnoreNextNavigation;
+
+ private Uri mCurrentDir;
+ private boolean mCurrentSupportsCreate;
+
@Override
public void onCreate(Bundle icicle) {
super.onCreate(icicle);
- SourceFragment.show(getFragmentManager());
+ final Intent intent = getIntent();
+ final String action = intent.getAction();
+ if (Intent.ACTION_OPEN_DOCUMENT.equals(action)) {
+ mAction = ACTION_OPEN;
+ mDisplayState.allowMultiple = intent.getBooleanExtra(Intent.EXTRA_ALLOW_MULTIPLE, false);
+ } else if (Intent.ACTION_CREATE_DOCUMENT.equals(action)) {
+ mAction = ACTION_CREATE;
+ mDisplayState.allowMultiple = false;
+ }
+
+ if (intent.hasExtra(Intent.EXTRA_MIME_TYPES)) {
+ mAcceptMimes = intent.getStringArrayExtra(Intent.EXTRA_MIME_TYPES);
+ } else {
+ mAcceptMimes = new String[] { intent.getType() };
+ }
+
+ if (mimeMatches("image/*", mAcceptMimes)) {
+ mDisplayState.mode = DisplayState.MODE_GRID;
+ } else {
+ mDisplayState.mode = DisplayState.MODE_LIST;
+ }
+
setResult(Activity.RESULT_CANCELED);
+ setContentView(R.layout.activity);
+
+ getFragmentManager().addOnBackStackChangedListener(mStackListener);
+ BackendFragment.show(getFragmentManager());
+
+ updateActionBar();
+
+ if (mAction == ACTION_CREATE) {
+ final String mimeType = getIntent().getType();
+ final String title = getIntent().getStringExtra(Intent.EXTRA_TITLE);
+ SaveFragment.show(getFragmentManager(), mimeType, title);
+ }
}
- public void onDocumentPicked(Uri uri) {
- Log.d(TAG, "onDocumentPicked() " + uri);
+ public void updateActionBar() {
+ final FragmentManager fm = getFragmentManager();
+ final ActionBar actionBar = getActionBar();
+
+ if (fm.getBackStackEntryCount() > 0) {
+ actionBar.setNavigationMode(ActionBar.NAVIGATION_MODE_LIST);
+ actionBar.setDisplayShowHomeEnabled(true);
+ actionBar.setDisplayHomeAsUpEnabled(true);
+ actionBar.setTitle(null);
+ actionBar.setListNavigationCallbacks(mStackAdapter, mNavigationListener);
+ actionBar.setSelectedNavigationItem(mStackAdapter.getCount() - 1);
+ mIgnoreNextNavigation = true;
+
+ } else {
+ actionBar.setNavigationMode(ActionBar.NAVIGATION_MODE_STANDARD);
+ actionBar.setDisplayShowHomeEnabled(false);
+ actionBar.setDisplayHomeAsUpEnabled(false);
+
+ if (mAction == ACTION_OPEN) {
+ actionBar.setTitle(R.string.title_open);
+ } else if (mAction == ACTION_CREATE) {
+ actionBar.setTitle(R.string.title_save);
+ }
+ }
+ }
+
+ @Override
+ public boolean onCreateOptionsMenu(Menu menu) {
+ super.onCreateOptionsMenu(menu);
+ getMenuInflater().inflate(R.menu.activity, menu);
+ return true;
+ }
+
+ @Override
+ public boolean onPrepareOptionsMenu(Menu menu) {
+ super.onPrepareOptionsMenu(menu);
+
+ final MenuItem createDir = menu.findItem(R.id.menu_create_dir);
+ createDir.setVisible(mAction == ACTION_CREATE);
+ createDir.setEnabled(mCurrentSupportsCreate);
+
+ return true;
+ }
+
+ @Override
+ public boolean onOptionsItemSelected(MenuItem item) {
+ final int id = item.getItemId();
+ if (id == android.R.id.home) {
+ getFragmentManager().popBackStack();
+ updateActionBar();
+ } else if (id == R.id.menu_create_dir) {
+ // TODO: show dialog to create directory
+ }
+ return super.onOptionsItemSelected(item);
+ }
+
+ private OnBackStackChangedListener mStackListener = new OnBackStackChangedListener() {
+ @Override
+ public void onBackStackChanged() {
+ updateActionBar();
+ }
+ };
+
+ private BaseAdapter mStackAdapter = new BaseAdapter() {
+ @Override
+ public int getCount() {
+ return getFragmentManager().getBackStackEntryCount();
+ }
+
+ @Override
+ public Object getItem(int position) {
+ return getFragmentManager().getBackStackEntryAt(position);
+ }
+
+ @Override
+ public long getItemId(int position) {
+ return getFragmentManager().getBackStackEntryAt(position).getId();
+ }
+
+ @Override
+ public View getView(int position, View convertView, ViewGroup parent) {
+ if (convertView == null) {
+ convertView = LayoutInflater.from(parent.getContext())
+ .inflate(android.R.layout.simple_dropdown_item_1line, parent, false);
+ }
+
+ final BackStackEntry entry = getFragmentManager().getBackStackEntryAt(position);
+ final TextView text1 = (TextView) convertView.findViewById(android.R.id.text1);
+ text1.setText(entry.getBreadCrumbTitle());
+
+ return convertView;
+ }
+ };
+
+ private OnNavigationListener mNavigationListener = new OnNavigationListener() {
+ @Override
+ public boolean onNavigationItemSelected(int itemPosition, long itemId) {
+ if (mIgnoreNextNavigation) {
+ mIgnoreNextNavigation = false;
+ return false;
+ }
+
+ getFragmentManager().popBackStack((int) itemId, 0);
+ return true;
+ }
+ };
+
+ public DisplayState getDisplayState() {
+ return mDisplayState;
+ }
+
+ public void onDirectoryChanged(Uri uri, int flags) {
+ mCurrentDir = uri;
+ mCurrentSupportsCreate = (flags & DocumentsContract.FLAG_SUPPORTS_CREATE) != 0;
+
+ if (mAction == ACTION_CREATE) {
+ final FragmentManager fm = getFragmentManager();
+ SaveFragment.get(fm).setSaveEnabled(mCurrentSupportsCreate);
+ }
+
+ invalidateOptionsMenu();
+ }
+
+ public void onBackendPicked(ProviderInfo info) {
+ final Uri uri = DocumentsContract.buildDocumentUri(
+ info.authority, DocumentsContract.ROOT_GUID);
+ final CharSequence displayName = info.loadLabel(getPackageManager());
+ DirectoryFragment.show(getFragmentManager(), uri, displayName.toString());
+ }
+
+ public void onDocumentPicked(Document doc) {
+ final FragmentManager fm = getFragmentManager();
+ if (DocumentsContract.MIME_TYPE_DIRECTORY.equals(doc.mimeType)) {
+ // Nested directory picked, recurse using new fragment
+ DirectoryFragment.show(fm, doc.uri, doc.displayName);
+ } else if (mAction == ACTION_OPEN) {
+ // Explicit file picked, return
+ onFinished(doc.uri);
+ } else if (mAction == ACTION_CREATE) {
+ // Overwrite current filename
+ SaveFragment.get(fm).setDisplayName(doc.displayName);
+ }
+ }
+
+ public void onDocumentsPicked(List<Document> docs) {
+ final int size = docs.size();
+ final Uri[] uris = new Uri[size];
+ for (int i = 0; i < size; i++) {
+ uris[i] = docs.get(i).uri;
+ }
+ onFinished(uris);
+ }
+
+ public void onSaveRequested(String mimeType, String displayName) {
+ // TODO: create file, confirming before overwriting
+ final Uri uri = null;
+ onFinished(uri);
+ }
+
+ private void onFinished(Uri... uris) {
+ Log.d(TAG, "onFinished() " + Arrays.toString(uris));
final Intent intent = new Intent();
- intent.setData(uri);
+ if (uris.length == 1) {
+ intent.setData(uris[0]);
+ } else if (uris.length > 1) {
+ final ContentResolver resolver = getContentResolver();
+ final ClipData clipData = new ClipData(null, mAcceptMimes, new ClipData.Item(uris[0]));
+ for (int i = 1; i < uris.length; i++) {
+ clipData.addItem(new ClipData.Item(uris[i]));
+ }
+ intent.setClipData(clipData);
+ }
intent.addFlags(
Intent.FLAG_GRANT_READ_URI_PERMISSION | Intent.FLAG_PERSIST_GRANT_URI_PERMISSION);
- if (Intent.ACTION_CREATE_DOCUMENT.equals(getIntent().getAction())) {
+ if (mAction == ACTION_CREATE) {
intent.addFlags(Intent.FLAG_GRANT_WRITE_URI_PERMISSION);
}
@@ -66,50 +293,70 @@
finish();
}
- public static class SourceFragment extends ListFragment {
- private ArrayList<ProviderInfo> mProviders = Lists.newArrayList();
- private ArrayAdapter<ProviderInfo> mAdapter;
+ public static class DisplayState {
+ public int mode;
+ public int sortBy;
+ public boolean allowMultiple;
- public static void show(FragmentManager fm) {
- final SourceFragment fragment = new SourceFragment();
+ public static final int MODE_LIST = 0;
+ public static final int MODE_GRID = 1;
- final FragmentTransaction ft = fm.beginTransaction();
- ft.replace(android.R.id.content, fragment);
- ft.setBreadCrumbTitle("TOP");
- ft.commitAllowingStateLoss();
+ public static final int SORT_BY_NAME = 0;
+ public static final int SORT_BY_DATE = 1;
+ }
+
+ public static class Document {
+ public Uri uri;
+ public String mimeType;
+ public String displayName;
+
+ public static Document fromCursor(String authority, Cursor cursor) {
+ final Document doc = new Document();
+ final String guid = getCursorString(cursor, DocumentColumns.GUID);
+ doc.uri = DocumentsContract.buildDocumentUri(authority, guid);
+ doc.mimeType = getCursorString(cursor, DocumentColumns.MIME_TYPE);
+ doc.displayName = getCursorString(cursor, DocumentColumns.DISPLAY_NAME);
+ return doc;
}
+ }
- @Override
- public View onCreateView(
- LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
- final Context context = inflater.getContext();
-
- // Gather known storage providers
- mProviders.clear();
- final List<ProviderInfo> providers = context.getPackageManager()
- .queryContentProviders(null, -1, PackageManager.GET_META_DATA);
- for (ProviderInfo info : providers) {
- if (info.metaData != null
- && info.metaData.containsKey(
- DocumentsContract.META_DATA_DOCUMENT_PROVIDER)) {
- mProviders.add(info);
- }
+ public static boolean mimeMatches(String filter, String[] tests) {
+ for (String test : tests) {
+ if (mimeMatches(filter, test)) {
+ return true;
}
-
- mAdapter = new ArrayAdapter<ProviderInfo>(
- context, android.R.layout.simple_list_item_1, mProviders);
- setListAdapter(mAdapter);
-
- return super.onCreateView(inflater, container, savedInstanceState);
}
+ return false;
+ }
- @Override
- public void onListItemClick(ListView l, View v, int position, long id) {
- final ProviderInfo info = mAdapter.getItem(position);
- final Uri uri = DocumentsContract.buildContentsUri(DocumentsContract.buildDocumentUri(
- info.authority, DocumentsContract.ROOT_GUID));
- final String displayName = info.name;
- DirectoryFragment.show(getFragmentManager(), uri, displayName);
+ public static boolean mimeMatches(String filter, String test) {
+ if (filter.equals(test)) {
+ return true;
+ } else if ("*/*".equals(filter)) {
+ return true;
+ } else if (filter.endsWith("/*")) {
+ return filter.regionMatches(0, test, 0, filter.indexOf('/'));
+ } else {
+ return false;
+ }
+ }
+
+ public static Drawable resolveDocumentIcon(Context context, String mimeType) {
+ // TODO: allow backends to provide custom MIME icons
+ if (DocumentsContract.MIME_TYPE_DIRECTORY.equals(mimeType)) {
+ return context.getResources().getDrawable(R.drawable.ic_dir);
+ } else {
+ final PackageManager pm = context.getPackageManager();
+ final Intent intent = new Intent(Intent.ACTION_VIEW);
+ intent.setType(mimeType);
+
+ final ResolveInfo info = pm.resolveActivity(
+ intent, PackageManager.MATCH_DEFAULT_ONLY);
+ if (info != null) {
+ return info.loadIcon(pm);
+ } else {
+ return null;
+ }
}
}
}
diff --git a/packages/DocumentsUI/src/com/android/documentsui/SaveFragment.java b/packages/DocumentsUI/src/com/android/documentsui/SaveFragment.java
new file mode 100644
index 0000000..19a1d2a
--- /dev/null
+++ b/packages/DocumentsUI/src/com/android/documentsui/SaveFragment.java
@@ -0,0 +1,98 @@
+/*
+ * Copyright (C) 2013 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.documentsui;
+
+import android.app.Fragment;
+import android.app.FragmentManager;
+import android.app.FragmentTransaction;
+import android.content.Context;
+import android.os.Bundle;
+import android.view.LayoutInflater;
+import android.view.View;
+import android.view.ViewGroup;
+import android.widget.Button;
+import android.widget.EditText;
+import android.widget.ImageView;
+
+/**
+ * Display document title editor and save button.
+ */
+public class SaveFragment extends Fragment {
+ public static final String TAG = "SaveFragment";
+
+ private EditText mDisplayName;
+ private Button mSave;
+
+ private static final String EXTRA_MIME_TYPE = "mime_type";
+ private static final String EXTRA_DISPLAY_NAME = "display_name";
+
+ public static void show(FragmentManager fm, String mimeType, String displayName) {
+ final Bundle args = new Bundle();
+ args.putString(EXTRA_MIME_TYPE, mimeType);
+ args.putString(EXTRA_DISPLAY_NAME, displayName);
+
+ final SaveFragment fragment = new SaveFragment();
+ fragment.setArguments(args);
+
+ final FragmentTransaction ft = fm.beginTransaction();
+ ft.replace(R.id.save, fragment, TAG);
+ ft.commitAllowingStateLoss();
+ }
+
+ public static SaveFragment get(FragmentManager fm) {
+ return (SaveFragment) fm.findFragmentByTag(TAG);
+ }
+
+ @Override
+ public View onCreateView(
+ LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
+ final Context context = inflater.getContext();
+
+ final View view = inflater.inflate(R.layout.fragment_save, container, false);
+
+ final ImageView icon = (ImageView) view.findViewById(android.R.id.icon);
+ icon.setImageDrawable(DocumentsActivity.resolveDocumentIcon(
+ context, getArguments().getString(EXTRA_MIME_TYPE)));
+
+ mDisplayName = (EditText) view.findViewById(android.R.id.title);
+ mDisplayName.setText(getArguments().getString(EXTRA_DISPLAY_NAME));
+
+ mSave = (Button) view.findViewById(android.R.id.button1);
+ mSave.setOnClickListener(mSaveListener);
+ mSave.setEnabled(false);
+
+ return view;
+ }
+
+ private View.OnClickListener mSaveListener = new View.OnClickListener() {
+ @Override
+ public void onClick(View v) {
+ final String mimeType = getArguments().getString(EXTRA_MIME_TYPE);
+ final String displayName = getArguments().getString(EXTRA_DISPLAY_NAME);
+ ((DocumentsActivity) getActivity()).onSaveRequested(mimeType, displayName);
+ }
+ };
+
+ public void setDisplayName(String displayName) {
+ getArguments().putString(EXTRA_DISPLAY_NAME, displayName);
+ mDisplayName.setText(displayName);
+ }
+
+ public void setSaveEnabled(boolean enabled) {
+ mSave.setEnabled(enabled);
+ }
+}
diff --git a/packages/DocumentsUI/src/com/android/documentsui/TestActivity.java b/packages/DocumentsUI/src/com/android/documentsui/TestActivity.java
new file mode 100644
index 0000000..b15d123
--- /dev/null
+++ b/packages/DocumentsUI/src/com/android/documentsui/TestActivity.java
@@ -0,0 +1,117 @@
+/*
+ * Copyright (C) 2013 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.documentsui;
+
+import android.app.Activity;
+import android.content.Context;
+import android.content.Intent;
+import android.os.Bundle;
+import android.view.View;
+import android.view.View.OnClickListener;
+import android.widget.Button;
+import android.widget.CheckBox;
+import android.widget.LinearLayout;
+import android.widget.TextView;
+
+public class TestActivity extends Activity {
+ private TextView mResult;
+
+ @Override
+ public void onCreate(Bundle icicle) {
+ super.onCreate(icicle);
+
+ final Context context = this;
+
+ final LinearLayout view = new LinearLayout(context);
+ view.setOrientation(LinearLayout.VERTICAL);
+
+ final CheckBox multiple = new CheckBox(context);
+ multiple.setText("ALLOW_MULTIPLE");
+ view.addView(multiple);
+
+ Button button;
+ button = new Button(context);
+ button.setText("OPEN_DOC */*");
+ button.setOnClickListener(new OnClickListener() {
+ @Override
+ public void onClick(View v) {
+ Intent intent = new Intent(Intent.ACTION_OPEN_DOCUMENT);
+ intent.setType("*/*");
+ if (multiple.isChecked()) {
+ intent.putExtra(Intent.EXTRA_ALLOW_MULTIPLE, true);
+ }
+ startActivityForResult(intent, 42);
+ }
+ });
+ view.addView(button);
+
+ button = new Button(context);
+ button.setText("OPEN_DOC image/*");
+ button.setOnClickListener(new OnClickListener() {
+ @Override
+ public void onClick(View v) {
+ Intent intent = new Intent(Intent.ACTION_OPEN_DOCUMENT);
+ intent.setType("image/*");
+ if (multiple.isChecked()) {
+ intent.putExtra(Intent.EXTRA_ALLOW_MULTIPLE, true);
+ }
+ startActivityForResult(intent, 42);
+ }
+ });
+ view.addView(button);
+
+ button = new Button(context);
+ button.setText("OPEN_DOC text/plain, application/msword");
+ button.setOnClickListener(new OnClickListener() {
+ @Override
+ public void onClick(View v) {
+ Intent intent = new Intent(Intent.ACTION_OPEN_DOCUMENT);
+ intent.setType("*/*");
+ intent.putExtra(Intent.EXTRA_MIME_TYPES, new String[] {
+ "text/plain", "application/msword" });
+ if (multiple.isChecked()) {
+ intent.putExtra(Intent.EXTRA_ALLOW_MULTIPLE, true);
+ }
+ startActivityForResult(intent, 42);
+ }
+ });
+ view.addView(button);
+
+ button = new Button(context);
+ button.setText("CREATE_DOC text/plain");
+ button.setOnClickListener(new OnClickListener() {
+ @Override
+ public void onClick(View v) {
+ Intent intent = new Intent(Intent.ACTION_CREATE_DOCUMENT);
+ intent.setType("text/plain");
+ intent.putExtra(Intent.EXTRA_TITLE, "foobar.txt");
+ startActivityForResult(intent, 42);
+ }
+ });
+ view.addView(button);
+
+ mResult = new TextView(context);
+ view.addView(mResult);
+
+ setContentView(view);
+ }
+
+ @Override
+ protected void onActivityResult(int requestCode, int resultCode, Intent data) {
+ mResult.setText("resultCode=" + resultCode + ", data=" + String.valueOf(data));
+ }
+}
diff --git a/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java b/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java
index 5838526..b65a9a0 100644
--- a/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java
+++ b/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java
@@ -2239,14 +2239,11 @@
// Set default cdma call auto retry
loadSetting(stmt, Settings.Global.CALL_AUTO_RETRY, 0);
- // Set the preferred network mode to 0 = Global, CDMA default
+ // Set the preferred network mode to target desired value or Default
+ // value defined in RILConstants
int type;
- if (TelephonyManager.getLteOnCdmaModeStatic() == PhoneConstants.LTE_ON_CDMA_TRUE) {
- type = Phone.NT_MODE_GLOBAL;
- } else {
- type = SystemProperties.getInt("ro.telephony.default_network",
+ type = SystemProperties.getInt("ro.telephony.default_network",
RILConstants.PREFERRED_NETWORK_MODE);
- }
loadSetting(stmt, Settings.Global.PREFERRED_NETWORK_MODE, type);
// --- New global settings start here
diff --git a/packages/SystemUI/res/values-de/strings.xml b/packages/SystemUI/res/values-de/strings.xml
index 43cde46..8e13c57 100644
--- a/packages/SystemUI/res/values-de/strings.xml
+++ b/packages/SystemUI/res/values-de/strings.xml
@@ -196,7 +196,7 @@
<string name="quick_settings_wifi_no_network" msgid="2221993077220856376">"Kein Netz"</string>
<string name="quick_settings_wifi_off_label" msgid="7558778100843885864">"WLAN aus"</string>
<string name="quick_settings_wifi_display_label" msgid="6893592964463624333">"WLAN-Display"</string>
- <string name="quick_settings_wifi_display_no_connection_label" msgid="2355298740765736918">"Kabellose Übertragung"</string>
+ <string name="quick_settings_wifi_display_no_connection_label" msgid="2355298740765736918">"Kabellose Übertragung (WiDi)"</string>
<string name="quick_settings_brightness_dialog_title" msgid="8599674057673605368">"Helligkeit"</string>
<string name="quick_settings_brightness_dialog_auto_brightness_label" msgid="5064982743784071218">"AUTO"</string>
<string name="status_bar_help_title" msgid="1199237744086469217">"Benachrichtigungen erscheinen hier"</string>
diff --git a/services/input/Android.mk b/services/input/Android.mk
index 5d913f3..6e944ef 100644
--- a/services/input/Android.mk
+++ b/services/input/Android.mk
@@ -36,12 +36,13 @@
libhardware_legacy \
libskia \
libgui \
- libui
+ libui \
+ libinput
LOCAL_C_INCLUDES := \
external/skia/include/core
-LOCAL_MODULE:= libinput
+LOCAL_MODULE:= libinputservice
LOCAL_MODULE_TAGS := optional
diff --git a/services/input/EventHub.cpp b/services/input/EventHub.cpp
index 376de96..65749b3 100644
--- a/services/input/EventHub.cpp
+++ b/services/input/EventHub.cpp
@@ -36,9 +36,9 @@
#include <errno.h>
#include <assert.h>
-#include <androidfw/KeyLayoutMap.h>
-#include <androidfw/KeyCharacterMap.h>
-#include <androidfw/VirtualKeyMap.h>
+#include <input/KeyLayoutMap.h>
+#include <input/KeyCharacterMap.h>
+#include <input/VirtualKeyMap.h>
#include <string.h>
#include <stdint.h>
diff --git a/services/input/EventHub.h b/services/input/EventHub.h
index c93fc7a..daa1bea 100644
--- a/services/input/EventHub.h
+++ b/services/input/EventHub.h
@@ -18,12 +18,12 @@
#ifndef _RUNTIME_EVENT_HUB_H
#define _RUNTIME_EVENT_HUB_H
-#include <androidfw/Input.h>
-#include <androidfw/InputDevice.h>
-#include <androidfw/Keyboard.h>
-#include <androidfw/KeyLayoutMap.h>
-#include <androidfw/KeyCharacterMap.h>
-#include <androidfw/VirtualKeyMap.h>
+#include <input/Input.h>
+#include <input/InputDevice.h>
+#include <input/Keyboard.h>
+#include <input/KeyLayoutMap.h>
+#include <input/KeyCharacterMap.h>
+#include <input/VirtualKeyMap.h>
#include <utils/String8.h>
#include <utils/threads.h>
#include <utils/Log.h>
diff --git a/services/input/InputApplication.h b/services/input/InputApplication.h
index c04a935..1f5504c 100644
--- a/services/input/InputApplication.h
+++ b/services/input/InputApplication.h
@@ -17,7 +17,7 @@
#ifndef _UI_INPUT_APPLICATION_H
#define _UI_INPUT_APPLICATION_H
-#include <androidfw/Input.h>
+#include <input/Input.h>
#include <utils/RefBase.h>
#include <utils/Timers.h>
diff --git a/services/input/InputDispatcher.h b/services/input/InputDispatcher.h
index 430721e..63ea781 100644
--- a/services/input/InputDispatcher.h
+++ b/services/input/InputDispatcher.h
@@ -17,8 +17,8 @@
#ifndef _UI_INPUT_DISPATCHER_H
#define _UI_INPUT_DISPATCHER_H
-#include <androidfw/Input.h>
-#include <androidfw/InputTransport.h>
+#include <input/Input.h>
+#include <input/InputTransport.h>
#include <utils/KeyedVector.h>
#include <utils/Vector.h>
#include <utils/threads.h>
diff --git a/services/input/InputListener.h b/services/input/InputListener.h
index cd7c25a..78ae10f 100644
--- a/services/input/InputListener.h
+++ b/services/input/InputListener.h
@@ -17,7 +17,7 @@
#ifndef _UI_INPUT_LISTENER_H
#define _UI_INPUT_LISTENER_H
-#include <androidfw/Input.h>
+#include <input/Input.h>
#include <utils/RefBase.h>
#include <utils/Vector.h>
diff --git a/services/input/InputManager.h b/services/input/InputManager.h
index 29584c9..a213b2d 100644
--- a/services/input/InputManager.h
+++ b/services/input/InputManager.h
@@ -25,8 +25,8 @@
#include "InputReader.h"
#include "InputDispatcher.h"
-#include <androidfw/Input.h>
-#include <androidfw/InputTransport.h>
+#include <input/Input.h>
+#include <input/InputTransport.h>
#include <utils/Errors.h>
#include <utils/Vector.h>
#include <utils/Timers.h>
diff --git a/services/input/InputReader.cpp b/services/input/InputReader.cpp
index e229755..5b64d8a 100644
--- a/services/input/InputReader.cpp
+++ b/services/input/InputReader.cpp
@@ -42,8 +42,8 @@
#include "InputReader.h"
#include <cutils/log.h>
-#include <androidfw/Keyboard.h>
-#include <androidfw/VirtualKeyMap.h>
+#include <input/Keyboard.h>
+#include <input/VirtualKeyMap.h>
#include <stddef.h>
#include <stdlib.h>
diff --git a/services/input/InputReader.h b/services/input/InputReader.h
index 0189ba7..7e303e4 100644
--- a/services/input/InputReader.h
+++ b/services/input/InputReader.h
@@ -21,9 +21,9 @@
#include "PointerController.h"
#include "InputListener.h"
-#include <androidfw/Input.h>
-#include <androidfw/VelocityControl.h>
-#include <androidfw/VelocityTracker.h>
+#include <input/Input.h>
+#include <input/VelocityControl.h>
+#include <input/VelocityTracker.h>
#include <utils/KeyedVector.h>
#include <utils/threads.h>
#include <utils/Timers.h>
diff --git a/services/input/InputWindow.h b/services/input/InputWindow.h
index 7bd3af7..136870a 100644
--- a/services/input/InputWindow.h
+++ b/services/input/InputWindow.h
@@ -17,8 +17,8 @@
#ifndef _UI_INPUT_WINDOW_H
#define _UI_INPUT_WINDOW_H
-#include <androidfw/Input.h>
-#include <androidfw/InputTransport.h>
+#include <input/Input.h>
+#include <input/InputTransport.h>
#include <utils/RefBase.h>
#include <utils/Timers.h>
#include <utils/String8.h>
diff --git a/services/input/PointerController.h b/services/input/PointerController.h
index fd68b61..790c0bb 100644
--- a/services/input/PointerController.h
+++ b/services/input/PointerController.h
@@ -20,7 +20,7 @@
#include "SpriteController.h"
#include <ui/DisplayInfo.h>
-#include <androidfw/Input.h>
+#include <input/Input.h>
#include <utils/BitSet.h>
#include <utils/RefBase.h>
#include <utils/Looper.h>
diff --git a/services/input/tests/Android.mk b/services/input/tests/Android.mk
index f3e2dee..9278f41 100644
--- a/services/input/tests/Android.mk
+++ b/services/input/tests/Android.mk
@@ -17,7 +17,8 @@
libui \
libskia \
libstlport \
- libinput
+ libinput \
+ libinputservice
static_libraries := \
libgtest \
diff --git a/services/java/com/android/server/AlarmManagerService.java b/services/java/com/android/server/AlarmManagerService.java
index bc06561..0be9ca5 100644
--- a/services/java/com/android/server/AlarmManagerService.java
+++ b/services/java/com/android/server/AlarmManagerService.java
@@ -53,7 +53,7 @@
import java.util.Comparator;
import java.util.Date;
import java.util.HashMap;
-import java.util.Iterator;
+import java.util.LinkedList;
import java.util.Map;
import java.util.TimeZone;
@@ -69,6 +69,7 @@
private static final int ELAPSED_REALTIME_WAKEUP_MASK = 1 << AlarmManager.ELAPSED_REALTIME_WAKEUP;
private static final int ELAPSED_REALTIME_MASK = 1 << AlarmManager.ELAPSED_REALTIME;
private static final int TIME_CHANGED_MASK = 1 << 16;
+ private static final int IS_WAKEUP_MASK = RTC_WAKEUP_MASK|ELAPSED_REALTIME_WAKEUP_MASK;
// Alignment quantum for inexact repeating alarms
private static final long QUANTUM = AlarmManager.INTERVAL_FIFTEEN_MINUTES;
@@ -82,6 +83,8 @@
private static final Intent mBackgroundIntent
= new Intent().addFlags(Intent.FLAG_FROM_BACKGROUND);
+ private static final boolean WAKEUP_STATS = true;
+
private final Context mContext;
private final LocalLog mLog = new LocalLog(TAG);
@@ -106,6 +109,21 @@
private final PendingIntent mTimeTickSender;
private final PendingIntent mDateChangeSender;
+ class WakeupEvent {
+ public long when;
+ public int uid;
+ public String action;
+
+ public WakeupEvent(long theTime, int theUid, String theAction) {
+ when = theTime;
+ uid = theUid;
+ action = theAction;
+ }
+ }
+
+ private final LinkedList<WakeupEvent> mRecentWakeups = new LinkedList<WakeupEvent>();
+ private final long RECENT_WAKEUP_PERIOD = 1000L * 60 * 60 * 24; // one day
+
private static final class InFlight extends Intent {
final PendingIntent mPendingIntent;
final Pair<String, ComponentName> mTarget;
@@ -640,6 +658,27 @@
pw.println();
}
}
+
+ if (WAKEUP_STATS) {
+ pw.println();
+ pw.println(" Recent Wakeup History:");
+ final SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd-HH:mm:ss.SSS");
+ long last = -1;
+ for (WakeupEvent event : mRecentWakeups) {
+ pw.print(" "); pw.print(sdf.format(new Date(event.when)));
+ pw.print('|');
+ if (last < 0) {
+ pw.print('0');
+ } else {
+ pw.print(event.when - last);
+ }
+ last = event.when;
+ pw.print('|'); pw.print(event.uid);
+ pw.print('|'); pw.print(event.action);
+ pw.println();
+ }
+ pw.println();
+ }
}
}
@@ -775,7 +814,20 @@
pw.print(prefix); pw.print("operation="); pw.println(operation);
}
}
-
+
+ void recordWakeupAlarms(ArrayList<Alarm> alarms, long now, long skewToRTC) {
+ for (Alarm a : alarms) {
+ if (a.when > now) {
+ break;
+ }
+
+ WakeupEvent e = new WakeupEvent(now + skewToRTC,
+ a.operation.getCreatorUid(),
+ a.operation.getIntent().getAction());
+ mRecentWakeups.add(e);
+ }
+ }
+
private class AlarmThread extends Thread
{
public AlarmThread()
@@ -809,6 +861,27 @@
TAG, "Checking for alarms... rtc=" + nowRTC
+ ", elapsed=" + nowELAPSED);
+ if (WAKEUP_STATS) {
+ if ((result & IS_WAKEUP_MASK) != 0) {
+ long newEarliest = nowRTC - RECENT_WAKEUP_PERIOD;
+ int n = 0;
+ for (WakeupEvent event : mRecentWakeups) {
+ if (event.when > newEarliest) break;
+ n++; // number of now-stale entries at the list head
+ }
+ for (int i = 0; i < n; i++) {
+ mRecentWakeups.remove();
+ }
+
+ recordWakeupAlarms(mRtcWakeupAlarms,
+ nowRTC,
+ 0);
+ recordWakeupAlarms(mElapsedRealtimeWakeupAlarms,
+ nowELAPSED,
+ nowRTC - nowELAPSED);
+ }
+ }
+
if ((result & RTC_WAKEUP_MASK) != 0)
triggerAlarmsLocked(mRtcWakeupAlarms, triggerList, nowRTC);
diff --git a/services/java/com/android/server/ConnectivityService.java b/services/java/com/android/server/ConnectivityService.java
index 54f6118..f2e0f29 100644
--- a/services/java/com/android/server/ConnectivityService.java
+++ b/services/java/com/android/server/ConnectivityService.java
@@ -31,6 +31,9 @@
import static android.net.NetworkPolicyManager.RULE_ALLOW_ALL;
import static android.net.NetworkPolicyManager.RULE_REJECT_METERED;
+import android.app.Notification;
+import android.app.NotificationManager;
+import android.app.PendingIntent;
import android.bluetooth.BluetoothTetheringDataTracker;
import android.content.BroadcastReceiver;
import android.content.ContentResolver;
@@ -52,11 +55,13 @@
import android.net.INetworkStatsService;
import android.net.LinkAddress;
import android.net.LinkProperties;
+import android.net.Uri;
import android.net.LinkProperties.CompareResult;
import android.net.MobileDataStateTracker;
import android.net.NetworkConfig;
import android.net.NetworkInfo;
import android.net.NetworkInfo.DetailedState;
+import android.net.NetworkInfo.State;
import android.net.NetworkQuotaInfo;
import android.net.NetworkState;
import android.net.NetworkStateTracker;
@@ -66,6 +71,7 @@
import android.net.RouteInfo;
import android.net.wifi.WifiStateTracker;
import android.net.wimax.WimaxManagerConstants;
+import android.os.AsyncTask;
import android.os.Binder;
import android.os.FileUtils;
import android.os.Handler;
@@ -79,6 +85,7 @@
import android.os.PowerManager;
import android.os.Process;
import android.os.RemoteException;
+import android.os.ResultReceiver;
import android.os.ServiceManager;
import android.os.SystemClock;
import android.os.SystemProperties;
@@ -86,13 +93,16 @@
import android.provider.Settings;
import android.security.Credentials;
import android.security.KeyStore;
+import android.telephony.TelephonyManager;
import android.text.TextUtils;
import android.util.Slog;
import android.util.SparseIntArray;
+import com.android.internal.R;
import com.android.internal.net.LegacyVpnInfo;
import com.android.internal.net.VpnConfig;
import com.android.internal.net.VpnProfile;
+import com.android.internal.telephony.DctConstants;
import com.android.internal.telephony.Phone;
import com.android.internal.telephony.PhoneConstants;
import com.android.internal.util.IndentingPrintWriter;
@@ -112,9 +122,11 @@
import java.io.IOException;
import java.io.PrintWriter;
import java.lang.reflect.Constructor;
+import java.net.HttpURLConnection;
import java.net.Inet4Address;
import java.net.Inet6Address;
import java.net.InetAddress;
+import java.net.URL;
import java.net.UnknownHostException;
import java.util.ArrayList;
import java.util.Arrays;
@@ -122,6 +134,8 @@
import java.util.GregorianCalendar;
import java.util.HashSet;
import java.util.List;
+import java.util.Random;
+import java.util.concurrent.atomic.AtomicInteger;
/**
* @hide
@@ -142,6 +156,12 @@
private static final String NETWORK_RESTORE_DELAY_PROP_NAME =
"android.telephony.apn-restore";
+ // Default value if FAIL_FAST_TIME_MS is not set
+ private static final int DEFAULT_FAIL_FAST_TIME_MS = 1 * 60 * 1000;
+ // system property that can override DEFAULT_FAIL_FAST_TIME_MS
+ private static final String FAIL_FAST_TIME_MS =
+ "persist.radio.fail_fast_time_ms";
+
// used in recursive route setting to add gateways for the host for which
// a host route was requested.
private static final int MAX_HOSTROUTE_CYCLE_COUNT = 10;
@@ -293,6 +313,11 @@
private static final int EVENT_VPN_STATE_CHANGED = 14;
+ /**
+ * Used internally to disable fail fast of mobile data
+ */
+ private static final int EVENT_ENABLE_FAIL_FAST_MOBILE_DATA = 15;
+
/** Handler used for internal events. */
private InternalHandler mHandler;
/** Handler used for incoming {@link NetworkStateTracker} events. */
@@ -348,6 +373,9 @@
List mProtectedNetworks;
private DataConnectionStats mDataConnectionStats;
+ private AtomicInteger mEnableFailFastMobileDataTag = new AtomicInteger(0);
+
+ TelephonyManager mTelephonyManager;
public ConnectivityService(Context context, INetworkManagementService netd,
INetworkStatsService statsService, INetworkPolicyManager policyManager) {
@@ -397,6 +425,7 @@
mNetd = checkNotNull(netManager, "missing INetworkManagementService");
mPolicyManager = checkNotNull(policyManager, "missing INetworkPolicyManager");
mKeyStore = KeyStore.getInstance();
+ mTelephonyManager = (TelephonyManager) mContext.getSystemService(Context.TELEPHONY_SERVICE);
try {
mPolicyManager.registerListener(mPolicyListener);
@@ -1414,8 +1443,12 @@
netState != DetailedState.CAPTIVE_PORTAL_CHECK) ||
tracker.isTeardownRequested()) {
if (VDBG) {
- log("requestRouteToHostAddress on down network " +
- "(" + networkType + ") - dropped");
+ log("requestRouteToHostAddress on down network "
+ + "(" + networkType + ") - dropped"
+ + " tracker=" + tracker
+ + " netState=" + netState
+ + " isTeardownRequested="
+ + ((tracker != null) ? tracker.isTeardownRequested() : "tracker:null"));
}
return false;
}
@@ -1423,12 +1456,15 @@
try {
InetAddress addr = InetAddress.getByAddress(hostAddress);
LinkProperties lp = tracker.getLinkProperties();
- return addRouteToAddress(lp, addr);
+ boolean ok = addRouteToAddress(lp, addr);
+ if (DBG) log("requestRouteToHostAddress ok=" + ok);
+ return ok;
} catch (UnknownHostException e) {
if (DBG) log("requestRouteToHostAddress got " + e.toString());
} finally {
Binder.restoreCallingIdentity(token);
}
+ if (DBG) log("requestRouteToHostAddress X bottom return false");
return false;
}
@@ -2830,6 +2866,19 @@
}
break;
}
+ case EVENT_ENABLE_FAIL_FAST_MOBILE_DATA: {
+ int tag = mEnableFailFastMobileDataTag.get();
+ if (msg.arg1 == tag) {
+ MobileDataStateTracker mobileDst =
+ (MobileDataStateTracker) mNetTrackers[ConnectivityManager.TYPE_MOBILE];
+ if (mobileDst != null) {
+ mobileDst.setEnableFailFastMobileData(msg.arg2);
+ }
+ } else {
+ log("EVENT_ENABLE_FAIL_FAST_MOBILE_DATA: stale arg1:" + msg.arg1
+ + " != tag:" + tag);
+ }
+ }
}
}
}
@@ -3484,4 +3533,470 @@
}
return ConnectivityManager.TYPE_NONE;
}
+
+ /**
+ * Have mobile data fail fast if enabled.
+ *
+ * @param enabled DctConstants.ENABLED/DISABLED
+ */
+ private void setEnableFailFastMobileData(int enabled) {
+ int tag;
+
+ if (enabled == DctConstants.ENABLED) {
+ tag = mEnableFailFastMobileDataTag.incrementAndGet();
+ } else {
+ tag = mEnableFailFastMobileDataTag.get();
+ }
+ mHandler.sendMessage(mHandler.obtainMessage(EVENT_ENABLE_FAIL_FAST_MOBILE_DATA, tag,
+ enabled));
+ }
+
+ @Override
+ public int checkMobileProvisioning(boolean sendNotification, int suggestedTimeOutMs,
+ final ResultReceiver resultReceiver) {
+ log("checkMobileProvisioning: E sendNotification=" + sendNotification
+ + " suggestedTimeOutMs=" + suggestedTimeOutMs
+ + " resultReceiver=" + resultReceiver);
+ enforceChangePermission();
+
+ int timeOutMs = suggestedTimeOutMs;
+ if (suggestedTimeOutMs > CheckMp.MAX_TIMEOUT_MS) {
+ timeOutMs = CheckMp.MAX_TIMEOUT_MS;
+ }
+
+ // Check that mobile networks are supported
+ if (!isNetworkSupported(ConnectivityManager.TYPE_MOBILE)
+ || !isNetworkSupported(ConnectivityManager.TYPE_MOBILE_HIPRI)) {
+ log("checkMobileProvisioning: X no mobile network");
+ if (resultReceiver != null) {
+ resultReceiver.send(ConnectivityManager.CMP_RESULT_CODE_NO_CONNECTION, null);
+ }
+ return timeOutMs;
+ }
+
+ final long token = Binder.clearCallingIdentity();
+ try {
+ CheckMp checkMp = new CheckMp(mContext, this);
+ CheckMp.CallBack cb = new CheckMp.CallBack() {
+ @Override
+ void onComplete(Integer result) {
+ log("CheckMp.onComplete: result=" + result);
+ if (resultReceiver != null) {
+ log("CheckMp.onComplete: send result");
+ resultReceiver.send(result, null);
+ }
+ NetworkInfo ni =
+ mNetTrackers[ConnectivityManager.TYPE_MOBILE_HIPRI].getNetworkInfo();
+ switch(result) {
+ case ConnectivityManager.CMP_RESULT_CODE_CONNECTABLE:
+ case ConnectivityManager.CMP_RESULT_CODE_NO_CONNECTION: {
+ log("CheckMp.onComplete: ignore, connected or no connection");
+ break;
+ }
+ case ConnectivityManager.CMP_RESULT_CODE_REDIRECTED: {
+ log("CheckMp.onComplete: warm sim");
+ String url = getProvisioningUrl();
+ if (TextUtils.isEmpty(url)) {
+ url = mContext.getResources()
+ .getString(R.string.mobile_redirected_provisioning_url);
+ }
+ if (TextUtils.isEmpty(url) == false) {
+ log("CheckMp.onComplete: warm sim (redirected), url=" + url);
+ setNotificationVisible(true, ni, url);
+ } else {
+ log("CheckMp.onComplete: warm sim (redirected), no url");
+ }
+ break;
+ }
+ case ConnectivityManager.CMP_RESULT_CODE_NO_DNS:
+ case ConnectivityManager.CMP_RESULT_CODE_NO_TCP_CONNECTION: {
+ String url = getProvisioningUrl();
+ if (TextUtils.isEmpty(url) == false) {
+ log("CheckMp.onComplete: warm sim (no dns/tcp), url=" + url);
+ setNotificationVisible(true, ni, url);
+ } else {
+ log("CheckMp.onComplete: warm sim (no dns/tcp), no url");
+ }
+ break;
+ }
+ default: {
+ loge("CheckMp.onComplete: ignore unexpected result=" + result);
+ break;
+ }
+ }
+ }
+ };
+ CheckMp.Params params =
+ new CheckMp.Params(checkMp.getDefaultUrl(), timeOutMs, cb);
+ log("checkMobileProvisioning: params=" + params);
+ setNotificationVisible(false, null, null);
+ checkMp.execute(params);
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ log("checkMobileProvisioning: X");
+ }
+ return timeOutMs;
+ }
+
+ static class CheckMp extends
+ AsyncTask<CheckMp.Params, Void, Integer> {
+ private static final String CHECKMP_TAG = "CheckMp";
+ public static final int MAX_TIMEOUT_MS = 60000;
+ private static final int SOCKET_TIMEOUT_MS = 5000;
+ private Context mContext;
+ private ConnectivityService mCs;
+ private TelephonyManager mTm;
+ private Params mParams;
+
+ /**
+ * Parameters for AsyncTask.execute
+ */
+ static class Params {
+ private String mUrl;
+ private long mTimeOutMs;
+ private CallBack mCb;
+
+ Params(String url, long timeOutMs, CallBack cb) {
+ mUrl = url;
+ mTimeOutMs = timeOutMs;
+ mCb = cb;
+ }
+
+ @Override
+ public String toString() {
+ return "{" + " url=" + mUrl + " mTimeOutMs=" + mTimeOutMs + " mCb=" + mCb + "}";
+ }
+ }
+
+ /**
+ * The call back object passed in Params. onComplete will be called
+ * on the main thread.
+ */
+ abstract static class CallBack {
+ // Called on the main thread.
+ abstract void onComplete(Integer result);
+ }
+
+ public CheckMp(Context context, ConnectivityService cs) {
+ mContext = context;
+ mCs = cs;
+
+ // Setup access to TelephonyService we'll be using.
+ mTm = (TelephonyManager) mContext.getSystemService(
+ Context.TELEPHONY_SERVICE);
+ }
+
+ /**
+ * Get the default url to use for the test.
+ */
+ public String getDefaultUrl() {
+ // See http://go/clientsdns for usage approval
+ String server = Settings.Global.getString(mContext.getContentResolver(),
+ Settings.Global.CAPTIVE_PORTAL_SERVER);
+ if (server == null) {
+ server = "clients3.google.com";
+ }
+ return "http://" + server + "/generate_204";
+ }
+
+ /**
+ * Detect if its possible to connect to the http url. DNS based detection techniques
+ * do not work at all hotspots. The best way to check is to perform a request to
+ * a known address that fetches the data we expect.
+ */
+ private synchronized Integer isMobileOk(Params params) {
+ Integer result = ConnectivityManager.CMP_RESULT_CODE_NO_CONNECTION;
+ Uri orgUri = Uri.parse(params.mUrl);
+ Random rand = new Random();
+ mParams = params;
+
+ try {
+ if (mCs.isNetworkSupported(ConnectivityManager.TYPE_MOBILE) == false) {
+ log("isMobileOk: not mobile capable");
+ result = ConnectivityManager.CMP_RESULT_CODE_NO_CONNECTION;
+ return result;
+ }
+
+ // Enable fail fast as we'll do retries here and use a
+ // hipri connection so the default connection stays active.
+ log("isMobileOk: start hipri url=" + params.mUrl);
+ mCs.setEnableFailFastMobileData(DctConstants.ENABLED);
+ mCs.startUsingNetworkFeature(ConnectivityManager.TYPE_MOBILE,
+ Phone.FEATURE_ENABLE_HIPRI, new Binder());
+
+ // Continue trying to connect until time has run out
+ long endTime = SystemClock.elapsedRealtime() + params.mTimeOutMs;
+ while(SystemClock.elapsedRealtime() < endTime) {
+ try {
+ // Wait for hipri to connect.
+ // TODO: Don't poll and handle situation where hipri fails
+ // because default is retrying. See b/9569540
+ NetworkInfo.State state = mCs
+ .getNetworkInfo(ConnectivityManager.TYPE_MOBILE_HIPRI).getState();
+ if (state != NetworkInfo.State.CONNECTED) {
+ log("isMobileOk: not connected ni=" +
+ mCs.getNetworkInfo(ConnectivityManager.TYPE_MOBILE_HIPRI));
+ sleep(1);
+ result = ConnectivityManager.CMP_RESULT_CODE_NO_CONNECTION;
+ continue;
+ }
+
+ // Get of the addresses associated with the url host. We need to use the
+ // address otherwise HttpURLConnection object will use the name to get
+ // the addresses and is will try every address but that will bypass the
+ // route to host we setup and the connection could succeed as the default
+ // interface might be connected to the internet via wifi or other interface.
+ InetAddress[] addresses;
+ try {
+ addresses = InetAddress.getAllByName(orgUri.getHost());
+ } catch (UnknownHostException e) {
+ log("isMobileOk: UnknownHostException");
+ result = ConnectivityManager.CMP_RESULT_CODE_NO_DNS;
+ return result;
+ }
+ log("isMobileOk: addresses=" + inetAddressesToString(addresses));
+
+ // Get the type of addresses supported by this link
+ LinkProperties lp = mCs.getLinkProperties(
+ ConnectivityManager.TYPE_MOBILE_HIPRI);
+ boolean linkHasIpv4 = hasIPv4Address(lp);
+ boolean linkHasIpv6 = hasIPv6Address(lp);
+ log("isMobileOk: linkHasIpv4=" + linkHasIpv4
+ + " linkHasIpv6=" + linkHasIpv6);
+
+ // Loop through at most 3 valid addresses or all of the address or until
+ // we run out of time
+ int loops = Math.min(3, addresses.length);
+ for(int validAddr=0, addrTried=0;
+ (validAddr < loops) && (addrTried < addresses.length)
+ && (SystemClock.elapsedRealtime() < endTime);
+ addrTried ++) {
+
+ // Choose the address at random but make sure its type is supported
+ InetAddress hostAddr = addresses[rand.nextInt(addresses.length)];
+ if (((hostAddr instanceof Inet4Address) && linkHasIpv4)
+ || ((hostAddr instanceof Inet6Address) && linkHasIpv6)) {
+ // Valid address, so use it
+ validAddr += 1;
+ } else {
+ // Invalid address so try next address
+ continue;
+ }
+
+ // Make a route to host so we check the specific interface.
+ if (mCs.requestRouteToHostAddress(ConnectivityManager.TYPE_MOBILE_HIPRI,
+ hostAddr.getAddress())) {
+ // Wait a short time to be sure the route is established ??
+ log("isMobileOk:"
+ + " wait to establish route to hostAddr=" + hostAddr);
+ sleep(3);
+ } else {
+ log("isMobileOk:"
+ + " could not establish route to hostAddr=" + hostAddr);
+ continue;
+ }
+
+ // Rewrite the url to have numeric address to use the specific route.
+ // I also set the "Connection" to "Close" as by default "Keep-Alive"
+ // is used which is useless in this case.
+ URL newUrl = new URL(orgUri.getScheme() + "://"
+ + hostAddr.getHostAddress() + orgUri.getPath());
+ log("isMobileOk: newUrl=" + newUrl);
+
+ HttpURLConnection urlConn = null;
+ try {
+ // Open the connection set the request header and get the response
+ urlConn = (HttpURLConnection) newUrl.openConnection(
+ java.net.Proxy.NO_PROXY);
+ urlConn.setInstanceFollowRedirects(false);
+ urlConn.setConnectTimeout(SOCKET_TIMEOUT_MS);
+ urlConn.setReadTimeout(SOCKET_TIMEOUT_MS);
+ urlConn.setUseCaches(false);
+ urlConn.setAllowUserInteraction(false);
+ urlConn.setRequestProperty("Connection", "close");
+ int responseCode = urlConn.getResponseCode();
+ if (responseCode == 204) {
+ result = ConnectivityManager.CMP_RESULT_CODE_CONNECTABLE;
+ } else {
+ result = ConnectivityManager.CMP_RESULT_CODE_REDIRECTED;
+ }
+ log("isMobileOk: connected responseCode=" + responseCode);
+ urlConn.disconnect();
+ urlConn = null;
+ return result;
+ } catch (Exception e) {
+ log("isMobileOk: HttpURLConnection Exception e=" + e);
+ if (urlConn != null) {
+ urlConn.disconnect();
+ urlConn = null;
+ }
+ }
+ }
+ result = ConnectivityManager.CMP_RESULT_CODE_NO_TCP_CONNECTION;
+ log("isMobileOk: loops|timed out");
+ return result;
+ } catch (Exception e) {
+ log("isMobileOk: Exception e=" + e);
+ continue;
+ }
+ }
+ log("isMobileOk: timed out");
+ } finally {
+ log("isMobileOk: F stop hipri");
+ mCs.setEnableFailFastMobileData(DctConstants.DISABLED);
+ mCs.stopUsingNetworkFeature(ConnectivityManager.TYPE_MOBILE,
+ Phone.FEATURE_ENABLE_HIPRI);
+ log("isMobileOk: X result=" + result);
+ }
+ return result;
+ }
+
+ @Override
+ protected Integer doInBackground(Params... params) {
+ return isMobileOk(params[0]);
+ }
+
+ @Override
+ protected void onPostExecute(Integer result) {
+ log("onPostExecute: result=" + result);
+ if ((mParams != null) && (mParams.mCb != null)) {
+ mParams.mCb.onComplete(result);
+ }
+ }
+
+ private String inetAddressesToString(InetAddress[] addresses) {
+ StringBuffer sb = new StringBuffer();
+ boolean firstTime = true;
+ for(InetAddress addr : addresses) {
+ if (firstTime) {
+ firstTime = false;
+ } else {
+ sb.append(",");
+ }
+ sb.append(addr);
+ }
+ return sb.toString();
+ }
+
+ private void printNetworkInfo() {
+ boolean hasIccCard = mTm.hasIccCard();
+ int simState = mTm.getSimState();
+ log("hasIccCard=" + hasIccCard
+ + " simState=" + simState);
+ NetworkInfo[] ni = mCs.getAllNetworkInfo();
+ if (ni != null) {
+ log("ni.length=" + ni.length);
+ for (NetworkInfo netInfo: ni) {
+ log("netInfo=" + netInfo.toString());
+ }
+ } else {
+ log("no network info ni=null");
+ }
+ }
+
+ /**
+ * Sleep for a few seconds then return.
+ * @param seconds
+ */
+ private static void sleep(int seconds) {
+ try {
+ Thread.sleep(seconds * 1000);
+ } catch (InterruptedException e) {
+ e.printStackTrace();
+ }
+ }
+
+ public boolean hasIPv4Address(LinkProperties lp) {
+ return lp.hasIPv4Address();
+ }
+
+ // Not implemented in LinkProperties, do it here.
+ public boolean hasIPv6Address(LinkProperties lp) {
+ for (LinkAddress address : lp.getLinkAddresses()) {
+ if (address.getAddress() instanceof Inet6Address) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ private void log(String s) {
+ Slog.d(ConnectivityService.TAG, "[" + CHECKMP_TAG + "] " + s);
+ }
+ }
+
+ private static final String NOTIFICATION_ID = "CaptivePortal.Notification";
+
+ private void setNotificationVisible(boolean visible, NetworkInfo networkInfo, String url) {
+ log("setNotificationVisible: E visible=" + visible + " ni=" + networkInfo + " url=" + url);
+
+ Resources r = Resources.getSystem();
+ NotificationManager notificationManager = (NotificationManager) mContext
+ .getSystemService(Context.NOTIFICATION_SERVICE);
+
+ if (visible) {
+ CharSequence title;
+ CharSequence details;
+ int icon;
+ switch (networkInfo.getType()) {
+ case ConnectivityManager.TYPE_WIFI:
+ log("setNotificationVisible: TYPE_WIFI");
+ title = r.getString(R.string.wifi_available_sign_in, 0);
+ details = r.getString(R.string.network_available_sign_in_detailed,
+ networkInfo.getExtraInfo());
+ icon = R.drawable.stat_notify_wifi_in_range;
+ break;
+ case ConnectivityManager.TYPE_MOBILE:
+ case ConnectivityManager.TYPE_MOBILE_HIPRI:
+ log("setNotificationVisible: TYPE_MOBILE|HIPRI");
+ title = r.getString(R.string.network_available_sign_in, 0);
+ // TODO: Change this to pull from NetworkInfo once a printable
+ // name has been added to it
+ details = mTelephonyManager.getNetworkOperatorName();
+ icon = R.drawable.stat_notify_rssi_in_range;
+ break;
+ default:
+ log("setNotificationVisible: other type=" + networkInfo.getType());
+ title = r.getString(R.string.network_available_sign_in, 0);
+ details = r.getString(R.string.network_available_sign_in_detailed,
+ networkInfo.getExtraInfo());
+ icon = R.drawable.stat_notify_rssi_in_range;
+ break;
+ }
+
+ Notification notification = new Notification();
+ notification.when = 0;
+ notification.icon = icon;
+ notification.flags = Notification.FLAG_AUTO_CANCEL;
+ Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(url));
+ intent.setFlags(Intent.FLAG_ACTIVITY_BROUGHT_TO_FRONT |
+ Intent.FLAG_ACTIVITY_NEW_TASK);
+ notification.contentIntent = PendingIntent.getActivity(mContext, 0, intent, 0);
+ notification.tickerText = title;
+ notification.setLatestEventInfo(mContext, title, details, notification.contentIntent);
+
+ log("setNotificaitionVisible: notify notificaiton=" + notification);
+ notificationManager.notify(NOTIFICATION_ID, 1, notification);
+ } else {
+ log("setNotificaitionVisible: cancel");
+ notificationManager.cancel(NOTIFICATION_ID, 1);
+ }
+ log("setNotificationVisible: X visible=" + visible + " ni=" + networkInfo + " url=" + url);
+ }
+
+ private String getProvisioningUrl() {
+ String url = mContext.getResources().getString(R.string.mobile_provisioning_url);
+ log("getProvisioningUrl: resource url=" + url);
+
+ // populate the iccid and imei in the provisioning url.
+ if (!TextUtils.isEmpty(url)) {
+ url = String.format(url,
+ mTelephonyManager.getSimSerialNumber() /* ICCID */,
+ mTelephonyManager.getDeviceId() /* IMEI */,
+ mTelephonyManager.getLine1Number() /* Phone numer */);
+ }
+
+ log("getProvisioningUrl: url=" + url);
+ return url;
+ }
}
diff --git a/services/java/com/android/server/am/ActivityManagerService.java b/services/java/com/android/server/am/ActivityManagerService.java
index 72be39b..6425693 100644
--- a/services/java/com/android/server/am/ActivityManagerService.java
+++ b/services/java/com/android/server/am/ActivityManagerService.java
@@ -36,6 +36,7 @@
import com.android.internal.os.TransferPipe;
import com.android.internal.util.FastPrintWriter;
import com.android.internal.util.FastXmlSerializer;
+import com.android.internal.util.MemInfoReader;
import com.android.server.AppOpsService;
import com.android.server.AttributeCache;
import com.android.server.IntentResolver;
@@ -2989,6 +2990,17 @@
}
@Override
+ public void reportActivityFullyDrawn(IBinder token) {
+ synchronized (this) {
+ ActivityRecord r = ActivityRecord.isInStackLocked(token);
+ if (r == null) {
+ return;
+ }
+ r.reportFullyDrawnLocked();
+ }
+ }
+
+ @Override
public void setRequestedOrientation(IBinder token, int requestedOrientation) {
synchronized (this) {
ActivityRecord r = ActivityRecord.isInStackLocked(token);
@@ -11100,6 +11112,7 @@
new ArrayList[DUMP_MEM_OOM_LABEL.length];
long totalPss = 0;
+ long cachedPss = 0;
Debug.MemoryInfo mi = null;
for (int i = procs.size() - 1 ; i >= 0 ; i--) {
@@ -11108,7 +11121,7 @@
int oomAdj;
synchronized (this) {
thread = r.thread;
- oomAdj = r.setAdj;
+ oomAdj = r.getSetAdjWithServices();
}
if (thread != null) {
if (!isCheckinRequest && dumpDetails) {
@@ -11139,7 +11152,7 @@
final long myTotalPss = mi.getTotalPss();
synchronized (this) {
- if (r.thread != null && oomAdj == r.setAdj) {
+ if (r.thread != null && oomAdj == r.getSetAdjWithServices()) {
// Record this for posterity if the process has been stable.
r.baseProcessTracker.addPss(myTotalPss, true);
}
@@ -11160,6 +11173,10 @@
otherPss -= mem;
}
+ if (oomAdj >= ProcessList.CACHED_APP_MIN_ADJ) {
+ cachedPss += myTotalPss;
+ }
+
for (int oomIndex=0; oomIndex<oomPss.length; oomIndex++) {
if (r.setAdj <= DUMP_MEM_OOM_ADJ[oomIndex]
|| oomIndex == (oomPss.length-1)) {
@@ -11274,7 +11291,14 @@
dumpMemItems(out, " ", catMems, true);
}
pw.println();
- pw.print("Total PSS: "); pw.print(totalPss); pw.println(" kB");
+ if (!brief) {
+ MemInfoReader memInfo = new MemInfoReader();
+ memInfo.readMemInfo();
+ pw.print("Total RAM: "); pw.print(memInfo.getTotalSize()/1024); pw.println(" kB");
+ pw.print(" Free RAM: "); pw.print(cachedPss + (memInfo.getCachedSize()/1024)
+ + (memInfo.getFreeSize()/1024)); pw.println(" kB");
+ }
+ pw.print(" Used PSS: "); pw.print(totalPss - cachedPss); pw.println(" kB");
if (!brief) {
final int[] SINGLE_LONG_FORMAT = new int[] {
Process.PROC_SPACE_TERM|Process.PROC_OUT_LONG
@@ -11295,10 +11319,12 @@
Process.readProcFile("/sys/kernel/mm/ksm/pages_volatile",
SINGLE_LONG_FORMAT, null, longOut, null);
long voltile = longOut[0] * ProcessList.PAGE_SIZE / 1024;
- pw.print(" KSM: "); pw.print(sharing); pw.print(" kB saved from shared ");
- pw.print(shared); pw.println(" kB");
- pw.print(" "); pw.print(unshared); pw.print(" kB unshared; ");
- pw.print(voltile); pw.println(" kB volatile");
+ if (sharing != 0 || shared != 0 || unshared != 0 || voltile != 0) {
+ pw.print(" KSM: "); pw.print(sharing); pw.print(" kB saved from shared ");
+ pw.print(shared); pw.println(" kB");
+ pw.print(" "); pw.print(unshared); pw.print(" kB unshared; ");
+ pw.print(voltile); pw.println(" kB volatile");
+ }
}
}
}
@@ -13469,6 +13495,7 @@
// infinite recursion.
app.adjSeq = mAdjSeq;
app.curRawAdj = app.nonStoppingAdj = adj;
+ app.hasStartedServices = false;
if (mBackupTarget != null && app == mBackupTarget.app) {
// If possible we want to avoid killing apps while they're being backed up
@@ -13489,6 +13516,7 @@
while (jt.hasNext() && adj > ProcessList.FOREGROUND_APP_ADJ) {
ServiceRecord s = jt.next();
if (s.startRequested) {
+ app.hasStartedServices = true;
if (app.hasShownUi && app != mHomeProcess) {
// If this process has shown some UI, let it immediately
// go to the LRU list because it may be pretty heavy with
@@ -14333,7 +14361,7 @@
emptyProcessLimit = 1;
cachedProcessLimit = 0;
} else {
- emptyProcessLimit = (mProcessLimit*2)/3;
+ emptyProcessLimit = ProcessList.computeEmptyProcessLimit(mProcessLimit);
cachedProcessLimit = mProcessLimit - emptyProcessLimit;
}
diff --git a/services/java/com/android/server/am/ActivityRecord.java b/services/java/com/android/server/am/ActivityRecord.java
index 973b9aa..83016df 100644
--- a/services/java/com/android/server/am/ActivityRecord.java
+++ b/services/java/com/android/server/am/ActivityRecord.java
@@ -16,6 +16,7 @@
package com.android.server.am;
+import android.os.Trace;
import com.android.internal.app.ResolverActivity;
import com.android.server.AttributeCache;
import com.android.server.am.ActivityStack.ActivityState;
@@ -92,7 +93,8 @@
int windowFlags; // custom window flags for preview window.
TaskRecord task; // the task this is in.
ThumbnailHolder thumbHolder; // where our thumbnails should go.
- long launchTime; // when we starting launching this activity
+ long displayStartTime; // when we started launching this activity
+ long fullyDrawnStartTime; // when we started launching this activity
long startTime; // last time this activity was started
long lastVisibleTime; // last time this activity became visible
long cpuTimeAtResume; // the cpu time of host process at the time of resuming activity
@@ -247,10 +249,10 @@
pw.print(" desc="); pw.print(thumbHolder.lastDescription);
}
pw.println();
- if (launchTime != 0 || startTime != 0) {
- pw.print(prefix); pw.print("launchTime=");
- if (launchTime == 0) pw.print("0");
- else TimeUtils.formatDuration(launchTime, now, pw);
+ if (displayStartTime != 0 || startTime != 0) {
+ pw.print(prefix); pw.print("displayStartTime=");
+ if (displayStartTime == 0) pw.print("0");
+ else TimeUtils.formatDuration(displayStartTime, now, pw);
pw.print(" startTime=");
if (startTime == 0) pw.print("0");
else TimeUtils.formatDuration(startTime, now, pw);
@@ -807,37 +809,77 @@
}
}
+ public void reportFullyDrawnLocked() {
+ final long curTime = SystemClock.uptimeMillis();
+ if (displayStartTime != 0) {
+ reportLaunchTimeLocked(curTime);
+ }
+ if (fullyDrawnStartTime != 0) {
+ final ActivityStack stack = task.stack;
+ final long thisTime = curTime - fullyDrawnStartTime;
+ final long totalTime = stack.mFullyDrawnStartTime != 0
+ ? (curTime - stack.mFullyDrawnStartTime) : thisTime;
+ if (ActivityManagerService.SHOW_ACTIVITY_START_TIME) {
+ Trace.traceCounter(Trace.TRACE_TAG_ACTIVITY_MANAGER, "fully-drawn", (int)totalTime);
+ EventLog.writeEvent(EventLogTags.AM_ACTIVITY_FULLY_DRAWN_TIME,
+ userId, System.identityHashCode(this), shortComponentName,
+ thisTime, totalTime);
+ StringBuilder sb = service.mStringBuilder;
+ sb.setLength(0);
+ sb.append("Fully drawn ");
+ sb.append(shortComponentName);
+ sb.append(": ");
+ TimeUtils.formatDuration(thisTime, sb);
+ if (thisTime != totalTime) {
+ sb.append(" (total ");
+ TimeUtils.formatDuration(totalTime, sb);
+ sb.append(")");
+ }
+ Log.i(ActivityManagerService.TAG, sb.toString());
+ }
+ if (totalTime > 0) {
+ service.mUsageStatsService.noteFullyDrawnTime(realActivity, (int) totalTime);
+ }
+ fullyDrawnStartTime = 0;
+ stack.mFullyDrawnStartTime = 0;
+ }
+ }
+
+ private void reportLaunchTimeLocked(final long curTime) {
+ final ActivityStack stack = task.stack;
+ final long thisTime = curTime - displayStartTime;
+ final long totalTime = stack.mLaunchStartTime != 0
+ ? (curTime - stack.mLaunchStartTime) : thisTime;
+ if (ActivityManagerService.SHOW_ACTIVITY_START_TIME) {
+ Trace.traceCounter(Trace.TRACE_TAG_ACTIVITY_MANAGER, "launch", (int)totalTime);
+ EventLog.writeEvent(EventLogTags.AM_ACTIVITY_LAUNCH_TIME,
+ userId, System.identityHashCode(this), shortComponentName,
+ thisTime, totalTime);
+ StringBuilder sb = service.mStringBuilder;
+ sb.setLength(0);
+ sb.append("Displayed ");
+ sb.append(shortComponentName);
+ sb.append(": ");
+ TimeUtils.formatDuration(thisTime, sb);
+ if (thisTime != totalTime) {
+ sb.append(" (total ");
+ TimeUtils.formatDuration(totalTime, sb);
+ sb.append(")");
+ }
+ Log.i(ActivityManagerService.TAG, sb.toString());
+ }
+ mStackSupervisor.reportActivityLaunchedLocked(false, this, thisTime, totalTime);
+ if (totalTime > 0) {
+ service.mUsageStatsService.noteLaunchTime(realActivity, (int)totalTime);
+ }
+ displayStartTime = 0;
+ stack.mLaunchStartTime = 0;
+ }
+
public void windowsDrawn() {
synchronized(service) {
- if (launchTime != 0) {
- final ActivityStack stack = task.stack;
- final long curTime = SystemClock.uptimeMillis();
- final long thisTime = curTime - launchTime;
- final long totalTime = stack.mInitialStartTime != 0
- ? (curTime - stack.mInitialStartTime) : thisTime;
- if (ActivityManagerService.SHOW_ACTIVITY_START_TIME) {
- EventLog.writeEvent(EventLogTags.AM_ACTIVITY_LAUNCH_TIME,
- userId, System.identityHashCode(this), shortComponentName,
- thisTime, totalTime);
- StringBuilder sb = service.mStringBuilder;
- sb.setLength(0);
- sb.append("Displayed ");
- sb.append(shortComponentName);
- sb.append(": ");
- TimeUtils.formatDuration(thisTime, sb);
- if (thisTime != totalTime) {
- sb.append(" (total ");
- TimeUtils.formatDuration(totalTime, sb);
- sb.append(")");
- }
- Log.i(ActivityManagerService.TAG, sb.toString());
- }
- mStackSupervisor.reportActivityLaunchedLocked(false, this, thisTime, totalTime);
- if (totalTime > 0) {
- service.mUsageStatsService.noteLaunchTime(realActivity, (int)totalTime);
- }
- launchTime = 0;
- stack.mInitialStartTime = 0;
+ if (displayStartTime != 0) {
+ reportLaunchTimeLocked(SystemClock.uptimeMillis());
}
startTime = 0;
finishLaunchTickingLocked();
diff --git a/services/java/com/android/server/am/ActivityStack.java b/services/java/com/android/server/am/ActivityStack.java
index 8e8bb55..9013b4a 100644
--- a/services/java/com/android/server/am/ActivityStack.java
+++ b/services/java/com/android/server/am/ActivityStack.java
@@ -205,7 +205,8 @@
*/
boolean mConfigWillChange;
- long mInitialStartTime = 0;
+ long mLaunchStartTime = 0;
+ long mFullyDrawnStartTime = 0;
/**
* Save the most recent screenshot for reuse. This keeps Recents from taking two identical
@@ -595,16 +596,20 @@
}
void setLaunchTime(ActivityRecord r) {
- if (r.launchTime == 0) {
- r.launchTime = SystemClock.uptimeMillis();
- if (mInitialStartTime == 0) {
- mInitialStartTime = r.launchTime;
+ if (r.displayStartTime == 0) {
+ r.fullyDrawnStartTime = r.displayStartTime = SystemClock.uptimeMillis();
+ if (mLaunchStartTime == 0) {
+ mLaunchStartTime = mFullyDrawnStartTime = r.displayStartTime;
}
- } else if (mInitialStartTime == 0) {
- mInitialStartTime = SystemClock.uptimeMillis();
+ } else if (mLaunchStartTime == 0) {
+ mLaunchStartTime = mFullyDrawnStartTime = SystemClock.uptimeMillis();
}
}
+ void clearLaunchTime(ActivityRecord r) {
+ r.displayStartTime = r.fullyDrawnStartTime = 0;
+ }
+
void stopIfSleepingLocked() {
if (mLaunchingActivity.isHeld()) {
if (VALIDATE_WAKE_LOCK_CALLER && Binder.getCallingUid() != Process.myUid()) {
@@ -710,6 +715,7 @@
mLastPausedActivity = prev;
prev.state = ActivityState.PAUSING;
prev.task.touchActiveTime();
+ clearLaunchTime(prev);
prev.updateThumbnail(screenshotActivities(prev), null);
mService.updateCpuStats();
diff --git a/services/java/com/android/server/am/EventLogTags.logtags b/services/java/com/android/server/am/EventLogTags.logtags
index f784861..f4bf9f3 100644
--- a/services/java/com/android/server/am/EventLogTags.logtags
+++ b/services/java/com/android/server/am/EventLogTags.logtags
@@ -86,3 +86,6 @@
# User switched
30041 am_switch_user (id|1|5)
+
+# Activity fully drawn time
+30042 am_activity_fully_drawn_time (User|1|5),(Token|1|5),(Component Name|3),(time|2|3)
diff --git a/services/java/com/android/server/am/ProcessList.java b/services/java/com/android/server/am/ProcessList.java
index 7ea4a32..5585ac8 100644
--- a/services/java/com/android/server/am/ProcessList.java
+++ b/services/java/com/android/server/am/ProcessList.java
@@ -98,21 +98,30 @@
// without empty apps being able to push them out of memory.
static final int MIN_CACHED_APPS = 2;
- // The maximum number of cached processes we will keep around before
- // killing them; this is just a control to not let us go too crazy with
- // keeping around processes on devices with large amounts of RAM.
+ // The maximum number of cached processes we will keep around before killing them.
+ // NOTE: this constant is *only* a control to not let us go too crazy with
+ // keeping around processes on devices with large amounts of RAM. For devices that
+ // are tighter on RAM, the out of memory killer is responsible for killing background
+ // processes as RAM is needed, and we should *never* be relying on this limit to
+ // kill them. Also note that this limit only applies to cached background processes;
+ // we have no limit on the number of service, visible, foreground, or other such
+ // processes and the number of those processes does not count against the cached
+ // process limit.
static final int MAX_CACHED_APPS = 24;
// We allow empty processes to stick around for at most 30 minutes.
static final long MAX_EMPTY_TIME = 30*60*1000;
- // The number of cached at which we don't consider it necessary to do
- // memory trimming.
- static final int TRIM_CACHED_APPS = 3;
+ // The maximum number of empty app processes we will let sit around.
+ private static final int MAX_EMPTY_APPS = computeEmptyProcessLimit(MAX_CACHED_APPS);
// The number of empty apps at which we don't consider it necessary to do
// memory trimming.
- static final int TRIM_EMPTY_APPS = 3;
+ static final int TRIM_EMPTY_APPS = MAX_EMPTY_APPS/2;
+
+ // The number of cached at which we don't consider it necessary to do
+ // memory trimming.
+ static final int TRIM_CACHED_APPS = (MAX_CACHED_APPS-MAX_EMPTY_APPS)/2;
// Threshold of number of cached+empty where we consider memory critical.
static final int TRIM_CRITICAL_THRESHOLD = 3;
@@ -234,6 +243,10 @@
// HC: 8192,10240,12288,14336,16384,20480
}
+ public static int computeEmptyProcessLimit(int totalProcessLimit) {
+ return (totalProcessLimit*2)/3;
+ }
+
long getMemLevel(int adjustment) {
for (int i=0; i<mOomAdj.length; i++) {
if (adjustment <= mOomAdj[i]) {
diff --git a/services/java/com/android/server/am/ProcessRecord.java b/services/java/com/android/server/am/ProcessRecord.java
index 365009d..1671d24 100644
--- a/services/java/com/android/server/am/ProcessRecord.java
+++ b/services/java/com/android/server/am/ProcessRecord.java
@@ -81,6 +81,7 @@
boolean setIsForeground; // Running foreground UI when last set?
boolean hasActivities; // Are there any activities running in this process?
boolean hasClientActivities; // Are there any client services with activities?
+ boolean hasStartedServices; // Are there any started services running in this process?
boolean foregroundServices; // Running any services that are foreground?
boolean foregroundActivities; // Running any activities that are foreground?
boolean systemNoUi; // This is a system process, but not currently showing UI.
@@ -246,6 +247,9 @@
pw.print(" hasClientActivities="); pw.print(hasClientActivities);
pw.print(" foregroundActivities="); pw.println(foregroundActivities);
}
+ if (hasStartedServices) {
+ pw.print(prefix); pw.print("hasStartedServices="); pw.println(hasStartedServices);
+ }
if (!keeping) {
long wtime;
synchronized (batteryStats.getBatteryStats()) {
@@ -454,10 +458,17 @@
return false;
}
+ public int getSetAdjWithServices() {
+ if (setAdj >= ProcessList.CACHED_APP_MIN_ADJ && hasStartedServices) {
+ return ProcessList.SERVICE_B_ADJ;
+ }
+ return setAdj;
+ }
+
public void setProcessTrackerState(ProcessRecord TOP_APP, int memFactor, long now,
ProcessList plist) {
int state = this == TOP_APP ? ProcessTracker.STATE_TOP
- : plist.adjToTrackedState(setAdj);
+ : plist.adjToTrackedState(getSetAdjWithServices());
baseProcessTracker.setState(state, memFactor, now, pkgList);
}
diff --git a/services/java/com/android/server/am/ProcessTracker.java b/services/java/com/android/server/am/ProcessTracker.java
index 7985df48..fbdbdd9 100644
--- a/services/java/com/android/server/am/ProcessTracker.java
+++ b/services/java/com/android/server/am/ProcessTracker.java
@@ -46,6 +46,7 @@
public final class ProcessTracker {
static final String TAG = "ProcessTracker";
+ static final boolean DEBUG = false;
public static final int STATE_NOTHING = -1;
public static final int STATE_PERSISTENT = 0;
@@ -239,6 +240,18 @@
return pnew;
}
+ void resetSafely(long now) {
+ mDurationsTable = null;
+ mDurationsTableSize = 0;
+ mStartTime = now;
+ mLastPssState = STATE_NOTHING;
+ mLastPssTime = 0;
+ mPssTable = null;
+ mPssTableSize = 0;
+ mNumExcessiveWake = 0;
+ mNumExcessiveCpu = 0;
+ }
+
void writeToParcel(Parcel out, long now) {
commitStateTime(now);
out.writeInt(mMultiPackage ? 1 : 0);
@@ -272,8 +285,11 @@
return table;
}
- boolean readFromParcel(Parcel in) {
- mMultiPackage = in.readInt() != 0;
+ boolean readFromParcel(Parcel in, boolean fully) {
+ boolean multiPackage = in.readInt() != 0;
+ if (fully) {
+ mMultiPackage = multiPackage;
+ }
mDurationsTable = readTable(in, "durations");
if (mDurationsTable == null) {
return false;
@@ -463,6 +479,14 @@
int mExecState = STATE_NOTHING;
long mExecStartTime;
+ void resetSafely(long now) {
+ for (int i=0; i<ADJ_COUNT; i++) {
+ mStartedDurations[i] = mBoundDurations[i] = mExecDurations[i] = 0;
+ }
+ mStartedCount = mBoundCount = mExecCount = 0;
+ mStartedStartTime = mBoundStartTime = mExecStartTime = now;
+ }
+
void writeToParcel(Parcel out, long now) {
if (mStartedState != STATE_NOTHING) {
mStartedDurations[mStartedState] += now - mStartedStartTime;
@@ -571,9 +595,47 @@
}
void reset() {
- mTimePeriodStart = mTimePeriodEnd = System.currentTimeMillis();
+ resetCommon();
mPackages.getMap().clear();
mProcesses.getMap().clear();
+ mMemFactor = STATE_NOTHING;
+ mStartTime = 0;
+ }
+
+ void resetSafely() {
+ resetCommon();
+ long now = SystemClock.uptimeMillis();
+ ArrayMap<String, SparseArray<ProcessState>> procMap = mProcesses.getMap();
+ final int NPROC = procMap.size();
+ for (int ip=0; ip<NPROC; ip++) {
+ SparseArray<ProcessState> uids = procMap.valueAt(ip);
+ final int NUID = uids.size();
+ for (int iu=0; iu<NUID; iu++) {
+ uids.valueAt(iu).resetSafely(now);
+ }
+ }
+ ArrayMap<String, SparseArray<PackageState>> pkgMap = mPackages.getMap();
+ final int NPKG = pkgMap.size();
+ for (int ip=0; ip<NPKG; ip++) {
+ SparseArray<PackageState> uids = pkgMap.valueAt(ip);
+ final int NUID = uids.size();
+ for (int iu=0; iu<NUID; iu++) {
+ PackageState pkgState = uids.valueAt(iu);
+ final int NPROCS = pkgState.mProcesses.size();
+ for (int iproc=0; iproc<NPROCS; iproc++) {
+ pkgState.mProcesses.valueAt(iproc).resetSafely(now);
+ }
+ final int NSRVS = pkgState.mServices.size();
+ for (int isvc=0; isvc<NSRVS; isvc++) {
+ pkgState.mServices.valueAt(isvc).resetSafely(now);
+ }
+ }
+ }
+ mStartTime = SystemClock.uptimeMillis();
+ }
+
+ private void resetCommon() {
+ mTimePeriodStart = mTimePeriodEnd = System.currentTimeMillis();
mLongs.clear();
mLongs.add(new long[LONGS_SIZE]);
mNextLong = 0;
@@ -671,7 +733,12 @@
}
void readFromParcel(Parcel in) {
- reset();
+ final boolean hadData = mPackages.getMap().size() > 0
+ || mProcesses.getMap().size() > 0;
+ if (hadData) {
+ resetSafely();
+ }
+
if (!readCheckedInt(in, MAGIC, "magic number")) {
return;
}
@@ -740,14 +807,24 @@
Slog.w(TAG, "Ignoring existing stats; bad process package name");
return;
}
- ProcessState proc = new ProcessState(this, pkgName, uid, procName);
- if (!proc.readFromParcel(in)) {
- return;
+ ProcessState proc = hadData ? mProcesses.get(procName, uid) : null;
+ if (proc != null) {
+ if (!proc.readFromParcel(in, false)) {
+ return;
+ }
+ } else {
+ proc = new ProcessState(this, pkgName, uid, procName);
+ if (!proc.readFromParcel(in, true)) {
+ return;
+ }
}
+ if (DEBUG) Slog.d(TAG, "Adding process: " + procName + " " + uid + " " + proc);
mProcesses.put(procName, uid, proc);
}
}
+ if (DEBUG) Slog.d(TAG, "Read " + mProcesses.getMap().size() + " processes");
+
int NPKG = in.readInt();
if (NPKG < 0) {
Slog.w(TAG, "Ignoring existing stats; bad package count: " + NPKG);
@@ -773,6 +850,7 @@
return;
}
PackageState pkgState = new PackageState(uid);
+ mPackages.put(pkgName, uid, pkgState);
int NPROCS = in.readInt();
if (NPROCS < 0) {
Slog.w(TAG, "Ignoring existing stats; bad package process count: " + NPROCS);
@@ -786,21 +864,33 @@
return;
}
int hasProc = in.readInt();
+ if (DEBUG) Slog.d(TAG, "Reading package " + pkgName + " " + uid
+ + " process " + procName + " hasProc=" + hasProc);
if (hasProc != 0) {
// The process for this package is unique to the package; we
// need to load it. We don't need to do anything about it if
// it is not unique because if someone later looks for it
// they will find and use it from the global procs.
ProcessState commonProc = mProcesses.get(procName, uid);
+ if (DEBUG) Slog.d(TAG, "Got common proc " + procName + " " + uid
+ + ": " + commonProc);
if (commonProc == null) {
Slog.w(TAG, "Ignoring existing stats; no common proc: " + procName);
return;
}
- ProcessState proc = new ProcessState(commonProc, pkgName, uid,
- procName, 0);
- if (!proc.readFromParcel(in)) {
- return;
+ ProcessState proc = hadData ? pkgState.mProcesses.get(procName) : null;
+ if (proc != null) {
+ if (!proc.readFromParcel(in, false)) {
+ return;
+ }
+ } else {
+ proc = new ProcessState(commonProc, pkgName, uid, procName, 0);
+ if (!proc.readFromParcel(in, true)) {
+ return;
+ }
}
+ if (DEBUG) Slog.d(TAG, "Adding package " + pkgName + " process: "
+ + procName + " " + uid + " " + proc);
pkgState.mProcesses.put(procName, proc);
}
}
@@ -816,14 +906,21 @@
Slog.w(TAG, "Ignoring existing stats; bad package service name");
return;
}
- ServiceState serv = new ServiceState();
+ ServiceState serv = hadData ? pkgState.mServices.get(serviceName) : null;
+ if (serv == null) {
+ serv = new ServiceState();
+ }
if (!serv.readFromParcel(in)) {
return;
}
+ if (DEBUG) Slog.d(TAG, "Adding package " + pkgName + " service: "
+ + serviceName + " " + uid + " " + serv);
pkgState.mServices.put(serviceName, serv);
}
}
}
+
+ if (DEBUG) Slog.d(TAG, "Successfully read procstats!");
}
int addLongData(int index, int type, int num) {
@@ -949,7 +1046,7 @@
return ps;
}
- void dump(PrintWriter pw, String reqPackage, boolean dumpAll) {
+ void dumpLocked(PrintWriter pw, String reqPackage, boolean dumpAll) {
final long now = SystemClock.uptimeMillis();
ArrayMap<String, SparseArray<PackageState>> pkgMap = mPackages.getMap();
boolean printedHeader = false;
@@ -1097,7 +1194,7 @@
return outProcs;
}
- void dumpCheckin(PrintWriter pw, String reqPackage) {
+ void dumpCheckinLocked(PrintWriter pw, String reqPackage) {
final long now = SystemClock.uptimeMillis();
ArrayMap<String, SparseArray<PackageState>> pkgMap = mPackages.getMap();
pw.println("vers,1");
@@ -1741,7 +1838,7 @@
}
}
- boolean dumpFilteredProcessesCsv(PrintWriter pw, String header,
+ boolean dumpFilteredProcessesCsvLocked(PrintWriter pw, String header,
boolean sepScreenStates, int[] screenStates, boolean sepMemStates, int[] memStates,
boolean sepProcStates, int[] procStates, long now, String reqPackage) {
ArrayList<ProcessState> procs = mState.collectProcessesLocked(screenStates, memStates,
@@ -1883,6 +1980,7 @@
pw.println(" service, home, prev, cached");
pw.println(" --reset: reset the stats, clearing all current data.");
pw.println(" --write: write current in-memory stats to disk.");
+ pw.println(" --read: replace current stats with last-written stats.");
pw.println(" -a: print everything.");
pw.println(" -h: print this help text.");
pw.println(" <package.name>: optional name of package to filter output by.");
@@ -1961,13 +2059,17 @@
}
csvSepProcStats = sep[0];
} else if ("--reset".equals(arg)) {
- mState.reset();
+ mState.resetSafely();
pw.println("Process stats reset.");
return;
} else if ("--write".equals(arg)) {
writeStateSyncLocked();
pw.println("Process stats written.");
return;
+ } else if ("--read".equals(arg)) {
+ readLocked();
+ pw.println("Process stats read.");
+ return;
} else if ("-h".equals(arg)) {
dumpHelp(pw);
return;
@@ -2016,18 +2118,18 @@
}
}
pw.println();
- dumpFilteredProcessesCsv(pw, null,
+ dumpFilteredProcessesCsvLocked(pw, null,
csvSepScreenStats, csvScreenStats, csvSepMemStats, csvMemStats,
csvSepProcStats, csvProcStats, now, reqPackage);
/*
- dumpFilteredProcessesCsv(pw, "Processes running while critical mem:",
+ dumpFilteredProcessesCsvLocked(pw, "Processes running while critical mem:",
false, new int[] {ADJ_SCREEN_OFF, ADJ_SCREEN_ON},
true, new int[] {ADJ_MEM_FACTOR_CRITICAL},
true, new int[] {STATE_PERSISTENT, STATE_TOP, STATE_FOREGROUND, STATE_VISIBLE,
STATE_PERCEPTIBLE, STATE_BACKUP, STATE_SERVICE, STATE_HOME,
STATE_PREVIOUS, STATE_CACHED},
now, reqPackage);
- dumpFilteredProcessesCsv(pw, "Processes running over all mem:",
+ dumpFilteredProcessesCsvLocked(pw, "Processes running over all mem:",
false, new int[] {ADJ_SCREEN_OFF, ADJ_SCREEN_ON},
false, new int[] {ADJ_MEM_FACTOR_CRITICAL, ADJ_MEM_FACTOR_LOW,
ADJ_MEM_FACTOR_MODERATE, ADJ_MEM_FACTOR_MODERATE},
@@ -2040,9 +2142,9 @@
}
if (isCheckin) {
- mState.dumpCheckin(pw, reqPackage);
+ mState.dumpCheckinLocked(pw, reqPackage);
} else {
- mState.dump(pw, reqPackage, dumpAll);
+ mState.dumpLocked(pw, reqPackage, dumpAll);
}
}
}
diff --git a/services/java/com/android/server/am/UsageStatsService.java b/services/java/com/android/server/am/UsageStatsService.java
index f799535..e96d8b1 100644
--- a/services/java/com/android/server/am/UsageStatsService.java
+++ b/services/java/com/android/server/am/UsageStatsService.java
@@ -77,7 +77,7 @@
private static final String TAG = "UsageStats";
// Current on-disk Parcel version
- private static final int VERSION = 1007;
+ private static final int VERSION = 1008;
private static final int CHECKIN_VERSION = 4;
@@ -166,8 +166,10 @@
}
private class PkgUsageStatsExtended {
- final HashMap<String, TimeStats> mLaunchTimes
- = new HashMap<String, TimeStats>();
+ final ArrayMap<String, TimeStats> mLaunchTimes
+ = new ArrayMap<String, TimeStats>();
+ final ArrayMap<String, TimeStats> mFullyDrawnTimes
+ = new ArrayMap<String, TimeStats>();
int mLaunchCount;
long mUsageTime;
long mPausedTime;
@@ -184,14 +186,25 @@
if (localLOGV) Slog.v(TAG, "Launch count: " + mLaunchCount
+ ", Usage time:" + mUsageTime);
- final int numTimeStats = in.readInt();
- if (localLOGV) Slog.v(TAG, "Reading comps: " + numTimeStats);
- for (int i=0; i<numTimeStats; i++) {
+ final int numLaunchTimeStats = in.readInt();
+ if (localLOGV) Slog.v(TAG, "Reading launch times: " + numLaunchTimeStats);
+ mLaunchTimes.ensureCapacity(numLaunchTimeStats);
+ for (int i=0; i<numLaunchTimeStats; i++) {
String comp = in.readString();
if (localLOGV) Slog.v(TAG, "Component: " + comp);
TimeStats times = new TimeStats(in);
mLaunchTimes.put(comp, times);
}
+
+ final int numFullyDrawnTimeStats = in.readInt();
+ if (localLOGV) Slog.v(TAG, "Reading fully drawn times: " + numFullyDrawnTimeStats);
+ mFullyDrawnTimes.ensureCapacity(numFullyDrawnTimeStats);
+ for (int i=0; i<numFullyDrawnTimeStats; i++) {
+ String comp = in.readString();
+ if (localLOGV) Slog.v(TAG, "Component: " + comp);
+ TimeStats times = new TimeStats(in);
+ mFullyDrawnTimes.put(comp, times);
+ }
}
void updateResume(String comp, boolean launched) {
@@ -223,23 +236,36 @@
}
times.add(millis);
}
-
+
+ void addFullyDrawnTime(String comp, int millis) {
+ TimeStats times = mFullyDrawnTimes.get(comp);
+ if (times == null) {
+ times = new TimeStats();
+ mFullyDrawnTimes.put(comp, times);
+ }
+ times.add(millis);
+ }
+
void writeToParcel(Parcel out) {
out.writeInt(mLaunchCount);
out.writeLong(mUsageTime);
- final int numTimeStats = mLaunchTimes.size();
- out.writeInt(numTimeStats);
- if (numTimeStats > 0) {
- for (Map.Entry<String, TimeStats> ent : mLaunchTimes.entrySet()) {
- out.writeString(ent.getKey());
- TimeStats times = ent.getValue();
- times.writeToParcel(out);
- }
+ final int numLaunchTimeStats = mLaunchTimes.size();
+ out.writeInt(numLaunchTimeStats);
+ for (int i=0; i<numLaunchTimeStats; i++) {
+ out.writeString(mLaunchTimes.keyAt(i));
+ mLaunchTimes.valueAt(i).writeToParcel(out);
+ }
+ final int numFullyDrawnTimeStats = mFullyDrawnTimes.size();
+ out.writeInt(numFullyDrawnTimeStats);
+ for (int i=0; i<numFullyDrawnTimeStats; i++) {
+ out.writeString(mFullyDrawnTimes.keyAt(i));
+ mFullyDrawnTimes.valueAt(i).writeToParcel(out);
}
}
void clear() {
mLaunchTimes.clear();
+ mFullyDrawnTimes.clear();
mLaunchCount = 0;
mUsageTime = 0;
}
@@ -783,6 +809,25 @@
}
}
+ public void noteFullyDrawnTime(ComponentName componentName, int millis) {
+ enforceCallingPermission();
+ String pkgName;
+ if ((componentName == null) ||
+ ((pkgName = componentName.getPackageName()) == null)) {
+ return;
+ }
+
+ // Persist current data to file if needed.
+ writeStatsToFile(false, false);
+
+ synchronized (mStatsLock) {
+ PkgUsageStatsExtended pus = mStats.get(pkgName);
+ if (pus != null) {
+ pus.addFullyDrawnTime(componentName.getClassName(), millis);
+ }
+ }
+ }
+
public void enforceCallingPermission() {
if (Binder.getCallingPid() == Process.myPid()) {
return;
@@ -935,29 +980,33 @@
sb.append(',');
sb.append(pus.mUsageTime);
sb.append('\n');
- final int NC = pus.mLaunchTimes.size();
- if (NC > 0) {
- for (Map.Entry<String, TimeStats> ent : pus.mLaunchTimes.entrySet()) {
- sb.append("A:");
- String activity = ent.getKey();
- if (activity.startsWith(pkgName)) {
- sb.append('*');
- sb.append(activity.substring(
- pkgName.length(), activity.length()));
- } else {
- sb.append(activity);
- }
- TimeStats times = ent.getValue();
- sb.append(',');
- sb.append(times.count);
- for (int i=0; i<NUM_LAUNCH_TIME_BINS; i++) {
- sb.append(",");
- sb.append(times.times[i]);
- }
- sb.append('\n');
+ final int NLT = pus.mLaunchTimes.size();
+ for (int i=0; i<NLT; i++) {
+ sb.append("A:");
+ String activity = pus.mLaunchTimes.keyAt(i);
+ sb.append(activity);
+ TimeStats times = pus.mLaunchTimes.valueAt(i);
+ sb.append(',');
+ sb.append(times.count);
+ for (int j=0; j<NUM_LAUNCH_TIME_BINS; j++) {
+ sb.append(",");
+ sb.append(times.times[j]);
}
+ sb.append('\n');
}
-
+ final int NFDT = pus.mFullyDrawnTimes.size();
+ for (int i=0; i<NFDT; i++) {
+ sb.append("A:");
+ String activity = pus.mFullyDrawnTimes.keyAt(i);
+ sb.append(activity);
+ TimeStats times = pus.mFullyDrawnTimes.valueAt(i);
+ for (int j=0; j<NUM_LAUNCH_TIME_BINS; j++) {
+ sb.append(",");
+ sb.append(times.times[j]);
+ }
+ sb.append('\n');
+ }
+
} else {
sb.append(" ");
sb.append(pkgName);
@@ -967,36 +1016,68 @@
sb.append(pus.mUsageTime);
sb.append(" ms");
sb.append('\n');
- final int NC = pus.mLaunchTimes.size();
- if (NC > 0) {
- for (Map.Entry<String, TimeStats> ent : pus.mLaunchTimes.entrySet()) {
- sb.append(" ");
- sb.append(ent.getKey());
- TimeStats times = ent.getValue();
- sb.append(": ");
- sb.append(times.count);
- sb.append(" starts");
- int lastBin = 0;
- for (int i=0; i<NUM_LAUNCH_TIME_BINS-1; i++) {
- if (times.times[i] != 0) {
- sb.append(", ");
- sb.append(lastBin);
- sb.append('-');
- sb.append(LAUNCH_TIME_BINS[i]);
- sb.append("ms=");
- sb.append(times.times[i]);
- }
- lastBin = LAUNCH_TIME_BINS[i];
- }
- if (times.times[NUM_LAUNCH_TIME_BINS-1] != 0) {
+ final int NLT = pus.mLaunchTimes.size();
+ for (int i=0; i<NLT; i++) {
+ sb.append(" ");
+ sb.append(pus.mLaunchTimes.keyAt(i));
+ TimeStats times = pus.mLaunchTimes.valueAt(i);
+ sb.append(": ");
+ sb.append(times.count);
+ sb.append(" starts");
+ int lastBin = 0;
+ for (int j=0; j<NUM_LAUNCH_TIME_BINS-1; j++) {
+ if (times.times[j] != 0) {
sb.append(", ");
- sb.append(">=");
sb.append(lastBin);
+ sb.append('-');
+ sb.append(LAUNCH_TIME_BINS[j]);
sb.append("ms=");
- sb.append(times.times[NUM_LAUNCH_TIME_BINS-1]);
+ sb.append(times.times[j]);
}
- sb.append('\n');
+ lastBin = LAUNCH_TIME_BINS[j];
}
+ if (times.times[NUM_LAUNCH_TIME_BINS-1] != 0) {
+ sb.append(", ");
+ sb.append(">=");
+ sb.append(lastBin);
+ sb.append("ms=");
+ sb.append(times.times[NUM_LAUNCH_TIME_BINS-1]);
+ }
+ sb.append('\n');
+ }
+ final int NFDT = pus.mFullyDrawnTimes.size();
+ for (int i=0; i<NFDT; i++) {
+ sb.append(" ");
+ sb.append(pus.mFullyDrawnTimes.keyAt(i));
+ TimeStats times = pus.mFullyDrawnTimes.valueAt(i);
+ sb.append(": fully drawn ");
+ boolean needComma = false;
+ int lastBin = 0;
+ for (int j=0; j<NUM_LAUNCH_TIME_BINS-1; j++) {
+ if (times.times[j] != 0) {
+ if (needComma) {
+ sb.append(", ");
+ } else {
+ needComma = true;
+ }
+ sb.append(lastBin);
+ sb.append('-');
+ sb.append(LAUNCH_TIME_BINS[j]);
+ sb.append("ms=");
+ sb.append(times.times[j]);
+ }
+ lastBin = LAUNCH_TIME_BINS[j];
+ }
+ if (times.times[NUM_LAUNCH_TIME_BINS-1] != 0) {
+ if (needComma) {
+ sb.append(", ");
+ }
+ sb.append(">=");
+ sb.append(lastBin);
+ sb.append("ms=");
+ sb.append(times.times[NUM_LAUNCH_TIME_BINS-1]);
+ }
+ sb.append('\n');
}
}
diff --git a/services/java/com/android/server/pm/KeySetManager.java b/services/java/com/android/server/pm/KeySetManager.java
index ee8cc71..cc2473b 100644
--- a/services/java/com/android/server/pm/KeySetManager.java
+++ b/services/java/com/android/server/pm/KeySetManager.java
@@ -368,7 +368,7 @@
// Now remove them from the KeySets known to each package
for (String pkgName : mPackages.keySet()) {
- PackageSetting p = mPackages.get(packageName);
+ PackageSetting p = mPackages.get(pkgName);
for (Long ks : deletableKeySets) {
p.keySetData.removeSigningKeySet(ks);
p.keySetData.removeDefinedKeySet(ks);
diff --git a/services/jni/Android.mk b/services/jni/Android.mk
index e416676..f332350 100644
--- a/services/jni/Android.mk
+++ b/services/jni/Android.mk
@@ -41,6 +41,7 @@
libutils \
libui \
libinput \
+ libinputservice \
libskia \
libgui \
libusbhost \
diff --git a/telephony/java/com/android/internal/telephony/DctConstants.java b/telephony/java/com/android/internal/telephony/DctConstants.java
index 9d556c0..4d8342c 100644
--- a/telephony/java/com/android/internal/telephony/DctConstants.java
+++ b/telephony/java/com/android/internal/telephony/DctConstants.java
@@ -93,6 +93,7 @@
public static final int EVENT_ICC_CHANGED = BASE + 33;
public static final int EVENT_DISCONNECT_DC_RETRYING = BASE + 34;
public static final int EVENT_DATA_SETUP_COMPLETE_ERROR = BASE + 35;
+ public static final int CMD_SET_ENABLE_FAIL_FAST_MOBILE_DATA = BASE + 36;
/***** Constants *****/
diff --git a/tools/aapt/Android.mk b/tools/aapt/Android.mk
index 3b49819..452c60a 100644
--- a/tools/aapt/Android.mk
+++ b/tools/aapt/Android.mk
@@ -83,20 +83,19 @@
LOCAL_C_INCLUDES += external/libpng
LOCAL_C_INCLUDES += external/zlib
-LOCAL_CFLAGS += -DSTATIC_ANDROIDFW_FOR_TOOLS
LOCAL_CFLAGS += -Wno-non-virtual-dtor
LOCAL_SHARED_LIBRARIES := \
+ libandroidfw \
+ libutils \
+ libcutils \
libpng \
+ liblog \
libz
LOCAL_STATIC_LIBRARIES := \
libstlport_static \
- libandroidfw \
- libutils \
- libcutils \
- libexpat_static \
- liblog
+ libexpat_static
include $(BUILD_EXECUTABLE)
endif
diff --git a/tools/validatekeymaps/Android.mk b/tools/validatekeymaps/Android.mk
index 90fbc08..9af721d 100644
--- a/tools/validatekeymaps/Android.mk
+++ b/tools/validatekeymaps/Android.mk
@@ -15,10 +15,8 @@
LOCAL_CFLAGS := -Wall -Werror
-#LOCAL_C_INCLUDES +=
-
LOCAL_STATIC_LIBRARIES := \
- libandroidfw \
+ libinput \
libutils \
libcutils \
liblog
diff --git a/tools/validatekeymaps/Main.cpp b/tools/validatekeymaps/Main.cpp
index 91e4fda..5b45c55 100644
--- a/tools/validatekeymaps/Main.cpp
+++ b/tools/validatekeymaps/Main.cpp
@@ -14,9 +14,9 @@
* limitations under the License.
*/
-#include <androidfw/KeyCharacterMap.h>
-#include <androidfw/KeyLayoutMap.h>
-#include <androidfw/VirtualKeyMap.h>
+#include <input/KeyCharacterMap.h>
+#include <input/KeyLayoutMap.h>
+#include <input/VirtualKeyMap.h>
#include <utils/PropertyMap.h>
#include <utils/String8.h>