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

MissionStatus Enum #2151

Merged
merged 19 commits into from
Mar 12, 2021

Conversation

Windchild292
Copy link
Contributor

This PR swaps MissionStatus from magic numbers to an enum.

As part of this I reworked the CompleteMissionDialog, which is the first commit.

@Windchild292 Windchild292 self-assigned this Oct 16, 2020
Copy link
Member

@NickAragua NickAragua left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One suggestion, looks fine otherwise.

MekHQ/src/mekhq/campaign/Campaign.java Outdated Show resolved Hide resolved
@codecov
Copy link

codecov bot commented Dec 4, 2020

Codecov Report

Merging #2151 (98253ba) into master (559cb00) will increase coverage by 0.01%.
The diff coverage is 19.14%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #2151      +/-   ##
============================================
+ Coverage     10.34%   10.36%   +0.01%     
- Complexity     3417     3432      +15     
============================================
  Files           674      675       +1     
  Lines         94621    94574      -47     
  Branches      15906    15870      -36     
============================================
+ Hits           9788     9801      +13     
+ Misses        83468    83399      -69     
- Partials       1365     1374       +9     
Impacted Files Coverage Δ Complexity Δ
MekHQ/src/mekhq/campaign/force/Lance.java 0.00% <0.00%> (ø) 0.00 <0.00> (ø)
MekHQ/src/mekhq/campaign/io/CampaignXmlParser.java 0.00% <0.00%> (ø) 0.00 <0.00> (ø)
MekHQ/src/mekhq/campaign/market/UnitMarket.java 2.46% <0.00%> (+0.05%) 1.00 <0.00> (ø)
MekHQ/src/mekhq/campaign/mission/AtBContract.java 18.99% <0.00%> (-0.12%) 63.00 <0.00> (-1.00)
MekHQ/src/mekhq/campaign/mission/Contract.java 43.14% <0.00%> (-0.26%) 44.00 <1.00> (+1.00) ⬇️
...mekhq/campaign/mission/atb/AtBScenarioFactory.java 0.00% <0.00%> (ø) 0.00 <0.00> (ø)
...campaign/personnel/RetirementDefectionTracker.java 1.71% <0.00%> (+0.01%) 1.00 <0.00> (ø)
MekHQ/src/mekhq/gui/BriefingTab.java 0.00% <0.00%> (ø) 0.00 <0.00> (ø)
MekHQ/src/mekhq/gui/CampaignGUI.java 0.00% <0.00%> (ø) 0.00 <0.00> (ø)
MekHQ/src/mekhq/gui/adapter/TOEMouseAdapter.java 0.00% <0.00%> (ø) 0.00 <0.00> (ø)
... and 17 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6df784e...98253ba. Read the comment docs.

@Windchild292 Windchild292 added the (RFE) Enhancement Requests for Enhancement, new features or implementations label Dec 4, 2020
@Windchild292 Windchild292 added this to the 0.49-dev milestone Dec 31, 2020
Copy link
Member

@NickAragua NickAragua left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Two minor potential code changes, good to go otherwise.

MekHQ/src/mekhq/gui/dialog/ContractMarketDialog.java Outdated Show resolved Hide resolved
MekHQ/src/mekhq/campaign/Campaign.java Outdated Show resolved Hide resolved
@Windchild292
Copy link
Contributor Author

Fixed both issues and have now pushed the changes

@Windchild292 Windchild292 merged commit 8edd806 into MegaMek:master Mar 12, 2021
@Windchild292 Windchild292 deleted the dev_Windchild_MissionStatus branch March 12, 2021 13:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Refactoring (RFE) Enhancement Requests for Enhancement, new features or implementations
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants