Switch to unified view

a/src/qtgui/ssearchb.ui.h b/src/qtgui/ssearchb.ui.h
...
...
25
** These will automatically be called by the form's constructor and
25
** These will automatically be called by the form's constructor and
26
** destructor.
26
** destructor.
27
*****************************************************************************/
27
*****************************************************************************/
28
28
29
#include "debuglog.h"
29
#include "debuglog.h"
30
#include "guiutils.h"
30
31
31
void SSearchBase::init()
32
void SSearchBase::init()
32
{
33
{
33
    searchTypCMB->insertItem(tr("Any term"));
34
    searchTypCMB->insertItem(tr("Any term"));
34
    searchTypCMB->insertItem(tr("All terms"));
35
    searchTypCMB->insertItem(tr("All terms"));
...
...
38
void SSearchBase::searchTextChanged( const QString & text )
39
void SSearchBase::searchTextChanged( const QString & text )
39
{
40
{
40
    if (text.isEmpty()) {
41
    if (text.isEmpty()) {
41
    searchPB->setEnabled(false);
42
    searchPB->setEnabled(false);
42
    clearqPB->setEnabled(false);
43
    clearqPB->setEnabled(false);
44
  emit clearSearch();
43
    } else {
45
    } else {
44
    searchPB->setEnabled(true);
46
    searchPB->setEnabled(true);
45
    clearqPB->setEnabled(true);
47
    clearqPB->setEnabled(true);
48
  string u8 =  (const char *)queryText->text().utf8();
49
  if (prefs.autoSearchOnWS && !u8.empty() && u8[u8.length()-1] == ' ')
50
      startSimpleSearch();
46
    }
51
    }
47
}
52
}
48
53
49
void SSearchBase::startSimpleSearch()
54
void SSearchBase::startSimpleSearch()
50
{
55
{