Skip to content

Commit 61d9309

Browse files
thankyouverycoolawesomekling
authored andcommitted
FontEditor: Remove redundant set_scale() helper
1 parent 8f7dbf3 commit 61d9309

File tree

2 files changed

+2
-8
lines changed

2 files changed

+2
-8
lines changed

Userland/Applications/FontEditor/MainWidget.cpp

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,7 @@ ErrorOr<void> MainWidget::create_actions()
239239
m_next_glyph_action->set_status_tip("Seek the next visible glyph");
240240

241241
i32 scale = Config::read_i32("FontEditor"sv, "GlyphEditor"sv, "Scale"sv, 10);
242-
set_scale(scale);
242+
m_glyph_editor_widget->set_scale(scale);
243243
m_scale_five_action = GUI::Action::create_checkable("500%", { Mod_Ctrl, Key_1 }, [this](auto&) {
244244
set_scale_and_save(5);
245245
});
@@ -897,15 +897,10 @@ void MainWidget::drop_event(GUI::DropEvent& event)
897897
}
898898
}
899899

900-
void MainWidget::set_scale(i32 scale)
901-
{
902-
m_glyph_editor_widget->set_scale(scale);
903-
}
904-
905900
void MainWidget::set_scale_and_save(i32 scale)
906901
{
907-
set_scale(scale);
908902
Config::write_i32("FontEditor"sv, "GlyphEditor"sv, "Scale"sv, scale);
903+
m_glyph_editor_widget->set_scale(scale);
909904
m_glyph_editor_widget->set_fixed_size(m_glyph_editor_widget->preferred_width(), m_glyph_editor_widget->preferred_height());
910905
}
911906

Userland/Applications/FontEditor/MainWidget.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,6 @@ class MainWidget final : public GUI::Widget {
7070
void did_modify_font();
7171
void update_statusbar();
7272
void update_preview();
73-
void set_scale(i32);
7473
void set_scale_and_save(i32);
7574

7675
ErrorOr<void> copy_selected_glyphs();

0 commit comments

Comments
 (0)