summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Platform.WinRT
diff options
context:
space:
mode:
authorNick Gamroth <thebeekeeper@gmail.com>2016-04-27 18:58:24 (GMT)
committerRui Marinho <me@ruimarinho.net>2016-04-27 18:58:24 (GMT)
commit6b9adc7459f9babf3288a6800ca12a76eab244ca (patch)
tree99dc17fa2d1c5f6479799446da900153e0cec843 /Xamarin.Forms.Platform.WinRT
parent8a00a96ffb34058bfb03f8cc16c28b38a79791a4 (diff)
downloadxamarin-forms-6b9adc7459f9babf3288a6800ca12a76eab244ca.zip
xamarin-forms-6b9adc7459f9babf3288a6800ca12a76eab244ca.tar.gz
xamarin-forms-6b9adc7459f9babf3288a6800ca12a76eab244ca.tar.bz2
Removed hard reference to StatusBar, changed to type name to prevent crash when StatusBar type is not present (#144)
Diffstat (limited to 'Xamarin.Forms.Platform.WinRT')
-rw-r--r--Xamarin.Forms.Platform.WinRT/Platform.cs5
1 files changed, 3 insertions, 2 deletions
diff --git a/Xamarin.Forms.Platform.WinRT/Platform.cs b/Xamarin.Forms.Platform.WinRT/Platform.cs
index 4d7309d..6c158a0 100644
--- a/Xamarin.Forms.Platform.WinRT/Platform.cs
+++ b/Xamarin.Forms.Platform.WinRT/Platform.cs
@@ -76,8 +76,9 @@ namespace Xamarin.Forms.Platform.WinRT
UpdateBounds();
+
#if WINDOWS_UWP
- if (ApiInformation.IsTypePresent(typeof(StatusBar).ToString()))
+ if (ApiInformation.IsTypePresent("Windows.UI.ViewManagement.StatusBar"))
{
StatusBar statusBar = StatusBar.GetForCurrentView();
statusBar.Showing += (sender, args) => UpdateBounds();
@@ -417,7 +418,7 @@ namespace Xamarin.Forms.Platform.WinRT
{
_bounds = new Rectangle(0, 0, _page.ActualWidth, _page.ActualHeight);
#if WINDOWS_UWP
- if (ApiInformation.IsTypePresent(typeof(StatusBar).ToString()))
+ if (ApiInformation.IsTypePresent("Windows.UI.ViewManagement.StatusBar"))
{
StatusBar statusBar = StatusBar.GetForCurrentView();