-
-
Notifications
You must be signed in to change notification settings - Fork 912
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
Codechange: merge guiflags and flags in settings .ini files #9333
Merged
TrueBrain
merged 4 commits into
OpenTTD:master
from
TrueBrain:settings-flags-not-saveload-flags
Jun 6, 2021
Merged
Codechange: merge guiflags and flags in settings .ini files #9333
TrueBrain
merged 4 commits into
OpenTTD:master
from
TrueBrain:settings-flags-not-saveload-flags
Jun 6, 2021
+366
−464
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rubidium42
reviewed
Jun 3, 2021
TrueBrain
changed the title
Codechange: move SLF_NOT_IN_SAVE and SLF_NOT_IN_CONFIG to SettingFlag
Codechange: only set SettingFlag for settings
Jun 3, 2021
TrueBrain
changed the title
Codechange: only set SettingFlag for settings
Codechange: merge guiflags and flags for settings
Jun 3, 2021
TrueBrain
force-pushed
the
settings-flags-not-saveload-flags
branch
2 times, most recently
from
June 3, 2021 19:10
6b51368
to
8563e4c
Compare
frosch123
reviewed
Jun 3, 2021
TrueBrain
force-pushed
the
settings-flags-not-saveload-flags
branch
3 times, most recently
from
June 3, 2021 20:06
1e5cf05
to
4faaceb
Compare
TrueBrain
commented
Jun 3, 2021
@@ -578,7 +578,7 @@ static inline uint SlGetArrayLength(size_t length) | |||
* @param conv VarType type of variable that is used for calculating the size | |||
* @return Return the size of this type in bytes | |||
*/ | |||
static inline uint SlCalcConvMemLen(VarType conv) | |||
uint SlCalcConvMemLen(VarType conv) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In #9335 I revert this back to a static inline
, but for my sanity (and yours) in this PR I first make it available for settings.cpp
.
TrueBrain
changed the title
Codechange: merge guiflags and flags for settings
Codechange: merge guiflags and flags in settings .ini files
Jun 4, 2021
TrueBrain
force-pushed
the
settings-flags-not-saveload-flags
branch
from
June 4, 2021 07:38
4faaceb
to
2904dc4
Compare
It is a settings-only flag, so don't pollute SaveLoad code with it.
It is a settings-only flag, so don't pollute SaveLoad code with it.
It was rather confusing which one was for what, especially as some SaveLoad flags were settings-only. Clean up this mess a bit by having only Setting flags.
TrueBrain
force-pushed
the
settings-flags-not-saveload-flags
branch
from
June 6, 2021 07:45
2904dc4
to
6f7dcf1
Compare
rubidium42
approved these changes
Jun 6, 2021
glx22
added a commit
to glx22/OpenTTD
that referenced
this pull request
Apr 15, 2022
… for osk_activation
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation / Problem
While working on SaveLoad I ran into the issue that it has two flags which have nothing to do with SaveLoad. Additionally, the Settings were settings SaveLoad settings directly, which gave for some confusing ini file ..
flags
vsguiflags
.Description
Simplify the situation by only having
flags
.This now means that
SF_NOT_IN_CONFIG
,SF_NOT_IN_SAVE
andSF_NO_NETWORK_SYNC
remain within the Setting, and don't pollute SaveLoad for no good reason.Limitations
Checklist for review
Some things are not automated, and forgotten often. This list is a reminder for the reviewers.