8000 allow setting MekHQ Options from splash screen by kuronekochomusuke · Pull Request #6348 · MegaMek/mekhq · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

allow setting MekHQ Options from splash screen #6348

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions MekHQ/resources/mekhq/resources/GUI.properties
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ GMMode.text=GM Mode
GMMode.toolTipText=The contents of this menu are intended solely for GM use.
Import.text=Import
InvalidOptions.title=Error: Invalid Option Selection
MHQOptions.text=MekHQ Options
NA.text=N/A
No.text=No
None.text=None
Expand Down
10 changes: 10 additions & 0 deletions MekHQ/src/mekhq/gui/panels/StartupScreenPanel.java
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
import mekhq.gui.FileDialogs;
import mekhq.gui.baseComponents.AbstractMHQPanel;
import mekhq.gui.dialog.DataLoadingDialog;
import mekhq.gui.dialog.MHQOptionsDialog;
import mekhq.gui.dialog.StoryArcSelectionDialog;

import javax.swing.*;
Expand Down Expand Up @@ -177,6 +178,11 @@
}
});
});

MegaMekButton btnMHQOptions = new MegaMekButton(resources.getString("MHQOptions.text"),
UIComponents.MainMenuButton.getComp(), true);
btnMHQOptions.addActionListener(evt -> new MHQOptionsDialog(getFrame()).setVisible(true));

MegaMekButton btnQuit = new MegaMekButton(resources.getString("Quit.text"),
UIComponents.MainMenuButton.getComp(), true);
btnQuit.addActionListener(evt -> System.exit(0));
Expand Down Expand Up @@ -208,6 +214,8 @@
btnLoadLastCampaign.setPreferredSize(minButtonDim);
btnLoadStoryArc.setMinimumSize(minButtonDim);
btnLoadStoryArc.setPreferredSize(minButtonDim);
btnMHQOptions.setMinimumSize(minButtonDim);
btnMHQOptions.setPreferredSize(minButtonDim);
btnQuit.setMinimumSize(minButtonDim);
btnQuit.setPreferredSize(minButtonDim);

Expand Down Expand Up @@ -247,6 +255,8 @@
c.gridy++;
add(btnLoadStoryArc, c);
c.gridy++;
add(btnMHQOptions, c);
c.gridy++;
add(btnQuit, c);

getFrame().setResizable(false);
Expand Down
0