Button wird teilweise im Debuggen Grau
This commit is contained in:
@@ -38,7 +38,7 @@ namespace BeWo.View.Controls.AI
|
||||
public partial class AiPromptbausteinButton : UserControl
|
||||
{
|
||||
public static readonly DependencyProperty CanExecuteProperty =
|
||||
DependencyProperty.Register("CanExecute", typeof(bool), typeof(AiPromptbausteinButton), new PropertyMetadata(true, OnCanExecuteChanged));
|
||||
DependencyProperty.Register("CanExecute", typeof(bool), typeof(AiPromptbausteinButton), new PropertyMetadata(false, OnCanExecuteChanged));
|
||||
|
||||
public static readonly DependencyProperty StateProperty =
|
||||
DependencyProperty.Register("State", typeof(AiPromptbausteinButtonState), typeof(AiPromptbausteinButton), new PropertyMetadata(AiPromptbausteinButtonState.Normal, OnStateChanged));
|
||||
@@ -134,7 +134,11 @@ namespace BeWo.View.Controls.AI
|
||||
private void UpdateState(AiPromptbausteinButtonState state)
|
||||
{
|
||||
if (state == AiPromptbausteinButtonState.Normal && !CanExecute)
|
||||
state = AiPromptbausteinButtonState.Disabled;
|
||||
{
|
||||
State = AiPromptbausteinButtonState.Disabled;
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
switch (state)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user