/Application/GUI/Controls/Navigation.xaml

http://yet-another-music-application.googlecode.com/ · XAML · 108 lines · 85 code · 7 blank · 16 comment · 0 complexity · c8280320eb14a82210efb0f87ac68507 MD5 · raw file

  1. <!--Navigation.xaml
  2. The left-hand navigation tree.
  3. = = = = = = = = = =
  4. This code is part of the Stoffi Music Player Project.
  5. Visit our website at: stoffiplayer.com
  6. This program is free software; you can redistribute it and/or
  7. modify it under the terms of the GNU General Public License
  8. as published by the Free Software Foundation; either version
  9. 3 of the License, or (at your option) any later version.
  10. See stoffiplayer.com/license for more information.
  11. -->
  12. <UserControl x:Class="Stoffi.Navigation"
  13. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  14. xmlns:loc="http://schemas.tomer.com/winfx/2006/xaml/presentation"
  15. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  16. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  17. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  18. xmlns:local="clr-namespace:Stoffi"
  19. mc:Ignorable="d"
  20. Loaded="Navigation_Loaded"
  21. d:DesignHeight="300" d:DesignWidth="300">
  22. <Grid>
  23. <TreeView BorderThickness="0" x:Name="NavigationTree" Padding="0 10 0 0" KeyUp="NavigationTree_KeyUp">
  24. <TreeViewItem x:Name="NowPlaying" Margin="0 10" Selected="NowPlaying_Selected">
  25. <TreeViewItem.Header>
  26. <StackPanel Orientation="Horizontal">
  27. <Image Source="..\Images\Icons\NoteSingle.ico" Width="16" Height="16" Name="NowPlayingIcon"/>
  28. <TextBlock loc:Translate.Uid="NavigationNowPlaying" Text="{loc:Translate Text}" Margin="5 0"/>
  29. </StackPanel>
  30. </TreeViewItem.Header>
  31. </TreeViewItem>
  32. <TreeViewItem x:Name="Library" Margin="0 10" IsExpanded="True">
  33. <TreeViewItem.Header>
  34. <StackPanel Orientation="Horizontal">
  35. <Image Source="..\Images\Icons\Library.ico" Width="16" Height="16" Name="MusicIcon" />
  36. <TextBlock loc:Translate.Uid="NavigationMusic" Text="{loc:Translate Text}" Margin="5 0"/>
  37. </StackPanel>
  38. </TreeViewItem.Header>
  39. <TreeViewItem x:Name="Files" Selected="Files_Selected" Padding="8 0 0 0">
  40. <TreeViewItem.Header>
  41. <StackPanel Orientation="Horizontal">
  42. <Image Source="..\Images\Icons\FileAudio.ico" Width="16" Height="16" Name="FilesIcon"/>
  43. <TextBlock loc:Translate.Uid="NavigationFiles" Text="{loc:Translate Text}" Margin="5 0"/>
  44. </StackPanel>
  45. </TreeViewItem.Header>
  46. </TreeViewItem>
  47. <TreeViewItem x:Name="Youtube" Selected="Youtube_Selected" Padding="8 0 0 0">
  48. <TreeViewItem.Header>
  49. <StackPanel Orientation="Horizontal">
  50. <Image Source="..\Images\Icons\YouTube.ico" Width="16" Height="16" Name="YoutubeIcon"/>
  51. <TextBlock loc:Translate.Uid="NavigationYouTube" Text="{loc:Translate Text}" Margin="5 0"/>
  52. </StackPanel>
  53. </TreeViewItem.Header>
  54. </TreeViewItem>
  55. </TreeViewItem>
  56. <TreeViewItem x:Name="Queue" Margin="0 10" Selected="Queue_Selected">
  57. <TreeViewItem.Header>
  58. <StackPanel Orientation="Horizontal">
  59. <Image Source="..\Images\Icons\Queue.ico" Width="16" Height="16" Name="QueueIcon"/>
  60. <TextBlock loc:Translate.Uid="NavigationQueue" Text="{loc:Translate Text}" Margin="5 0"/>
  61. </StackPanel>
  62. </TreeViewItem.Header>
  63. </TreeViewItem>
  64. <TreeViewItem x:Name="History" Margin="0 10" Selected="History_Selected">
  65. <TreeViewItem.Header>
  66. <StackPanel Orientation="Horizontal">
  67. <Image Source="..\Images\Icons\Clock.ico" Width="16" Height="16" Name="HistoryIcon"/>
  68. <TextBlock loc:Translate.Uid="NavigationHistory" Text="{loc:Translate Text}" Margin="5 0"/>
  69. </StackPanel>
  70. </TreeViewItem.Header>
  71. </TreeViewItem>
  72. <TreeViewItem x:Name="Playlists" Margin="0 10" Selected="Playlists_Selected" AllowDrop="True" IsExpanded="True">
  73. <TreeViewItem.Header>
  74. <StackPanel Orientation="Horizontal">
  75. <Image Source="..\Images\Icons\DiscAudio.ico" Width="16" Height="16" Name="PlaylistsIcon"/>
  76. <TextBlock loc:Translate.Uid="NavigationPlaylists" Text="{loc:Translate Text}" Margin="5 0"/>
  77. </StackPanel>
  78. </TreeViewItem.Header>
  79. <TreeViewItem x:Name="CreateNewPlaylist" Selected="CreateNewPlaylist_Selected" Drop="Playlist_Drop" Padding="8 0 0 0">
  80. <TreeViewItem.Header>
  81. <StackPanel Orientation="Horizontal">
  82. <Image Source="..\Images\Icons\DiscAudio.ico" Width="16" Height="16" Name="CreateNewIcon"/>
  83. <local:EditableTextBlock x:Name="CreateNewPlaylistETB"
  84. Margin="5 0"
  85. loc:Translate.Uid="NavigationCreateNew"
  86. Text="{loc:Translate Text}"
  87. FontStyle="Italic"
  88. Edited="CreateNewPlaylist_Edited"
  89. Canceled="CreateNewPlaylist_Canceled"/>
  90. </StackPanel>
  91. </TreeViewItem.Header>
  92. </TreeViewItem>
  93. </TreeViewItem>
  94. </TreeView>
  95. </Grid>
  96. </UserControl>