Reword code comments in plain technical language

Comments only, no code changes. Replaces vague or personified phrasing
with explicit statements of what the code does and why, uses bullet
lists for multi-case behavior, and fixes the settings path in
WindowSettings.h (~/.config/sloposk/sloposk.conf).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-03 19:58:59 +01:00
co-authored by Claude Opus 5.5
parent 5e4d4051f3
commit 23e957660f
53 changed files with 232 additions and 226 deletions
+4 -4
View File
@@ -37,7 +37,7 @@ bool CollapseController::collapse()
m_expandedSize = m_window.size();
m_collapsed = true;
Q_EMIT collapsedChanged();
// After the next frame, once the compositor knows the lower minimum size.
// Wait one frame, so the compositor has the new (lower) minimum size before the resize.
connect(&m_window, &QQuickWindow::frameSwapped, this, [this] {
if (m_collapsed)
m_placement.moveResize(m_keyRect, false);
@@ -50,10 +50,10 @@ void CollapseController::expand()
if (!m_collapsed || m_expanding.isActive())
return;
if (roughlyEqual(m_window.size(), m_expandedSize)) {
finishExpanding(); // never shrank: nothing to move
finishExpanding(); // window never shrank: nothing to resize
return;
}
// Stays collapsed until the window has grown, so the keys don't flash squeezed.
// Stay collapsed until the window has grown, so the keys aren't drawn squeezed.
m_placement.moveResize(QRectF(-m_keyRect.topLeft(), m_expandedSize), true);
m_expanding.start();
}
@@ -68,7 +68,7 @@ void CollapseController::finishExpanding()
{
m_expanding.stop();
if (!roughlyEqual(m_window.size(), m_expandedSize))
m_window.resize(m_expandedSize); // no KWin to do it
m_window.resize(m_expandedSize); // KWin didn't resize (timeout): resize directly
m_collapsed = false;
Q_EMIT collapsedChanged();
}