]> git.smokeofanarchy.ru Git - space-station-14.git/commitdiff
Re-organise main menu screen (#25173)
authormetalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
Fri, 16 Feb 2024 18:55:42 +0000 (05:55 +1100)
committerGitHub <noreply@github.com>
Fri, 16 Feb 2024 18:55:42 +0000 (13:55 -0500)
- The dummy control of 2px size has annoyed me for almost 5 years.
- Why is it in the top-right.
- Why is the server address not labelled.

Content.Client/MainMenu/UI/MainMenuControl.xaml
Resources/Locale/en-US/main-menu/main-menu.ftl

index 16a8cc267a09c35546d4826996353ddc04d67616..d6c3f4b94155b9167f480d0ae8659e694665fb52 100644 (file)
@@ -2,44 +2,46 @@
          xmlns:pllax="clr-namespace:Content.Client.Parallax"
          xmlns:clog="clr-namespace:Content.Client.Changelog">
     <pllax:ParallaxControl />
-    <LayoutContainer>
-        <BoxContainer Name="VBox"
-                      Orientation="Vertical"
-                      StyleIdentifier="mainMenuVBox">
-            <TextureRect Name="Logo"
-                         Stretch="KeepCentered" />
-            <BoxContainer Orientation="Horizontal"
-                          SeparationOverride="4">
-                <Label Text="{Loc 'main-menu-username-label'}" />
-                <LineEdit Name="UsernameBox"
-                          Access="Public"
-                          PlaceHolder="{Loc 'main-menu-username-text'}"
-                          HorizontalExpand="True" />
-            </BoxContainer>
+    <BoxContainer Name="VBox"
+                  Orientation="Vertical"
+                  HorizontalAlignment="Center"
+                  VerticalAlignment="Center"
+                  HorizontalExpand="True"
+                  VerticalExpand="True"
+                  StyleIdentifier="mainMenuVBox"
+                  SeparationOverride="3">
+        <TextureRect Name="Logo"
+                     Stretch="KeepCentered"/>
+        <GridContainer Columns="2">
+            <Label Text="{Loc 'main-menu-username-label'}" />
+            <LineEdit Name="UsernameBox"
+                      Access="Public"
+                      PlaceHolder="{Loc 'main-menu-username-text'}"
+                      HorizontalExpand="True" />
+            <Label Text="{Loc 'main-menu-address-label'}"/>
             <LineEdit Name="AddressBox"
                       Access="Public"
                       Text="localhost"
                       PlaceHolder="server address:port"
                       HorizontalExpand="True" />
-            <Button Name="DirectConnectButton"
-                    Access="Public"
-                    Text="{Loc 'main-menu-direct-connect-button'}"
-                    TextAlign="Center"
-                    StyleIdentifier="mainMenu" />
-            <Control MinSize="0 2" />
-            <Button Name="OptionsButton"
-                    Access="Public"
-                    Text="{Loc 'main-menu-options-button'}"
-                    TextAlign="Center"
-                    StyleIdentifier="mainMenu" />
-            <Button Name="QuitButton"
-                    Access="Public"
-                    Text="{Loc 'main-menu-quit-button'}"
-                    TextAlign="Center"
-                    StyleIdentifier="mainMenu" />
-            <clog:ChangelogButton
-                Name="ChangelogButton"
-                Access="Public"/>
-        </BoxContainer>
-    </LayoutContainer>
+        </GridContainer>
+        <Button Name="DirectConnectButton"
+                Access="Public"
+                Text="{Loc 'main-menu-direct-connect-button'}"
+                TextAlign="Center"
+                StyleIdentifier="mainMenu"/>
+        <Button Name="OptionsButton"
+                Access="Public"
+                Text="{Loc 'main-menu-options-button'}"
+                TextAlign="Center"
+                StyleIdentifier="mainMenu"/>
+        <Button Name="QuitButton"
+                Access="Public"
+                Text="{Loc 'main-menu-quit-button'}"
+                TextAlign="Center"
+                StyleIdentifier="mainMenu"/>
+        <clog:ChangelogButton
+            Name="ChangelogButton"
+            Access="Public"/>
+    </BoxContainer>
 </Control>
index 6e7bfa3e924c1ec92b032327cd88c572bcd3b216..ca81befaafede59b34fc862c3134ba8c18014439 100644 (file)
@@ -2,11 +2,12 @@ main-menu-invalid-username-with-reason = Invalid username:
                                          {$invalidReason}
 main-menu-invalid-username = Invalid username
 main-menu-failed-to-connect = Failed to connect:
-                              {$reason} 
+                              {$reason}
 main-menu-username-label = Username:
 main-menu-username-text = Username
+main-menu-address-label = Server Address:
 main-menu-join-public-server-button = Join Public Server
 main-menu-join-public-server-button-tooltip = Cannot connect to public server with a debug build.
 main-menu-direct-connect-button = Direct Connect
 main-menu-options-button = Options
-main-menu-quit-button = Quit
\ No newline at end of file
+main-menu-quit-button = Quit