kicad/eeschema/libedit/libedit_onrightclick.cpp

30 lines
858 B
C++
Raw Normal View History

2008-10-18 23:41:16 +00:00
2019-05-08 18:56:03 +00:00
#if 0
case LIB_POLYLINE_T:
2013-01-02 07:55:48 +00:00
if( item->IsNew() )
{
if( ( (LIB_POLYLINE*) item )->GetCornerCount() > 2 )
2008-10-18 23:41:16 +00:00
{
2019-04-01 17:14:16 +00:00
msg = AddHotkeyName( _( "Delete" ), g_Libedit_Hotkeys_Descr, HK_DELETE );
AddMenuItem( PopMenu, ID_POPUP_LIBEDIT_DELETE_CURRENT_POLY_SEGMENT,
msg, KiBitmap( delete_xpm ) );
2008-10-18 23:41:16 +00:00
}
}
break;
2008-10-18 23:41:16 +00:00
2019-05-08 18:56:03 +00:00
//===============================================
2019-05-08 18:56:03 +00:00
case ID_POPUP_LIBEDIT_DELETE_CURRENT_POLY_SEGMENT:
{
// Delete the last created segment, while creating a polyline draw item
if( item == NULL )
break;
2019-05-08 18:56:03 +00:00
m_canvas->MoveCursorToCrossHair();
static_cast<LIB_POLYLINE*>( item )->DeleteSegment( GetCrossHairPosition( true ) );
}
break;
2019-05-08 18:56:03 +00:00
#endif