Namespaces fix

This commit is contained in:
Yaroslav Zyubanov
2014-05-24 14:07:03 +06:00
parent 9eefd8839c
commit 33d7e40e7c
5 changed files with 18 additions and 22 deletions

View File

@@ -3,11 +3,10 @@
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:wox="clr-namespace:Wox" xmlns:converters="clr-namespace:Wox.Converters"
mc:Ignorable="d" d:DesignWidth="100" d:DesignHeight="100" mc:Ignorable="d" d:DesignWidth="100" d:DesignHeight="100">
>
<UserControl.Resources> <UserControl.Resources>
<wox:ImagePathConverter x:Key="ImagePathConverter"/> <converters:ImagePathConverter x:Key="ImagePathConverter"/>
</UserControl.Resources> </UserControl.Resources>
<!-- set max height of listbox to allow 6 results showed at once --> <!-- set max height of listbox to allow 6 results showed at once -->
@@ -42,7 +41,7 @@
<RowDefinition Height="Auto" x:Name="SubTitleRowDefinition"></RowDefinition> <RowDefinition Height="Auto" x:Name="SubTitleRowDefinition"></RowDefinition>
</Grid.RowDefinitions> </Grid.RowDefinitions>
<TextBlock Style="{DynamicResource ItemTitleStyle}" VerticalAlignment="Center" ToolTip="{Binding Title}" x:Name="tbTitle" Text="{Binding Title}"></TextBlock> <TextBlock Style="{DynamicResource ItemTitleStyle}" VerticalAlignment="Center" ToolTip="{Binding Title}" x:Name="tbTitle" Text="{Binding Title}"></TextBlock>
<TextBlock Style="{DynamicResource ItemSubTitleStyle}" ToolTip="{Binding SubTitle}" Visibility="{Binding SubTitle, Converter={wox:StringNullOrEmptyToVisibilityConverter}}" Grid.Row="1" x:Name="tbSubTitle" Text="{Binding SubTitle}"></TextBlock> <TextBlock Style="{DynamicResource ItemSubTitleStyle}" ToolTip="{Binding SubTitle}" Visibility="{Binding SubTitle, Converter={converters:StringNullOrEmptyToVisibilityConverter}}" Grid.Row="1" x:Name="tbSubTitle" Text="{Binding SubTitle}"></TextBlock>
</Grid> </Grid>
</Grid> </Grid>
<DataTemplate.Triggers> <DataTemplate.Triggers>

View File

@@ -1,16 +1,10 @@
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Diagnostics;
using System.Windows; using System.Windows;
using System.Windows.Controls; using System.Windows.Controls;
using System.Windows.Forms;
using System.Windows.Input; using System.Windows.Input;
using System.Windows.Media; using System.Windows.Media;
using System.Windows.Media.Animation;
using Wox.Helper;
using Wox.Infrastructure;
using Wox.Plugin; using Wox.Plugin;
using MessageBox = System.Windows.MessageBox;
using UserControl = System.Windows.Controls.UserControl; using UserControl = System.Windows.Controls.UserControl;
namespace Wox namespace Wox

View File

@@ -5,13 +5,14 @@
xmlns:UserSettings="clr-namespace:Wox.Infrastructure.Storage.UserSettings;assembly=Wox.Infrastructure" x:Class="Wox.SettingWindow" xmlns:UserSettings="clr-namespace:Wox.Infrastructure.Storage.UserSettings;assembly=Wox.Infrastructure" x:Class="Wox.SettingWindow"
xmlns:woxPlugin="clr-namespace:Wox.Plugin;assembly=Wox.Plugin" xmlns:woxPlugin="clr-namespace:Wox.Plugin;assembly=Wox.Plugin"
xmlns:system="clr-namespace:Wox.Plugin.SystemPlugins;assembly=Wox.Plugin.SystemPlugins" xmlns:system="clr-namespace:Wox.Plugin.SystemPlugins;assembly=Wox.Plugin.SystemPlugins"
xmlns:converters="clr-namespace:Wox.Converters"
Icon="Images\app.png" Icon="Images\app.png"
Title="Wox Setting" Title="Wox Setting"
ResizeMode="NoResize" ResizeMode="NoResize"
WindowStartupLocation="CenterScreen" WindowStartupLocation="CenterScreen"
Height="600" Width="800"> Height="600" Width="800">
<Window.Resources> <Window.Resources>
<wox:ImagePathConverter x:Key="ImagePathConverter"/> <converters:ImagePathConverter x:Key="ImagePathConverter"/>
<ListBoxItem HorizontalContentAlignment="Stretch" <ListBoxItem HorizontalContentAlignment="Stretch"
IsEnabled="False" IsEnabled="False"
IsHitTestVisible="False" x:Key="FeatureBoxSeperator"> IsHitTestVisible="False" x:Key="FeatureBoxSeperator">
@@ -71,7 +72,7 @@
<RowDefinition Height="Auto"></RowDefinition> <RowDefinition Height="Auto"></RowDefinition>
</Grid.RowDefinitions> </Grid.RowDefinitions>
<TextBlock VerticalAlignment="Center" ToolTip="{Binding Name}" x:Name="tbTitle" Text="{Binding Name}"></TextBlock> <TextBlock VerticalAlignment="Center" ToolTip="{Binding Name}" x:Name="tbTitle" Text="{Binding Name}"></TextBlock>
<TextBlock ToolTip="{Binding Description}" Visibility="{Binding Description, Converter={wox:StringNullOrEmptyToVisibilityConverter}}" Grid.Row="1" x:Name="tbSubTitle" Text="{Binding Description}" Opacity="0.5"></TextBlock> <TextBlock ToolTip="{Binding Description}" Visibility="{Binding Description, Converter={converters:StringNullOrEmptyToVisibilityConverter}}" Grid.Row="1" x:Name="tbSubTitle" Text="{Binding Description}" Opacity="0.5"></TextBlock>
</Grid> </Grid>
<CheckBox Content="Enabled" /> <CheckBox Content="Enabled" />
</Grid> </Grid>
@@ -98,7 +99,7 @@
<RowDefinition Height="Auto"></RowDefinition> <RowDefinition Height="Auto"></RowDefinition>
</Grid.RowDefinitions> </Grid.RowDefinitions>
<TextBlock VerticalAlignment="Center" ToolTip="{Binding Metadata.Name}" x:Name="tbTitle" Text="{Binding Metadata.Name}"></TextBlock> <TextBlock VerticalAlignment="Center" ToolTip="{Binding Metadata.Name}" x:Name="tbTitle" Text="{Binding Metadata.Name}"></TextBlock>
<TextBlock ToolTip="{Binding Metadata.Description}" Visibility="{Binding Metadata.Description, Converter={wox:StringNullOrEmptyToVisibilityConverter}}" Grid.Row="1" x:Name="tbSubTitle" Text="{Binding Metadata.Description}" Opacity="0.5"></TextBlock> <TextBlock ToolTip="{Binding Metadata.Description}" Visibility="{Binding Metadata.Description, Converter={converters:StringNullOrEmptyToVisibilityConverter}}" Grid.Row="1" x:Name="tbSubTitle" Text="{Binding Metadata.Description}" Opacity="0.5"></TextBlock>
</Grid> </Grid>
</Grid> </Grid>
</DataTemplate> </DataTemplate>
@@ -122,7 +123,7 @@
<RowDefinition Height="Auto"></RowDefinition> <RowDefinition Height="Auto"></RowDefinition>
</Grid.RowDefinitions> </Grid.RowDefinitions>
<TextBlock VerticalAlignment="Center" x:Name="pluginTitle" ToolTip="{Binding Source=pluginTitle, Path=Text}" FontSize="24"></TextBlock> <TextBlock VerticalAlignment="Center" x:Name="pluginTitle" ToolTip="{Binding Source=pluginTitle, Path=Text}" FontSize="24"></TextBlock>
<TextBlock Grid.Row="1" x:Name="pluginSubTitle" Opacity="0.5" ToolTip="{Binding Source=pluginSubTitle, Path=Text}" Visibility="{Binding Source=pluginSubTitle, Path=Text, Converter={wox:StringNullOrEmptyToVisibilityConverter}}" ></TextBlock> <TextBlock Grid.Row="1" x:Name="pluginSubTitle" Opacity="0.5" ToolTip="{Binding Source=pluginSubTitle, Path=Text}" Visibility="{Binding Source=pluginSubTitle, Path=Text, Converter={converters:StringNullOrEmptyToVisibilityConverter}}" ></TextBlock>
</Grid> </Grid>
</Grid> </Grid>
</ContentControl> </ContentControl>
@@ -215,7 +216,7 @@
<UserSettings:OpacityMode>DWM</UserSettings:OpacityMode> <UserSettings:OpacityMode>DWM</UserSettings:OpacityMode>
<ComboBox.ItemTemplate> <ComboBox.ItemTemplate>
<DataTemplate> <DataTemplate>
<TextBlock Text="{Binding Converter={wox:OpacityModeConverter}}" /> <TextBlock Text="{Binding Converter={converters:OpacityModeConverter}}" />
</DataTemplate> </DataTemplate>
</ComboBox.ItemTemplate> </ComboBox.ItemTemplate>
</ComboBox> </ComboBox>

View File

@@ -9,6 +9,7 @@ using System.Windows.Media;
using System.Windows.Media.Imaging; using System.Windows.Media.Imaging;
using IWshRuntimeLibrary; using IWshRuntimeLibrary;
using Microsoft.VisualBasic.ApplicationServices; using Microsoft.VisualBasic.ApplicationServices;
using Wox.Converters;
using Wox.Infrastructure; using Wox.Infrastructure;
using Wox.Infrastructure.Storage; using Wox.Infrastructure.Storage;
using Wox.Infrastructure.Storage.UserSettings; using Wox.Infrastructure.Storage.UserSettings;
@@ -462,7 +463,7 @@ namespace Wox
() => () =>
pluginIcon.Source = pluginIcon.Source =
(ImageSource) (ImageSource)
new Wox.ImagePathConverter().Convert( new ImagePathConverter().Convert(
new object[] {pair.Metadata.IcoPath, pair.Metadata.PluginDirecotry}, null, null, new object[] {pair.Metadata.IcoPath, pair.Metadata.PluginDirecotry}, null, null,
null)); null));
} }
@@ -479,7 +480,7 @@ namespace Wox
() => () =>
pluginIcon.Source = pluginIcon.Source =
(ImageSource) (ImageSource)
new Wox.ImagePathConverter().Convert( new ImagePathConverter().Convert(
new object[] { sys.IcoPath, sys.PluginDirectory }, null, null, new object[] { sys.IcoPath, sys.PluginDirectory }, null, null,
null)); null));
} }

View File

@@ -109,6 +109,7 @@
<Compile Include="Commands\CommandFactory.cs" /> <Compile Include="Commands\CommandFactory.cs" />
<Compile Include="Commands\PluginCommand.cs" /> <Compile Include="Commands\PluginCommand.cs" />
<Compile Include="Commands\SystemCommand.cs" /> <Compile Include="Commands\SystemCommand.cs" />
<Compile Include="Converters\ConvertorBase.cs" />
<Compile Include="Helper\DataWebRequestFactory.cs" /> <Compile Include="Helper\DataWebRequestFactory.cs" />
<Compile Include="Helper\ErrorReporting\ErrorReporting.cs" /> <Compile Include="Helper\ErrorReporting\ErrorReporting.cs" />
<Compile Include="Helper\ErrorReporting\WPFErrorReportingDialog.xaml.cs"> <Compile Include="Helper\ErrorReporting\WPFErrorReportingDialog.xaml.cs">
@@ -120,7 +121,7 @@
<Compile Include="Helper\WallpaperPathRetrieval.cs" /> <Compile Include="Helper\WallpaperPathRetrieval.cs" />
<Compile Include="Helper\WindowIntelopHelper.cs" /> <Compile Include="Helper\WindowIntelopHelper.cs" />
<Compile Include="Helper\WindowOpener.cs" /> <Compile Include="Helper\WindowOpener.cs" />
<Compile Include="OpacityModeConverter.cs" /> <Compile Include="Converters\OpacityModeConverter.cs" />
<Compile Include="CustomPluginHotkeySetting.xaml.cs"> <Compile Include="CustomPluginHotkeySetting.xaml.cs">
<DependentUpon>CustomPluginHotkeySetting.xaml</DependentUpon> <DependentUpon>CustomPluginHotkeySetting.xaml</DependentUpon>
</Compile> </Compile>
@@ -133,7 +134,7 @@
<Compile Include="HotkeyControl.xaml.cs"> <Compile Include="HotkeyControl.xaml.cs">
<DependentUpon>HotkeyControl.xaml</DependentUpon> <DependentUpon>HotkeyControl.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="ImagePathConverter.cs" /> <Compile Include="Converters\ImagePathConverter.cs" />
<Compile Include="Msg.xaml.cs"> <Compile Include="Msg.xaml.cs">
<DependentUpon>Msg.xaml</DependentUpon> <DependentUpon>Msg.xaml</DependentUpon>
</Compile> </Compile>
@@ -149,8 +150,8 @@
<Compile Include="SettingWindow.xaml.cs"> <Compile Include="SettingWindow.xaml.cs">
<DependentUpon>SettingWindow.xaml</DependentUpon> <DependentUpon>SettingWindow.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="StringEmptyConverter.cs" /> <Compile Include="Converters\StringEmptyConverter.cs" />
<Compile Include="StringNullOrEmptyToVisibilityConverter.cs" /> <Compile Include="Converters\StringNullOrEmptyToVisibilityConverter.cs" />
<Page Include="Helper\ErrorReporting\WPFErrorReportingDialog.xaml"> <Page Include="Helper\ErrorReporting\WPFErrorReportingDialog.xaml">
<SubType>Designer</SubType> <SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>