Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
kicad-source-mirror
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
kicad-source-mirror
Commits
11e2bdf1
Commit
11e2bdf1
authored
Feb 20, 2015
by
jean-pierre charras
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Eeschema: code cleaning, remove dead code and not used #define or#include in some cpp files.
parent
6c7744e2
Changes
15
Hide whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
141 additions
and
285 deletions
+141
-285
CMakeLists.txt
eeschema/CMakeLists.txt
+0
-1
database.cpp
eeschema/database.cpp
+0
-132
find.cpp
eeschema/find.cpp
+0
-1
libedit.cpp
eeschema/libedit.cpp
+1
-2
libeditframe.cpp
eeschema/libeditframe.cpp
+0
-1
pinedit.cpp
eeschema/pinedit.cpp
+0
-1
protos.h
eeschema/protos.h
+0
-43
sch_bus_entry.cpp
eeschema/sch_bus_entry.cpp
+0
-1
sch_field.cpp
eeschema/sch_field.cpp
+0
-1
sch_line.cpp
eeschema/sch_line.cpp
+2
-4
sch_no_connect.cpp
eeschema/sch_no_connect.cpp
+2
-5
selpart.cpp
eeschema/selpart.cpp
+45
-31
viewlibs.cpp
eeschema/viewlibs.cpp
+49
-54
sch_base_frame.h
include/sch_base_frame.h
+39
-2
wxEeschemaStruct.h
include/wxEeschemaStruct.h
+3
-6
No files found.
eeschema/CMakeLists.txt
View file @
11e2bdf1
...
...
@@ -84,7 +84,6 @@ set( EESCHEMA_SRCS
component_references_lister.cpp
controle.cpp
cross-probing.cpp
database.cpp
${
EESCHEMA_DLGS
}
edit_component_in_schematic.cpp
edit_bitmap.cpp
...
...
eeschema/database.cpp
deleted
100644 → 0
View file @
6c7744e2
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 2007 Jean-Pierre Charras, jaen-pierre.charras@gipsa-lab.inpg.com
* Copyright (C) 1992-2013 KiCad Developers, see AUTHORS.txt for contributors.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, you may find one here:
* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
* or you may search the http://www.gnu.org website for the version 2 license,
* or you may write to the Free Software Foundation, Inc.,
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
*/
/**
* @file database.cpp
*/
#include <fctsys.h>
#include <confirm.h>
#include <eda_doc.h>
#include <kicad_string.h>
#include <draw_frame.h>
#include <macros.h>
#include <protos.h>
#include <class_library.h>
#include <dialog_helpers.h>
#include <boost/foreach.hpp>
// Used in DataBaseGetName: this is a callback function for EDA_LIST_DIALOG
// to display keywords and description of a component
void
DisplayCmpDocAndKeywords
(
wxString
&
aName
,
void
*
aData
)
{
PART_LIBS
*
libs
=
(
PART_LIBS
*
)
aData
;
wxASSERT
(
libs
);
LIB_ALIAS
*
part
=
libs
->
FindLibraryEntry
(
aName
);
if
(
!
part
)
return
;
aName
=
wxT
(
"Description: "
)
+
part
->
GetDescription
();
aName
+=
wxT
(
"
\n
Key Words: "
)
+
part
->
GetKeyWords
();
}
#if 0 // not used, should be wxFrame member for KIWAY and PROJECT access.
/*
* Displays a list of filtered components found in libraries for selection,
* Keys is a list of keywords to filter components which do not match these keywords
* If Keys is empty, list components that match BufName mask (with * and?)
*
* Returns the name of the selected component, or an empty string
*/
wxString DataBaseGetName( EDA_DRAW_FRAME* frame, wxString& Keys, wxString& BufName )
{
std::vector<wxArrayString> nameList;
wxString msg;
// BufName.MakeUpper();
Keys.MakeUpper();
/* Review the list of libraries for counting. */
BOOST_FOREACH( PART_LIB& lib, PART_LIB::GetLibraryList() )
{
lib.SearchEntryNames( nameList, BufName, Keys );
}
if( nameList.empty() )
{
if( !BufName.IsEmpty() )
{
if( !Keys.IsEmpty() )
{
msg.Printf( _( "No components found matching name search criteria '%s' and key search criteria '%s'" ),
GetChars( BufName ), GetChars( Keys ) );
}
else
{
msg.Printf( _( "No components found matching name search criteria '%s'" ),
GetChars( BufName ) );
}
}
else
{
if( !Keys.IsEmpty() )
{
msg.Printf( _( "No components found matching key search criteria '%s'" ),
GetChars( Keys ) );
}
else
{
msg = _( "No components found matching" );
}
}
DisplayInfoMessage( frame, msg );
return wxEmptyString;
}
wxArrayString headers;
headers.Add( _( "Component" ) );
headers.Add( _( "Library" ) );
// Show candidate list:
wxString cmpname;
EDA_LIST_DIALOG dlg( frame, _( "Select Component" ), headers, nameList, cmpname,
DisplayCmpDocAndKeywords, true );
if( dlg.ShowModal() != wxID_OK )
return wxEmptyString;
cmpname = dlg.GetTextSelection();
return cmpname;
}
#endif
eeschema/find.cpp
View file @
11e2bdf1
...
...
@@ -43,7 +43,6 @@
#include <base_units.h>
#include <general.h>
#include <protos.h>
#include <class_library.h>
#include <lib_pin.h>
#include <sch_marker.h>
...
...
eeschema/libedit.cpp
View file @
11e2bdf1
...
...
@@ -40,7 +40,6 @@
#include <eeschema_id.h>
#include <general.h>
#include <protos.h>
#include <libeditframe.h>
#include <class_library.h>
#include <template_fieldnames.h>
...
...
@@ -73,7 +72,7 @@ void LIB_EDIT_FRAME::DisplayLibInfos()
void
LIB_EDIT_FRAME
::
SelectActiveLibrary
(
PART_LIB
*
aLibrary
)
{
if
(
!
aLibrary
)
aLibrary
=
SelectLibraryFromList
(
this
);
aLibrary
=
SelectLibraryFromList
();
if
(
aLibrary
)
{
...
...
eeschema/libeditframe.cpp
View file @
11e2bdf1
...
...
@@ -39,7 +39,6 @@
#include <msgpanel.h>
#include <general.h>
#include <protos.h>
#include <eeschema_id.h>
#include <libeditframe.h>
#include <class_library.h>
...
...
eeschema/pinedit.cpp
View file @
11e2bdf1
...
...
@@ -41,7 +41,6 @@
#include <class_libentry.h>
#include <lib_pin.h>
#include <general.h>
#include <protos.h>
#include <../common/dialogs/dialog_display_info_HTML_base.h>
#include <dialog_lib_edit_pin.h>
...
...
eeschema/protos.h
View file @
11e2bdf1
...
...
@@ -29,13 +29,9 @@
#include <colors.h>
class
EDA_DRAW_PANEL
;
class
EDA_DRAW_FRAME
;
class
PICKED_ITEMS_LIST
;
class
PART_LIB
;
class
SCH_ITEM
;
//void DisplayCmpDoc( wxString& Name );
wxString
DataBaseGetName
(
EDA_DRAW_FRAME
*
frame
,
wxString
&
Keys
,
wxString
&
BufName
);
// operations_on_item_lists.cpp
void
DeleteItemsInList
(
EDA_DRAW_PANEL
*
panel
,
PICKED_ITEMS_LIST
&
aItemsList
);
...
...
@@ -59,43 +55,4 @@ void DrawDanglingSymbol( EDA_DRAW_PANEL* panel, wxDC* DC,
const
wxPoint
&
pos
,
EDA_COLOR_T
Color
);
/***************/
/* SELPART.CPP */
/***************/
/**
* Function DisplayComponentsNamesInLib
* Select component from list of components in this library
*
* If == NULL Library, selection of library REQUESTED
* If only in research library
*
* Returns
* 1 if selected component
* 0 if canceled order
*/
int
DisplayComponentsNamesInLib
(
EDA_DRAW_FRAME
*
frame
,
PART_LIB
*
Library
,
wxString
&
Buffer
,
wxString
&
OldName
);
/**
* Function SelectLibraryFromList
* displays a list of current loaded libraries, and allows the user to select
* a library
* This list is sorted, with the library cache always at end of the list
*/
PART_LIB
*
SelectLibraryFromList
(
EDA_DRAW_FRAME
*
frame
);
/**
* Get the name component from a library to load.
*
* If no library specified, there will be demand for selection of a library.
* Returns
* 1 if selected component
* 0 if canceled order
* Place the name of the selected component list in BufName
*/
int
GetNameOfPartToLoad
(
EDA_DRAW_FRAME
*
frame
,
PART_LIB
*
Lib
,
wxString
&
BufName
);
#endif
/* __PROTOS_H__ */
eeschema/sch_bus_entry.cpp
View file @
11e2bdf1
...
...
@@ -38,7 +38,6 @@
#include <eeschema_config.h>
#include <general.h>
#include <protos.h>
#include <sch_bus_entry.h>
...
...
eeschema/sch_field.cpp
View file @
11e2bdf1
...
...
@@ -46,7 +46,6 @@
#include <plot_common.h>
#include <general.h>
#include <protos.h>
#include <class_library.h>
#include <sch_component.h>
#include <sch_field.h>
...
...
eeschema/sch_line.cpp
View file @
11e2bdf1
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 20
09
Jean-Pierre Charras, jaen-pierre.charras@gipsa-lab.inpg.com
* Copyright (C) 1992-201
1
KiCad Developers, see AUTHORS.txt for contributors.
* Copyright (C) 20
15
Jean-Pierre Charras, jaen-pierre.charras@gipsa-lab.inpg.com
* Copyright (C) 1992-201
5
KiCad Developers, see AUTHORS.txt for contributors.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
...
...
@@ -31,8 +31,6 @@
#include <gr_basic.h>
#include <macros.h>
#include <class_drawpanel.h>
#include <trigo.h>
#include <richio.h>
#include <plot_common.h>
#include <base_units.h>
#include <eeschema_config.h>
...
...
eeschema/sch_no_connect.cpp
View file @
11e2bdf1
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 20
09
Jean-Pierre Charras, jaen-pierre.charras@gipsa-lab.inpg.com
* Copyright (C) 1992-201
1
KiCad Developers, see AUTHORS.txt for contributors.
* Copyright (C) 20
15
Jean-Pierre Charras, jaen-pierre.charras@gipsa-lab.inpg.com
* Copyright (C) 1992-201
5
KiCad Developers, see AUTHORS.txt for contributors.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
...
...
@@ -32,12 +32,9 @@
#include <macros.h>
#include <class_drawpanel.h>
#include <common.h>
#include <trigo.h>
#include <richio.h>
#include <plot_common.h>
#include <general.h>
#include <protos.h>
#include <sch_no_connect.h>
#include <class_netlist_object.h>
...
...
eeschema/selpart.cpp
View file @
11e2bdf1
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 20
07
Jean-Pierre Charras, jp.charras at wanadoo.fr
* Copyright (C) 201
4
KiCad Developers, see CHANGELOG.TXT for contributors.
* Copyright (C) 20
15
Jean-Pierre Charras, jp.charras at wanadoo.fr
* Copyright (C) 201
5
KiCad Developers, see CHANGELOG.TXT for contributors.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
...
...
@@ -29,23 +29,40 @@
#include <fctsys.h>
#include <gr_basic.h>
#include <confirm.h>
#include <draw_frame.h>
#include <pgm_base.h>
#include <sch_base_frame.h>
#include <general.h>
#include <protos.h>
#include <class_library.h>
#include <dialog_helpers.h>
// Used in DisplayListComponentsInLib: this is a callback function for EDA_LIST_DIALOG
// to display keywords and description of a component
static
void
DisplayCmpDocAndKeywords
(
wxString
&
aName
,
void
*
aData
)
{
PART_LIBS
*
libs
=
(
PART_LIBS
*
)
aData
;
wxASSERT
(
libs
);
LIB_ALIAS
*
part
=
libs
->
FindLibraryEntry
(
aName
);
if
(
!
part
)
return
;
PART_LIB
*
SelectLibraryFromList
(
EDA_DRAW_FRAME
*
aFrame
)
aName
=
wxT
(
"Description: "
)
+
part
->
GetDescription
();
aName
+=
wxT
(
"
\n
Key Words: "
)
+
part
->
GetKeyWords
();
}
PART_LIB
*
SCH_BASE_FRAME
::
SelectLibraryFromList
()
{
PROJECT
&
prj
=
aFrame
->
Prj
();
PROJECT
&
prj
=
Prj
();
if
(
PART_LIBS
*
libs
=
prj
.
SchLibs
()
)
{
if
(
!
libs
->
GetLibraryCount
()
)
{
DisplayError
(
aFrame
,
_
(
"No component libraries are loaded."
)
);
DisplayError
(
this
,
_
(
"No component libraries are loaded."
)
);
return
NULL
;
}
...
...
@@ -69,7 +86,7 @@ PART_LIB* SelectLibraryFromList( EDA_DRAW_FRAME* aFrame )
wxString
old_lib_name
=
prj
.
GetRString
(
PROJECT
::
SCH_LIB_SELECT
);
EDA_LIST_DIALOG
dlg
(
aFrame
,
_
(
"Select Library"
),
headers
,
itemsToDisplay
,
old_lib_name
);
EDA_LIST_DIALOG
dlg
(
this
,
_
(
"Select Library"
),
headers
,
itemsToDisplay
,
old_lib_name
);
if
(
dlg
.
ShowModal
()
!=
wxID_OK
)
return
NULL
;
...
...
@@ -91,22 +108,19 @@ PART_LIB* SelectLibraryFromList( EDA_DRAW_FRAME* aFrame )
}
void
DisplayCmpDocAndKeywords
(
wxString
&
aName
,
void
*
aData
);
int
DisplayComponentsNamesInLib
(
EDA_DRAW_FRAME
*
frame
,
PART_LIB
*
Library
,
wxString
&
Buffer
,
wxString
&
OldName
)
bool
SCH_BASE_FRAME
::
DisplayListComponentsInLib
(
PART_LIB
*
aLibrary
,
wxString
&
aBuffer
,
wxString
&
aPreviousChoice
)
{
wxArrayString
nameList
;
if
(
Library
==
NULL
)
Library
=
SelectLibraryFromList
(
frame
);
if
(
a
Library
==
NULL
)
aLibrary
=
SelectLibraryFromList
(
);
if
(
Library
==
NULL
)
return
0
;
if
(
a
Library
==
NULL
)
return
false
;
Library
->
GetEntryNames
(
nameList
);
a
Library
->
GetEntryNames
(
nameList
);
wxArrayString
headers
;
headers
.
Add
(
wxT
(
"Component"
)
);
...
...
@@ -118,32 +132,32 @@ int DisplayComponentsNamesInLib( EDA_DRAW_FRAME* frame,
{
wxArrayString
item
;
item
.
Add
(
nameList
[
i
]
);
item
.
Add
(
Library
->
GetLogicalName
()
);
item
.
Add
(
a
Library
->
GetLogicalName
()
);
itemsToDisplay
.
push_back
(
item
);
}
EDA_LIST_DIALOG
dlg
(
frame
,
_
(
"Select Component"
),
headers
,
itemsToDisplay
,
OldName
,
DisplayCmpDocAndKeywords
,
frame
->
Prj
().
SchLibs
()
);
EDA_LIST_DIALOG
dlg
(
this
,
_
(
"Select Component"
),
headers
,
itemsToDisplay
,
aPreviousChoice
,
DisplayCmpDocAndKeywords
,
Prj
().
SchLibs
()
);
if
(
dlg
.
ShowModal
()
!=
wxID_OK
)
return
0
;
return
false
;
Buffer
=
dlg
.
GetTextSelection
();
a
Buffer
=
dlg
.
GetTextSelection
();
return
1
;
return
true
;
}
int
GetNameOfPartToLoad
(
EDA_DRAW_FRAME
*
frame
,
PART_LIB
*
Library
,
wxString
&
BufName
)
bool
SCH_BASE_FRAME
::
SelectPartNameToLoad
(
PART_LIB
*
aLibrary
,
wxString
&
a
BufName
)
{
int
ii
;
static
wxString
Old
CmpName
;
static
wxString
previous
CmpName
;
ii
=
Display
ComponentsNamesInLib
(
frame
,
Library
,
BufName
,
Old
CmpName
);
ii
=
Display
ListComponentsInLib
(
aLibrary
,
aBufName
,
previous
CmpName
);
if
(
ii
<=
0
||
BufName
.
IsEmpty
()
)
return
0
;
if
(
ii
<=
0
||
a
BufName
.
IsEmpty
()
)
return
false
;
OldCmpName
=
BufName
;
return
1
;
previousCmpName
=
a
BufName
;
return
true
;
}
eeschema/viewlibs.cpp
View file @
11e2bdf1
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 20
07
Jean-Pierre Charras, jp.charras at wanadoo.fr
* Copyright (C) 201
4
KiCad Developers, see CHANGELOG.TXT for contributors.
* Copyright (C) 20
15
Jean-Pierre Charras, jp.charras at wanadoo.fr
* Copyright (C) 201
5
KiCad Developers, see CHANGELOG.TXT for contributors.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
...
...
@@ -36,7 +36,6 @@
#include <class_sch_screen.h>
#include <general.h>
#include <protos.h>
#include <viewlib_frame.h>
#include <eeschema_id.h>
#include <class_library.h>
...
...
@@ -152,7 +151,7 @@ void LIB_VIEW_FRAME::SelectCurrentLibrary()
{
PART_LIB
*
Lib
;
Lib
=
SelectLibraryFromList
(
this
);
Lib
=
SelectLibraryFromList
();
if
(
Lib
)
{
...
...
@@ -179,6 +178,7 @@ void LIB_VIEW_FRAME::SelectAndViewLibraryPart( int option )
{
if
(
m_libraryName
.
IsEmpty
()
)
SelectCurrentLibrary
();
if
(
m_libraryName
.
IsEmpty
()
)
return
;
...
...
@@ -224,9 +224,7 @@ void LIB_VIEW_FRAME::ViewOneLibraryContent( PART_LIB* Lib, int Flag )
return
;
if
(
Flag
==
NEW_PART
)
{
DisplayComponentsNamesInLib
(
this
,
Lib
,
CmpName
,
m_entryName
);
}
DisplayListComponentsInLib
(
Lib
,
CmpName
,
m_entryName
);
if
(
Flag
==
NEXT_PART
)
{
...
...
@@ -259,59 +257,56 @@ void LIB_VIEW_FRAME::ViewOneLibraryContent( PART_LIB* Lib, int Flag )
if
(
id
>=
0
)
m_cmpList
->
SetSelection
(
id
);
}
ReCreateHToolbar
();
}
void
LIB_VIEW_FRAME
::
RedrawActiveWindow
(
wxDC
*
DC
,
bool
EraseBg
)
{
if
(
PART_LIBS
*
libs
=
Prj
().
SchLibs
()
)
LIB_ALIAS
*
entry
=
Prj
().
SchLibs
()
->
FindLibraryEntry
(
m_entryName
,
m_libraryName
);
if
(
!
entry
)
return
;
LIB_PART
*
part
=
entry
->
GetPart
();
if
(
!
part
)
return
;
wxString
msg
;
wxString
tmp
;
m_canvas
->
DrawBackGround
(
DC
);
if
(
!
entry
->
IsRoot
()
)
{
if
(
PART_LIB
*
lib
=
libs
->
FindLibrary
(
m_libraryName
)
)
{
if
(
LIB_ALIAS
*
entry
=
lib
->
FindEntry
(
m_entryName
)
)
{
if
(
LIB_PART
*
part
=
entry
->
GetPart
()
)
{
wxString
msg
;
wxString
tmp
;
m_canvas
->
DrawBackGround
(
DC
);
if
(
!
entry
->
IsRoot
()
)
{
// Temporarily change the name field text to reflect the alias name.
msg
=
entry
->
GetName
();
tmp
=
part
->
GetName
();
part
->
SetName
(
msg
);
if
(
m_unit
<
1
)
m_unit
=
1
;
if
(
m_convert
<
1
)
m_convert
=
1
;
}
else
{
msg
=
_
(
"None"
);
}
part
->
Draw
(
m_canvas
,
DC
,
wxPoint
(
0
,
0
),
m_unit
,
m_convert
,
GR_DEFAULT_DRAWMODE
);
// Redraw the cursor
m_canvas
->
DrawCrossHair
(
DC
);
if
(
!
tmp
.
IsEmpty
()
)
part
->
SetName
(
tmp
);
ClearMsgPanel
();
AppendMsgPanel
(
_
(
"Part"
),
part
->
GetName
(),
BLUE
,
6
);
AppendMsgPanel
(
_
(
"Alias"
),
msg
,
RED
,
6
);
AppendMsgPanel
(
_
(
"Description"
),
entry
->
GetDescription
(),
CYAN
,
6
);
AppendMsgPanel
(
_
(
"Key words"
),
entry
->
GetKeyWords
(),
DARKDARKGRAY
);
}
}
}
// Temporarily change the name field text to reflect the alias name.
msg
=
entry
->
GetName
();
tmp
=
part
->
GetName
();
part
->
SetName
(
msg
);
if
(
m_unit
<
1
)
m_unit
=
1
;
if
(
m_convert
<
1
)
m_convert
=
1
;
}
else
msg
=
_
(
"None"
);
part
->
Draw
(
m_canvas
,
DC
,
wxPoint
(
0
,
0
),
m_unit
,
m_convert
,
GR_DEFAULT_DRAWMODE
);
// Redraw the cursor
m_canvas
->
DrawCrossHair
(
DC
);
if
(
!
tmp
.
IsEmpty
()
)
part
->
SetName
(
tmp
);
ClearMsgPanel
();
AppendMsgPanel
(
_
(
"Part"
),
part
->
GetName
(),
BLUE
,
6
);
AppendMsgPanel
(
_
(
"Alias"
),
msg
,
RED
,
6
);
AppendMsgPanel
(
_
(
"Description"
),
entry
->
GetDescription
(),
CYAN
,
6
);
AppendMsgPanel
(
_
(
"Key words"
),
entry
->
GetKeyWords
(),
DARKDARKGRAY
);
}
include/sch_base_frame.h
View file @
11e2bdf1
...
...
@@ -3,8 +3,8 @@
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 201
2
SoftPLC Corporation, Dick Hollenbeck <dick@softplc.com>
* Copyright (C) 201
2
KiCad Developers, see change_log.txt for contributors.
* Copyright (C) 201
5
SoftPLC Corporation, Dick Hollenbeck <dick@softplc.com>
* Copyright (C) 201
5
KiCad Developers, see change_log.txt for contributors.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
...
...
@@ -32,6 +32,7 @@ class TITLE_BLOCK;
class
LIB_VIEW_FRAME
;
class
LIB_EDIT_FRAME
;
class
LIB_ALIAS
;
class
PART_LIB
;
/**
* Class SCH_BASE_FRAME
...
...
@@ -132,6 +133,42 @@ protected:
* If the viewed is already opened from an other window, close it and reopen
*/
void
OnOpenLibraryViewer
(
wxCommandEvent
&
event
);
/**
* Function DisplayComponentsNamesInLib
* Select a component from the list of components in a library
*
* @param aLibrary = a reference to the library to explore
* If NULL the user will be prompted tp chose a library
* @param aBuffer = a wxString to put the selected component name
*
* @return true if a component is selected
* false on cancel
*/
bool
DisplayListComponentsInLib
(
PART_LIB
*
aLibrary
,
wxString
&
aBuffer
,
wxString
&
aPreviousChoice
);
/**
* Function SelectLibraryFromList
* displays a list of current loaded libraries, and allows the user to select
* a library
* This list is sorted, with the library cache always at end of the list
* @return a reference to the selected library, or NULL
*/
PART_LIB
*
SelectLibraryFromList
();
/**
* Function SelectPartNameToLoad
* Select a part name from the list of components (parts) found in a library.
*
* @param aLibrary = a reference to the library to explore
* If NULL the user will be prompted tp chose a library
* @param aBufName = a wxString to put the selected component name
*
* @return true if a component is selected
* false on cancel
*/
bool
SelectPartNameToLoad
(
PART_LIB
*
aLibrary
,
wxString
&
aBufName
);
};
#endif // SCH_BASE_FRAME_H_
include/wxEeschemaStruct.h
View file @
11e2bdf1
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 20
04 Jean-Pierre Charras, jaen-pierre.charras@gipsa-lab.inpg.com
* Copyright (C) 2008-201
1
Wayne Stambaugh <stambaughw@verizon.net>
* Copyright (C) 2004-201
1
KiCad Developers, see change_log.txt for contributors.
* Copyright (C) 20
15 Jean-Pierre Charras, jp.charras wanadoo.fr
* Copyright (C) 2008-201
5
Wayne Stambaugh <stambaughw@verizon.net>
* Copyright (C) 2004-201
5
KiCad Developers, see change_log.txt for contributors.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
...
...
@@ -44,9 +44,6 @@ class LIB_VIEW_FRAME;
class
DRAWSEGMENT
;
class
SCH_ITEM
;
class
SCH_NO_CONNECT
;
class
CMP_LIBRARY
;
class
LIB_COMPONENT
;
class
LIB_DRAW_ITEM
;
class
EDA_ITEM
;
class
SCH_BUS_ENTRY_BASE
;
class
SCH_BUS_WIRE_ENTRY
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment