├── .gitignore ├── HamburgerMenu.sln ├── HamburgerMenu ├── HamburgerMenu.cs ├── HamburgerMenu.csproj ├── HamburgerMenuItem.cs ├── Properties │ └── AssemblyInfo.cs └── Themes │ ├── ButtonStyle.xaml │ ├── Generic.xaml │ ├── HamburgerMenu.xaml │ ├── HamburgerMenuItem.xaml │ ├── ListBoxStyle.xaml │ └── ToggleButtonStyle.xaml ├── HamburgerMenuDemo ├── App.config ├── App.xaml ├── App.xaml.cs ├── Assets │ ├── favorite.png │ ├── home.png │ ├── list.png │ ├── person.png │ └── search.png ├── HamburgerMenuDemo.csproj ├── MainWindow.xaml ├── MainWindow.xaml.cs └── Properties │ ├── AssemblyInfo.cs │ ├── Resources.Designer.cs │ ├── Resources.resx │ ├── Settings.Designer.cs │ └── Settings.settings ├── LICENSE └── README.md /.gitignore: -------------------------------------------------------------------------------- 1 | ## Ignore Visual Studio temporary files, build results, and 2 | ## files generated by popular Visual Studio add-ons. 3 | 4 | # User-specific files 5 | *.suo 6 | *.user 7 | *.userosscache 8 | *.sln.docstates 9 | 10 | # User-specific files (MonoDevelop/Xamarin Studio) 11 | *.userprefs 12 | 13 | # Build results 14 | [Dd]ebug/ 15 | [Dd]ebugPublic/ 16 | [Rr]elease/ 17 | [Rr]eleases/ 18 | x64/ 19 | x86/ 20 | build/ 21 | bld/ 22 | [Bb]in/ 23 | [Oo]bj/ 24 | 25 | # Visual Studo 2015 cache/options directory 26 | .vs/ 27 | 28 | # MSTest test Results 29 | [Tt]est[Rr]esult*/ 30 | [Bb]uild[Ll]og.* 31 | 32 | # NUNIT 33 | *.VisualState.xml 34 | TestResult.xml 35 | 36 | # Build Results of an ATL Project 37 | [Dd]ebugPS/ 38 | [Rr]eleasePS/ 39 | dlldata.c 40 | 41 | *_i.c 42 | *_p.c 43 | *_i.h 44 | *.ilk 45 | *.meta 46 | *.obj 47 | *.pch 48 | *.pdb 49 | *.pgc 50 | *.pgd 51 | *.rsp 52 | *.sbr 53 | *.tlb 54 | *.tli 55 | *.tlh 56 | *.tmp 57 | *.tmp_proj 58 | *.log 59 | *.vspscc 60 | *.vssscc 61 | .builds 62 | *.pidb 63 | *.svclog 64 | *.scc 65 | 66 | # Chutzpah Test files 67 | _Chutzpah* 68 | 69 | # Visual C++ cache files 70 | ipch/ 71 | *.aps 72 | *.ncb 73 | *.opensdf 74 | *.sdf 75 | *.cachefile 76 | 77 | # Visual Studio profiler 78 | *.psess 79 | *.vsp 80 | *.vspx 81 | 82 | # TFS 2012 Local Workspace 83 | $tf/ 84 | 85 | # Guidance Automation Toolkit 86 | *.gpState 87 | 88 | # ReSharper is a .NET coding add-in 89 | _ReSharper*/ 90 | *.[Rr]e[Ss]harper 91 | *.DotSettings.user 92 | 93 | # JustCode is a .NET coding addin-in 94 | .JustCode 95 | 96 | # TeamCity is a build add-in 97 | _TeamCity* 98 | 99 | # DotCover is a Code Coverage Tool 100 | *.dotCover 101 | 102 | # NCrunch 103 | _NCrunch_* 104 | .*crunch*.local.xml 105 | 106 | # MightyMoose 107 | *.mm.* 108 | AutoTest.Net/ 109 | 110 | # Web workbench (sass) 111 | .sass-cache/ 112 | 113 | # Installshield output folder 114 | [Ee]xpress/ 115 | 116 | # DocProject is a documentation generator add-in 117 | DocProject/buildhelp/ 118 | DocProject/Help/*.HxT 119 | DocProject/Help/*.HxC 120 | DocProject/Help/*.hhc 121 | DocProject/Help/*.hhk 122 | DocProject/Help/*.hhp 123 | DocProject/Help/Html2 124 | DocProject/Help/html 125 | 126 | # Click-Once directory 127 | publish/ 128 | 129 | # Publish Web Output 130 | *.[Pp]ublish.xml 131 | *.azurePubxml 132 | # TODO: Comment the next line if you want to checkin your web deploy settings 133 | # but database connection strings (with potential passwords) will be unencrypted 134 | *.pubxml 135 | *.publishproj 136 | 137 | # NuGet Packages 138 | *.nupkg 139 | # The packages folder can be ignored because of Package Restore 140 | **/packages/* 141 | # except build/, which is used as an MSBuild target. 142 | !**/packages/build/ 143 | # Uncomment if necessary however generally it will be regenerated when needed 144 | #!**/packages/repositories.config 145 | 146 | # Windows Azure Build Output 147 | csx/ 148 | *.build.csdef 149 | 150 | # Windows Store app package directory 151 | AppPackages/ 152 | 153 | # Others 154 | *.[Cc]ache 155 | ClientBin/ 156 | [Ss]tyle[Cc]op.* 157 | ~$* 158 | *~ 159 | *.dbmdl 160 | *.dbproj.schemaview 161 | *.pfx 162 | *.publishsettings 163 | node_modules/ 164 | bower_components/ 165 | 166 | # RIA/Silverlight projects 167 | Generated_Code/ 168 | 169 | # Backup & report files from converting an old project file 170 | # to a newer Visual Studio version. Backup files are not needed, 171 | # because we have git ;-) 172 | _UpgradeReport_Files/ 173 | Backup*/ 174 | UpgradeLog*.XML 175 | UpgradeLog*.htm 176 | 177 | # SQL Server files 178 | *.mdf 179 | *.ldf 180 | 181 | # Business Intelligence projects 182 | *.rdl.data 183 | *.bim.layout 184 | *.bim_*.settings 185 | 186 | # Microsoft Fakes 187 | FakesAssemblies/ 188 | 189 | # Node.js Tools for Visual Studio 190 | .ntvs_analysis.dat 191 | 192 | # Visual Studio 6 build log 193 | *.plg 194 | 195 | # Visual Studio 6 workspace options file 196 | *.opt 197 | -------------------------------------------------------------------------------- /HamburgerMenu.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio 14 4 | VisualStudioVersion = 14.0.24720.0 5 | MinimumVisualStudioVersion = 10.0.40219.1 6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HamburgerMenu", "HamburgerMenu\HamburgerMenu.csproj", "{CF1B7D25-4744-4B04-B725-7F2D8223806B}" 7 | EndProject 8 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HamburgerMenuDemo", "HamburgerMenuDemo\HamburgerMenuDemo.csproj", "{C987C1BB-C5A2-4EF2-96DB-C7C55C4FE23C}" 9 | EndProject 10 | Global 11 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 12 | Debug|Any CPU = Debug|Any CPU 13 | Release|Any CPU = Release|Any CPU 14 | EndGlobalSection 15 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 16 | {CF1B7D25-4744-4B04-B725-7F2D8223806B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 17 | {CF1B7D25-4744-4B04-B725-7F2D8223806B}.Debug|Any CPU.Build.0 = Debug|Any CPU 18 | {CF1B7D25-4744-4B04-B725-7F2D8223806B}.Release|Any CPU.ActiveCfg = Release|Any CPU 19 | {CF1B7D25-4744-4B04-B725-7F2D8223806B}.Release|Any CPU.Build.0 = Release|Any CPU 20 | {C987C1BB-C5A2-4EF2-96DB-C7C55C4FE23C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 21 | {C987C1BB-C5A2-4EF2-96DB-C7C55C4FE23C}.Debug|Any CPU.Build.0 = Debug|Any CPU 22 | {C987C1BB-C5A2-4EF2-96DB-C7C55C4FE23C}.Release|Any CPU.ActiveCfg = Release|Any CPU 23 | {C987C1BB-C5A2-4EF2-96DB-C7C55C4FE23C}.Release|Any CPU.Build.0 = Release|Any CPU 24 | EndGlobalSection 25 | GlobalSection(SolutionProperties) = preSolution 26 | HideSolutionNode = FALSE 27 | EndGlobalSection 28 | EndGlobal 29 | -------------------------------------------------------------------------------- /HamburgerMenu/HamburgerMenu.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using System.Windows; 7 | using System.Windows.Controls; 8 | using System.Windows.Media; 9 | 10 | namespace HamburgerMenu 11 | { 12 | public class HamburgerMenu : ContentControl 13 | { 14 | public new List Content 15 | { 16 | get { return (List)GetValue(ContentProperty); } 17 | set { SetValue(ContentProperty, value); } 18 | } 19 | 20 | public new static readonly DependencyProperty ContentProperty = 21 | DependencyProperty.Register("Content", typeof(List), typeof(HamburgerMenu), 22 | new FrameworkPropertyMetadata(null, FrameworkPropertyMetadataOptions.AffectsRender | FrameworkPropertyMetadataOptions.AffectsMeasure)); 23 | 24 | static HamburgerMenu() 25 | { 26 | DefaultStyleKeyProperty.OverrideMetadata(typeof(HamburgerMenu), new FrameworkPropertyMetadata(typeof(HamburgerMenu))); 27 | } 28 | 29 | public override void BeginInit() 30 | { 31 | Content = new List(); 32 | base.BeginInit(); 33 | } 34 | 35 | public bool IsOpen 36 | { 37 | get { return (bool)GetValue(IsOpenProperty); } 38 | set 39 | { 40 | SetValue(IsOpenProperty, value); 41 | } 42 | } 43 | 44 | public static readonly DependencyProperty IsOpenProperty = 45 | DependencyProperty.Register("IsOpen", typeof(bool), typeof(HamburgerMenu), new PropertyMetadata(true)); 46 | 47 | 48 | public System.Windows.Media.Brush MenuIconColor 49 | { 50 | get { return (System.Windows.Media.Brush)GetValue(MenuIconColorProperty); } 51 | set { SetValue(MenuIconColorProperty, value); } 52 | } 53 | 54 | public static readonly DependencyProperty MenuIconColorProperty = 55 | DependencyProperty.Register("MenuIconColor", typeof(System.Windows.Media.Brush), typeof(HamburgerMenu), new PropertyMetadata(System.Windows.Media.Brushes.White)); 56 | 57 | 58 | public Brush SelectionIndicatorColor 59 | { 60 | get { return (Brush)GetValue(SelectionIndicatorColorProperty); } 61 | set { SetValue(SelectionIndicatorColorProperty, value); } 62 | } 63 | 64 | public static readonly DependencyProperty SelectionIndicatorColorProperty = 65 | DependencyProperty.Register("SelectionIndicatorColor", typeof(Brush), typeof(HamburgerMenu), new PropertyMetadata(Brushes.Red)); 66 | 67 | public Brush MenuItemForeground 68 | { 69 | get { return (Brush)GetValue(MenuItemForegroundProperty); } 70 | set { SetValue(MenuItemForegroundProperty, value); } 71 | } 72 | 73 | public static readonly DependencyProperty MenuItemForegroundProperty = 74 | DependencyProperty.Register("MenuItemForeground", typeof(Brush), typeof(HamburgerMenu), new PropertyMetadata(Brushes.Transparent)); 75 | 76 | public int SelectedIndex 77 | { 78 | get { return (int)GetValue(SelectedIndexProperty); } 79 | set { SetValue(SelectedIndexProperty, value); } 80 | } 81 | 82 | public static readonly DependencyProperty SelectedIndexProperty = 83 | DependencyProperty.Register("SelectedIndex", typeof(int), typeof(HamburgerMenu), new PropertyMetadata(0)); 84 | } 85 | } 86 | -------------------------------------------------------------------------------- /HamburgerMenu/HamburgerMenu.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | Debug 6 | AnyCPU 7 | {CF1B7D25-4744-4B04-B725-7F2D8223806B} 8 | Library 9 | Properties 10 | HamburgerMenu 11 | HamburgerMenu 12 | v4.6 13 | 512 14 | 15 | 16 | 17 | true 18 | full 19 | false 20 | bin\Debug\ 21 | DEBUG;TRACE 22 | prompt 23 | 4 24 | 25 | 26 | pdbonly 27 | true 28 | bin\Release\ 29 | TRACE 30 | prompt 31 | 4 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | MSBuild:Compile 56 | Designer 57 | 58 | 59 | MSBuild:Compile 60 | Designer 61 | 62 | 63 | MSBuild:Compile 64 | Designer 65 | 66 | 67 | MSBuild:Compile 68 | Designer 69 | 70 | 71 | MSBuild:Compile 72 | Designer 73 | 74 | 75 | MSBuild:Compile 76 | Designer 77 | 78 | 79 | 80 | 87 | -------------------------------------------------------------------------------- /HamburgerMenu/HamburgerMenuItem.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using System.Windows; 7 | using System.Windows.Controls; 8 | using System.Windows.Input; 9 | using System.Windows.Media; 10 | 11 | namespace HamburgerMenu 12 | { 13 | public class HamburgerMenuItem : ListBoxItem 14 | { 15 | static HamburgerMenuItem() 16 | { 17 | DefaultStyleKeyProperty.OverrideMetadata(typeof(HamburgerMenuItem), new FrameworkPropertyMetadata(typeof(HamburgerMenuItem))); 18 | } 19 | public string Text 20 | { 21 | get { return (string)GetValue(TextProperty); } 22 | set { SetValue(TextProperty, value); } 23 | } 24 | 25 | public static readonly DependencyProperty TextProperty = 26 | DependencyProperty.Register("Text", typeof(string), typeof(HamburgerMenuItem), new PropertyMetadata(String.Empty)); 27 | 28 | 29 | public ImageSource Icon 30 | { 31 | get { return (ImageSource)GetValue(IconProperty); } 32 | set { SetValue(IconProperty, value); } 33 | } 34 | 35 | public static readonly DependencyProperty IconProperty = 36 | DependencyProperty.Register("Icon", typeof(ImageSource), typeof(HamburgerMenuItem), new PropertyMetadata(null)); 37 | 38 | public Brush SelectionIndicatorColor 39 | { 40 | get { return (Brush)GetValue(SelectionIndicatorColorProperty); } 41 | set { SetValue(SelectionIndicatorColorProperty, value); } 42 | } 43 | 44 | public static readonly DependencyProperty SelectionIndicatorColorProperty = 45 | DependencyProperty.Register("SelectionIndicatorColor", typeof(Brush), typeof(HamburgerMenuItem), new PropertyMetadata(Brushes.Blue)); 46 | 47 | public ICommand SelectionCommand 48 | { 49 | get { return (ICommand)GetValue(SelectionCommandProperty); } 50 | set { SetValue(SelectionCommandProperty, value); } 51 | } 52 | 53 | public static readonly DependencyProperty SelectionCommandProperty = 54 | DependencyProperty.Register("SelectionCommand", typeof(ICommand), typeof(HamburgerMenuItem), new PropertyMetadata(null)); 55 | } 56 | } 57 | -------------------------------------------------------------------------------- /HamburgerMenu/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | using System.Windows; 5 | 6 | // General Information about an assembly is controlled through the following 7 | // set of attributes. Change these attribute values to modify the information 8 | // associated with an assembly. 9 | [assembly: AssemblyTitle("HamburgerMenu")] 10 | [assembly: AssemblyDescription("")] 11 | [assembly: AssemblyConfiguration("")] 12 | [assembly: AssemblyCompany("")] 13 | [assembly: AssemblyProduct("HamburgerMenu")] 14 | [assembly: AssemblyCopyright("Copyright © 2015")] 15 | [assembly: AssemblyTrademark("")] 16 | [assembly: AssemblyCulture("")] 17 | 18 | // Setting ComVisible to false makes the types in this assembly not visible 19 | // to COM components. If you need to access a type in this assembly from 20 | // COM, set the ComVisible attribute to true on that type. 21 | [assembly: ComVisible(false)] 22 | 23 | // The following GUID is for the ID of the typelib if this project is exposed to COM 24 | [assembly: Guid("cf1b7d25-4744-4b04-b725-7f2d8223806b")] 25 | 26 | // Version information for an assembly consists of the following four values: 27 | // 28 | // Major Version 29 | // Minor Version 30 | // Build Number 31 | // Revision 32 | // 33 | // You can specify all the values or you can default the Build and Revision Numbers 34 | // by using the '*' as shown below: 35 | // [assembly: AssemblyVersion("1.0.*")] 36 | [assembly: AssemblyVersion("1.0.0.0")] 37 | [assembly: AssemblyFileVersion("1.0.0.0")] 38 | 39 | [assembly: ThemeInfo( 40 | ResourceDictionaryLocation.None, //where theme specific resource dictionaries are located 41 | //(used if a resource is not found in the page, 42 | // or application resource dictionaries) 43 | ResourceDictionaryLocation.SourceAssembly //where the generic resource dictionary is located 44 | //(used if a resource is not found in the page, 45 | // app, or any theme specific resource dictionaries) 46 | )] 47 | -------------------------------------------------------------------------------- /HamburgerMenu/Themes/ButtonStyle.xaml: -------------------------------------------------------------------------------- 1 |  3 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 91 | -------------------------------------------------------------------------------- /HamburgerMenu/Themes/Generic.xaml: -------------------------------------------------------------------------------- 1 |  3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /HamburgerMenu/Themes/HamburgerMenu.xaml: -------------------------------------------------------------------------------- 1 |  4 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | -------------------------------------------------------------------------------- /HamburgerMenu/Themes/HamburgerMenuItem.xaml: -------------------------------------------------------------------------------- 1 |  4 | 59 | -------------------------------------------------------------------------------- /HamburgerMenu/Themes/ListBoxStyle.xaml: -------------------------------------------------------------------------------- 1 |  3 | 16 | -------------------------------------------------------------------------------- /HamburgerMenu/Themes/ToggleButtonStyle.xaml: -------------------------------------------------------------------------------- 1 |  3 | 4 | Transparent 5 | Transparent 6 | Transparent 7 | 8 | Transparent 9 | Transparent 10 | Transparent 11 | 12 | Transparent 13 | Transparent 14 | 15 | Transparent 16 | Transparent 17 | Transparent 18 | 19 | Transparent 20 | Transparent 21 | 22 | 23 | Transparent 24 | Transparent 25 | 26 | 27 | Transparent 28 | Transparent 29 | Transparent 30 | 31 | Transparent 32 | Transparent 33 | 34 | Transparent 35 | Transparent 36 | 37 | Transparent 38 | 39 | 40 | Transparent 41 | Transparent 42 | Transparent 43 | Transparent 44 | Transparent 45 | Transparent 46 | 47 | 72 | -------------------------------------------------------------------------------- /HamburgerMenuDemo/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /HamburgerMenuDemo/App.xaml: -------------------------------------------------------------------------------- 1 |  6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /HamburgerMenuDemo/App.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Configuration; 4 | using System.Data; 5 | using System.Linq; 6 | using System.Threading.Tasks; 7 | using System.Windows; 8 | 9 | namespace HamburgerMenuDemo 10 | { 11 | /// 12 | /// Interaction logic for App.xaml 13 | /// 14 | public partial class App : Application 15 | { 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /HamburgerMenuDemo/Assets/favorite.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alicanerdogan/HamburgerMenu/7d6c476a4d2ed6355c23400aa5e023769a773fb8/HamburgerMenuDemo/Assets/favorite.png -------------------------------------------------------------------------------- /HamburgerMenuDemo/Assets/home.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alicanerdogan/HamburgerMenu/7d6c476a4d2ed6355c23400aa5e023769a773fb8/HamburgerMenuDemo/Assets/home.png -------------------------------------------------------------------------------- /HamburgerMenuDemo/Assets/list.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alicanerdogan/HamburgerMenu/7d6c476a4d2ed6355c23400aa5e023769a773fb8/HamburgerMenuDemo/Assets/list.png -------------------------------------------------------------------------------- /HamburgerMenuDemo/Assets/person.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alicanerdogan/HamburgerMenu/7d6c476a4d2ed6355c23400aa5e023769a773fb8/HamburgerMenuDemo/Assets/person.png -------------------------------------------------------------------------------- /HamburgerMenuDemo/Assets/search.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alicanerdogan/HamburgerMenu/7d6c476a4d2ed6355c23400aa5e023769a773fb8/HamburgerMenuDemo/Assets/search.png -------------------------------------------------------------------------------- /HamburgerMenuDemo/HamburgerMenuDemo.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | Debug 6 | AnyCPU 7 | {C987C1BB-C5A2-4EF2-96DB-C7C55C4FE23C} 8 | WinExe 9 | Properties 10 | HamburgerMenuDemo 11 | HamburgerMenuDemo 12 | v4.6 13 | 512 14 | {60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} 15 | 4 16 | true 17 | 18 | 19 | 20 | AnyCPU 21 | true 22 | full 23 | false 24 | bin\Debug\ 25 | DEBUG;TRACE 26 | prompt 27 | 4 28 | 29 | 30 | AnyCPU 31 | pdbonly 32 | true 33 | bin\Release\ 34 | TRACE 35 | prompt 36 | 4 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 4.0 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | MSBuild:Compile 57 | Designer 58 | 59 | 60 | MSBuild:Compile 61 | Designer 62 | 63 | 64 | App.xaml 65 | Code 66 | 67 | 68 | MainWindow.xaml 69 | Code 70 | 71 | 72 | 73 | 74 | Code 75 | 76 | 77 | True 78 | True 79 | Resources.resx 80 | 81 | 82 | True 83 | Settings.settings 84 | True 85 | 86 | 87 | ResXFileCodeGenerator 88 | Resources.Designer.cs 89 | 90 | 91 | SettingsSingleFileGenerator 92 | Settings.Designer.cs 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | {cf1b7d25-4744-4b04-b725-7f2d8223806b} 102 | HamburgerMenu 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 119 | 120 | 121 | 128 | -------------------------------------------------------------------------------- /HamburgerMenuDemo/MainWindow.xaml: -------------------------------------------------------------------------------- 1 |  10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /HamburgerMenuDemo/MainWindow.xaml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using System.Windows; 7 | using System.Windows.Controls; 8 | using System.Windows.Data; 9 | using System.Windows.Documents; 10 | using System.Windows.Input; 11 | using System.Windows.Media; 12 | using System.Windows.Media.Imaging; 13 | using System.Windows.Navigation; 14 | using System.Windows.Shapes; 15 | 16 | namespace HamburgerMenuDemo 17 | { 18 | /// 19 | /// Interaction logic for MainWindow.xaml 20 | /// 21 | public partial class MainWindow : Window, ICommand 22 | { 23 | public MainWindow() 24 | { 25 | InitializeComponent(); 26 | } 27 | 28 | public event EventHandler CanExecuteChanged; 29 | 30 | public bool CanExecute(object parameter) 31 | { 32 | return true; 33 | } 34 | 35 | public void Execute(object parameter) 36 | { 37 | MessageBox.Show("Selection Binding"); 38 | } 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /HamburgerMenuDemo/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Resources; 3 | using System.Runtime.CompilerServices; 4 | using System.Runtime.InteropServices; 5 | using System.Windows; 6 | 7 | // General Information about an assembly is controlled through the following 8 | // set of attributes. Change these attribute values to modify the information 9 | // associated with an assembly. 10 | [assembly: AssemblyTitle("HamburgerMenuDemo")] 11 | [assembly: AssemblyDescription("")] 12 | [assembly: AssemblyConfiguration("")] 13 | [assembly: AssemblyCompany("")] 14 | [assembly: AssemblyProduct("HamburgerMenuDemo")] 15 | [assembly: AssemblyCopyright("Copyright © 2015")] 16 | [assembly: AssemblyTrademark("")] 17 | [assembly: AssemblyCulture("")] 18 | 19 | // Setting ComVisible to false makes the types in this assembly not visible 20 | // to COM components. If you need to access a type in this assembly from 21 | // COM, set the ComVisible attribute to true on that type. 22 | [assembly: ComVisible(false)] 23 | 24 | //In order to begin building localizable applications, set 25 | //CultureYouAreCodingWith in your .csproj file 26 | //inside a . For example, if you are using US english 27 | //in your source files, set the to en-US. Then uncomment 28 | //the NeutralResourceLanguage attribute below. Update the "en-US" in 29 | //the line below to match the UICulture setting in the project file. 30 | 31 | //[assembly: NeutralResourcesLanguage("en-US", UltimateResourceFallbackLocation.Satellite)] 32 | 33 | 34 | [assembly: ThemeInfo( 35 | ResourceDictionaryLocation.None, //where theme specific resource dictionaries are located 36 | //(used if a resource is not found in the page, 37 | // or application resource dictionaries) 38 | ResourceDictionaryLocation.SourceAssembly //where the generic resource dictionary is located 39 | //(used if a resource is not found in the page, 40 | // app, or any theme specific resource dictionaries) 41 | )] 42 | 43 | 44 | // Version information for an assembly consists of the following four values: 45 | // 46 | // Major Version 47 | // Minor Version 48 | // Build Number 49 | // Revision 50 | // 51 | // You can specify all the values or you can default the Build and Revision Numbers 52 | // by using the '*' as shown below: 53 | // [assembly: AssemblyVersion("1.0.*")] 54 | [assembly: AssemblyVersion("1.0.0.0")] 55 | [assembly: AssemblyFileVersion("1.0.0.0")] 56 | -------------------------------------------------------------------------------- /HamburgerMenuDemo/Properties/Resources.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:4.0.30319.42000 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace HamburgerMenuDemo.Properties { 12 | using System; 13 | 14 | 15 | /// 16 | /// A strongly-typed resource class, for looking up localized strings, etc. 17 | /// 18 | // This class was auto-generated by the StronglyTypedResourceBuilder 19 | // class via a tool like ResGen or Visual Studio. 20 | // To add or remove a member, edit your .ResX file then rerun ResGen 21 | // with the /str option, or rebuild your VS project. 22 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")] 23 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 24 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 25 | internal class Resources { 26 | 27 | private static global::System.Resources.ResourceManager resourceMan; 28 | 29 | private static global::System.Globalization.CultureInfo resourceCulture; 30 | 31 | [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] 32 | internal Resources() { 33 | } 34 | 35 | /// 36 | /// Returns the cached ResourceManager instance used by this class. 37 | /// 38 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 39 | internal static global::System.Resources.ResourceManager ResourceManager { 40 | get { 41 | if (object.ReferenceEquals(resourceMan, null)) { 42 | global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("HamburgerMenuDemo.Properties.Resources", typeof(Resources).Assembly); 43 | resourceMan = temp; 44 | } 45 | return resourceMan; 46 | } 47 | } 48 | 49 | /// 50 | /// Overrides the current thread's CurrentUICulture property for all 51 | /// resource lookups using this strongly typed resource class. 52 | /// 53 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 54 | internal static global::System.Globalization.CultureInfo Culture { 55 | get { 56 | return resourceCulture; 57 | } 58 | set { 59 | resourceCulture = value; 60 | } 61 | } 62 | } 63 | } 64 | -------------------------------------------------------------------------------- /HamburgerMenuDemo/Properties/Resources.resx: -------------------------------------------------------------------------------- 1 |  2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | text/microsoft-resx 107 | 108 | 109 | 2.0 110 | 111 | 112 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 113 | 114 | 115 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | -------------------------------------------------------------------------------- /HamburgerMenuDemo/Properties/Settings.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:4.0.30319.42000 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace HamburgerMenuDemo.Properties { 12 | 13 | 14 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 15 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "14.0.0.0")] 16 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase { 17 | 18 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); 19 | 20 | public static Settings Default { 21 | get { 22 | return defaultInstance; 23 | } 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /HamburgerMenuDemo/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2015 alicanerdogan 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | 23 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # HamburgerMenu 2 | Windows 10 styled, customizable Hamburger Menu control for WPF 3 | 4 | ![Animation](http://i.imgur.com/ReTRU2E.gif "Animation") 5 | 6 | # Getting Started 7 | 8 | ## Install 9 | From nuget: 10 | ``` 11 | Install-Package HamburgerMenu 12 | ``` 13 | 14 | ## Use 15 | Add library reference in xaml: 16 | ``` 17 | xmlns:HamburgerMenu="clr-namespace:HamburgerMenu;assembly=HamburgerMenu" 18 | ``` 19 | 20 | Create a Hamburger Menu control and set Background Color, Menu Icon Color, Selection Indicator Color and Menu Item Foreground Color: 21 | ``` 22 | 23 | 24 | ``` 25 | 26 | Add Menu Items and set their Icon and Text: 27 | ``` 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | ``` 36 | --------------------------------------------------------------------------------