Make schematic and project inherit from PROJECT::ELEM
Just to see if anything weird happens first.
This commit is contained in:
@@ -24,6 +24,7 @@
|
||||
#include <embedded_files.h>
|
||||
#include <sch_sheet_path.h>
|
||||
#include <schematic_settings.h>
|
||||
#include <project.h>
|
||||
|
||||
|
||||
class BUS_ALIAS;
|
||||
@@ -64,7 +65,7 @@ public:
|
||||
* Right now, Eeschema can have only one schematic open at a time, but this could change.
|
||||
* Please keep this possibility in mind when adding to this object.
|
||||
*/
|
||||
class SCHEMATIC : public EDA_ITEM, public EMBEDDED_FILES
|
||||
class SCHEMATIC : public EDA_ITEM, public EMBEDDED_FILES, public PROJECT::_ELEM
|
||||
{
|
||||
public:
|
||||
SCHEMATIC( PROJECT* aPrj );
|
||||
@@ -354,6 +355,8 @@ public:
|
||||
void Show( int nestLevel, std::ostream& os ) const override {}
|
||||
#endif
|
||||
|
||||
PROJECT::ELEM ProjectElementType() override { return PROJECT::ELEM::SCHEMATIC; }
|
||||
|
||||
private:
|
||||
friend class SCH_EDIT_FRAME;
|
||||
|
||||
|
||||
@@ -78,6 +78,9 @@ public:
|
||||
|
||||
DESIGN_BLOCK_LIB_TABLE,
|
||||
|
||||
SCHEMATIC,
|
||||
BOARD,
|
||||
|
||||
COUNT
|
||||
};
|
||||
|
||||
|
||||
+4
-1
@@ -40,6 +40,7 @@
|
||||
#include <title_block.h>
|
||||
#include <tools/pcb_selection.h>
|
||||
#include <shared_mutex>
|
||||
#include <project.h>
|
||||
#include <list>
|
||||
|
||||
class BOARD_DESIGN_SETTINGS;
|
||||
@@ -291,7 +292,7 @@ enum class BOARD_USE
|
||||
/**
|
||||
* Information pertinent to a Pcbnew printed circuit board.
|
||||
*/
|
||||
class BOARD : public BOARD_ITEM_CONTAINER, public EMBEDDED_FILES
|
||||
class BOARD : public BOARD_ITEM_CONTAINER, public EMBEDDED_FILES, public PROJECT::_ELEM
|
||||
{
|
||||
public:
|
||||
static inline bool ClassOf( const EDA_ITEM* aItem )
|
||||
@@ -1301,6 +1302,8 @@ public:
|
||||
*/
|
||||
COMPONENT_CLASS_MANAGER& GetComponentClassManager() { return m_componentClassManager; }
|
||||
|
||||
PROJECT::ELEM ProjectElementType() override { return PROJECT::ELEM::BOARD; }
|
||||
|
||||
// --------- Item order comparators ---------
|
||||
|
||||
struct cmp_items
|
||||
|
||||
Reference in New Issue
Block a user