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
39ba3608
Commit
39ba3608
authored
Feb 22, 2012
by
Marco Mattila
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix eeschema component drawing issue during copy. Add hotkey for block save.
parent
4154af55
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
17 additions
and
4 deletions
+17
-4
events_called_functions_for_edit.cpp
eeschema/events_called_functions_for_edit.cpp
+1
-1
hotkeys.cpp
eeschema/hotkeys.cpp
+6
-0
hotkeys.h
eeschema/hotkeys.h
+1
-0
onrightclick.cpp
eeschema/onrightclick.cpp
+9
-3
No files found.
eeschema/events_called_functions_for_edit.cpp
View file @
39ba3608
...
...
@@ -35,7 +35,7 @@ void SCH_EDIT_FRAME::OnCopySchematicItemRequest( wxCommandEvent& event )
MoveItem
(
(
SCH_ITEM
*
)
newitem
,
&
dc
);
// Redraw the original part, because StartMovePart() erased it from screen.
curr_item
->
Draw
(
m_canvas
,
&
dc
,
wxPoint
(
0
,
0
),
GR_DEFAULT_DRAWMODE
);
curr_item
->
Draw
(
m_canvas
,
&
dc
,
wxPoint
(
0
,
0
),
g_XorMode
);
}
break
;
...
...
eeschema/hotkeys.cpp
View file @
39ba3608
...
...
@@ -177,6 +177,7 @@ static EDA_HOTKEY HkCopyComponentOrText( wxT( "Copy Component or Label" ),
ID_POPUP_SCH_COPY_ITEM
);
static
EDA_HOTKEY
HkDrag
(
wxT
(
"Drag Schematic Item"
),
HK_DRAG
,
'G'
,
ID_SCH_DRAG_ITEM
);
static
EDA_HOTKEY
HkSaveBlock
(
wxT
(
"Save Block"
),
HK_SAVE_BLOCK
,
'C'
+
GR_KB_CTRL
);
static
EDA_HOTKEY
HkMove2Drag
(
wxT
(
"Move Block -> Drag Block"
),
HK_MOVEBLOCK_TO_DRAGBLOCK
,
'\t'
);
static
EDA_HOTKEY
HkInsert
(
wxT
(
"Repeat Last Item"
),
HK_REPEAT_LAST
,
WXK_INSERT
);
...
...
@@ -218,6 +219,7 @@ EDA_HOTKEY* s_Schematic_Hotkey_List[] =
&
HkDelete
,
&
HkInsert
,
&
HkMove2Drag
,
&
HkSaveBlock
,
&
HkMove
,
&
HkCopyComponentOrText
,
&
HkDrag
,
...
...
@@ -357,6 +359,10 @@ void SCH_EDIT_FRAME::OnHotKey( wxDC* aDC, int aHotKey, const wxPoint& aPosition,
HandleBlockEndByPopUp
(
BLOCK_DRAG
,
aDC
);
break
;
case
HK_SAVE_BLOCK
:
HandleBlockEndByPopUp
(
BLOCK_SAVE
,
aDC
);
break
;
case
HK_DELETE
:
if
(
notBusy
)
DeleteItemAtCrossHair
(
aDC
);
...
...
eeschema/hotkeys.h
View file @
39ba3608
...
...
@@ -17,6 +17,7 @@ enum hotkey_id_commnand {
HK_REPEAT_LAST
,
HK_LIBEDIT_MOVE_GRAPHIC_ITEM
,
HK_MOVEBLOCK_TO_DRAGBLOCK
,
HK_SAVE_BLOCK
,
HK_LIBEDIT_CREATE_PIN
,
HK_DELETE_PIN
,
HK_ROTATE
,
...
...
eeschema/onrightclick.cpp
View file @
39ba3608
...
...
@@ -682,14 +682,20 @@ void AddMenusForBlock( wxMenu* PopMenu, SCH_EDIT_FRAME* frame )
// a block function.
if
(
frame
->
GetScreen
()
->
m_BlockLocate
.
m_Command
==
BLOCK_MOVE
)
{
AddMenuItem
(
PopMenu
,
wxID_COPY
,
_
(
"Save Block"
),
KiBitmap
(
copy_button_xpm
)
);
msg
=
AddHotkeyName
(
_
(
"Save Block"
),
s_Schematic_Hokeys_Descr
,
HK_SAVE_BLOCK
);
AddMenuItem
(
PopMenu
,
wxID_COPY
,
msg
,
KiBitmap
(
copy_button_xpm
)
);
AddMenuItem
(
PopMenu
,
ID_POPUP_COPY_BLOCK
,
_
(
"Copy Block"
),
KiBitmap
(
copyblock_xpm
)
);
msg
=
AddHotkeyName
(
_
(
"Drag Block"
),
s_Schematic_Hokeys_Descr
,
HK_MOVEBLOCK_TO_DRAGBLOCK
);
AddMenuItem
(
PopMenu
,
ID_POPUP_DRAG_BLOCK
,
msg
,
KiBitmap
(
move_xpm
)
);
AddMenuItem
(
PopMenu
,
ID_POPUP_DELETE_BLOCK
,
_
(
"Delete Block"
),
KiBitmap
(
delete_xpm
)
);
AddMenuItem
(
PopMenu
,
ID_SCH_MIRROR_Y
,
_
(
"Mirror Block ||"
),
KiBitmap
(
mirror_h_xpm
)
);
AddMenuItem
(
PopMenu
,
ID_SCH_MIRROR_X
,
_
(
"Mirror Block --"
),
KiBitmap
(
mirror_v_xpm
)
);
msg
=
AddHotkeyName
(
_
(
"Mirror Block ||"
),
s_Schematic_Hokeys_Descr
,
HK_MIRROR_Y_COMPONENT
);
AddMenuItem
(
PopMenu
,
ID_SCH_MIRROR_Y
,
msg
,
KiBitmap
(
mirror_h_xpm
)
);
msg
=
AddHotkeyName
(
_
(
"Mirror Block --"
),
s_Schematic_Hokeys_Descr
,
HK_MIRROR_X_COMPONENT
);
AddMenuItem
(
PopMenu
,
ID_SCH_MIRROR_X
,
msg
,
KiBitmap
(
mirror_v_xpm
)
);
AddMenuItem
(
PopMenu
,
ID_SCH_ROTATE_CLOCKWISE
,
_
(
"Rotate Block ccw"
),
KiBitmap
(
rotate_ccw_xpm
)
);
...
...
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