mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-03 15:16:14 +00:00
LibGUI: Disallow GlyphMapWidget selection sizes equal to zero
This is a bogus size as the map must always have at least 1 glyph selected, and it was causing occasional desync between selection contents and the focused glyph when manipulating selections with the keyboard.
This commit is contained in:
committed by
Andreas Kling
parent
8d3f60c7ef
commit
360e58a276
@@ -44,7 +44,7 @@ bool GlyphMapWidget::Selection::contains(int i) const
|
||||
void GlyphMapWidget::Selection::extend_to(int glyph)
|
||||
{
|
||||
m_size = glyph - m_start;
|
||||
if (m_size > 0)
|
||||
if (m_size >= 0)
|
||||
m_size++;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user