summaryrefslogtreecommitdiffstats
path: root/krename/confdialog.h
blob: 0efe999eb3e88cb50866eb2878c4fd0d3a7d6dac (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
/***************************************************************************
                          confdialog.h  -  description
                             -------------------
    begin                : Sun Jan 27 2002
    copyright            : (C) 2002 by Dominik Seichter
    email                : domseichter@web.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 of the License, or     *
 *   (at your option) any later version.                                   *
 *                                                                         *
 ***************************************************************************/

#ifndef CONFDIALOG_H
#define CONFDIALOG_H

// QT includes
#include <tqcheckbox.h>

// KDE includes
#include <kdialogbase.h>
#include <knuminput.h>

#include "guimodeselector.h"

class TQHBoxLayout;
class TQVBoxLayout;
class TQWidget;
class KIntNumInput;
class ConfDialog : public KDialogBase, public GUIModeSelector {
    Q_OBJECT
  
    public:
        ConfDialog( TQWidget* parent = 0, const char* name = 0 );
        ~ConfDialog();

        inline bool loadplugins() const { return checkPlugins->isChecked(); }
        inline int thumbSize() const { return spinSize->value(); }
        inline bool autosize() const { return checkAutosize->isChecked(); }
        inline int historyItems() const { return spinHistory->value(); }

        inline void setLoadPlugins( bool b ) { checkPlugins->setChecked( b ); }
        inline void setThumbSize( int b ) { spinSize->setValue( b ); }
        inline void setAutosize( bool b ) { checkAutosize->setChecked( b ); }
        inline void setHistoryItems( int b ) { spinHistory->setValue( b ); }
        
    private slots:
        void defaults();

    private:
        void setupTab1();
        void setupTab2();
        
    protected:
        TQCheckBox* checkAsk;
        TQCheckBox* checkPlugins;
        TQCheckBox* checkAutosize;

        KIntNumInput* spinSize;
        KIntNumInput* spinHistory;
};

#endif