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
2571080e
Commit
2571080e
authored
Aug 30, 2011
by
Andrey Fedorushkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pcbnew: add hotkey 'D' - drag track segment keep slope
parent
9c61e5d1
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
13 additions
and
1 deletion
+13
-1
hotkeys.cpp
pcbnew/hotkeys.cpp
+3
-0
hotkeys.h
pcbnew/hotkeys.h
+1
-0
hotkeys_board_editor.cpp
pcbnew/hotkeys_board_editor.cpp
+6
-0
onrightclick.cpp
pcbnew/onrightclick.cpp
+3
-1
No files found.
pcbnew/hotkeys.cpp
View file @
2571080e
...
...
@@ -65,6 +65,8 @@ static Ki_HotkeyInfo HkAddNewTrack( wxT( "Add new track" ), HK_ADD_NEW_TRACK, 'X
static
Ki_HotkeyInfo
HkAddVia
(
wxT
(
"Add Via"
),
HK_ADD_VIA
,
'V'
);
static
Ki_HotkeyInfo
HkSwitchTrackPosture
(
wxT
(
"Switch Track Posture"
),
HK_SWITCH_TRACK_POSTURE
,
'/'
);
static
Ki_HotkeyInfo
HkDragTrackKeepSlope
(
wxT
(
"Drag track keep slope"
),
HK_DRAG_TRACK_KEEP_SLOPE
,
'D'
);
static
Ki_HotkeyInfo
HkAddMicroVia
(
wxT
(
"Add MicroVia"
),
HK_ADD_MICROVIA
,
'V'
+
GR_KB_CTRL
);
static
Ki_HotkeyInfo
HkEndTrack
(
wxT
(
"End Track"
),
HK_END_TRACK
,
WXK_END
);
...
...
@@ -154,6 +156,7 @@ Ki_HotkeyInfo* board_edit_Hotkey_List[] =
&
HkBackspace
,
&
HkAddNewTrack
,
&
HkAddVia
,
&
HkAddMicroVia
,
&
HkSwitchTrackPosture
,
&
HkDragTrackKeepSlope
,
&
HkEndTrack
,
&
HkMoveItem
,
&
HkFlipFootprint
,
&
HkRotateItem
,
&
HkDragFootprint
,
&
HkGetAndMoveFootprint
,
&
HkLock_Unlock_Footprint
,
&
HkSavefile
,
...
...
pcbnew/hotkeys.h
View file @
2571080e
...
...
@@ -23,6 +23,7 @@ enum hotkey_id_commnand {
HK_ADD_VIA
,
HK_ADD_MICROVIA
,
HK_SWITCH_TRACK_POSTURE
,
HK_DRAG_TRACK_KEEP_SLOPE
,
HK_END_TRACK
,
HK_SAVE_BOARD
,
HK_LOAD_BOARD
,
HK_SWITCH_UNITS
,
...
...
pcbnew/hotkeys_board_editor.cpp
View file @
2571080e
...
...
@@ -279,6 +279,10 @@ void PCB_EDIT_FRAME::OnHotKey( wxDC* aDC, int aHotkeyCode, const wxPoint& aPosit
evt_type
=
ID_POPUP_PCB_SWITCH_TRACK_POSTURE
;
break
;
case
HK_DRAG_TRACK_KEEP_SLOPE
:
OnHotkeyMoveItem
(
HK_DRAG_TRACK_KEEP_SLOPE
);
break
;
case
HK_ADD_NEW_TRACK
:
// Start new track
if
(
getActiveLayer
()
>
LAYER_N_FRONT
)
break
;
...
...
@@ -558,6 +562,8 @@ bool PCB_EDIT_FRAME::OnHotkeyMoveItem( int aIdCommand )
evt_type
=
ID_POPUP_PCB_MOVE_TRACK_NODE
;
if
(
aIdCommand
==
HK_DRAG_ITEM
)
evt_type
=
ID_POPUP_PCB_DRAG_TRACK_SEGMENT
;
if
(
aIdCommand
==
HK_DRAG_TRACK_KEEP_SLOPE
)
evt_type
=
ID_POPUP_PCB_DRAG_TRACK_SEGMENT_KEEP_SLOPE
;
break
;
case
TYPE_MODULE
:
...
...
pcbnew/onrightclick.cpp
View file @
2571080e
...
...
@@ -414,8 +414,10 @@ void PCB_EDIT_FRAME::createPopupMenuForTracks( TRACK* Track, wxMenu* PopMenu )
}
else
{
msg
=
AddHotkeyName
(
_
(
"Drag Segments, Keep Slope"
),
g_Board_Editor_Hokeys_Descr
,
HK_DRAG_TRACK_KEEP_SLOPE
);
ADD_MENUITEM
(
PopMenu
,
ID_POPUP_PCB_DRAG_TRACK_SEGMENT_KEEP_SLOPE
,
_
(
"Drag Segments, Keep Slope"
)
,
drag_segment_withslope_xpm
);
msg
,
drag_segment_withslope_xpm
);
msg
=
AddHotkeyName
(
_
(
"Drag Segment"
),
g_Board_Editor_Hokeys_Descr
,
HK_DRAG_ITEM
);
ADD_MENUITEM
(
PopMenu
,
ID_POPUP_PCB_DRAG_TRACK_SEGMENT
,
...
...
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