reset scroll on resource change

Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
This commit is contained in:
Trial97 2026-01-03 23:44:09 +02:00
parent 5767479c21
commit eb15897b1a
No known key found for this signature in database
GPG key ID: 55EF5DA53DB36318
2 changed files with 8 additions and 0 deletions

View file

@ -270,6 +270,7 @@ void InfoFrame::updateHiddenState()
void InfoFrame::setName(QString text)
{
resetScrolll();
if (text.isEmpty()) {
ui->nameLabel->setHidden(true);
} else {
@ -419,3 +420,9 @@ void InfoFrame::boxClosed([[maybe_unused]] int result)
{
m_current_box = nullptr;
}
void InfoFrame::resetScrolll()
{
ui->scrollArea->horizontalScrollBar()->setValue(0);
ui->scrollArea->verticalScrollBar()->setValue(0);
}