diff options
| author | Yuqian Yang <crupest@crupest.life> | 2025-11-22 21:24:18 +0800 |
|---|---|---|
| committer | Yuqian Yang <crupest@crupest.life> | 2025-11-22 21:24:18 +0800 |
| commit | 8f8b7dfd056dfa23dd1989d3f3dfd3d5d91d0168 (patch) | |
| tree | 435917530667bd4532c9bb70826c5796ca1ffa6a /src/ThemeBuilder/components/stylers | |
| parent | 7ce185d5a3fcfad8c8f746f95f3d50a8829faac4 (diff) | |
| download | cru-8f8b7dfd056dfa23dd1989d3f3dfd3d5d91d0168.tar.gz cru-8f8b7dfd056dfa23dd1989d3f3dfd3d5d91d0168.tar.bz2 cru-8f8b7dfd056dfa23dd1989d3f3dfd3d5d91d0168.zip | |
Clean measure requirement codes.
Diffstat (limited to 'src/ThemeBuilder/components/stylers')
| -rw-r--r-- | src/ThemeBuilder/components/stylers/CompoundStylerEditor.cpp | 2 | ||||
| -rw-r--r-- | src/ThemeBuilder/components/stylers/PreferredSizeStylerEditor.cpp | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/ThemeBuilder/components/stylers/CompoundStylerEditor.cpp b/src/ThemeBuilder/components/stylers/CompoundStylerEditor.cpp index 698cc699..fb144e60 100644 --- a/src/ThemeBuilder/components/stylers/CompoundStylerEditor.cpp +++ b/src/ThemeBuilder/components/stylers/CompoundStylerEditor.cpp @@ -25,7 +25,7 @@ CompoundStylerEditor::CompoundStylerEditor() { "cru.theme_builder.icon-button.style")); add_child_button_.GetButton()->SetIconWithSvgPathDataStringResourceKey( "icon.plus", {0, 0, 16, 16}); - add_child_button_.GetButton()->SetPreferredSize({24, 24}); + add_child_button_.GetButton()->SetSuggestSize({24, 24}); add_child_button_.GetButton()->SetPadding(ui::Thickness(2)); add_child_button_.GetButton()->SetIconFillColor(ui::colors::green); add_child_button_.SetMenuItems({"Compound Styler", "Border Styler", diff --git a/src/ThemeBuilder/components/stylers/PreferredSizeStylerEditor.cpp b/src/ThemeBuilder/components/stylers/PreferredSizeStylerEditor.cpp index 8c7c751f..d230e09c 100644 --- a/src/ThemeBuilder/components/stylers/PreferredSizeStylerEditor.cpp +++ b/src/ThemeBuilder/components/stylers/PreferredSizeStylerEditor.cpp @@ -24,8 +24,8 @@ PreferredSizeStylerEditor::GetValue() { void PreferredSizeStylerEditor::SetValue(ui::style::PreferredSizeStyler* styler, bool trigger_change) { - width_editor_.SetValue(styler->GetPreferredSize().width, false); - height_editor_.SetValue(styler->GetPreferredSize().height, false); + width_editor_.SetValue(styler->GetSuggestSize().width, false); + height_editor_.SetValue(styler->GetSuggestSize().height, false); if (trigger_change) { RaiseChangeEvent(); |
