InTheHand.UI.ApplicationSettings.SettingsPane.GetForCurrentView C# (CSharp) Method

GetForCurrentView() public static method

Gets a SettingsPane object that is associated with the current app.
public static GetForCurrentView ( ) : SettingsPane
return SettingsPane
        public static SettingsPane GetForCurrentView()
        {
            if (instance == null)
            {
#if WINDOWS_UWP
                hasSettingsPane = Windows.Foundation.Metadata.ApiInformation.IsApiContractPresent("Windows.UI.ApplicationSettings.ApplicationsSettingsContract", 1);
#endif
                instance = new SettingsPane();
            }

            return instance;
        }

Usage Example

Esempio n. 1
0
        void AboutPage_Loaded(object sender, RoutedEventArgs e)
        {
            AppIcon.Source   = new BitmapImage(InTheHand.ApplicationModel.Package.Current.Logo);
            AppNameText.Text = InTheHand.ApplicationModel.Package.Current.DisplayName;
            Version.Text     = "Version " + InTheHand.ApplicationModel.Package.Current.Id.Version.ToString();
            if (SettingsPane.GetForCurrentView().showPublisher)
            {
                AuthorText.Text = string.Format("By {0}", InTheHand.ApplicationModel.Package.Current.PublisherDisplayName);
            }
            else
            {
                AuthorText.Visibility = Visibility.Collapsed;
            }

            Description.Text = InTheHand.ApplicationModel.Package.Current.Description;
        }
All Usage Examples Of InTheHand.UI.ApplicationSettings.SettingsPane::GetForCurrentView