~ubuntu-branches/ubuntu/wily/oxygen/wily

« back to all changes in this revision

Viewing changes to kstyle/config/oxygenconfigdialog.h

  • Committer: Package Import Robot
  • Author(s): Jonathan Riddell, Scarlett Clark, Jonathan Riddell
  • Date: 2015-08-10 23:18:51 UTC
  • mfrom: (1.1.9)
  • Revision ID: package-import@ubuntu.com-20150810231851-wtw33zvkigya4f7t
Tags: 4:5.3.95-0ubuntu1
[ Scarlett Clark ]
* Vivid backport. 

[ Jonathan Riddell ]
* new upstream beta release

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#ifndef oxygenconfigdialog_h
2
 
#define oxygenconfigdialog_h
3
 
 
4
 
//////////////////////////////////////////////////////////////////////////////
5
 
// oxygenconfigdialog.h
6
 
// oxygen configuration dialog
7
 
// -------------------
8
 
//
9
 
// Copyright (c) 2010 Hugo Pereira Da Costa <hugo.pereira@free.fr>
10
 
//
11
 
// Permission is hereby granted, free of charge, to any person obtaining a copy
12
 
// of this software and associated documentation files (the "Software"), to
13
 
// deal in the Software without restriction, including without limitation the
14
 
// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
15
 
// sell copies of the Software, and to permit persons to whom the Software is
16
 
// furnished to do so, subject to the following conditions:
17
 
//
18
 
// The above copyright notice and this permission notice shall be included in
19
 
// all copies or substantial portions of the Software.
20
 
//
21
 
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22
 
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23
 
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24
 
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25
 
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
26
 
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
27
 
// IN THE SOFTWARE.
28
 
//////////////////////////////////////////////////////////////////////////////
29
 
 
30
 
#include "ui_oxygenconfigdialog.h"
31
 
 
32
 
namespace Oxygen
33
 
{
34
 
 
35
 
    class ConfigDialog: public QDialog, Ui::OxygenConfigDialog
36
 
    {
37
 
        Q_OBJECT
38
 
 
39
 
        public:
40
 
 
41
 
        //! constructor
42
 
        explicit ConfigDialog( QWidget* parent = 0 );
43
 
 
44
 
        //! destructor
45
 
        virtual ~ConfigDialog( void )
46
 
        {}
47
 
 
48
 
        Q_SIGNALS:
49
 
 
50
 
        //! save local changes
51
 
        void pluginSave( void );
52
 
 
53
 
        //! expert mode
54
 
        void pluginToggleExpertMode( bool );
55
 
 
56
 
        public Q_SLOTS:
57
 
 
58
 
        //! save local changes
59
 
        virtual void save( void );
60
 
 
61
 
        protected Q_SLOTS:
62
 
 
63
 
        // update decoration changed state
64
 
        void updateStyleChanged( bool state = true )
65
 
        { _styleChanged = state; }
66
 
 
67
 
        // update decoration changed state
68
 
        void updateDecorationChanged( bool state = true )
69
 
        { _decorationChanged = state; }
70
 
 
71
 
        // handle configuration modifications
72
 
        virtual void updateChanged( void );
73
 
 
74
 
        // update window title based on selected page
75
 
        virtual void updateWindowTitle( KPageWidgetItem* = 0 );
76
 
 
77
 
        private:
78
 
 
79
 
        //! true if configuration changed
80
 
        bool changed( void ) const
81
 
        { return _styleChanged || _decorationChanged; }
82
 
 
83
 
        //! load style config widget from plugin
84
 
        KPageWidgetItem* loadStyleConfig( void );
85
 
 
86
 
        //! load decoration config widget from plugin
87
 
        KPageWidgetItem* loadDecorationConfig( void );
88
 
 
89
 
        //! style plugin widget
90
 
        QObject *_stylePluginObject;
91
 
 
92
 
        //! decoration plugin widget
93
 
        QObject *_decorationPluginObject;
94
 
 
95
 
        bool _styleChanged;
96
 
        bool _decorationChanged;
97
 
 
98
 
    };
99
 
 
100
 
}
101
 
 
102
 
#endif