mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
Cleanup Code
This commit is contained in:
parent
8686308a9a
commit
1c1bad087c
3 changed files with 10 additions and 13 deletions
|
|
@ -28,7 +28,7 @@
|
||||||
</Grid.ColumnDefinitions>
|
</Grid.ColumnDefinitions>
|
||||||
<StackPanel Grid.Column="0" Orientation="Horizontal">
|
<StackPanel Grid.Column="0" Orientation="Horizontal">
|
||||||
<Border
|
<Border
|
||||||
x:Name="Part_IconBorder"
|
x:Name="PART_IconBorder"
|
||||||
Width="16"
|
Width="16"
|
||||||
Height="16"
|
Height="16"
|
||||||
Margin="0 0 12 0"
|
Margin="0 0 12 0"
|
||||||
|
|
|
||||||
|
|
@ -49,7 +49,6 @@ namespace Flow.Launcher.Resources.Controls
|
||||||
set
|
set
|
||||||
{
|
{
|
||||||
SetValue(MessageProperty, value);
|
SetValue(MessageProperty, value);
|
||||||
UpdateMessageVisibility(); // Visibility update when change Message
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -128,13 +127,13 @@ namespace Flow.Launcher.Resources.Controls
|
||||||
{
|
{
|
||||||
if (Length == InfoBarLength.Short)
|
if (Length == InfoBarLength.Short)
|
||||||
{
|
{
|
||||||
Part_IconBorder.VerticalAlignment = VerticalAlignment.Center;
|
PART_IconBorder.VerticalAlignment = VerticalAlignment.Center;
|
||||||
Part_IconBorder.Margin = new Thickness(0, 0, 12, 0);
|
PART_IconBorder.Margin = new Thickness(0, 0, 12, 0);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Part_IconBorder.VerticalAlignment = VerticalAlignment.Top;
|
PART_IconBorder.VerticalAlignment = VerticalAlignment.Top;
|
||||||
Part_IconBorder.Margin = new Thickness(0, 2, 12, 0);
|
PART_IconBorder.Margin = new Thickness(0, 2, 12, 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -158,22 +157,22 @@ namespace Flow.Launcher.Resources.Controls
|
||||||
{
|
{
|
||||||
case InfoBarType.Info:
|
case InfoBarType.Info:
|
||||||
PART_Border.Background = (Brush)FindResource("InfoBarInfoBG");
|
PART_Border.Background = (Brush)FindResource("InfoBarInfoBG");
|
||||||
Part_IconBorder.Background = (Brush)FindResource("InfoBarInfoIcon");
|
PART_IconBorder.Background = (Brush)FindResource("InfoBarInfoIcon");
|
||||||
PART_Icon.Glyph = "\xF13F";
|
PART_Icon.Glyph = "\xF13F";
|
||||||
break;
|
break;
|
||||||
case InfoBarType.Success:
|
case InfoBarType.Success:
|
||||||
PART_Border.Background = (Brush)FindResource("InfoBarSuccessBG");
|
PART_Border.Background = (Brush)FindResource("InfoBarSuccessBG");
|
||||||
Part_IconBorder.Background = (Brush)FindResource("InfoBarSuccessIcon");
|
PART_IconBorder.Background = (Brush)FindResource("InfoBarSuccessIcon");
|
||||||
PART_Icon.Glyph = "\xF13E";
|
PART_Icon.Glyph = "\xF13E";
|
||||||
break;
|
break;
|
||||||
case InfoBarType.Warning:
|
case InfoBarType.Warning:
|
||||||
PART_Border.Background = (Brush)FindResource("InfoBarWarningBG");
|
PART_Border.Background = (Brush)FindResource("InfoBarWarningBG");
|
||||||
Part_IconBorder.Background = (Brush)FindResource("InfoBarWarningIcon");
|
PART_IconBorder.Background = (Brush)FindResource("InfoBarWarningIcon");
|
||||||
PART_Icon.Glyph = "\xF13C";
|
PART_Icon.Glyph = "\xF13C";
|
||||||
break;
|
break;
|
||||||
case InfoBarType.Error:
|
case InfoBarType.Error:
|
||||||
PART_Border.Background = (Brush)FindResource("InfoBarErrorBG");
|
PART_Border.Background = (Brush)FindResource("InfoBarErrorBG");
|
||||||
Part_IconBorder.Background = (Brush)FindResource("InfoBarErrorIcon");
|
PART_IconBorder.Background = (Brush)FindResource("InfoBarErrorIcon");
|
||||||
PART_Icon.Glyph = "\xF13D";
|
PART_Icon.Glyph = "\xF13D";
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
@ -193,7 +192,7 @@ namespace Flow.Launcher.Resources.Controls
|
||||||
|
|
||||||
private void UpdateIconVisibility()
|
private void UpdateIconVisibility()
|
||||||
{
|
{
|
||||||
Part_IconBorder.Visibility = IsIconVisible ? Visibility.Visible : Visibility.Collapsed;
|
PART_IconBorder.Visibility = IsIconVisible ? Visibility.Visible : Visibility.Collapsed;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void UpdateCloseButtonVisibility()
|
private void UpdateCloseButtonVisibility()
|
||||||
|
|
|
||||||
|
|
@ -34,8 +34,6 @@ public partial class SettingsPaneGeneralViewModel : BaseModel
|
||||||
_portable = portable;
|
_portable = portable;
|
||||||
_translater = translater;
|
_translater = translater;
|
||||||
UpdateEnumDropdownLocalizations();
|
UpdateEnumDropdownLocalizations();
|
||||||
// Initialize the Korean IME status by checking registry
|
|
||||||
IsLegacyKoreanIMEEnabled();
|
|
||||||
OpenImeSettingsCommand = new RelayCommand(OpenImeSettings);
|
OpenImeSettingsCommand = new RelayCommand(OpenImeSettings);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue