public static void OnChange(DependencyObject o, DependencyPropertyChangedEventArgs args) { ViewerAppSettingsViewModel source = o as ViewerAppSettingsViewModel; if (source != null) { source.raiseChange(); } }
public static void OnViewerAppChange(DependencyObject o, DependencyPropertyChangedEventArgs args) { ViewerAppSettingsViewModel source = o as ViewerAppSettingsViewModel; if (source != null) { Binding b = new Binding("BingMapsAppId") { Source = source.ViewerApplication }; b.Mode = BindingMode.OneWay; BindingOperations.SetBinding(source, BingMapsAppIdProperty, b); b = new Binding("PortalAppId") { Source = source.ViewerApplication }; b.Mode = BindingMode.OneWay; BindingOperations.SetBinding(source, PortalAppIdProperty, b); b = new Binding("GeometryService") { Source = source.ViewerApplication }; b.Mode = BindingMode.OneWay; BindingOperations.SetBinding(source, GeometryServiceUrlProperty, b); b = new Binding("ArcGISOnlineSharing") { Source = source.ViewerApplication }; b.Mode = BindingMode.OneWay; BindingOperations.SetBinding(source, ArcGISOnlineSharingProperty, b); b = new Binding("ArcGISOnlineSecure") { Source = source.ViewerApplication }; b.Mode = BindingMode.OneWay; BindingOperations.SetBinding(source, ArcGISOnlineSecureProperty, b); b = new Binding("Proxy") { Source = source.ViewerApplication }; b.Mode = BindingMode.OneWay; BindingOperations.SetBinding(source, ProxyProperty, b); } }