summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Platform.Android
diff options
context:
space:
mode:
authorRui Marinho <me@ruimarinho.net>2016-09-13 12:18:03 (GMT)
committerRui Marinho <me@ruimarinho.net>2016-09-13 12:18:03 (GMT)
commit6fa569cfda33d6875896788bba274a313a24fac2 (patch)
tree35a49d9322afeb1269b13333d8adf4548cd34a7b /Xamarin.Forms.Platform.Android
parent960f02d0e7549088d15b74bd11628eb987c77a74 (diff)
downloadxamarin-forms-6fa569cfda33d6875896788bba274a313a24fac2.zip
xamarin-forms-6fa569cfda33d6875896788bba274a313a24fac2.tar.gz
xamarin-forms-6fa569cfda33d6875896788bba274a313a24fac2.tar.bz2
Revert "[Android] Fix warnings (#346)"
This reverts commit 960f02d0e7549088d15b74bd11628eb987c77a74.
Diffstat (limited to 'Xamarin.Forms.Platform.Android')
-rw-r--r--Xamarin.Forms.Platform.Android/AppCompat/FormsAppCompatActivity.cs8
-rw-r--r--Xamarin.Forms.Platform.Android/FormsApplicationActivity.cs8
-rw-r--r--Xamarin.Forms.Platform.Android/Renderers/WebViewRenderer.cs1
3 files changed, 10 insertions, 7 deletions
diff --git a/Xamarin.Forms.Platform.Android/AppCompat/FormsAppCompatActivity.cs b/Xamarin.Forms.Platform.Android/AppCompat/FormsAppCompatActivity.cs
index ab2fb61..b200e27 100644
--- a/Xamarin.Forms.Platform.Android/AppCompat/FormsAppCompatActivity.cs
+++ b/Xamarin.Forms.Platform.Android/AppCompat/FormsAppCompatActivity.cs
@@ -414,6 +414,10 @@ namespace Xamarin.Forms.Platform.Android
{
_busyCount = Math.Max(0, enabled ? _busyCount + 1 : _busyCount - 1);
+ if (!Forms.SupportsProgress)
+ return;
+
+ SetProgressBarIndeterminate(true);
UpdateProgressBarVisibility(_busyCount > 0);
}
@@ -487,10 +491,8 @@ namespace Xamarin.Forms.Platform.Android
{
if (!Forms.SupportsProgress)
return;
-#pragma warning disable 612, 618
- SetProgressBarIndeterminate(true);
+
SetProgressBarIndeterminateVisibility(isBusy);
-#pragma warning restore 612, 618
}
internal class DefaultApplication : Application
diff --git a/Xamarin.Forms.Platform.Android/FormsApplicationActivity.cs b/Xamarin.Forms.Platform.Android/FormsApplicationActivity.cs
index c8795c6..adb27f7 100644
--- a/Xamarin.Forms.Platform.Android/FormsApplicationActivity.cs
+++ b/Xamarin.Forms.Platform.Android/FormsApplicationActivity.cs
@@ -243,6 +243,11 @@ namespace Xamarin.Forms.Platform.Android
MessagingCenter.Subscribe(this, Page.BusySetSignalName, (Page sender, bool enabled) =>
{
busyCount = Math.Max(0, enabled ? busyCount + 1 : busyCount - 1);
+
+ if (!Forms.SupportsProgress)
+ return;
+
+ SetProgressBarIndeterminate(true);
UpdateProgressBarVisibility(busyCount > 0);
});
@@ -333,10 +338,7 @@ namespace Xamarin.Forms.Platform.Android
{
if (!Forms.SupportsProgress)
return;
-#pragma warning disable 612, 618
- SetProgressBarIndeterminate(true);
SetProgressBarIndeterminateVisibility(isBusy);
-#pragma warning restore 612, 618
}
internal class DefaultApplication : Application
diff --git a/Xamarin.Forms.Platform.Android/Renderers/WebViewRenderer.cs b/Xamarin.Forms.Platform.Android/Renderers/WebViewRenderer.cs
index 8efc41e..bd5b805 100644
--- a/Xamarin.Forms.Platform.Android/Renderers/WebViewRenderer.cs
+++ b/Xamarin.Forms.Platform.Android/Renderers/WebViewRenderer.cs
@@ -201,7 +201,6 @@ namespace Xamarin.Forms.Platform.Android
base.OnReceivedError(view, request, error);
}
- [Obsolete]
public override bool ShouldOverrideUrlLoading(AWebView view, string url)
{
if (_renderer.Element == null)