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
9db22f0a
Commit
9db22f0a
authored
May 08, 2015
by
Mikhail Karpenko
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' into teardrops
parents
7e5160ad
e3700cae
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
39 additions
and
2 deletions
+39
-2
CMakeLists.txt
cvpcb/CMakeLists.txt
+1
-0
wxPcbStruct.h
include/wxPcbStruct.h
+6
-0
pcbframe.cpp
pcbnew/pcbframe.cpp
+32
-2
No files found.
cvpcb/CMakeLists.txt
View file @
9db22f0a
...
@@ -118,6 +118,7 @@ target_link_libraries( cvpcb_kiface
...
@@ -118,6 +118,7 @@ target_link_libraries( cvpcb_kiface
gal
gal
${
wxWidgets_LIBRARIES
}
${
wxWidgets_LIBRARIES
}
${
GDI_PLUS_LIBRARIES
}
${
GDI_PLUS_LIBRARIES
}
${
OPENMP_LIBRARIES
}
# used by 3d viewer
)
)
if
(
BUILD_GITHUB_PLUGIN
)
if
(
BUILD_GITHUB_PLUGIN
)
...
...
include/wxPcbStruct.h
View file @
9db22f0a
...
@@ -125,6 +125,12 @@ protected:
...
@@ -125,6 +125,12 @@ protected:
void
createPopUpBlockMenu
(
wxMenu
*
menu
);
void
createPopUpBlockMenu
(
wxMenu
*
menu
);
void
createPopUpMenuForMarkers
(
MARKER_PCB
*
aMarker
,
wxMenu
*
aPopMenu
);
void
createPopUpMenuForMarkers
(
MARKER_PCB
*
aMarker
,
wxMenu
*
aPopMenu
);
/**
* an helper function to enable some menus only active when the display
* is switched to GAL mode and which do nothing in legacy mode
*/
void
enableGALSpecificMenus
();
// Has meaning only if DKICAD_SCRIPTING_WXPYTHON option is on
// Has meaning only if DKICAD_SCRIPTING_WXPYTHON option is on
/**
/**
...
...
pcbnew/pcbframe.cpp
View file @
9db22f0a
...
@@ -448,14 +448,13 @@ PCB_EDIT_FRAME::PCB_EDIT_FRAME( KIWAY* aKiway, wxWindow* aParent ) :
...
@@ -448,14 +448,13 @@ PCB_EDIT_FRAME::PCB_EDIT_FRAME( KIWAY* aKiway, wxWindow* aParent ) :
wxAuiPaneInfo
(
mesg
).
Name
(
wxT
(
"MsgPanel"
)
).
Bottom
().
Layer
(
10
)
);
wxAuiPaneInfo
(
mesg
).
Name
(
wxT
(
"MsgPanel"
)
).
Bottom
().
Layer
(
10
)
);
ReFillLayerWidget
();
// this is near end because contents establish size
ReFillLayerWidget
();
// this is near end because contents establish size
m_Layers
->
ReFillRender
();
// Update colors in Render after the config is read
m_Layers
->
ReFillRender
();
// Update colors in Render after the config is read
syncLayerWidgetLayer
();
syncLayerWidgetLayer
();
m_auimgr
.
Update
();
m_auimgr
.
Update
();
setupTools
();
setupTools
();
enableGALSpecificMenus
();
Zoom_Automatique
(
false
);
Zoom_Automatique
(
false
);
}
}
...
@@ -683,6 +682,8 @@ void PCB_EDIT_FRAME::UseGalCanvas( bool aEnable )
...
@@ -683,6 +682,8 @@ void PCB_EDIT_FRAME::UseGalCanvas( bool aEnable )
// Redirect all events to the legacy canvas
// Redirect all events to the legacy canvas
GetGalCanvas
()
->
SetEventDispatcher
(
NULL
);
GetGalCanvas
()
->
SetEventDispatcher
(
NULL
);
}
}
enableGALSpecificMenus
();
}
}
...
@@ -714,6 +715,35 @@ void PCB_EDIT_FRAME::SwitchCanvas( wxCommandEvent& aEvent )
...
@@ -714,6 +715,35 @@ void PCB_EDIT_FRAME::SwitchCanvas( wxCommandEvent& aEvent )
}
}
void
PCB_EDIT_FRAME
::
enableGALSpecificMenus
()
{
// some menus are active only in GAL mode and do nothing in legacy mode.
// So enable or disable them, depending on the display mode
if
(
GetMenuBar
()
)
{
// Enable / disable some menus which are usable only on GAL
pcbnew_ids
id_list
[]
=
{
ID_MENU_INTERACTIVE_ROUTER_SETTINGS
,
ID_DIFF_PAIR_BUTT
,
ID_TUNE_SINGLE_TRACK_LEN_BUTT
,
ID_TUNE_DIFF_PAIR_LEN_BUTT
,
ID_TUNE_DIFF_PAIR_SKEW_BUTT
,
ID_MENU_DIFF_PAIR_DIMENSIONS
};
bool
enbl
=
IsGalCanvasActive
();
for
(
unsigned
ii
=
0
;
ii
<
DIM
(
id_list
);
ii
++
)
{
if
(
GetMenuBar
()
->
FindItem
(
id_list
[
ii
]
)
)
GetMenuBar
()
->
FindItem
(
id_list
[
ii
]
)
->
Enable
(
enbl
);
}
}
}
void
PCB_EDIT_FRAME
::
ShowDesignRulesEditor
(
wxCommandEvent
&
event
)
void
PCB_EDIT_FRAME
::
ShowDesignRulesEditor
(
wxCommandEvent
&
event
)
{
{
DIALOG_DESIGN_RULES
dR_editor
(
this
);
DIALOG_DESIGN_RULES
dR_editor
(
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