mirror of
https://github.com/amyinspace/MagicSetEditor2.git
synced 2026-06-10 04:57:00 -04:00
Disable auto replaces that match an empty string.
Some people are having problems with these suddenly showing up and making typing impossible. This doesn't fix the cause of the ARs appearing, but it at least prevents it from making MSE unusable.
This commit is contained in:
@@ -49,3 +49,9 @@ IMPLEMENT_REFLECTION_NO_SCRIPT(AutoReplace) {
|
||||
REFLECT(match);
|
||||
REFLECT(replace);
|
||||
}
|
||||
|
||||
void after_reading(AutoReplace& ar, Version) {
|
||||
if (ar.match.empty()) {
|
||||
ar.enabled = false;
|
||||
}
|
||||
}
|
||||
@@ -58,3 +58,5 @@ public:
|
||||
DECLARE_REFLECTION();
|
||||
};
|
||||
|
||||
void after_reading(AutoReplace& ar, Version);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user