diff options
author | chill <chill.gtnh@outlook.com> | 2023-05-26 11:40:45 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-26 11:40:45 +0200 |
commit | 497080d591db8af491ece783bf9a480b50a7c16b (patch) | |
tree | ea61add576de62051e325127268d2e5d5e9d72d6 /src/main/java/gregtech/common/gui/modularui/widget | |
parent | 97a977e6ce0f55492f77d39fa0c44501867e3886 (diff) | |
download | GT5-Unofficial-497080d591db8af491ece783bf9a480b50a7c16b.tar.gz GT5-Unofficial-497080d591db8af491ece783bf9a480b50a7c16b.tar.bz2 GT5-Unofficial-497080d591db8af491ece783bf9a480b50a7c16b.zip |
Fix warnings about ModularUI methods that can only be overridden (#2022)
* address ModularUI methods that can only be overridden
A call of super was safely deleted.
A call of draw() is legit, but it's labeled as OverrideOnly in ModularUI,
so IntelliJ considers it incorrect to call draw(). This warning was
suppressed. On top of that, IntelliJ incorrectly says that this
suppression is redundant, so that was addressed too.
Fixing the issue without suppressing the warning entails changing the
ModularUI mod, which is too much work for one warning.
However, if there are many warnings like that, it might be reasonable
to change ModularUI.
The whitespace change is Spotless, although it did not detect it
before the changes to the file.
* remove suppression on RedundantSuppression
The mark of OverrideOnly suppression as RedundantSuppression
could not be reproduced. Therefore the suppression of
RedundantSuppression is not needed.
Diffstat (limited to 'src/main/java/gregtech/common/gui/modularui/widget')
-rw-r--r-- | src/main/java/gregtech/common/gui/modularui/widget/DataControllerWidget.java | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/main/java/gregtech/common/gui/modularui/widget/DataControllerWidget.java b/src/main/java/gregtech/common/gui/modularui/widget/DataControllerWidget.java index 959edb80fd..3717b128bb 100644 --- a/src/main/java/gregtech/common/gui/modularui/widget/DataControllerWidget.java +++ b/src/main/java/gregtech/common/gui/modularui/widget/DataControllerWidget.java @@ -25,7 +25,7 @@ import gregtech.api.util.ISerializableObject; * This widget wraps data and handles validation, e.g. tell client to close GUI when tile is broken or cover is removed. * <br> * Data can be anything, e.g. {@link ISerializableObject} or machine recipe mode. - * + * * @param <T> Data type stored in this widget * @see IDataFollowerWidget */ @@ -53,7 +53,6 @@ public abstract class DataControllerWidget<T> extends MultiChildWidget implement @Override public void onPostInit() { - super.onPostInit(); // client _should_ have received initial cover data from `GT_UIInfos#openCoverUI` lastData = dataGetter.get(); if (NetworkUtils.isClient()) { |