AudioBook Plugin: Move selection up/down

This commit is contained in:
Jakub Melka
2021-08-26 21:09:26 +02:00
parent 7525265233
commit 3318a2a6d7
6 changed files with 123 additions and 0 deletions

View File

@ -309,6 +309,28 @@ void PDFDocumentTextFlowEditorModel::restoreOriginalTexts()
emit dataChanged(index(0, 0), index(rowCount(QModelIndex()) - 1, ColumnLast));
}
void PDFDocumentTextFlowEditorModel::moveSelectionUp()
{
if (!m_editor || m_editor->isEmpty())
{
return;
}
m_editor->moveSelectionUp();
notifyDataChanged();
}
void PDFDocumentTextFlowEditorModel::moveSelectionDown()
{
if (!m_editor || m_editor->isEmpty())
{
return;
}
m_editor->moveSelectionDown();
notifyDataChanged();
}
void PDFDocumentTextFlowEditorModel::notifyDataChanged()
{
if (!m_editor || m_editor->isEmpty())