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
be2f22d4
Commit
be2f22d4
authored
Apr 09, 2011
by
jean-pierre charras
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Testing minor enhancements and fixes
parent
053498d1
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
15 deletions
+14
-15
getpart.cpp
eeschema/getpart.cpp
+5
-2
viewlib_frame.cpp
eeschema/viewlib_frame.cpp
+8
-12
files.cpp
pcbnew/files.cpp
+1
-1
No files found.
eeschema/getpart.cpp
View file @
be2f22d4
...
@@ -70,6 +70,7 @@ static void abortMoveComponent( EDA_DRAW_PANEL* aPanel, wxDC* aDC )
...
@@ -70,6 +70,7 @@ static void abortMoveComponent( EDA_DRAW_PANEL* aPanel, wxDC* aDC )
wxString
SCH_EDIT_FRAME
::
SelectFromLibBrowser
(
void
)
wxString
SCH_EDIT_FRAME
::
SelectFromLibBrowser
(
void
)
{
{
wxSemaphore
semaphore
(
0
,
1
);
wxSemaphore
semaphore
(
0
,
1
);
wxString
cmpname
;
/* Close the current Lib browser, if open, and open a new one, in "modal" mode */
/* Close the current Lib browser, if open, and open a new one, in "modal" mode */
if
(
m_ViewlibFrame
)
if
(
m_ViewlibFrame
)
...
@@ -80,7 +81,6 @@ wxString SCH_EDIT_FRAME::SelectFromLibBrowser( void )
...
@@ -80,7 +81,6 @@ wxString SCH_EDIT_FRAME::SelectFromLibBrowser( void )
m_ViewlibFrame
=
new
LIB_VIEW_FRAME
(
this
,
NULL
,
&
semaphore
);
m_ViewlibFrame
=
new
LIB_VIEW_FRAME
(
this
,
NULL
,
&
semaphore
);
m_ViewlibFrame
->
AdjustScrollBars
(
wxPoint
(
0
,
0
)
);
m_ViewlibFrame
->
AdjustScrollBars
(
wxPoint
(
0
,
0
)
);
// Show the library viewer frame until it is closed
// Show the library viewer frame until it is closed
while
(
semaphore
.
TryWait
()
==
wxSEMA_BUSY
)
// Wait for viewer closing event
while
(
semaphore
.
TryWait
()
==
wxSEMA_BUSY
)
// Wait for viewer closing event
{
{
...
@@ -88,7 +88,10 @@ wxString SCH_EDIT_FRAME::SelectFromLibBrowser( void )
...
@@ -88,7 +88,10 @@ wxString SCH_EDIT_FRAME::SelectFromLibBrowser( void )
wxMilliSleep
(
50
);
wxMilliSleep
(
50
);
}
}
return
m_ViewlibFrame
->
GetSelectedComponent
();
cmpname
=
m_ViewlibFrame
->
GetSelectedComponent
();
m_ViewlibFrame
->
Destroy
();
return
cmpname
;
}
}
...
...
eeschema/viewlib_frame.cpp
View file @
be2f22d4
...
@@ -103,7 +103,7 @@ LIB_VIEW_FRAME::LIB_VIEW_FRAME( wxWindow* father, CMP_LIBRARY* Library, wxSemaph
...
@@ -103,7 +103,7 @@ LIB_VIEW_FRAME::LIB_VIEW_FRAME( wxWindow* father, CMP_LIBRARY* Library, wxSemaph
m_exportToEeschemaCmpName
.
Empty
();
m_exportToEeschemaCmpName
.
Empty
();
if
(
m_Semaphore
)
if
(
m_Semaphore
)
SetWindowStyle
(
GetWindowStyle
()
|
wxFRAME_FLOAT_ON_PARENT
);
MakeModal
(
true
);
SetScreen
(
new
SCH_SCREEN
()
);
SetScreen
(
new
SCH_SCREEN
()
);
GetScreen
()
->
m_Center
=
true
;
// Center coordinate origins on screen.
GetScreen
()
->
m_Center
=
true
;
// Center coordinate origins on screen.
...
@@ -247,20 +247,16 @@ void LIB_VIEW_FRAME::OnCloseWindow( wxCloseEvent& Event )
...
@@ -247,20 +247,16 @@ void LIB_VIEW_FRAME::OnCloseWindow( wxCloseEvent& Event )
{
{
SaveSettings
();
SaveSettings
();
if
(
m_Semaphore
)
m_Semaphore
->
Post
();
Destroy
();
if
(
m_Semaphore
)
if
(
m_Semaphore
)
{
{
// Raise EESchema above all other windows when the library viewer is being used
m_Semaphore
->
Post
();
// to select a component.
MakeModal
(
false
);
wxWindow
*
parent
=
GetParent
();
// This window will be destroyed by the calling function,
// to avoid side effects
if
(
parent
)
parent
->
Raise
();
}
}
else
Destroy
();
}
}
...
...
pcbnew/files.cpp
View file @
be2f22d4
...
@@ -281,9 +281,9 @@ this file again." ) );
...
@@ -281,9 +281,9 @@ this file again." ) );
// Display the loaded board:
// Display the loaded board:
Zoom_Automatique
(
false
);
Zoom_Automatique
(
false
);
wxSafeYield
();
// Needed if we want to see the board now.
// Compile ratsnest and displays net info
// Compile ratsnest and displays net info
wxBusyCursor
dummy
;
// Displays an Hourglass while building connectivity
Compile_Ratsnest
(
NULL
,
true
);
Compile_Ratsnest
(
NULL
,
true
);
GetBoard
()
->
DisplayInfo
(
this
);
GetBoard
()
->
DisplayInfo
(
this
);
...
...
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