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
ba6100e3
Commit
ba6100e3
authored
Mar 22, 2011
by
jean-pierre charras
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Pcbnew: fix a minor issue: *.pro file updated by Pcbnew only on demand.
parent
03d85728
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
22 additions
and
14 deletions
+22
-14
dialog_netlist.cpp
pcbnew/dialogs/dialog_netlist.cpp
+17
-2
pcbframe.cpp
pcbnew/pcbframe.cpp
+0
-7
pcbnew_config.cpp
pcbnew/pcbnew_config.cpp
+1
-1
pcbplot.cpp
pcbnew/pcbplot.cpp
+4
-4
No files found.
pcbnew/dialogs/dialog_netlist.cpp
View file @
ba6100e3
...
...
@@ -5,10 +5,12 @@
/////////////////////////////////////////////////////////////////////////////
#include "fctsys.h"
#include "appl_wxstruct.h"
#include "common.h"
#include "confirm.h"
#include "pcbnew.h"
#include "wxPcbStruct.h"
#include "pcbnew_config.h"
#include "dialog_netlist.h"
...
...
@@ -24,6 +26,7 @@ void PCB_EDIT_FRAME::InstallNetlistFrame( wxDC* DC, const wxPoint& pos )
* name if no last file read is not set.
*/
wxFileName
fn
=
GetLastNetListRead
();
wxString
lastNetlistName
=
GetLastNetListRead
();
if
(
!
fn
.
FileExists
()
)
{
...
...
@@ -31,9 +34,21 @@ void PCB_EDIT_FRAME::InstallNetlistFrame( wxDC* DC, const wxPoint& pos )
fn
.
SetExt
(
NetExtBuffer
);
}
DIALOG_NETLIST
frame
(
this
,
DC
,
fn
.
GetFullPath
()
);
DIALOG_NETLIST
frame
(
this
,
DC
,
lastNetlistName
);
frame
.
ShowModal
();
// Save project settings if needed.
// Project settings are saved in the corresponding <board name>.pro file
if
(
lastNetlistName
!=
GetLastNetListRead
()
&&
!
GetScreen
()
->
GetFileName
().
IsEmpty
()
&&
IsOK
(
NULL
,
_
(
"Project config has changed. Save it ?"
)
)
)
{
wxFileName
fn
=
GetScreen
()
->
GetFileName
();
fn
.
SetExt
(
ProjectFileExtension
);
wxGetApp
().
WriteProjectConfig
(
fn
.
GetFullPath
(),
GROUP
,
GetProjectFileParameters
()
);
}
}
...
...
pcbnew/pcbframe.cpp
View file @
ba6100e3
...
...
@@ -467,13 +467,6 @@ void PCB_EDIT_FRAME::OnCloseWindow( wxCloseEvent& Event )
}
}
if
(
!
GetScreen
()
->
GetFileName
().
IsEmpty
()
)
{
wxFileName
fn
=
GetScreen
()
->
GetFileName
();
fn
.
SetExt
(
ProjectFileExtension
);
wxGetApp
().
WriteProjectConfig
(
fn
.
GetFullPath
(),
GROUP
,
GetProjectFileParameters
()
);
}
SaveSettings
();
// do not show the window because ScreenPcb will be deleted and we do not
...
...
pcbnew/pcbnew_config.cpp
View file @
ba6100e3
...
...
@@ -231,7 +231,7 @@ PARAM_CFG_ARRAY& PCB_EDIT_FRAME::GetProjectFileParameters()
120
,
0
,
0xFFFF
)
);
m_projectFileParams
.
push_back
(
new
PARAM_CFG_INT
(
wxT
(
"MSegLar"
),
&
g_ModuleSegmentWidth
,
120
,
0
,
0xFFFF
)
);
m_projectFileParams
.
push_back
(
new
PARAM_CFG_
WXSTRING
(
wxT
(
"LastNetListRead"
),
m_projectFileParams
.
push_back
(
new
PARAM_CFG_
FILENAME
(
wxT
(
"LastNetListRead"
),
&
m_lastNetListRead
)
);
return
m_projectFileParams
;
}
...
...
pcbnew/pcbplot.cpp
View file @
ba6100e3
...
...
@@ -19,7 +19,6 @@
#include "dialog_plot_base.h"
#include "pcb_plot_params.h"
/* Keywords to r/w options in m_Config */
#define CONFIG_XFINESCALE_ADJ wxT( "PlotXFineScaleAdj" )
#define CONFIG_YFINESCALE_ADJ wxT( "PlotYFineScaleAdj" )
...
...
@@ -57,10 +56,10 @@ class DIALOG_PLOT : public DIALOG_PLOT_BASE
private
:
PCB_EDIT_FRAME
*
m_Parent
;
wxConfig
*
m_Config
;
std
::
vector
<
int
>
layerList
;
// List to hold CheckListBox layer numbers
std
::
vector
<
int
>
layerList
;
// List to hold CheckListBox layer numbers
double
m_XScaleAdjust
;
double
m_YScaleAdjust
;
static
wxPoint
prevPosition
;
// Dialog position & size
static
wxPoint
prevPosition
;
// Dialog position & size
static
wxSize
prevSize
;
public
:
DIALOG_PLOT
(
PCB_EDIT_FRAME
*
parent
);
...
...
@@ -235,6 +234,7 @@ void DIALOG_PLOT::OnClose( wxCloseEvent& event )
prevPosition
=
GetPosition
();
prevSize
=
GetSize
();
applyPlotSettings
();
EndModal
(
0
);
}
...
...
@@ -260,7 +260,7 @@ void DIALOG_PLOT::OnSetScaleOpt( wxCommandEvent& event )
void
DIALOG_PLOT
::
OnOutputDirectoryBrowseClicked
(
wxCommandEvent
&
event
)
{
// Build the absolute path of current output plot directory
// to preselect it when opening the
Di D
ialog.
// to preselect it when opening the
d
ialog.
wxFileName
fn
(
m_outputDirectoryName
->
GetValue
()
);
wxString
path
;
if
(
fn
.
IsRelative
()
)
...
...
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