Skip to content

Commit b17dc2d

Browse files
committed
Use Fluent folder icon
1 parent 305584d commit b17dc2d

File tree

6 files changed

+52
-19
lines changed

6 files changed

+52
-19
lines changed

Files/Assets/FolderIcon.svg

Lines changed: 28 additions & 0 deletions
Loading

Files/Files.csproj

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -231,6 +231,7 @@
231231
<Content Include="Assets\Files UWP Icon.png" />
232232
<Content Include="Assets\FilesHome.png" />
233233
<Content Include="Assets\FilesDrive.png" />
234+
<Content Include="Assets\FolderIcon.svg" />
234235
<Content Include="Assets\logo.bmp" />
235236
<None Include="Package.StoreAssociation.xml" />
236237
<Content Include="Assets\QuickLook\quicklook_icon_black.png" />

Files/GenericFileBrowser.xaml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,11 @@
188188
<DataTemplate x:DataType="local2:ListedItem">
189189
<Grid x:Name="Icon" Margin="0, 0, 0, 0">
190190
<Rectangle Visibility="Collapsed" x:Name="CutIndicator" Opacity="0.1" Fill="LightGray"/>
191-
<FontIcon Visibility="{x:Bind FolderImg}" Glyph="&#xE8D5;" FontFamily="Segoe MDL2 Assets" Foreground="#ffe793"/>
191+
<Image Width="24" Height="24" Visibility="{x:Bind FolderImg}">
192+
<Image.Source>
193+
<SvgImageSource RasterizePixelWidth="128" RasterizePixelHeight="128" UriSource="/Assets/FolderIcon.svg" />
194+
</Image.Source>
195+
</Image>
192196
<FontIcon Visibility="{x:Bind EmptyImgVis}" Glyph="&#xE7C3;" FontFamily="Segoe MDL2 Assets"/>
193197
<Image Visibility="{x:Bind FileIconVis}" Height="20" Width="20" Source="{x:Bind FileImg}" Stretch="UniformToFill" />
194198
</Grid>

Files/InstanceTabsView.xaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@
107107
<ContentPresenter x:Name="RightContentPresenter" ContentTemplate="{TemplateBinding TabStripFooterTemplate}" Content="{TemplateBinding TabStripFooter}" Grid.Column="3" HorizontalAlignment="Stretch"/>
108108
</Grid>
109109
<Grid x:Name="ShadowCaster" Background="Transparent" Height="10" Margin="0,0,0,-10" Grid.Row="0" VerticalAlignment="Bottom"/>
110-
<ContentPresenter x:Name="TabContentPresenter" BorderThickness="{TemplateBinding BorderThickness}" BorderBrush="{TemplateBinding BorderBrush}" Grid.Row="1"/>
110+
<ContentPresenter ContentTransitions="{x:Null}" x:Name="TabContentPresenter" BorderThickness="{TemplateBinding BorderThickness}" BorderBrush="{TemplateBinding BorderBrush}" Grid.Row="1"/>
111111
</Grid>
112112
</ControlTemplate>
113113
</Setter.Value>

Files/PhotoAlbum.xaml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -160,11 +160,11 @@
160160
<Grid Padding="12" VerticalAlignment="Stretch" HorizontalAlignment="Stretch" x:Name="Picture" Visibility="{x:Bind FileIconVis}">
161161
<Image Stretch="Uniform" Source="{x:Bind FileImg}"/>
162162
</Grid>
163-
<Grid x:Name="Album" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Visibility="{x:Bind FolderImg}">
164-
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
165-
<FontIcon FontSize="72" Glyph="&#xE8D5;" FontFamily="Segoe MDL2 Assets" Foreground="#ffe793"/>
166-
</Grid>
167-
</Grid>
163+
<Image Stretch="Uniform" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Visibility="{x:Bind FolderImg}">
164+
<Image.Source>
165+
<SvgImageSource RasterizePixelWidth="128" RasterizePixelHeight="128" UriSource="/Assets/FolderIcon.svg" />
166+
</Image.Source>
167+
</Image>
168168
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Visibility="{x:Bind EmptyImgVis}">
169169
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
170170
<FontIcon FontSize="72" Glyph="&#xE7C3;" FontFamily="Segoe MDL2 Assets"/>

Files/ProHome.xaml.cs

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ private void LocationsList_ItemInvoked(Microsoft.UI.Xaml.Controls.NavigationView
220220

221221
if (clickedItem == "Home")
222222
{
223-
ItemDisplayFrame.Navigate(typeof(YourHome), "New tab");
223+
ItemDisplayFrame.Navigate(typeof(YourHome), "New tab", new SuppressNavigationTransitionInfo());
224224
PathText.Text = "New tab";
225225
HomeItems.isEnabled = false;
226226
ShareItems.isEnabled = false;
@@ -229,7 +229,7 @@ private void LocationsList_ItemInvoked(Microsoft.UI.Xaml.Controls.NavigationView
229229
}
230230
else if (clickedItem == "Desktop")
231231
{
232-
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), App.DesktopPath);
232+
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), App.DesktopPath, new SuppressNavigationTransitionInfo());
233233
PathText.Text = "Desktop";
234234
HomeItems.isEnabled = false;
235235
ShareItems.isEnabled = false;
@@ -238,7 +238,7 @@ private void LocationsList_ItemInvoked(Microsoft.UI.Xaml.Controls.NavigationView
238238
}
239239
else if (clickedItem == "Downloads")
240240
{
241-
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), App.DownloadsPath);
241+
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), App.DownloadsPath, new SuppressNavigationTransitionInfo());
242242
PathText.Text = "Downloads";
243243
HomeItems.isEnabled = false;
244244
ShareItems.isEnabled = false;
@@ -247,7 +247,7 @@ private void LocationsList_ItemInvoked(Microsoft.UI.Xaml.Controls.NavigationView
247247
}
248248
else if (clickedItem == "Documents")
249249
{
250-
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), App.DocumentsPath);
250+
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), App.DocumentsPath, new SuppressNavigationTransitionInfo());
251251
PathText.Text = "Documents";
252252
HomeItems.isEnabled = false;
253253
ShareItems.isEnabled = false;
@@ -256,7 +256,7 @@ private void LocationsList_ItemInvoked(Microsoft.UI.Xaml.Controls.NavigationView
256256
}
257257
else if (clickedItem == "Pictures")
258258
{
259-
ItemDisplayFrame.Navigate(typeof(PhotoAlbum), App.PicturesPath);
259+
ItemDisplayFrame.Navigate(typeof(PhotoAlbum), App.PicturesPath, new SuppressNavigationTransitionInfo());
260260
PathText.Text = "Pictures";
261261
HomeItems.isEnabled = false;
262262
ShareItems.isEnabled = false;
@@ -265,7 +265,7 @@ private void LocationsList_ItemInvoked(Microsoft.UI.Xaml.Controls.NavigationView
265265
}
266266
else if (clickedItem == "Music")
267267
{
268-
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), App.MusicPath);
268+
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), App.MusicPath, new SuppressNavigationTransitionInfo());
269269
PathText.Text = "Music";
270270
HomeItems.isEnabled = false;
271271
ShareItems.isEnabled = false;
@@ -274,7 +274,7 @@ private void LocationsList_ItemInvoked(Microsoft.UI.Xaml.Controls.NavigationView
274274
}
275275
else if (clickedItem == "Videos")
276276
{
277-
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), App.VideosPath);
277+
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), App.VideosPath, new SuppressNavigationTransitionInfo());
278278
PathText.Text = "Videos";
279279
HomeItems.isEnabled = false;
280280
ShareItems.isEnabled = false;
@@ -283,7 +283,7 @@ private void LocationsList_ItemInvoked(Microsoft.UI.Xaml.Controls.NavigationView
283283
}
284284
else
285285
{
286-
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), clickedItemContainer.Tag.ToString());
286+
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), clickedItemContainer.Tag.ToString(), new SuppressNavigationTransitionInfo());
287287
PathText.Text = clickedItem;
288288
HomeItems.isEnabled = false;
289289
ShareItems.isEnabled = false;
@@ -316,19 +316,19 @@ private void DrivesList_ItemInvoked(Microsoft.UI.Xaml.Controls.NavigationView se
316316

317317
if (clickedItem.Tag.ToString() == "LocalDisk")
318318
{
319-
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), @"C:\");
319+
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), @"C:\", new SuppressNavigationTransitionInfo());
320320
PathText.Text = @"Local Disk (C:\)";
321321
LayoutItems.isEnabled = true;
322322
}
323323
else if (clickedItem.Tag.ToString() == "OneDrive")
324324
{
325-
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), App.OneDrivePath);
325+
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), App.OneDrivePath, new SuppressNavigationTransitionInfo());
326326
PathText.Text = "OneDrive";
327327
LayoutItems.isEnabled = true;
328328
}
329329
else
330330
{
331-
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), clickedItem.Tag.ToString());
331+
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), clickedItem.Tag.ToString(), new SuppressNavigationTransitionInfo());
332332
PathText.Text = clickedItem.Tag.ToString();
333333
LayoutItems.isEnabled = true;
334334
}
@@ -401,7 +401,7 @@ private void LinuxList_ItemInvoked(Microsoft.UI.Xaml.Controls.NavigationView sen
401401

402402
var clickedItem = args.InvokedItemContainer;
403403

404-
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), clickedItem.Tag.ToString());
404+
ItemDisplayFrame.Navigate(typeof(GenericFileBrowser), clickedItem.Tag.ToString(), new SuppressNavigationTransitionInfo());
405405
PathText.Text = clickedItem.Tag.ToString();
406406
LayoutItems.isEnabled = true;
407407
}

0 commit comments

Comments
 (0)