Switch to unified view

a/src/qtgui/rclmain_w.cpp b/src/qtgui/rclmain_w.cpp
1
#ifndef lint
1
#ifndef lint
2
static char rcsid[] = "@(#$Id: rclmain_w.cpp,v 1.26 2007-05-21 14:26:19 dockes Exp $ (C) 2005 J.F.Dockes";
2
static char rcsid[] = "@(#$Id: rclmain_w.cpp,v 1.27 2007-06-11 08:33:56 dockes Exp $ (C) 2005 J.F.Dockes";
3
#endif
3
#endif
4
/*
4
/*
5
 *   This program is free software; you can redistribute it and/or modify
5
 *   This program is free software; you can redistribute it and/or modify
6
 *   it under the terms of the GNU General Public License as published by
6
 *   it under the terms of the GNU General Public License as published by
7
 *   the Free Software Foundation; either version 2 of the License, or
7
 *   the Free Software Foundation; either version 2 of the License, or
...
...
48
#include <qlineedit.h>
48
#include <qlineedit.h>
49
#include <qaction.h>
49
#include <qaction.h>
50
#include <qpushbutton.h>
50
#include <qpushbutton.h>
51
#include <qimage.h>
51
#include <qimage.h>
52
#include <qiconset.h>
52
#include <qiconset.h>
53
#include <qapplication.h>
54
#include <qcursor.h>
53
55
54
#include "recoll.h"
56
#include "recoll.h"
55
#include "debuglog.h"
57
#include "debuglog.h"
56
#include "mimehandler.h"
58
#include "mimehandler.h"
57
#include "pathut.h"
59
#include "pathut.h"
...
...
372
    resList->resetSearch();
374
    resList->resetSearch();
373
375
374
    int qopts = 0;
376
    int qopts = 0;
375
    if (!prefs.queryStemLang.length() == 0)
377
    if (!prefs.queryStemLang.length() == 0)
376
    qopts |= Rcl::Db::QO_STEM;
378
    qopts |= Rcl::Db::QO_STEM;
377
379
    QApplication::setOverrideCursor(QCursor(Qt::WaitCursor));
378
    if (!rcldb->setQuery(sdata, qopts, prefs.queryStemLang.ascii())) {
380
    if (!rcldb->setQuery(sdata, qopts, prefs.queryStemLang.ascii())) {
379
    QMessageBox::warning(0, "Recoll", tr("Cant start query: ") +
381
    QMessageBox::warning(0, "Recoll", tr("Cant start query: ") +
380
                 QString::fromAscii(rcldb->getReason().c_str()));
382
                 QString::fromAscii(rcldb->getReason().c_str()));
381
    return;
383
    return;
382
    }
384
    }
...
...
384
    DocSequenceDb *src = 
386
    DocSequenceDb *src = 
385
    new DocSequenceDb(rcldb, string(tr("Query results").utf8()), sdata);
387
    new DocSequenceDb(rcldb, string(tr("Query results").utf8()), sdata);
386
    m_docSource = RefCntr<DocSequence>(src);
388
    m_docSource = RefCntr<DocSequence>(src);
387
    m_searchData = sdata;
389
    m_searchData = sdata;
388
    setDocSequence();
390
    setDocSequence();
391
    QApplication::restoreOverrideCursor();
389
}
392
}
390
393
391
void RclMain::resetSearch()
394
void RclMain::resetSearch()
392
{
395
{
393
    resList->resetSearch();
396
    resList->resetSearch();