okular/ui/presentationsearchbar.h
Pino Toscano 6cf46e9160 make the D-Bus call for the search have effect also when in presentation mode;
give focus to the presentation search toolbar when showing it

svn path=/trunk/KDE/kdegraphics/okular/; revision=656256
2007-04-20 19:45:33 +00:00

48 lines
1.3 KiB
C++

/***************************************************************************
* Copyright (C) 2007 by Pino Toscano <pino@kde.org> *
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
***************************************************************************/
#ifndef _OKULAR_PRESENTATIONSEARCHBAR_H_
#define _OKULAR_PRESENTATIONSEARCHBAR_H_
#include <qwidget.h>
class SearchLineEdit;
namespace Okular {
class Document;
}
class PresentationSearchBar
: public QWidget
{
Q_OBJECT
public:
PresentationSearchBar( Okular::Document *document, QWidget *anchor, QWidget *parent = 0 );
virtual ~PresentationSearchBar();
void forceSnap();
void focusOnSearchEdit();
protected:
void resizeEvent( QResizeEvent * );
bool eventFilter( QObject *, QEvent * );
private:
QWidget *m_handle;
QWidget *m_anchor;
QPoint m_point;
bool m_snapped;
QPoint m_drag;
SearchLineEdit *m_search;
};
#endif