summaryrefslogtreecommitdiffstats
path: root/noatun/modules/kaiman/userinterface.h
blob: 2fb461843154220f815a949bad720d979d68eac3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
/*
   Copyright (c) 2000 Stefan Schimanski <1Stein@gmx.de>

   This program is free software; you can redistribute it and/or modify
   it under the terms of the GNU General Public License as published by
   the Free Software Foundation; either version 2, or (at your option)
   any later version.

   This program is distributed in the hope that it will be useful,
   but WITHOUT ANY WARRANTY; without even the implied warranty of
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
   GNU General Public License for more details.

   You should have received a copy of the GNU General Public License
   aint with this program; if not, write to the Free Software
   Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
*/

#ifndef USERINTERFACE_H
#define USERINTERFACE_H

#include <noatun/plugin.h>
#include <noatun/app.h>
#include <kmainwindow.h>
#include "style.h"


class Player;

/**
 * @short Main window class
 * @author Stefan Schimanski <1Stein@gmx.de>
 * @version 0.1
 */
class Kaiman : public KMainWindow, public UserInterface
{
Q_OBJECT
 public:
    Kaiman();
    virtual ~Kaiman();

    bool changeStyle( const QString &style, const QString &desc=QString::null );
 public slots:
    void dropEvent( QDropEvent * );
    void doDropEvent( QDropEvent * );
    void dragEnterEvent( QDragEnterEvent * );
    void closeEvent(QCloseEvent*);

 protected slots:
    void seekStart( int );
    void seekDrag( int );
    void seekStop( int );
    void seek( int );
    void toggleSkin();

    void setVolume( int vol );
    void volumeUp();
    void volumeDown();

    void execMixer();


    void timeout();
    void loopTypeChange( int t );
    void newSongLen( int mins, int sec );
    void newSong();
    void updateMode();
    void toggleLoop();
    void toggleShuffle();

 public:
    static const char DEFAULT_SKIN[];
    static Kaiman *kaiman;

 protected:
    bool loadStyle( const QString &style, const QString &desc );


    bool _seeking;
    bool _altSkin;
    KaimanStyle *_style;
};


#endif