~ubuntu-branches/ubuntu/intrepid/digikam/intrepid

« back to all changes in this revision

Viewing changes to digikam/utilities/slideshow/slideshow.h

  • Committer: Bazaar Package Importer
  • Author(s): Mark Purcell
  • Date: 2008-07-17 20:25:39 UTC
  • mfrom: (1.3.2 upstream) (37 hardy)
  • mto: This revision was merged to the branch mainline in revision 39.
  • Revision ID: james.westby@ubuntu.com-20080717202539-1bw3w3nrsso7yj4z
* New upstream release
  - digiKam 0.9.4 Release Plan (KDE3) ~ 13 July 08 (Closes: #490144)
* DEB_CONFIGURE_EXTRA_FLAGS := --without-included-sqlite3
* Debhelper compatibility level V7
* Install pixmaps in debian/*.install
* Add debian/digikam.lintian-overrides

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* ============================================================
 
2
 *
 
3
 * This file is a part of digiKam project
 
4
 * http://www.digikam.org
 
5
 * 
 
6
 * Date        : 2005-04-21
 
7
 * Description : slide show tool using preview of pictures.
 
8
 * 
 
9
 * Copyright (C) 2005-2007 by Gilles Caulier <caulier dot gilles at gmail dot com>
 
10
 *
 
11
 * This program is free software; you can redistribute it
 
12
 * and/or modify it under the terms of the GNU General
 
13
 * Public License as published by the Free Software Foundation;
 
14
 * either version 2, or (at your option)
 
15
 * any later version.
 
16
 * 
 
17
 * This program is distributed in the hope that it will be useful,
 
18
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
19
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
20
 * GNU General Public License for more details.
 
21
 * 
 
22
 * ============================================================ */
 
23
 
 
24
#ifndef SLIDE_SHOW_H
 
25
#define SLIDE_SHOW_H
 
26
 
 
27
// Qt includes.
 
28
 
 
29
#include <qwidget.h>
 
30
 
 
31
// Local includes.
 
32
 
 
33
#include "digikam_export.h"
 
34
#include "loadingdescription.h"
 
35
#include "slideshowsettings.h"
 
36
 
 
37
namespace Digikam
 
38
{
 
39
 
 
40
class DImg;
 
41
class SlideShowPriv;
 
42
 
 
43
class DIGIKAM_EXPORT SlideShow : public QWidget
 
44
{
 
45
    Q_OBJECT
 
46
 
 
47
public:
 
48
 
 
49
    SlideShow(const SlideShowSettings& settings);
 
50
    ~SlideShow();
 
51
 
 
52
    void setCurrent(const KURL& url);
 
53
 
 
54
protected:
 
55
 
 
56
    void paintEvent(QPaintEvent *);
 
57
    void mousePressEvent(QMouseEvent *);
 
58
    void mouseMoveEvent(QMouseEvent *);
 
59
    void keyPressEvent(QKeyEvent *);
 
60
    void wheelEvent(QWheelEvent *);
 
61
 
 
62
private slots:
 
63
 
 
64
    void slotTimeOut();
 
65
    void slotMouseMoveTimeOut();
 
66
    void slotGotImagePreview(const LoadingDescription &, const DImg &);
 
67
 
 
68
    void slotPause();
 
69
    void slotPlay();
 
70
    void slotPrev();
 
71
    void slotNext();
 
72
    void slotClose();
 
73
 
 
74
private:
 
75
 
 
76
    void loadNextImage();
 
77
    void loadPrevImage();
 
78
    void preloadNextImage();
 
79
    void updatePixmap();
 
80
    void printInfoText(QPainter &p, int &offset, const QString& str);
 
81
    void printComments(QPainter &p, int &offset, const QString& comments);
 
82
 
 
83
private:
 
84
 
 
85
    SlideShowPriv *d;
 
86
};
 
87
 
 
88
}  // NameSpace Digikam
 
89
 
 
90
#endif /* SLIDE_SHOW_H */