1 /***************************************************************************
2 copyright : (C) 2004 Nathan Toone
3 email : nathan@toonetown.com
4 ***************************************************************************/
6 /***************************************************************************
8 * This program is free software; you can redistribute it and/or modify *
9 * it under the terms of the GNU General Public License as published by *
10 * the Free Software Foundation; either version 2 of the License, or *
11 * (at your option) any later version. *
13 ***************************************************************************/
15 #ifndef GOOGLEFETCHERDIALOG_H
16 #define GOOGLEFETCHERDIALOG_H
19 #include <k3iconview.h>
21 #include "googlefetcher.h"
22 #include "filehandle.h"
29 class GoogleFetcherDialog
: public KDialog
34 GoogleFetcherDialog(const QString
&name
,
35 const GoogleImageList
&urlList
,
36 const FileHandle
&file
,
39 virtual ~GoogleFetcherDialog();
41 QPixmap
result() const { return m_pixmap
; }
42 bool takeIt() const { return m_takeIt
; }
43 bool newSearch() const { return m_newSearch
; }
46 void setImageList(const GoogleImageList
&urlList
);
50 void refreshScreen(GoogleImageList
&list
);
53 void sizeChanged(GoogleFetcher::ImageSize
);
59 void imgSizeChanged(int index
);
62 QPixmap
fetchedImage(int index
) const;
63 QPixmap
pixmapFromURL(const KUrl
&url
) const;
66 GoogleImageList m_imageList
;
67 K3IconView
*m_iconWidget
;
79 class CoverIconViewItem
: public QObject
, public K3IconViewItem
84 CoverIconViewItem(Q3IconView
*parent
, const GoogleImage
&image
);
88 void imageData(KIO::Job
*job
, const QByteArray
&data
);
89 void imageResult(KIO::Job
*job
);
93 QPointer
<KIO::TransferJob
> m_job
;
98 // vim: set et sw=4 tw=0 sta: