Disable resolution button when fullscreen is ticked
This commit is contained in:
parent
cf41b2e456
commit
bad9a639d9
|
@ -91,7 +91,7 @@ void UOptionsUIWidget::NativeConstruct()
|
||||||
if (ResetToDefaultsButton)
|
if (ResetToDefaultsButton)
|
||||||
{
|
{
|
||||||
ResetToDefaultsButton->OnClicked.AddUniqueDynamic(this, &UOptionsUIWidget::ResetToDefaultsButtonOnClicked);
|
ResetToDefaultsButton->OnClicked.AddUniqueDynamic(this, &UOptionsUIWidget::ResetToDefaultsButtonOnClicked);
|
||||||
BackButton->OnClicked.AddUniqueDynamic(this, &UOptionsUIWidget::PlayClickedSound);
|
ResetToDefaultsButton->OnClicked.AddUniqueDynamic(this, &UOptionsUIWidget::PlayClickedSound);
|
||||||
|
|
||||||
ResetToDefaultsButton->OnHovered.AddUniqueDynamic(this, &UOptionsUIWidget::PlayHoveredSound);
|
ResetToDefaultsButton->OnHovered.AddUniqueDynamic(this, &UOptionsUIWidget::PlayHoveredSound);
|
||||||
ResetToDefaultsButton->OnHovered.AddUniqueDynamic(this, &UOptionsUIWidget::ResetToDefaultsTextBlockHoveredDelegate);
|
ResetToDefaultsButton->OnHovered.AddUniqueDynamic(this, &UOptionsUIWidget::ResetToDefaultsTextBlockHoveredDelegate);
|
||||||
|
@ -177,10 +177,12 @@ void UOptionsUIWidget::OnFullscreenCheckboxChanged(bool bIsChecked)
|
||||||
if (bIsChecked)
|
if (bIsChecked)
|
||||||
{
|
{
|
||||||
GEngine->GameUserSettings->SetFullscreenMode(EWindowMode::Fullscreen);
|
GEngine->GameUserSettings->SetFullscreenMode(EWindowMode::Fullscreen);
|
||||||
|
ResolutionButton->SetIsEnabled(false);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
GEngine->GameUserSettings->SetFullscreenMode(EWindowMode::Windowed);
|
GEngine->GameUserSettings->SetFullscreenMode(EWindowMode::Windowed);
|
||||||
|
ResolutionButton->SetIsEnabled(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
GEngine->GameUserSettings->ApplySettings(true);
|
GEngine->GameUserSettings->ApplySettings(true);
|
||||||
|
|
Loading…
Reference in New Issue