diff options
author | 2014-10-22 14:04:07 +0900 | |
---|---|---|
committer | 2014-10-23 09:58:42 +0900 | |
commit | d3a4c5132422b189c8dbb94dbbe84a9b9761b0a8 (patch) | |
tree | 0f2e5b9e4dfb35bc1794033621943ec1fe607f52 /java/src/com/android/inputmethod/latin/settings/SettingsValues.java | |
parent | 924b8fd0fa456a084358ce916ac2b637b915946e (diff) | |
download | latinime-d3a4c5132422b189c8dbb94dbbe84a9b9761b0a8.tar.gz latinime-d3a4c5132422b189c8dbb94dbbe84a9b9761b0a8.tar.xz latinime-d3a4c5132422b189c8dbb94dbbe84a9b9761b0a8.zip |
Fix Javadoc and null analysis related warnings
This CL also adds @SuppressWarning("unused" to java-overridable package.
Bug: 18003991
Change-Id: If70527e30654384705d7a814f5efd181d9f539e1
Diffstat (limited to 'java/src/com/android/inputmethod/latin/settings/SettingsValues.java')
-rw-r--r-- | java/src/com/android/inputmethod/latin/settings/SettingsValues.java | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/java/src/com/android/inputmethod/latin/settings/SettingsValues.java b/java/src/com/android/inputmethod/latin/settings/SettingsValues.java index 5b99652b8..da8810fae 100644 --- a/java/src/com/android/inputmethod/latin/settings/SettingsValues.java +++ b/java/src/com/android/inputmethod/latin/settings/SettingsValues.java @@ -37,6 +37,8 @@ import com.android.inputmethod.latin.utils.TargetPackageInfoGetterTask; import java.util.Arrays; import java.util.Locale; +import javax.annotation.Nonnull; + /** * When you call the constructor of this class, you may want to change the current system locale by * using {@link com.android.inputmethod.latin.utils.RunInLocale}. @@ -85,6 +87,7 @@ public class SettingsValues { public final int mScreenMetrics; // From the input box + @Nonnull public final InputAttributes mInputAttributes; // Deduced settings @@ -115,7 +118,7 @@ public class SettingsValues { public final float mKeyPreviewDismissEndYScale; public SettingsValues(final Context context, final SharedPreferences prefs, final Resources res, - final InputAttributes inputAttributes) { + @Nonnull final InputAttributes inputAttributes) { mLocale = res.getConfiguration().locale; // Get the resources mDelayInMillisecondsToUpdateOldSuggestions = @@ -123,12 +126,7 @@ public class SettingsValues { mSpacingAndPunctuations = new SpacingAndPunctuations(res); // Store the input attributes - if (null == inputAttributes) { - mInputAttributes = new InputAttributes( - null, false /* isFullscreenMode */, context.getPackageName()); - } else { - mInputAttributes = inputAttributes; - } + mInputAttributes = inputAttributes; // Get the settings preferences mAutoCap = prefs.getBoolean(Settings.PREF_AUTO_CAP, true); |