Skip to content

Commit

Permalink
Fixed previous commit
Browse files Browse the repository at this point in the history
  • Loading branch information
Seph authored and Seph committed Sep 11, 2015
1 parent c4b20ed commit 234eb06
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
3 changes: 0 additions & 3 deletions Menu.cs
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,6 @@ public static class MenuGlobals

internal static class MenuSettings
{
internal static bool ShowingMenu;
public static Vector2 BasePosition = new Vector2(10, 10);
private static bool _drawTheMenu;

Expand Down Expand Up @@ -239,13 +238,11 @@ private static void Game_OnWndProc(WndEventArgs args)
if ((args.Msg == (uint) WindowsMessages.WM_KEYUP || args.Msg == (uint) WindowsMessages.WM_KEYDOWN) &&
args.WParam == Config.ShowMenuPressKey)
{
ShowingMenu = true;
DrawMenu = args.Msg == (uint) WindowsMessages.WM_KEYDOWN;
}

if (args.Msg == (uint) WindowsMessages.WM_KEYUP && args.WParam == Config.ShowMenuToggleKey)
{
ShowingMenu = false;
DrawMenu = !DrawMenu;
}
}
Expand Down
4 changes: 2 additions & 2 deletions PermaShow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@ private static void DrawingOnPreReset(EventArgs args)

private static void OnWndProc(WndEventArgs args)
{
if (MenuSettings.ShowingMenu)
if (MenuSettings.DrawMenu)
{
return;
}
Expand Down Expand Up @@ -306,7 +306,7 @@ private static void CreateMenu()
var yvalue = new MenuItem("Y", "Y").SetValue(new Slider((int)DefaultPosition.Y, 0, Drawing.Height));
placetosave.AddItem(xvalue);
placetosave.AddItem(yvalue);
CommonMenu.Config.SubMenu("Menu Settings").AddSubMenu(placetosave);
CommonMenu.Config.AddSubMenu(placetosave);

enablepermashow.ValueChanged += (sender, args) =>
{
Expand Down

0 comments on commit 234eb06

Please sign in to comment.