当前位置: 首页>>代码示例>>C#>>正文


C# Window.GetValue方法代码示例

本文整理汇总了C#中System.Windows.Window.GetValue方法的典型用法代码示例。如果您正苦于以下问题:C# Window.GetValue方法的具体用法?C# Window.GetValue怎么用?C# Window.GetValue使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在System.Windows.Window的用法示例。


在下文中一共展示了Window.GetValue方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: DettachWindowListeners

		private static void DettachWindowListeners(Window window, object vm) {
			if(vm != null) {
				var listener = (WindowMessageListener)window.GetValue(WindowMessageListenerProperty);
				if(listener != null) {
					window.SetValue(WindowMessageListenerProperty, null);
					listener.Dettach(vm, window);
				}
			}
		}
开发者ID:catwalkagogo,项目名称:Heron,代码行数:9,代码来源:MessageReceivers.WindowMessages.cs

示例2: GetCanMaximize

        public static bool GetCanMaximize(Window obj)
        {
            if (obj == null)
            {
                throw new ArgumentNullException("obj");
            }

            return (bool)obj.GetValue(CanMaximizeProperty);
        }
开发者ID:MyLoadTest,项目名称:VuGenAddinManager,代码行数:9,代码来源:ExtraWindowStyles.cs

示例3: EnsureHotkeyServiceHelper

        private static HotkeyServiceHelper EnsureHotkeyServiceHelper(Window window)
        {
            HotkeyServiceHelper helper = (HotkeyServiceHelper)window.GetValue(HotkeyServiceHelperPropertyKey.DependencyProperty);

            if (helper == null)
            {
                helper = new HotkeyServiceHelper(window);
                window.SetValue(HotkeyServiceHelperPropertyKey, helper);
            }

            return helper;
        }
开发者ID:JamesNK,项目名称:Newtonsoft.Googleman,代码行数:12,代码来源:HotkeyService.cs

示例4: _EnsureAttachedExtensions

        private static WindowExtensions _EnsureAttachedExtensions(Window window)
        {
            Assert.IsNotNull(window);

            var ext = (WindowExtensions)window.GetValue(WindowExtensionsProperty);
            if (ext == null)
            {
                ext = new WindowExtensions(window);
                window.SetValue(WindowExtensionsProperty, ext);
            }

            return ext;
        }
开发者ID:grandtiger,项目名称:wpf-shell,代码行数:13,代码来源:WindowExtensions.cs

示例5: FindFirstModalDialog

        static Window FindFirstModalDialog(Window ownerWindow)
        {
            if (ownerWindow != null)
            {
                if (ownerWindow.OwnedWindows.Count != 0)
                {
                    foreach (Window w in ownerWindow.OwnedWindows)
                    {
                        var window = FindFirstModalDialog(w);
                        if (window != null)
                        {
                            return window;
                        }
                    }
                }

                if ((bool)ownerWindow.GetValue(IsModalProperty) && ownerWindow.IsEnabled && ownerWindow.IsVisible && ownerWindow.IsActive)
                {
                    return ownerWindow;
                }
            }

            return null;
        }
开发者ID:Particular,项目名称:ServiceInsight,代码行数:24,代码来源:Dialog.xaml.cs

示例6: GetIsModalProperty

 public static bool GetIsModalProperty(Window window)
 {
     return (bool)window.GetValue(IsModalProperty);
 }
开发者ID:4lx,项目名称:Profiler,代码行数:4,代码来源:Dialog.xaml.cs

示例7: GetApplicationClosing

 public static ApplicationExitingDelegate GetApplicationClosing(Window element)
 {
     return (ApplicationExitingDelegate)element.GetValue(ApplicationClosingProperty);
 }
开发者ID:RolandPheasant,项目名称:TailBlazer,代码行数:4,代码来源:WindowAssist.cs

示例8: GetInstance

 public static WindowChrome GetInstance(Window window)
 {
     return (WindowChrome)window.GetValue(InstanceProperty);
 }
开发者ID:CirnoV,项目名称:MetroRadiance,代码行数:4,代码来源:WindowChrome.cs

示例9: GetIsClosingAsPartOfDragOperation

 public static bool GetIsClosingAsPartOfDragOperation(Window element)
 {
     return (bool) element.GetValue(IsClosingAsPartOfDragOperationProperty);
 }
开发者ID:tleviathan,项目名称:Dragablz,代码行数:4,代码来源:TabablzControl.cs

示例10: GetIsHiddenCloseButton

 public static bool GetIsHiddenCloseButton(Window obj)
 {
     return (bool)obj.GetValue(IsHiddenCloseButtonProperty);
 }
开发者ID:rdingwall,项目名称:mixplanner,代码行数:4,代码来源:WindowBehavior.cs

示例11: GetSettings

 public static Settings GetSettings(Window element)
 {
     return (Settings)element.GetValue(SettingsProperty);
 }
开发者ID:thoemmi,项目名称:Solutionizer,代码行数:4,代码来源:WindowStatePersistence.cs

示例12: GetCurrentValidatedControl

 private static FrameworkElement GetCurrentValidatedControl (Window d)
 {
     return (FrameworkElement)d.GetValue(CurrentValidatedControlProperty);
 }
开发者ID:binki,项目名称:Alba.Framework,代码行数:4,代码来源:ValidationProps.g.cs

示例13: GetDialogResult

 /// <summary>
 /// Gets the DialogResult value from the specified target.
 /// </summary>
 /// <param name="target">The target.</param>
 /// <returns>The value.</returns>
 public static bool? GetDialogResult(Window target)
 {
     return (bool?)target.GetValue(DialogResultProperty);
 }
开发者ID:Mediomondo,项目名称:codemaid,代码行数:9,代码来源:WindowAttachedProperties.cs

示例14: GetTooltipPopup

 private static TooltipPopup GetTooltipPopup (Window d)
 {
     return (TooltipPopup)d.GetValue(TooltipPopupProperty);
 }
开发者ID:binki,项目名称:Alba.Framework,代码行数:4,代码来源:ValidationProps.g.cs

示例15: GetNadenade

 /// <summary>添付プロパティから撫でた量を取得します。</summary>
 /// <param name="target">取得元</param>
 /// <returns>撫でた量</returns>
 public static double GetNadenade(Window target)
 {
     return (double)target.GetValue(NadenadeProperty);
 }
开发者ID:malaybaku,项目名称:harriet,代码行数:7,代码来源:MainWindow.xaml.cs


注:本文中的System.Windows.Window.GetValue方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。