From bc9909169b6669cb92faf83c85c0eca0671bde14 Mon Sep 17 00:00:00 2001 From: thindil Date: Sun, 3 Nov 2024 04:27:29 +0000 Subject: [PATCH] feat: continue work on new version of the game's main menu FossilOrigin-Name: 6e6a25a648cab19992f941d9c17cfdbc46fe9405b10ea66a90f8be13b340e97d --- src/newui/mainmenu.nim | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/src/newui/mainmenu.nim b/src/newui/mainmenu.nim index 00ffbc798..312698d2d 100644 --- a/src/newui/mainmenu.nim +++ b/src/newui/mainmenu.nim @@ -44,14 +44,16 @@ proc showNews*(state: var GameState) {.raises: [], tags: [], contractual.} = resetTooltips() setLayoutRowDynamic(height = (windowHeight - 50).float, cols = 1) label(str = "here") - setLayoutRowDynamic(height = 40, cols = 2) - addTooltip(bounds = getWidgetBounds(), text = "Show all changes to the game since previous big stable version") - labelButton(title = "Show all changes"): - echo "button pressed" - addTooltip(bounds = getWidgetBounds(), text = "Back to the main menu") - labelButton(title = "Back to menu"): - state = mainMenu - return + layoutSpaceStatic(height = 40, widgetsCount = 2): + row(x = (windowWidth - 350).float, y = 0, w = 175, h = 40): + addTooltip(bounds = getWidgetBounds(), text = "Show all changes to the game since previous big stable version") + labelButton(title = "Show all changes"): + echo "button pressed" + row(x = (windowWidth - 175).float, y = 0, w = 175, h = 40): + addTooltip(bounds = getWidgetBounds(), text = "Back to the main menu") + labelButton(title = "Back to menu"): + state = mainMenu + return showTooltips() proc showMainMenu*(state: var GameState) {.raises: [], tags: [], contractual.} =