Skip to content
Merged
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
Original file line number Diff line number Diff line change
Expand Up @@ -365,7 +365,12 @@ public boolean toClipboard() {

@Override
public boolean fromClipboard() {
if (!NbtUtils.fromClipboard(setting.get())) {
if (NbtUtils.fromClipboard(setting.get())) {
// The color was deserialised onto the existing object, so Setting#set -
// and with it onChanged() - was never reached.
setting.get().validate();
setting.onChanged();
} else {
String clipboard = mc.keyboardHandler.getClipboard().trim();
SettingColor parsed;

Expand All @@ -378,7 +383,7 @@ public boolean fromClipboard() {
setting.set(parsed);
}

setting.get().validate();
callAction();

if (parent instanceof WidgetScreen p) {
p.reload();
Expand Down
Loading