SVN_SILENT made messages (.desktop file)
[kdegraphics.git] / okular / ui / side_reviews.h
blob14aa950fde96babe4215c52c9ad3e0b242b2aeeb
1 /***************************************************************************
2 * Copyright (C) 2005 by Enrico Ros <eros.kde@email.it> *
3 * *
4 * This program is free software; you can redistribute it and/or modify *
5 * it under the terms of the GNU General Public License as published by *
6 * the Free Software Foundation; either version 2 of the License, or *
7 * (at your option) any later version. *
8 ***************************************************************************/
10 #ifndef _OKULAR_SIDE_REVIEWS_H_
11 #define _OKULAR_SIDE_REVIEWS_H_
13 #include <QtCore/QModelIndexList>
14 #include <QtCore/QVector>
15 #include <QtGui/QWidget>
17 #include "core/observer.h"
19 class QModelIndex;
21 namespace Okular {
22 class Annotation;
23 class Document;
26 class AnnotationModel;
27 class AuthorGroupProxyModel;
28 class PageFilterProxyModel;
29 class PageGroupProxyModel;
30 class TreeView;
32 /**
33 * @short ...
35 class Reviews : public QWidget, public Okular::DocumentObserver
37 Q_OBJECT
38 public:
39 Reviews( QWidget * parent, Okular::Document * document );
40 ~Reviews();
42 // [INHERITED] from DocumentObserver
43 uint observerId() const { return REVIEWS_ID; }
44 void notifyViewportChanged( bool smoothMove );
46 public Q_SLOTS:
47 void slotPageEnabled( bool );
48 void slotAuthorEnabled( bool );
49 void slotCurrentPageOnly( bool );
51 Q_SIGNALS:
52 void setAnnotationWindow( Okular::Annotation *annotation );
53 void removeAnnotationWindow( Okular::Annotation *annotation );
55 private Q_SLOTS:
56 void activated( const QModelIndex& );
57 void contextMenuRequested( const QPoint& );
59 private:
60 QModelIndexList retrieveAnnotations(const QModelIndex& idx) const;
62 // data fields (GUI)
63 TreeView * m_view;
64 // internal storage
65 Okular::Document * m_document;
66 AnnotationModel * m_model;
67 AuthorGroupProxyModel * m_authorProxy;
68 PageFilterProxyModel * m_filterProxy;
69 PageGroupProxyModel * m_groupProxy;
72 #endif