Changeset View
Changeset View
Standalone View
Standalone View
kdevplatform/services/interfaces/projectservicehookupconfigpage.h
- This file was added.
1 | /* This file is part of KDevelop | ||||
---|---|---|---|---|---|
2 | Copyright 2017 Friedrich W. H. Kossebau <friedrich.w.h@kossebau.de> | ||||
3 | | ||||
4 | This library is free software; you can redistribute it and/or | ||||
5 | modify it under the terms of the GNU Library General Public | ||||
6 | License as published by the Free Software Foundation; either | ||||
7 | version 2 of the License, or (at your option) any later version. | ||||
8 | | ||||
9 | This library is distributed in the hope that it will be useful, | ||||
10 | but WITHOUT ANY WARRANTY; without even the implied warranty of | ||||
11 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||||
12 | Library General Public License for more details. | ||||
13 | | ||||
14 | You should have received a copy of the GNU Library General Public License | ||||
15 | along with this library; see the file COPYING.LIB. If not, write to | ||||
16 | the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | ||||
17 | Boston, MA 02110-1301, USA. | ||||
18 | */ | ||||
19 | | ||||
20 | #ifndef KDEVPLATFORM_SERVICEHOOKUPCONFIGPAGE_H | ||||
21 | #define KDEVPLATFORM_SERVICEHOOKUPCONFIGPAGE_H | ||||
22 | | ||||
23 | #include "servicesexport.h" | ||||
24 | | ||||
25 | #include <QWidget> | ||||
26 | | ||||
27 | class KConfigGroup; | ||||
28 | | ||||
29 | namespace KDevelop | ||||
30 | { | ||||
31 | | ||||
32 | class IProject; | ||||
33 | class IProjectServiceHookupConfiguration; | ||||
34 | | ||||
35 | /** | ||||
36 | * Provides a configuration page for a project service hookup configuration, the interface | ||||
37 | * allows the actual dialog to easily load/save the configuration and show some title/icon | ||||
38 | */ | ||||
39 | class KDEVPLATFORMSERVICES_EXPORT ProjectServiceHookupConfigPage : public QWidget | ||||
40 | { | ||||
41 | Q_OBJECT | ||||
42 | | ||||
43 | public: | ||||
44 | explicit ProjectServiceHookupConfigPage(QWidget* parent); | ||||
45 | ~ProjectServiceHookupConfigPage() override; | ||||
46 | | ||||
47 | /** | ||||
48 | * Allows the page to load values from an existing service hookup configuration object | ||||
49 | * @param configuration the configuration to load from | ||||
50 | */ | ||||
51 | virtual void loadFromConfiguration(const IProjectServiceHookupConfiguration* configuration) = 0; | ||||
52 | | ||||
53 | /** | ||||
54 | * Allows the page to save values to an existing service hookup configuration object | ||||
55 | * @param configuration the configuration to save to | ||||
56 | */ | ||||
57 | virtual void saveToConfiguration(IProjectServiceHookupConfiguration* configuration) const = 0; | ||||
58 | | ||||
59 | Q_SIGNALS: | ||||
60 | /** | ||||
61 | * Emitted if the user did any editing to the loaded configuration data. | ||||
62 | */ | ||||
63 | void changed(); | ||||
64 | }; | ||||
65 | | ||||
66 | } | ||||
67 | | ||||
68 | #endif |