mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
Main Search Window- Update appearance
This commit is contained in:
parent
3c119714a6
commit
815c3f2a1e
8 changed files with 20 additions and 9 deletions
|
|
@ -9,7 +9,7 @@
|
|||
<ResourceDictionary.MergedDictionaries>
|
||||
<ui:ThemeResources />
|
||||
<ui:XamlControlsResources />
|
||||
<ResourceDictionary Source="pack://application:,,,/Themes/Dark.xaml" />
|
||||
<ResourceDictionary Source="pack://application:,,,/Themes/Darker.xaml" />
|
||||
<ResourceDictionary Source="pack://application:,,,/Languages/en.xaml" />
|
||||
</ResourceDictionary.MergedDictionaries>
|
||||
</ResourceDictionary>
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ namespace Flow.Launcher.Converters
|
|||
var queryText = (string)values[0];
|
||||
|
||||
if (string.IsNullOrEmpty(queryText))
|
||||
return "Type here to search";
|
||||
return string.Empty;
|
||||
|
||||
// second prop is the current selected item result
|
||||
var val = values[1];
|
||||
|
|
|
|||
|
|
@ -142,6 +142,9 @@
|
|||
<None Update="Images\logoff.png">
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
</None>
|
||||
<None Update="Images\mainsearch.png">
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
</None>
|
||||
<None Update="Images\New Message.png">
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
</None>
|
||||
|
|
|
|||
BIN
Flow.Launcher/Images/mainsearch.png
Normal file
BIN
Flow.Launcher/Images/mainsearch.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 62 KiB |
|
|
@ -18,6 +18,7 @@
|
|||
Style="{DynamicResource WindowStyle}"
|
||||
Icon="Images/app.png"
|
||||
AllowsTransparency="True"
|
||||
Background="Transparent"
|
||||
Loaded="OnLoaded"
|
||||
Initialized="OnInitialized"
|
||||
Closing="OnClosing"
|
||||
|
|
@ -58,13 +59,14 @@
|
|||
<KeyBinding Key="D8" Modifiers="Alt" Command="{Binding OpenResultCommand}" CommandParameter="7"></KeyBinding>
|
||||
<KeyBinding Key="D9" Modifiers="Alt" Command="{Binding OpenResultCommand}" CommandParameter="8"></KeyBinding>
|
||||
</Window.InputBindings>
|
||||
<Border Style="{DynamicResource WindowBorderStyle}" MouseDown="OnMouseDown" >
|
||||
<Border Style="{DynamicResource WindowBorderStyle}" MouseDown="OnMouseDown" CornerRadius="5" >
|
||||
<StackPanel Orientation="Vertical">
|
||||
<Grid>
|
||||
<TextBox x:Name="QueryTextSuggestionBox"
|
||||
Style="{DynamicResource QueryBoxStyle}"
|
||||
Foreground="DarkGray"
|
||||
IsEnabled="False">
|
||||
IsEnabled="False"
|
||||
Margin="0,0,56,0">
|
||||
<TextBox.Text>
|
||||
<MultiBinding Converter="{StaticResource QuerySuggestionBoxConverter}">
|
||||
<Binding ElementName="QueryTextBox" Path="Text"/>
|
||||
|
|
@ -79,7 +81,8 @@
|
|||
TextChanged="OnTextChanged"
|
||||
AllowDrop="True"
|
||||
Visibility="Visible"
|
||||
Background="Transparent">
|
||||
Background="Transparent"
|
||||
Margin="0,0,56,0">
|
||||
<TextBox.ContextMenu>
|
||||
<ContextMenu>
|
||||
<MenuItem Command="ApplicationCommands.Cut"/>
|
||||
|
|
@ -90,6 +93,7 @@
|
|||
</ContextMenu>
|
||||
</TextBox.ContextMenu>
|
||||
</TextBox>
|
||||
<Image Source="{Binding Image, IsAsync=True}" Width="48" HorizontalAlignment="Right" />
|
||||
</Grid>
|
||||
<Line x:Name="ProgressBar" HorizontalAlignment="Right"
|
||||
Style="{DynamicResource PendingLineStyle}" Visibility="{Binding ProgressBarVisibility, Mode=TwoWay}"
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
<Setter Property="FontSize" Value="28" />
|
||||
<Setter Property="FontWeight" Value="Medium" />
|
||||
<Setter Property="Height" Value="46" />
|
||||
<Setter Property="Background" Value="#616161" />
|
||||
<Setter Property="Background" Value="#2F2F2F" />
|
||||
<Setter Property="Foreground" Value="#E3E0E3" />
|
||||
<Setter Property="CaretBrush" Value="#E3E0E3" />
|
||||
<Setter Property="VerticalContentAlignment" Value="Center" />
|
||||
|
|
@ -33,7 +33,7 @@
|
|||
<Style x:Key="BaseWindowBorderStyle" TargetType="{x:Type Border}">
|
||||
<Setter Property="BorderThickness" Value="0" />
|
||||
<Setter Property="CornerRadius" Value="0" />
|
||||
<Setter Property="Background" Value="#424242"></Setter>
|
||||
<Setter Property="Background" Value="#2F2F2F"></Setter>
|
||||
<Setter Property="Padding" Value="8 10 8 8" />
|
||||
</Style>
|
||||
<Style x:Key="BaseWindowStyle" TargetType="{x:Type Window}">
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@
|
|||
</Style>
|
||||
<Style x:Key="ItemSubTitleSelectedStyle" BasedOn="{StaticResource BaseItemSubTitleSelectedStyle}" TargetType="{x:Type TextBlock}" >
|
||||
</Style>
|
||||
<SolidColorBrush x:Key="ItemSelectedBackgroundColor">#4F6180</SolidColorBrush>
|
||||
<SolidColorBrush x:Key="ItemSelectedBackgroundColor">#4D4D4D</SolidColorBrush>
|
||||
|
||||
<!-- button style in the middle of the scrollbar -->
|
||||
<Style x:Key="ThumbStyle" BasedOn="{StaticResource BaseThumbStyle}" TargetType="{x:Type Thumb}">
|
||||
|
|
@ -19,6 +19,8 @@ using Flow.Launcher.Infrastructure.UserSettings;
|
|||
using Flow.Launcher.Plugin;
|
||||
using Flow.Launcher.Plugin.SharedCommands;
|
||||
using Flow.Launcher.Storage;
|
||||
using System.Windows.Media;
|
||||
using Flow.Launcher.Infrastructure.Image;
|
||||
|
||||
namespace Flow.Launcher.ViewModel
|
||||
{
|
||||
|
|
@ -212,7 +214,7 @@ namespace Flow.Launcher.ViewModel
|
|||
Query();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// we need move cursor to end when we manually changed query
|
||||
/// but we don't want to move cursor to end when query is updated from TextBox
|
||||
|
|
@ -277,6 +279,8 @@ namespace Flow.Launcher.ViewModel
|
|||
public ICommand LoadHistoryCommand { get; set; }
|
||||
public ICommand OpenResultCommand { get; set; }
|
||||
|
||||
public ImageSource Image => ImageLoader.Load($"{Constant.ProgramDirectory}\\Images\\mainsearch.png");
|
||||
|
||||
#endregion
|
||||
|
||||
public void Query()
|
||||
|
|
|
|||
Loading…
Reference in a new issue