Diffstat (limited to 'noncore/graphics/drawpad/thumbnailview.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/graphics/drawpad/thumbnailview.h | 53 |
1 files changed, 43 insertions, 10 deletions
diff --git a/noncore/graphics/drawpad/thumbnailview.h b/noncore/graphics/drawpad/thumbnailview.h index c74730d..ae97ff1 100644 --- a/noncore/graphics/drawpad/thumbnailview.h +++ b/noncore/graphics/drawpad/thumbnailview.h @@ -9,32 +9,65 @@ * the Free Software Foundation; either version 2 of the License, or * * (at your option) any later version. * * * ***************************************************************************/ #ifndef THUMBNAILVIEW_H #define THUMBNAILVIEW_H -#include <qdialog.h> +#include <qwidget.h> +#include <qlistview.h> -#include <qlist.h> +class DrawPadCanvas; +class Page; -class QListView; +class PageListViewItem : public QListViewItem +{ +public: + PageListViewItem(Page* page, QListView* parent); + ~PageListViewItem(); -class Page; + Page* page() const; -class ThumbnailView : public QDialog -{ - Q_OBJECT +private: + Page* m_pPage; +}; +class PageListView : public QListView +{ public: - ThumbnailView(QList<Page> pages, QWidget* parent = 0, const char* name = 0); - ~ThumbnailView(); + PageListView(DrawPadCanvas* drawPadCanvas, QWidget* parent = 0, const char* name = 0); + ~PageListView(); + + void updateView(); + + Page* selected() const; protected: void resizeEvent(QResizeEvent* e); private: - QListView* m_pListView; + DrawPadCanvas* m_pDrawPadCanvas; +}; + +class ThumbnailView : public QWidget +{ + Q_OBJECT + +public: + ThumbnailView(DrawPadCanvas* drawPadCanvas, QWidget* parent = 0, const char* name = 0); + ~ThumbnailView(); + + void hide(); + void exec(); + +public slots: + void deletePage(); + +private: + bool inLoop; + DrawPadCanvas* m_pDrawPadCanvas; + + PageListView* m_pPageListView; }; #endif // THUMBNAILVIEW_H |