Dreamine.Hybrid.Wpf
1.0.3
`AddDreamineHybridWpf()` 내부에서 `AddWpfBlazorWebView()` 호출 및
Toggle main menu visibility
로딩중...
검색중...
일치하는것 없음
DesignTimeGuard.cs
이 파일의 문서화 페이지로 가기
1
using
System;
2
using
System.ComponentModel;
3
using
System.Windows;
4
5
namespace
Dreamine.Hybrid.Wpf.Utility
6
{
15
public
static
class
DesignTimeGuard
16
{
25
private
static
readonly
bool
_isInDesignMode
=
DetectDesignMode
();
26
35
public
static
bool
IsInDesignMode
=>
_isInDesignMode
;
36
53
private
static
bool
DetectDesignMode
()
54
{
55
try
56
{
57
if
(Application.Current?.Dispatcher is { } dispatcher &&
58
!dispatcher.CheckAccess())
59
{
60
return
false
;
61
}
62
63
return
DesignerProperties.GetIsInDesignMode(
new
DependencyObject());
64
}
65
catch
(InvalidOperationException)
66
{
67
return
false
;
68
}
69
}
70
}
71
}
Dreamine.Hybrid.Wpf.Utility
Definition
DesignTimeGuard.cs:6
Dreamine.Hybrid.Wpf.Utility.DesignTimeGuard
Definition
DesignTimeGuard.cs:16
Dreamine.Hybrid.Wpf.Utility.DesignTimeGuard.DetectDesignMode
static bool DetectDesignMode()
Definition
DesignTimeGuard.cs:53
Dreamine.Hybrid.Wpf.Utility.DesignTimeGuard.IsInDesignMode
static bool IsInDesignMode
Definition
DesignTimeGuard.cs:35
Dreamine.Hybrid.Wpf.Utility.DesignTimeGuard._isInDesignMode
static readonly bool _isInDesignMode
Definition
DesignTimeGuard.cs:25
Utility
DesignTimeGuard.cs
다음에 의해 생성됨 :
1.17.0