Skip to content
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

BriefingTab Fix #5272

Merged
merged 1 commit into from
Dec 3, 2024
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
5 changes: 2 additions & 3 deletions MekHQ/src/mekhq/gui/BriefingTab.java
Original file line number Diff line number Diff line change
Expand Up @@ -320,12 +320,11 @@ private void addMission() {
? new NewAtBContractDialog(getFrame(), true, getCampaign())
: new NewContractDialog(getFrame(), true, getCampaign());
ncd.setVisible(true);
this.setVisible(false);
comboMission.setSelectedItem(ncd.getContract());
} else {
}
if (mtd.isMission()) {
CustomizeMissionDialog cmd = new CustomizeMissionDialog(getFrame(), true, null, getCampaign());
cmd.setVisible(true);
this.setVisible(false);
comboMission.setSelectedItem(cmd.getMission());
}
}
Expand Down
7 changes: 6 additions & 1 deletion MekHQ/src/mekhq/gui/dialog/MissionTypeDialog.java
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ public class MissionTypeDialog extends JDialog {
private static final MMLogger logger = MMLogger.create(MissionTypeDialog.class);

private boolean contract;
private boolean mission;

public MissionTypeDialog(final JFrame frame, final boolean modal) {
super(frame, modal);
Expand All @@ -60,7 +61,7 @@ private void initComponents() {
btnMission.setToolTipText(resourceMap.getString("btnMission.tooltip"));
btnMission.setName("btnMission");
btnMission.addActionListener(evt -> {
contract = false;
mission = true;
setVisible(false);
});
getContentPane().add(btnMission);
Expand Down Expand Up @@ -92,4 +93,8 @@ private void setUserPreferences() {
public boolean isContract() {
return contract;
}

public boolean isMission() {
return mission;
}
}
Loading