<TreeView IsRoot="true" Name="treeView" Data="{./FileSystemEntries}" Background="{./Background}"
SelectedItemChanged="./onSelectedItemChanged">
<ItemTemplate DataType="System.IO.FileInfo">
- <HorizontalStack Focusable="true" Height="Fit" Width="Stretched" >
- <Image Margin="2" Width="14" Height="14"
- Path="#Crow.Icons.file.svg"/>
- <Label Text="{Name}" Width="Stretched"
- MouseEnter="{Background=vgradient|0:White|0.05:UnitedNationsBlue|1:Jet}"
- MouseLeave="{Background=Transparent}"/>
- </HorizontalStack>
+ <Border CornerRadius="2" Margin="0" Focusable="true" Height="Fit" Width="Stretched" Foreground="Transparent"
+ MouseEnter="{Foreground=DimGray}"
+ MouseLeave="{Foreground=Transparent}">
+ <HorizontalStack>
+ <Image Margin="1" Width="14" Height="14"
+ Path="#Crow.Icons.file.svg"/>
+ <Label Text="{Name}" Width="Stretched"/>
+ </HorizontalStack>
+ </Border>
</ItemTemplate>
<ItemTemplate DataType="System.IO.DirectoryInfo" Data="GetFileSystemInfos">
<Expandable Caption="{Name}" >
<Template>
<VerticalStack>
- <HorizontalStack Spacing="1" Height="Fit" MouseDoubleClick="./onClickForExpand"
- MouseEnter="{Background=vgradient|0:White|0.05:UnitedNationsBlue|1:Jet}"
- MouseLeave="{Background=Transparent}">
- <Container Margin="1" Width="10" Height="10" Focusable="true" MouseClick="./onClickForExpand"
- MouseEnter="{Background=LightGray}"
- MouseLeave="{Background=Transparent}">
- <Image
+ <Border CornerRadius="2" Margin="0" Height="Fit" MouseDoubleClick="./onClickForExpand"
+ Foreground="Transparent"
+ MouseEnter="{Foreground=DimGray}"
+ MouseLeave="{Foreground=Transparent}">
+ <HorizontalStack Spacing="1">
+ <Image Margin="1" Width="10" Height="10" Focusable="true" MouseClick="./onClickForExpand"
Path="{./Image}"
Visible="{./IsExpandable}"
- SvgSub="{./IsExpanded}"/>
- </Container>
- <Image Margin="2" Width="14" Height="14"
- Path="#Crow.Icons.folder.svg"/>
- <Label Text="{./Caption}"/>
- </HorizontalStack>
+ SvgSub="{./IsExpanded}"
+ MouseEnter="{Background=LightGray}"
+ MouseLeave="{Background=Transparent}"/>
+ <Image Margin="1" Width="14" Height="14"
+ Path="#Crow.Icons.folder.svg"/>
+ <Label Text="{./Caption}"/>
+ </HorizontalStack>
+ </Border>
<Container Name="Content" Visible="false"/>
</VerticalStack>
</Template>
{
return s.Width <= i && s.Height <= i ? true : false;
}
- public static bool operator <=(Size s1, Size s2)
+ public static bool operator >(Size s, int i)
+ {
+ return s.Width > i && s.Height > i ? true : false;
+ }
+ public static bool operator >=(Size s, int i)
+ {
+ return s.Width >= i && s.Height >= i ? true : false;
+ }
+ public static bool operator <=(Size s1, Size s2)
{
if (s1.Width <= s2.Width && s1.Height <= s2.Height)
return true;