Pimcommon

customtoolsplugin.h
1 /*
2  SPDX-FileCopyrightText: 2015-2022 Laurent Montel <[email protected]>
3 
4  SPDX-License-Identifier: GPL-2.0-or-later
5 */
6 
7 #pragma once
8 
9 #include "pimcommon_export.h"
10 #include <QObject>
11 #include <memory>
12 class KActionCollection;
13 namespace PimCommon
14 {
15 class CustomToolsWidgetNg;
16 class CustomToolsViewInterface;
17 class CustomToolsPluginPrivate;
18 /**
19  * @brief The CustomToolsPlugin class
20  * @author Laurent Montel <[email protected]>
21  */
22 class PIMCOMMON_EXPORT CustomToolsPlugin : public QObject
23 {
24  Q_OBJECT
25 public:
26  explicit CustomToolsPlugin(QObject *parent = nullptr);
27  ~CustomToolsPlugin() override;
28 
29  virtual PimCommon::CustomToolsViewInterface *createView(KActionCollection *ac, CustomToolsWidgetNg *parent = nullptr) = 0;
30  Q_REQUIRED_RESULT virtual QString customToolName() const = 0;
31 
32  Q_REQUIRED_RESULT virtual bool hasConfigureDialog() const;
33  virtual void showConfigureDialog(QWidget *parent);
34 
35  void emitConfigChanged();
36 
37  Q_REQUIRED_RESULT virtual QString description() const;
38 
39  void setIsEnabled(bool enabled);
40  Q_REQUIRED_RESULT bool isEnabled() const;
41 
42 private:
43  std::unique_ptr<CustomToolsPluginPrivate> const d;
44 };
45 }
folderdialogacltab.h
The CustomToolsViewInterface class.
The CustomToolsPlugin class.
The CustomToolsWidgetNg class.
This file is part of the KDE documentation.
Documentation copyright © 1996-2022 The KDE developers.
Generated on Sat May 28 2022 04:22:33 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.