Removed some stupid debug messages
[kdenetwork.git] / krdc / kfullscreenpanel.h
blob43b4944dbf24276e6fec39cdc68058dfe01e118b
1 /***************************************************************************
2 kfullscreenpanel.cpp - auto-hideable toolbar
3 -------------------
4 begin : Tue May 13 23:07:42 CET 2002
5 copyright : (C) 2002 by Tim Jansen
6 email : tim@tjansen.de
7 ***************************************************************************/
9 /***************************************************************************
10 * *
11 * This program is free software; you can redistribute it and/or modify *
12 * it under the terms of the GNU General Public License as published by *
13 * the Free Software Foundation; either version 2 of the License, or *
14 * (at your option) any later version. *
15 * *
16 ***************************************************************************/
18 #ifndef KFULLSCREENPANEL_H
19 #define KFULLSCREENPANEL_H
21 #include <qwidget.h>
22 #include <qlayout.h>
23 #include <qevent.h>
24 #include <qtimer.h>
26 class Counter : public QObject {
27 Q_OBJECT
28 private:
29 QTimer m_timer;
30 float m_stopValue, m_currentValue, m_stepSize;
31 int m_timeoutMs;
33 public:
34 Counter(float start);
36 void count(float stop, float stepSize, float frequency);
37 private slots:
38 void timeout();
40 signals:
41 void countingDownFinished();
42 void countingUpFinished();
43 void counted(float value);
47 class KFullscreenPanel : public QWidget {
48 Q_OBJECT
49 private:
50 QWidget *m_child;
51 QVBoxLayout *m_layout;
52 QSize m_fsResolution;
53 Counter m_counter;
55 void doLayout();
57 public:
58 KFullscreenPanel(QWidget* parent, const char *name,
59 const QSize &resolution);
60 ~KFullscreenPanel();
62 void setChild(QWidget *child);
63 void startShow();
64 void startHide();
66 protected:
67 void enterEvent(QEvent *e);
68 void leaveEvent(QEvent *e);
70 private slots:
71 void movePanel(float posY);
73 signals:
74 void mouseEnter();
75 void mouseLeave();
78 #endif