Commit ea08b463 authored by Albert Astals Cid's avatar Albert Astals Cid
Browse files

Remove code i did not want to commit

The part with the todo wasn't meant to be commited yet
parent b1152329
......@@ -1211,30 +1211,24 @@ void DocumentPrivate::doContinueDirectionMatchSearch(void *doContinueDirectionMa
Page * page = m_pagesVector[ searchStruct->currentPage ];
// request search page if needed
if ( !page->hasTextPage() )
{
m_parent->requestTextPage( page->number() );
// TODO wait for page text to be generated and call doContinueDirectionMatchSearch
// if found a match on the current page, end the loop
searchStruct->match = page->findText( searchStruct->searchID, searchStruct->text, searchStruct->forward ? FromTop : FromBottom, searchStruct->caseSensitivity );
if ( !searchStruct->match )
{
if (searchStruct->forward) searchStruct->currentPage++;
else searchStruct->currentPage--;
searchStruct->pagesDone++;
}
else
{
// if found a match on the current page, end the loop
searchStruct->match = page->findText( searchStruct->searchID, searchStruct->text, searchStruct->forward ? FromTop : FromBottom, searchStruct->caseSensitivity );
if ( !searchStruct->match )
{
if (searchStruct->forward) searchStruct->currentPage++;
else searchStruct->currentPage--;
searchStruct->pagesDone++;
}
else
{
searchStruct->pagesDone = 1;
}
// Both of the previous if branches need to call doContinueDirectionMatchSearch
QMetaObject::invokeMethod(m_parent, "doContinueDirectionMatchSearch", Qt::QueuedConnection, Q_ARG(void *, searchStruct));
searchStruct->pagesDone = 1;
}
// Both of the previous if branches need to call doContinueDirectionMatchSearch
QMetaObject::invokeMethod(m_parent, "doContinueDirectionMatchSearch", Qt::QueuedConnection, Q_ARG(void *, searchStruct));
}
else
{
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment