Diffstat (limited to 'noncore/graphics/drawpad/thumbnailview.h') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/graphics/drawpad/thumbnailview.h | 51 |
1 files changed, 42 insertions, 9 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 @@ | |||
9 | * the Free Software Foundation; either version 2 of the License, or * | 9 | * the Free Software Foundation; either version 2 of the License, or * |
10 | * (at your option) any later version. * | 10 | * (at your option) any later version. * |
11 | * * | 11 | * * |
12 | ***************************************************************************/ | 12 | ***************************************************************************/ |
13 | 13 | ||
14 | #ifndef THUMBNAILVIEW_H | 14 | #ifndef THUMBNAILVIEW_H |
15 | #define THUMBNAILVIEW_H | 15 | #define THUMBNAILVIEW_H |
16 | 16 | ||
17 | #include <qdialog.h> | 17 | #include <qwidget.h> |
18 | #include <qlistview.h> | ||
18 | 19 | ||
19 | #include <qlist.h> | 20 | class DrawPadCanvas; |
21 | class Page; | ||
22 | |||
23 | class PageListViewItem : public QListViewItem | ||
24 | { | ||
25 | public: | ||
26 | PageListViewItem(Page* page, QListView* parent); | ||
27 | ~PageListViewItem(); | ||
20 | 28 | ||
21 | class QListView; | 29 | Page* page() const; |
22 | 30 | ||
23 | class Page; | 31 | private: |
32 | Page* m_pPage; | ||
33 | }; | ||
34 | |||
35 | class PageListView : public QListView | ||
36 | { | ||
37 | public: | ||
38 | PageListView(DrawPadCanvas* drawPadCanvas, QWidget* parent = 0, const char* name = 0); | ||
39 | ~PageListView(); | ||
40 | |||
41 | void updateView(); | ||
24 | 42 | ||
25 | class ThumbnailView : public QDialog | 43 | Page* selected() const; |
44 | |||
45 | protected: | ||
46 | void resizeEvent(QResizeEvent* e); | ||
47 | |||
48 | private: | ||
49 | DrawPadCanvas* m_pDrawPadCanvas; | ||
50 | }; | ||
51 | |||
52 | class ThumbnailView : public QWidget | ||
26 | { | 53 | { |
27 | Q_OBJECT | 54 | Q_OBJECT |
28 | 55 | ||
29 | public: | 56 | public: |
30 | ThumbnailView(QList<Page> pages, QWidget* parent = 0, const char* name = 0); | 57 | ThumbnailView(DrawPadCanvas* drawPadCanvas, QWidget* parent = 0, const char* name = 0); |
31 | ~ThumbnailView(); | 58 | ~ThumbnailView(); |
32 | 59 | ||
33 | protected: | 60 | void hide(); |
34 | void resizeEvent(QResizeEvent* e); | 61 | void exec(); |
62 | |||
63 | public slots: | ||
64 | void deletePage(); | ||
35 | 65 | ||
36 | private: | 66 | private: |
37 | QListView* m_pListView; | 67 | bool inLoop; |
68 | DrawPadCanvas* m_pDrawPadCanvas; | ||
69 | |||
70 | PageListView* m_pPageListView; | ||
38 | }; | 71 | }; |
39 | 72 | ||
40 | #endif // THUMBNAILVIEW_H | 73 | #endif // THUMBNAILVIEW_H |