Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Zatsepin <az@mapswithme.com>2018-08-09 15:20:57 +0300
committerAleksey Belousov <beloal@users.noreply.github.com>2018-08-10 20:16:14 +0300
commitcd128520d57e309aa6c7b9977ba58a850b2ef684 (patch)
tree7e56032caedc77fc997ab80af112c54489a44aa8 /android/src/com/mapswithme/maps/intent
parent76fe38a833b8669ea362045e204c5947029e1d88 (diff)
[android] Maded intent processor returned value nullable
Diffstat (limited to 'android/src/com/mapswithme/maps/intent')
-rw-r--r--android/src/com/mapswithme/maps/intent/Factory.java17
-rw-r--r--android/src/com/mapswithme/maps/intent/IntentProcessor.java3
2 files changed, 10 insertions, 10 deletions
diff --git a/android/src/com/mapswithme/maps/intent/Factory.java b/android/src/com/mapswithme/maps/intent/Factory.java
index 9411213032..0447e308ee 100644
--- a/android/src/com/mapswithme/maps/intent/Factory.java
+++ b/android/src/com/mapswithme/maps/intent/Factory.java
@@ -4,6 +4,7 @@ import android.content.ContentResolver;
import android.content.Intent;
import android.net.Uri;
import android.support.annotation.NonNull;
+import android.support.annotation.Nullable;
import android.text.TextUtils;
import com.crashlytics.android.Crashlytics;
@@ -347,7 +348,7 @@ public class Factory
@NonNull
private final DownloadResourcesLegacyActivity mActivity;
- public KmzKmlProcessor(@NonNull DownloadResourcesLegacyActivity activity)
+ KmzKmlProcessor(@NonNull DownloadResourcesLegacyActivity activity)
{
mActivity = activity;
}
@@ -359,17 +360,15 @@ public class Factory
return mData != null;
}
- @NonNull
+ @Nullable
@Override
public MwmActivity.MapTask process(@NonNull Intent intent)
{
- return (MwmActivity.MapTask) target -> {
- ThreadPool.getStorage().execute(() -> {
- readKmzFromIntent();
- mActivity.runOnUiThread(mActivity::showMap);
- });
- return true;
- };
+ ThreadPool.getStorage().execute(() -> {
+ readKmzFromIntent();
+ mActivity.runOnUiThread(mActivity::showMap);
+ });
+ return null;
}
private void readKmzFromIntent()
diff --git a/android/src/com/mapswithme/maps/intent/IntentProcessor.java b/android/src/com/mapswithme/maps/intent/IntentProcessor.java
index db5dc3083a..60b7db1d06 100644
--- a/android/src/com/mapswithme/maps/intent/IntentProcessor.java
+++ b/android/src/com/mapswithme/maps/intent/IntentProcessor.java
@@ -2,6 +2,7 @@ package com.mapswithme.maps.intent;
import android.content.Intent;
import android.support.annotation.NonNull;
+import android.support.annotation.Nullable;
import com.mapswithme.maps.MwmActivity;
@@ -9,7 +10,7 @@ public interface IntentProcessor
{
boolean isSupported(@NonNull Intent intent);
- @NonNull
+ @Nullable
MwmActivity.MapTask process(@NonNull Intent intent);
}