parent
b3c51630a6
commit
b11339b3ab
|
@ -34,7 +34,8 @@
|
||||||
<application android:label="@string/english_ime_name"
|
<application android:label="@string/english_ime_name"
|
||||||
android:icon="@drawable/ic_launcher_keyboard"
|
android:icon="@drawable/ic_launcher_keyboard"
|
||||||
android:killAfterRestore="false"
|
android:killAfterRestore="false"
|
||||||
android:supportsRtl="true">
|
android:supportsRtl="true"
|
||||||
|
android:allowBackup="true">
|
||||||
|
|
||||||
<service android:name="LatinIME"
|
<service android:name="LatinIME"
|
||||||
android:label="@string/english_ime_name"
|
android:label="@string/english_ime_name"
|
||||||
|
@ -110,13 +111,14 @@
|
||||||
</intent-filter>
|
</intent-filter>
|
||||||
</receiver>
|
</receiver>
|
||||||
|
|
||||||
<receiver android:name=".personalization.DictionaryDecayBroadcastReciever">
|
<receiver android:name=".personalization.DictionaryDecayBroadcastReciever"
|
||||||
|
android:exported="false">
|
||||||
<intent-filter>
|
<intent-filter>
|
||||||
<action android:name="com.android.inputmethod.latin.personalization.DICT_DECAY" />
|
<action android:name="com.android.inputmethod.latin.personalization.DICT_DECAY" />
|
||||||
</intent-filter>
|
</intent-filter>
|
||||||
</receiver>
|
</receiver>
|
||||||
|
|
||||||
<receiver android:name=".DictionaryPackInstallBroadcastReceiver">
|
<receiver android:name=".DictionaryPackInstallBroadcastReceiver" android:exported="false">
|
||||||
<intent-filter>
|
<intent-filter>
|
||||||
<action android:name="com.android.inputmethod.dictionarypack.aosp.UNKNOWN_CLIENT" />
|
<action android:name="com.android.inputmethod.dictionarypack.aosp.UNKNOWN_CLIENT" />
|
||||||
</intent-filter>
|
</intent-filter>
|
||||||
|
|
|
@ -84,40 +84,32 @@
|
||||||
android:checked="false"
|
android:checked="false"
|
||||||
android:text="@string/research_feedback_include_recording_label" />
|
android:text="@string/research_feedback_include_recording_label" />
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
|
style="?android:attr/buttonBarStyle"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="vertical"
|
android:orientation="horizontal"
|
||||||
android:divider="?android:attr/dividerHorizontal"
|
android:layoutDirection="locale"
|
||||||
android:showDividers="beginning"
|
android:measureWithLargestChild="true">
|
||||||
android:dividerPadding="0dip">
|
<Button
|
||||||
<LinearLayout
|
android:id="@+id/research_feedback_cancel_button"
|
||||||
style="?android:attr/buttonBarStyle"
|
android:layout_width="wrap_content"
|
||||||
android:layout_width="match_parent"
|
android:layout_gravity="left"
|
||||||
android:layout_height="wrap_content"
|
android:layout_weight="1"
|
||||||
android:orientation="horizontal"
|
android:maxLines="2"
|
||||||
android:layoutDirection="locale"
|
style="?android:attr/buttonBarButtonStyle"
|
||||||
android:measureWithLargestChild="true">
|
android:textSize="14sp"
|
||||||
<Button
|
android:text="@string/research_feedback_cancel"
|
||||||
android:id="@+id/research_feedback_cancel_button"
|
android:layout_height="wrap_content" />
|
||||||
android:layout_width="wrap_content"
|
<Button
|
||||||
android:layout_gravity="left"
|
android:id="@+id/research_feedback_send_button"
|
||||||
android:layout_weight="1"
|
android:layout_width="wrap_content"
|
||||||
android:maxLines="2"
|
android:layout_gravity="right"
|
||||||
style="?android:attr/buttonBarButtonStyle"
|
android:layout_weight="1"
|
||||||
android:textSize="14sp"
|
android:maxLines="2"
|
||||||
android:text="@string/research_feedback_cancel"
|
style="?android:attr/buttonBarButtonStyle"
|
||||||
android:layout_height="wrap_content" />
|
android:textSize="14sp"
|
||||||
<Button
|
android:text="@string/research_feedback_send"
|
||||||
android:id="@+id/research_feedback_send_button"
|
android:layout_height="wrap_content" />
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_gravity="right"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:maxLines="2"
|
|
||||||
style="?android:attr/buttonBarButtonStyle"
|
|
||||||
android:textSize="14sp"
|
|
||||||
android:text="@string/research_feedback_send"
|
|
||||||
android:layout_height="wrap_content" />
|
|
||||||
</LinearLayout>
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
</ScrollView>
|
</ScrollView>
|
||||||
|
|
|
@ -33,7 +33,7 @@
|
||||||
<TextView android:id="@+id/seek_bar_dialog_value"
|
<TextView android:id="@+id/seek_bar_dialog_value"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:textSize="20dp"/>
|
android:textSize="20sp"/>
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
<SeekBar
|
<SeekBar
|
||||||
android:id="@+id/seek_bar_dialog_bar"
|
android:id="@+id/seek_bar_dialog_bar"
|
||||||
|
|
|
@ -21,7 +21,5 @@
|
||||||
<merge xmlns:android="http://schemas.android.com/apk/res/android">
|
<merge xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/setup_title"
|
android:id="@+id/setup_title"
|
||||||
style="@style/setupTitleStyle"
|
style="@style/setupTitleStyle" />
|
||||||
android:layout_alignParentLeft="true"
|
|
||||||
android:layout_alignParentTop="true" />
|
|
||||||
</merge>
|
</merge>
|
||||||
|
|
|
@ -21,9 +21,7 @@
|
||||||
<merge xmlns:android="http://schemas.android.com/apk/res/android">
|
<merge xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/setup_welcome_title"
|
android:id="@+id/setup_welcome_title"
|
||||||
style="@style/setupTitleStyle"
|
style="@style/setupTitleStyle" />
|
||||||
android:layout_alignParentLeft="true"
|
|
||||||
android:layout_alignParentTop="true" />
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/setup_welcome_description"
|
android:id="@+id/setup_welcome_description"
|
||||||
android:text="@string/setup_welcome_additional_description"
|
android:text="@string/setup_welcome_additional_description"
|
||||||
|
|
|
@ -19,9 +19,7 @@
|
||||||
-->
|
-->
|
||||||
|
|
||||||
<merge
|
<merge
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin"
|
|
||||||
>
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/suggestions_strip"
|
android:id="@+id/suggestions_strip"
|
||||||
android:orientation="horizontal"
|
android:orientation="horizontal"
|
||||||
|
|
|
@ -58,42 +58,33 @@
|
||||||
</EditText>
|
</EditText>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
|
style="?android:attr/buttonBarStyle"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:divider="?android:attr/dividerHorizontal"
|
android:measureWithLargestChild="true"
|
||||||
android:dividerPadding="0dip"
|
android:orientation="horizontal" >
|
||||||
android:orientation="vertical"
|
|
||||||
android:showDividers="beginning" >
|
|
||||||
|
|
||||||
<LinearLayout
|
<Button
|
||||||
style="?android:attr/buttonBarStyle"
|
style="?android:attr/buttonBarButtonStyle"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="0dip"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:measureWithLargestChild="true"
|
android:layout_gravity="start"
|
||||||
android:orientation="horizontal" >
|
android:layout_weight="1"
|
||||||
|
android:maxLines="2"
|
||||||
|
android:onClick="onClickCancel"
|
||||||
|
android:text="@string/cancel"
|
||||||
|
android:textSize="14sp" />
|
||||||
|
|
||||||
<Button
|
<Button
|
||||||
style="?android:attr/buttonBarButtonStyle"
|
style="?android:attr/buttonBarButtonStyle"
|
||||||
android:layout_width="0dip"
|
android:layout_width="0dip"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="start"
|
android:layout_gravity="end"
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
android:maxLines="2"
|
android:maxLines="2"
|
||||||
android:onClick="onClickCancel"
|
android:onClick="onClickConfirm"
|
||||||
android:text="@string/cancel"
|
android:text="@string/user_dict_settings_add_dialog_confirm"
|
||||||
android:textSize="14sp" />
|
android:textSize="14sp" />
|
||||||
|
|
||||||
<Button
|
|
||||||
style="?android:attr/buttonBarButtonStyle"
|
|
||||||
android:layout_width="0dip"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_gravity="end"
|
|
||||||
android:layout_weight="1"
|
|
||||||
android:maxLines="2"
|
|
||||||
android:onClick="onClickConfirm"
|
|
||||||
android:text="@string/user_dict_settings_add_dialog_confirm"
|
|
||||||
android:textSize="14sp" />
|
|
||||||
</LinearLayout>
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
|
@ -19,10 +19,11 @@
|
||||||
android:background="?android:attr/selectableItemBackground"
|
android:background="?android:attr/selectableItemBackground"
|
||||||
android:gravity="center_vertical"
|
android:gravity="center_vertical"
|
||||||
android:minHeight="?android:attr/listPreferredItemHeight"
|
android:minHeight="?android:attr/listPreferredItemHeight"
|
||||||
android:paddingEnd="?android:attr/scrollbarSize" >
|
android:paddingEnd="?android:attr/scrollbarSize"
|
||||||
|
android:baselineAligned="false" >
|
||||||
|
|
||||||
<RelativeLayout
|
<RelativeLayout
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="0dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:padding="6dip"
|
android:padding="6dip"
|
||||||
android:layout_weight="1" >
|
android:layout_weight="1" >
|
||||||
|
|
|
@ -23,7 +23,7 @@ public final class CommonPreferences {
|
||||||
private static final String COMMON_PREFERENCES_NAME = "LatinImeDictPrefs";
|
private static final String COMMON_PREFERENCES_NAME = "LatinImeDictPrefs";
|
||||||
|
|
||||||
public static SharedPreferences getCommonPreferences(final Context context) {
|
public static SharedPreferences getCommonPreferences(final Context context) {
|
||||||
return context.getSharedPreferences(COMMON_PREFERENCES_NAME, Context.MODE_WORLD_READABLE);
|
return context.getSharedPreferences(COMMON_PREFERENCES_NAME, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void enable(final SharedPreferences pref, final String id) {
|
public static void enable(final SharedPreferences pref, final String id) {
|
||||||
|
|
|
@ -100,6 +100,7 @@ public class DictionaryDownloadProgressBar extends ProgressBar {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void onDetachedFromWindow() {
|
protected void onDetachedFromWindow() {
|
||||||
|
super.onDetachedFromWindow();
|
||||||
mIsCurrentlyAttachedToWindow = false;
|
mIsCurrentlyAttachedToWindow = false;
|
||||||
updateReporterThreadRunningStatusAccordingToVisibility();
|
updateReporterThreadRunningStatusAccordingToVisibility();
|
||||||
}
|
}
|
||||||
|
|
|
@ -112,7 +112,7 @@ final public class BinaryDictionaryGetter {
|
||||||
public DictPackSettings(final Context context) {
|
public DictPackSettings(final Context context) {
|
||||||
mDictPreferences = null == context ? null
|
mDictPreferences = null == context ? null
|
||||||
: context.getSharedPreferences(COMMON_PREFERENCES_NAME,
|
: context.getSharedPreferences(COMMON_PREFERENCES_NAME,
|
||||||
Context.MODE_WORLD_READABLE | Context.MODE_MULTI_PROCESS);
|
Context.MODE_MULTI_PROCESS);
|
||||||
}
|
}
|
||||||
public boolean isWordListActive(final String dictId) {
|
public boolean isWordListActive(final String dictId) {
|
||||||
if (null == mDictPreferences) {
|
if (null == mDictPreferences) {
|
||||||
|
|
|
@ -35,7 +35,6 @@ import com.android.inputmethod.latin.utils.StringUtils;
|
||||||
import com.android.inputmethod.latin.utils.TextRange;
|
import com.android.inputmethod.latin.utils.TextRange;
|
||||||
import com.android.inputmethod.research.ResearchLogger;
|
import com.android.inputmethod.research.ResearchLogger;
|
||||||
|
|
||||||
import java.util.Locale;
|
|
||||||
import java.util.regex.Pattern;
|
import java.util.regex.Pattern;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue