~noskcaj/ubuntu/saucy/sflphone/merge-1.2.3-2

« back to all changes in this revision

Viewing changes to kde/src/conf/ConfigurationDialog.h

  • Committer: Package Import Robot
  • Author(s): Mark Purcell
  • Date: 2012-05-19 21:46:37 UTC
  • mfrom: (1.1.7)
  • Revision ID: package-import@ubuntu.com-20120519214637-la8rbrford5kj6m3
Tags: 1.1.0-1
* New upstream release 
  - Fixes "FTBFS with libccrtp-dev/2.0.2 from experimental" (Closes: #663282)
* NEW Maintainer: Debian VoIP Team - Thanks Francois for your work.
  - (Closes: #665789: O: sflphone -- SIP and IAX2 compatible VoIP phone)
* Added Build-Depends: libdbus-c++-bin
* Add gcc47-fixes.patch

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/***************************************************************************
2
 
 *   Copyright (C) 2009-2012 by Savoir-Faire Linux                         *
3
 
 *   Author : Jérémy Quentin <jeremy.quentin@savoirfairelinux.com>         *
4
 
 *            Emmanuel Lepage Vallee <emmanuel.lepage@savoirfairelinux.com>*
5
 
 *                                                                         *
6
 
 *   This program is free software; you can redistribute it and/or modify  *
7
 
 *   it under the terms of the GNU General Public License as published by  *
8
 
 *   the Free Software Foundation; either version 3 of the License, or     *
9
 
 *   (at your option) any later version.                                   *
10
 
 *                                                                         *
11
 
 *   This program is distributed in the hope that it will be useful,       *
12
 
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
13
 
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
14
 
 *   GNU General Public License for more details.                          *
15
 
 *                                                                         *
16
 
 *   You should have received a copy of the GNU General Public License     *
17
 
 *   along with this program; if not, write to the                         *
18
 
 *   Free Software Foundation, Inc.,                                       *
19
 
 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
20
 
 ***************************************************************************/
21
 
#ifndef CONFIGURATIONDIALOG_H
22
 
#define CONFIGURATIONDIALOG_H
23
 
 
24
 
#include <kconfigdialog.h>
25
 
 
26
 
 
27
 
#include "kcfg_settings.h"
28
 
#include "SFLPhoneView.h"
29
 
 
30
 
 
31
 
#define SETTINGS_NAME "settings"
32
 
 
33
 
class DlgGeneral;
34
 
class DlgDisplay;
35
 
class DlgAccounts;
36
 
class DlgAudio;
37
 
class DlgAddressBook;
38
 
class DlgRecord;
39
 
class DlgHooks;
40
 
 
41
 
class SFLPhoneView;
42
 
 
43
 
/**
44
 
   @author Jérémy Quentin <jeremy.quentin@gmail.com>
45
 
   This class represents the config dialog for sflphone.
46
 
   It uses the ConfigurationSkeleton class to handle most of the settings.
47
 
   It inherits KConfigDialog with the pages defined in dlg... files.
48
 
   A few complicated settings are handled directly by its pages.
49
 
   Some custom behaviors have been added to handle specific cases,
50
 
   as this config dialog is not the usual kind.
51
 
   A few things might be done a cleaner way by passing the handling
52
 
   to the skeleton like it has been done with codecs.
53
 
*/
54
 
class ConfigurationDialog : public KConfigDialog
55
 
{
56
 
Q_OBJECT
57
 
private:
58
 
 
59
 
 
60
 
   DlgGeneral     * dlgGeneral;
61
 
   DlgDisplay     * dlgDisplay;
62
 
   DlgAccounts    * dlgAccounts;
63
 
   DlgAudio       * dlgAudio;
64
 
   DlgAddressBook * dlgAddressBook;
65
 
   DlgHooks       * dlgHooks;
66
 
 
67
 
public:
68
 
   ConfigurationDialog(SFLPhoneView *parent = 0);
69
 
 
70
 
   ~ConfigurationDialog();
71
 
 
72
 
 
73
 
public slots:
74
 
   /**
75
 
    *   Reimplements KConfigDialog
76
 
    */
77
 
   void updateWidgets();
78
 
   /**
79
 
    *   Reimplements KConfigDialog
80
 
    */
81
 
   void updateSettings();
82
 
   /**
83
 
    *   Is implemented in KConfigDialog only from KDE4.3
84
 
    *   It it implemented here for KDE4.2 users.
85
 
    *   I didn't test with KDE4.3 so I leave it even for 4.3 users.
86
 
    *   Causes problems for a few cases (item managed by kconfig switched, item not managed
87
 
    *   switched and then switched back, apply becomes disabled).
88
 
    *   Can't be resolved without a method to know if items managed by kconfig have changed.
89
 
    *   Disable/Enable Apply Button according to hasChanged() result
90
 
    */
91
 
   void updateButtons();
92
 
   /**
93
 
    * @return whether any custom widget has changed in the dialog.
94
 
    */
95
 
   bool hasChanged();
96
 
 
97
 
   /**
98
 
    * reloads the informations before showing it.
99
 
    */
100
 
   void reload();
101
 
 
102
 
private slots:
103
 
   /**
104
 
    *   Apply settings not managed by kconfig (accounts)
105
 
    *   Should be removed when accounts are managed by kconfig.
106
 
    */
107
 
   void applyCustomSettings();
108
 
 
109
 
 
110
 
signals:
111
 
   void clearCallHistoryAsked();
112
 
   void changesApplied();
113
 
 
114
 
};
115
 
 
116
 
#endif