swift
dbmappingcomponentaware.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (C) 2015 swift Project Community / Contributors
2 // SPDX-License-Identifier: GPL-3.0-or-later OR LicenseRef-swift-pilot-client-1
3 
5 
6 #ifndef SWIFT_GUI_COMPONENTS_DBMAPPINGCOMPONENTAWARE_H
7 #define SWIFT_GUI_COMPONENTS_DBMAPPINGCOMPONENTAWARE_H
8 
9 #include <QObject>
10 
11 #include "gui/swiftguiexport.h"
12 #include "misc/statusmessage.h"
13 
14 namespace swift::gui::components
15 {
16  class CDbMappingComponent;
17 
20  {
21  public:
23  virtual void setMappingComponent(CDbMappingComponent *component);
24 
26  CDbMappingComponent *getMappingComponent() const { return m_mappingComponent; }
27 
28  protected:
30  CDbMappingComponentAware(QObject *parent);
31 
34 
37 
40 
43  bool showMappingComponentOverlayMessage(const swift::misc::CStatusMessage &message,
44  std::chrono::milliseconds timeout = std::chrono::milliseconds(0));
45  bool showMappingComponentOverlayHtmlMessage(const swift::misc::CStatusMessage &message,
46  std::chrono::milliseconds timeout = std::chrono::milliseconds(0));
48 
49  private:
50  CDbMappingComponent *m_mappingComponent = nullptr;
51  };
52 } // namespace swift::gui::components
53 
55  "org.swift-project.swiftgui.components.dbmappingcomponentaware")
56 
57 #endif // SWIFT_GUI_COMPONENTS_DBMAPPINGCOMPONENTAWARE_H
Allows subcomponents to gain access to model component.
CDbMappingComponent * getMappingComponent() const
Get the mapping component.
CDbMappingComponentAware(const CDbMappingComponentAware &)=default
Copy constructor.
CDbMappingComponentAware & operator=(const CDbMappingComponentAware &)=default
Copy assignment operator.
Streamable status message, e.g.
High level reusable GUI components.
Definition: aboutdialog.cpp:13
#define SWIFT_GUI_EXPORT
Export a class or function from the library.