mirror of
https://github.com/RGBCube/serenity
synced 2025-07-28 01:47:34 +00:00
HexEditor: Give magic constants names
There are a lot of numbers just floating around in the code. Give them proper names.
This commit is contained in:
parent
4aab6ff839
commit
be9a7057ff
2 changed files with 38 additions and 34 deletions
|
@ -83,11 +83,15 @@ private:
|
|||
NonnullRefPtr<Core::Timer> m_blink_timer;
|
||||
bool m_cursor_blink_active { false };
|
||||
|
||||
static constexpr int m_address_bar_width = 90;
|
||||
static constexpr int m_padding = 5;
|
||||
|
||||
void scroll_position_into_view(size_t position);
|
||||
|
||||
size_t total_rows() const { return ceil_div(m_content_length, m_bytes_per_row); }
|
||||
size_t line_height() const { return font().glyph_height() + m_line_spacing; }
|
||||
size_t character_width() const { return font().glyph_width('W'); }
|
||||
size_t cell_width() const { return character_width() * 3; }
|
||||
size_t offset_margin_width() const { return 80; }
|
||||
|
||||
void hex_mode_keydown_event(GUI::KeyEvent&);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue