LibrePCB Developers Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
compsymbvarpinsignalmapeditorwidget.h
Go to the documentation of this file.
1 /*
2  * LibrePCB - Professional EDA for everyone!
3  * Copyright (C) 2013 LibrePCB Developers, see AUTHORS.md for contributors.
4  * https://librepcb.org/
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, see <http://www.gnu.org/licenses/>.
18  */
19 
20 #ifndef LIBREPCB_LIBRARY_EDITOR_COMPSYMBVARPINSIGNALMAPEDITORWIDGET_H
21 #define LIBREPCB_LIBRARY_EDITOR_COMPSYMBVARPINSIGNALMAPEDITORWIDGET_H
22 
23 /*******************************************************************************
24  * Includes
25  ******************************************************************************/
27 
28 #include <QtCore>
29 #include <QtWidgets>
30 
31 /*******************************************************************************
32  * Namespace / Forward Declarations
33  ******************************************************************************/
34 namespace librepcb {
35 
36 class UndoStack;
37 class SortFilterProxyModel;
38 
39 namespace library {
40 
41 class LibraryElementCache;
42 class ComponentSymbolVariant;
43 class ComponentPinSignalMapModel;
44 
45 namespace editor {
46 
47 /*******************************************************************************
48  * Class CompSymbVarPinSignalMapEditorWidget
49  ******************************************************************************/
50 
54 class CompSymbVarPinSignalMapEditorWidget final : public QWidget {
55  Q_OBJECT
56 
57 public:
58  // Constructors / Destructor
60  QWidget* parent = nullptr) noexcept;
62  const CompSymbVarPinSignalMapEditorWidget& other) = delete;
64 
65  // General Methods
66  void setReferences(
67  ComponentSymbolVariant* variant,
68  const std::shared_ptr<const LibraryElementCache>& symbolCache,
69  const ComponentSignalList* sigs, UndoStack* undoStack) noexcept;
70 
71  // Operator Overloadings
73  const CompSymbVarPinSignalMapEditorWidget& rhs) = delete;
74 
75 private:
76  QScopedPointer<ComponentPinSignalMapModel> mModel;
77  QScopedPointer<SortFilterProxyModel> mProxy;
78  QScopedPointer<QTableView> mView;
79 };
80 
81 /*******************************************************************************
82  * End of File
83  ******************************************************************************/
84 
85 } // namespace editor
86 } // namespace library
87 } // namespace librepcb
88 
89 #endif // LIBREPCB_LIBRARY_EDITOR_COMPSYMBVARPINSIGNALMAPEDITORWIDGET_H
The CompSymbVarPinSignalMapEditorWidget class.
Definition: compsymbvarpinsignalmapeditorwidget.h:54
~CompSymbVarPinSignalMapEditorWidget() noexcept
Definition: compsymbvarpinsignalmapeditorwidget.cpp:88
The UndoStack class holds UndoCommand objects and provides undo/redo commands.
Definition: undostack.h:107
CompSymbVarPinSignalMapEditorWidget(QWidget *parent=nullptr) noexcept
Definition: compsymbvarpinsignalmapeditorwidget.cpp:43
void setReferences(ComponentSymbolVariant *variant, const std::shared_ptr< const LibraryElementCache > &symbolCache, const ComponentSignalList *sigs, UndoStack *undoStack) noexcept
Definition: compsymbvarpinsignalmapeditorwidget.cpp:95
CompSymbVarPinSignalMapEditorWidget & operator=(const CompSymbVarPinSignalMapEditorWidget &rhs)=delete
QScopedPointer< ComponentPinSignalMapModel > mModel
Definition: compsymbvarpinsignalmapeditorwidget.h:76
QScopedPointer< QTableView > mView
Definition: compsymbvarpinsignalmapeditorwidget.h:78
The ComponentSymbolVariant class represents a symbol variant of a component.
Definition: componentsymbolvariant.h:58
QScopedPointer< SortFilterProxyModel > mProxy
Definition: compsymbvarpinsignalmapeditorwidget.h:77