summaryrefslogtreecommitdiffstats
path: root/ksplashml/themeengine/unified/themeunified.h
blob: e2930943c0de0742e6a87c80943329201196bf03 (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
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
/***************************************************************************
 *   Copyright Brian Ledbetter 2001-2003 <brian@shadowcom.net>             *
 *   Copyright Ravikiran Rajagopal 2003                                    *
 *   ravi@ee.eng.ohio-state.edu                                            *
 *                                                                         *
 *   This program is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU General Public License (version 2) as   *
 *   published by the Free Software Foundation. (The original KSplash/ML   *
 *   codebase (upto version 0.95.3) is BSD-licensed.)                      *
 *                                                                         *
 ***************************************************************************/

#ifndef __THEMEUNIFIED_H__
#define __THEMEUNIFIED_H__

#include <kprogress.h>

#include <tqlabel.h>
#include <tqwidget.h>

#include <kdialog.h>

#include "themeengine.h"
class TQPixmap;
class TQTimer;

class TQCheckBox;

class UnifiedConfig: public ThemeEngineConfig
{
  TQ_OBJECT
public:
  UnifiedConfig( TQWidget *, TDEConfig * );
  void save();
protected:
  TQCheckBox *mAlwaysShow;
};

/**
 * @short Traditional Trinity splash screen.
 */
class ObjKsTheme;
class KDE_EXPORT ThemeUnified : public ThemeEngine
{
  TQ_OBJECT
public:
  ThemeUnified( TQWidget *, const char *, const TQStringList& );
   virtual ~ThemeUnified();

  inline const UnifiedConfig *config( TQWidget *p, TDEConfig *c )
  {
    return new UnifiedConfig( p, c );
  };

  static TQStringList names()
  {
    TQStringList Names;
    Names << "Unified";
    return( Names );
  }

public slots:
  inline void slotSetText( const TQString& s )
  {
      close();
      if (mSysModalDialog) mSysModalDialog->setStatusMessage(TQString(s).append("..."));
  }
  inline void slotSetTextIndex( const int i )
  {
      if (i == 3) {
          if (mSysModalDialog) {
              KSMModalDialog* temp = mSysModalDialog;
              mSysModalDialog = NULL;
              temp->closeSMDialog();
          }
      }
  }
  inline void slotUpdateSteps( int s )
  {
  }
  inline void slotUpdateProgress( int i )
  {
  }


private slots:
  void slotUpdateState();

private:
  void _initUi();
  void _readSettings();

  // Configurable Options
  TQColor mLabelForeground;

  // Internals.
  KSMModalDialog* mSysModalDialog;
  int mState;
};

#endif