am 18be472e
: am 7f9b5681
: am 553074f0
: Merge "Return RESULT_OK when wifi connection established" into jb-mr1-dev
* commit '18be472ef46d2320a98173a6d68d9d62b60b6ccc': Return RESULT_OK when wifi connection established
This commit is contained in:
@@ -332,6 +332,7 @@ public class WifiSettings extends SettingsPreferenceFragment
|
|||||||
activity.getSystemService(Context.CONNECTIVITY_SERVICE);
|
activity.getSystemService(Context.CONNECTIVITY_SERVICE);
|
||||||
if (connectivity != null
|
if (connectivity != null
|
||||||
&& connectivity.getNetworkInfo(ConnectivityManager.TYPE_WIFI).isConnected()) {
|
&& connectivity.getNetworkInfo(ConnectivityManager.TYPE_WIFI).isConnected()) {
|
||||||
|
activity.setResult(Activity.RESULT_OK);
|
||||||
activity.finish();
|
activity.finish();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -837,6 +838,7 @@ public class WifiSettings extends SettingsPreferenceFragment
|
|||||||
if (mAutoFinishOnConnection && info.isConnected()) {
|
if (mAutoFinishOnConnection && info.isConnected()) {
|
||||||
Activity activity = getActivity();
|
Activity activity = getActivity();
|
||||||
if (activity != null) {
|
if (activity != null) {
|
||||||
|
activity.setResult(Activity.RESULT_OK);
|
||||||
activity.finish();
|
activity.finish();
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
|
Reference in New Issue
Block a user