Commit e832a6b8 authored by charras's avatar charras

pcbnew: fixed: footprint flip and rotate with hotkeys not undoable.

parent ce66aaa2
......@@ -108,7 +108,7 @@ void WinEDA_SchematicFrame::OnSetOptions( wxCommandEvent& event )
DIALOG_EESCHEMA_OPTIONS dlg( this );
wxLogDebug( _( "Current grid array index %d." ),
wxLogDebug( wxT( "Current grid array index %d." ),
grid_list.Index( GetBaseScreen()->GetGrid() ) );
units.Add( GetUnitsLabel( INCHES ) );
units.Add( GetUnitsLabel( MILLIMETRE ) );
......
No preview for this file type
......@@ -2,8 +2,8 @@ msgid ""
msgstr ""
"Project-Id-Version: kicad\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2009-11-28 14:17+0100\n"
"PO-Revision-Date: 2009-11-28 14:21+0100\n"
"POT-Creation-Date: 2009-12-02 10:24+0100\n"
"PO-Revision-Date: 2009-12-02 10:25+0100\n"
"Last-Translator: \n"
"Language-Team: kicad team <jean-pierre.charras@ujf-grenoble.fr>\n"
"MIME-Version: 1.0\n"
......@@ -2720,7 +2720,7 @@ msgstr "Simple Face"
#: pcbnew/dialog_layers_setup.cpp:119
msgid "Single Side, SMD on Back"
msgstr ""
msgstr "Simple face, CMS coté Cuivre"
#: pcbnew/dialog_layers_setup.cpp:120
msgid "Two Layers, Parts on Front"
......@@ -6350,12 +6350,59 @@ msgstr "Ajout Composant"
msgid "Add Power"
msgstr "Ajouter Alims"
#: eeschema/pinedit.cpp:194
msgid "This position is already occupied by another pin. Continue?"
msgstr "Position occupée par une autre pin. Continuer ?"
#: eeschema/pinedit.cpp:302
#: eeschema/pinedit.cpp:420
#, c-format
msgid "Initial pin position (%d, %d)"
msgstr "Position initiane de la pin (%d, %d)"
#: eeschema/pinedit.cpp:626
msgid "No pins!"
msgstr "Pas de Pins!"
#: eeschema/pinedit.cpp:637
msgid "Marker Information"
msgstr "Info Marqueur"
#: eeschema/pinedit.cpp:656
#, c-format
msgid "<b>Duplicate pin %s</b> \"%s\" at location <b>(%.3f, %.3f)</b> conflicts with pin %s \"%s\" at location <b>(%.3f, %.3f)</b>"
msgstr "<b>Pin dupliquée %s</b> \"%s\" en position <b>(%.3f, %.3f)</b> en conflit avec pin %s \"%s\" en position <b>(%.3f, %.3f)</b>"
#: eeschema/pinedit.cpp:669
#: eeschema/pinedit.cpp:708
#, c-format
msgid " in part %c"
msgstr " en composant %c"
#: eeschema/pinedit.cpp:676
#: eeschema/pinedit.cpp:715
msgid " of converted"
msgstr " de converti"
#: eeschema/pinedit.cpp:678
#: eeschema/pinedit.cpp:717
msgid " of normal"
msgstr " de normal"
#: eeschema/pinedit.cpp:699
#, c-format
msgid "<b>Off grid pin %s</b> \"%s\" at location <b>(%.3f, %.3f)</b>"
msgstr "<b>Pin %s hors grille </b> \"%s\" en position <b>(%.3f, %.3f)</b>"
#: eeschema/pinedit.cpp:726
msgid "No off grid or duplicate pins were found."
msgstr "Pas de pins doublées ou hors grille trouvées"
#: eeschema/libedit.cpp:25
msgid "Component Library Editor: "
msgstr "Editeur de Composants"
#: eeschema/libedit.cpp:30
#: eeschema/viewlibs.cpp:115
msgid "no library selected"
msgstr "Pas de librairie sélectionnée"
......@@ -6412,12 +6459,10 @@ msgid "Document file \""
msgstr "Fichier de doc \""
#: eeschema/libedit.cpp:303
#: eeschema/viewlibs.cpp:314
msgid "Part"
msgstr "Part"
#: eeschema/libedit.cpp:315
#: eeschema/viewlibs.cpp:315
msgid "Alias"
msgstr "Alias"
......@@ -6442,12 +6487,10 @@ msgid "Component"
msgstr "Composant"
#: eeschema/libedit.cpp:341
#: eeschema/viewlibs.cpp:316
msgid "Description"
msgstr "Description"
#: eeschema/libedit.cpp:348
#: eeschema/viewlibs.cpp:317
msgid "Key words"
msgstr "Mots clé"
......@@ -6501,33 +6544,57 @@ msgstr ""
"\n"
"Supprimer le composant courant de l'écran?"
#: eeschema/libedit.cpp:509
#: eeschema/libedit.cpp:511
msgid "This new component has no name and cannot be created. Aborted"
msgstr "Ce noveau composant n'a pas de nom et ne peut être créé, Abandon"
#: eeschema/libedit.cpp:520
#: eeschema/libedit.cpp:522
#, c-format
msgid "Component \"%s\" already exists in library \"%s\"."
msgstr "Composant \"%s\" déjà existant en librairie \"%s\"."
#: eeschema/libedit.cpp:585
#: eeschema/libedit.cpp:587
msgid "No component to save."
msgstr "Pas de composant à sauver."
#: eeschema/libedit.cpp:594
#: eeschema/libedit.cpp:596
msgid "No library specified."
msgstr "Pas de librairie spécifiée."
#: eeschema/libedit.cpp:604
#: eeschema/libedit.cpp:606
#, c-format
msgid "Component \"%s\" exists. Change it?"
msgstr "Le composant \" %s\" existe, Le changer ?"
#: eeschema/libedit.cpp:622
#: eeschema/libedit.cpp:624
#, c-format
msgid "Component %s saved in library %s"
msgstr "Composant %s sauvé en librairie %s"
#: eeschema/schframe.cpp:364
msgid "Schematic modified, Save before exit ?"
msgstr "Schématique modifiée, Sauver avant de quitter ?"
#: eeschema/schframe.cpp:503
msgid "Draw wires and busses in any direction"
msgstr "Tracer les fils et bus de n'importe quelle direction"
#: eeschema/schframe.cpp:504
msgid "Draw horizontal and vertical wires and busses only"
msgstr "Autoriser fils et bus verticaux et horizontaux seulement"
#: eeschema/schframe.cpp:514
msgid "Do not show hidden pins"
msgstr "Ne pas affichager les pins invisibles"
#: eeschema/schframe.cpp:515
msgid "Show hidden pins"
msgstr "Force affichage des pins invisibles"
#: eeschema/schframe.cpp:618
msgid "Schematic"
msgstr "Schématique"
#: eeschema/netlist.cpp:88
msgid "List"
msgstr "Liste"
......@@ -6640,30 +6707,6 @@ msgstr "Impossible de créer le fichier "
msgid "Library Browser"
msgstr "Visualisateur de Librairies"
#: eeschema/schframe.cpp:364
msgid "Schematic modified, Save before exit ?"
msgstr "Schématique modifiée, Sauver avant de quitter ?"
#: eeschema/schframe.cpp:503
msgid "Draw wires and busses in any direction"
msgstr "Tracer les fils et bus de n'importe quelle direction"
#: eeschema/schframe.cpp:504
msgid "Draw horizontal and vertical wires and busses only"
msgstr "Autoriser fils et bus verticaux et horizontaux seulement"
#: eeschema/schframe.cpp:514
msgid "Do not show hidden pins"
msgstr "Ne pas affichager les pins invisibles"
#: eeschema/schframe.cpp:515
msgid "Show hidden pins"
msgstr "Force affichage des pins invisibles"
#: eeschema/schframe.cpp:618
msgid "Schematic"
msgstr "Schématique"
#: eeschema/eeredraw.cpp:95
msgid "Sheet"
msgstr "Feuille"
......@@ -7062,6 +7105,10 @@ msgstr "Noir"
msgid "Background Color:"
msgstr "Couleur du Fond:"
#: eeschema/eeschema_config.cpp:326
msgid "Save Project Settings"
msgstr "Sauver Optionsr Projet"
#: eeschema/erc.cpp:210
msgid "Duplicate Sheet name"
msgstr "Nom de feuille en double"
......@@ -7917,12 +7964,10 @@ msgid "Check if you want this field's text rotated 90 degrees"
msgstr "Activer si vous voulez avoir le texte de ce champ tourné à 90°"
#: eeschema/dialog_edit_component_in_schematic_fbp.cpp:136
#: eeschema/dialog_edit_label_base.cpp:43
msgid "Bold"
msgstr "Gras"
#: eeschema/dialog_edit_component_in_schematic_fbp.cpp:136
#: eeschema/dialog_edit_label_base.cpp:43
msgid "Bold Italic"
msgstr "Gras Italique"
......@@ -8090,54 +8135,6 @@ msgstr "Champ 8"
msgid "All existing users fields"
msgstr "Tous les champs existants"
#: eeschema/pinedit.cpp:184
msgid "This position is already occupied by another pin. Continue?"
msgstr "Position occupée par une autre pin. Continuer ?"
#: eeschema/pinedit.cpp:292
#: eeschema/pinedit.cpp:410
#, c-format
msgid "Initial pin position (%d, %d)"
msgstr "Position initiane de la pin (%d, %d)"
#: eeschema/pinedit.cpp:616
msgid "No pins!"
msgstr "Pas de Pins!"
#: eeschema/pinedit.cpp:627
msgid "Marker Information"
msgstr "Info Marqueur"
#: eeschema/pinedit.cpp:646
#, c-format
msgid "<b>Duplicate pin %s</b> \"%s\" at location <b>(%.3f, %.3f)</b> conflicts with pin %s \"%s\" at location <b>(%.3f, %.3f)</b>"
msgstr "<b>Pin dupliquée %s</b> \"%s\" en position <b>(%.3f, %.3f)</b> en conflit avec pin %s \"%s\" en position <b>(%.3f, %.3f)</b>"
#: eeschema/pinedit.cpp:659
#: eeschema/pinedit.cpp:698
#, c-format
msgid " in part %c"
msgstr " en composant %c"
#: eeschema/pinedit.cpp:666
#: eeschema/pinedit.cpp:705
msgid " of converted"
msgstr " de converti"
#: eeschema/pinedit.cpp:668
#: eeschema/pinedit.cpp:707
msgid " of normal"
msgstr " de normal"
#: eeschema/pinedit.cpp:689
#, c-format
msgid "<b>Off grid pin %s</b> \"%s\" at location <b>(%.3f, %.3f)</b>"
msgstr "<b>Pin %s hors grille </b> \"%s\" en position <b>(%.3f, %.3f)</b>"
#: eeschema/pinedit.cpp:716
msgid "No off grid or duplicate pins were found."
msgstr "Pas de pins doublées ou hors grille trouvées"
#: eeschema/tool_sch.cpp:37
msgid "Open schematic project"
msgstr "Ouvrir un Projet schématique"
......@@ -8320,6 +8317,50 @@ msgstr ""
msgid "File <%s> not found."
msgstr "Fichier <%s> non trouvé"
#: eeschema/dialog_annotate_base.cpp:22
msgid "Scope"
msgstr "Sélection"
#: eeschema/dialog_annotate_base.cpp:31
msgid "Use the &entire schematic"
msgstr "Utiliser la schématique &entière"
#: eeschema/dialog_annotate_base.cpp:34
msgid "Use the current &page only"
msgstr "Utiliser la &feuille active uniquement"
#: eeschema/dialog_annotate_base.cpp:40
msgid "&Keep existing annotation"
msgstr "&Garder l'annotation existante"
#: eeschema/dialog_annotate_base.cpp:43
msgid "&Reset existing annotation"
msgstr "&Supprimer l'annotation existante"
#: eeschema/dialog_annotate_base.cpp:51
msgid "Annotation Order"
msgstr "Sens de Annotation"
#: eeschema/dialog_annotate_base.cpp:63
msgid "Sort Components by &X Position"
msgstr "Trier les Composants par Position &X"
#: eeschema/dialog_annotate_base.cpp:77
msgid "Sort Components by &Y Position"
msgstr "Trier les Composants par Position &Y"
#: eeschema/dialog_annotate_base.cpp:91
msgid "Sort Components by &Value"
msgstr "Trier Composants par &Valeur"
#: eeschema/dialog_annotate_base.cpp:113
msgid "Clear Annotation"
msgstr "Suppression Annotation"
#: eeschema/dialog_annotate_base.cpp:116
msgid "Annotation"
msgstr "Annotation"
#: eeschema/build_BOM.cpp:51
msgid "Bill of Materials file (*.lst)|*.lst"
msgstr "Fichier Liste du Materiel (*.lst)|*.lst"
......@@ -9169,10 +9210,6 @@ msgstr "Les librairies suivantes n'ont pas pu être trouvées:"
msgid "text only had %d parameters of the required 8"
msgstr "le texte a seulement %d paramètres sur les 8 requis"
#: eeschema/eeschema_config.cpp:284
msgid "Save Project Settings"
msgstr "Sauver Optionsr Projet"
#: eeschema/class_drc_erc_item.cpp:39
msgid "ERC err unspecified"
msgstr "Erreur ERC non specifiée"
......@@ -9410,84 +9447,6 @@ msgstr ""
"Les noms d'empreintes peuvent utiliser des caractères jockers.\n"
"(Comme sm* pour autoriser tous les noms d'empreintes commençant par sm)."
#: eeschema/dialog_options.cpp:139
#: eeschema/dialog_options.cpp:286
msgid "Delta Step X"
msgstr "Incrément X"
#: eeschema/dialog_options.cpp:144
#: eeschema/dialog_options.cpp:292
msgid "Delta Step Y"
msgstr "Incrément Y"
#: eeschema/dialog_options.cpp:213
msgid "Draw Options:"
msgstr "Options de Tracé:"
#: eeschema/dialog_options.cpp:222
msgid "Normal (50 mils)"
msgstr "Normal (50 mils)"
#: eeschema/dialog_options.cpp:223
msgid "Small (25 mils)"
msgstr "Petit (25 mils)"
#: eeschema/dialog_options.cpp:224
msgid "Very small (10 mils)"
msgstr "Très petit (10 mils)"
#: eeschema/dialog_options.cpp:225
msgid "Special (5 mils)"
msgstr "Spécial (5 mils)"
#: eeschema/dialog_options.cpp:226
msgid "Special (2 mils)"
msgstr "Spécial (2 mils)"
#: eeschema/dialog_options.cpp:227
msgid "Special (1 mil)"
msgstr "Spécial (1 mil)"
#: eeschema/dialog_options.cpp:228
msgid "Grid Size"
msgstr "Dim Grille"
#: eeschema/dialog_options.cpp:234
msgid "Show alls"
msgstr "Tout Afficher"
#: eeschema/dialog_options.cpp:235
msgid "Show pins"
msgstr "Montrer Pins"
#: eeschema/dialog_options.cpp:247
msgid "millimeter"
msgstr "millimètre"
#: eeschema/dialog_options.cpp:248
msgid "inches"
msgstr "Pouces"
#: eeschema/dialog_options.cpp:257
msgid "Horiz/Vertical"
msgstr "Horiz/Vertical"
#: eeschema/dialog_options.cpp:259
msgid "Wires - Bus orient"
msgstr "Fils-Bus Orient"
#: eeschema/dialog_options.cpp:282
msgid "Auto increment params"
msgstr "Auto incrément params"
#: eeschema/dialog_options.cpp:298
msgid "Delta Label:"
msgstr "Incrément Label:"
#: eeschema/dialog_options.cpp:315
msgid "Default Label Size"
msgstr "Taille Label par défaut"
#: eeschema/class_libentry.cpp:67
msgid "none"
msgstr "rien"
......@@ -10040,50 +9999,6 @@ msgstr "Remplissage en &avant plan"
msgid "Fill &background"
msgstr "Remplissage en a&rriere plan"
#: eeschema/dialog_annotate_base.cpp:22
msgid "Scope"
msgstr "Sélection"
#: eeschema/dialog_annotate_base.cpp:31
msgid "Use the &entire schematic"
msgstr "Utiliser la schématique &entière"
#: eeschema/dialog_annotate_base.cpp:34
msgid "Use the current &page only"
msgstr "Utiliser la &feuille active uniquement"
#: eeschema/dialog_annotate_base.cpp:40
msgid "&Keep existing annotation"
msgstr "&Garder l'annotation existante"
#: eeschema/dialog_annotate_base.cpp:43
msgid "&Reset existing annotation"
msgstr "&Supprimer l'annotation existante"
#: eeschema/dialog_annotate_base.cpp:51
msgid "Annotation Order"
msgstr "Sens de Annotation"
#: eeschema/dialog_annotate_base.cpp:66
msgid "Sort Components by &X Position"
msgstr "Trier les Composants par Position &X"
#: eeschema/dialog_annotate_base.cpp:77
msgid "Sort Components by &Y Position"
msgstr "Trier les Composants par Position &Y"
#: eeschema/dialog_annotate_base.cpp:88
msgid "Sort Components by &Value"
msgstr "Trier Composants par &Valeur"
#: eeschema/dialog_annotate_base.cpp:106
msgid "Clear Annotation"
msgstr "Suppression Annotation"
#: eeschema/dialog_annotate_base.cpp:109
msgid "Annotation"
msgstr "Annotation"
#: eeschema/save_schemas.cpp:66
msgid "Schematic Files"
msgstr "Fichiers Schématiques"
......@@ -10117,6 +10032,54 @@ msgstr " a été créé par une version plus ancienne de Eeschema. Il sera enreg
msgid "Done Loading "
msgstr "Chargement terminé "
#: eeschema/dialog_eeschema_options_base.cpp:34
msgid "Mesurement &units:"
msgstr "&Unités de mesure:"
#: eeschema/dialog_eeschema_options_base.cpp:46
msgid "&Grid size:"
msgstr "Dim &Grille:"
#: eeschema/dialog_eeschema_options_base.cpp:59
msgid "Default &line width:"
msgstr "Epaiss. &ligne par défaut:"
#: eeschema/dialog_eeschema_options_base.cpp:70
msgid "Default text &size:"
msgstr "Dim. &texte par défaut:"
#: eeschema/dialog_eeschema_options_base.cpp:81
msgid "Repeat draw item &horizontal displacement:"
msgstr "Déplacement &horizontal en répétition d'items:"
#: eeschema/dialog_eeschema_options_base.cpp:92
msgid "Repeat draw item &vertical displacement:"
msgstr "Déplacement &vertical en répétition d'items:"
#: eeschema/dialog_eeschema_options_base.cpp:103
msgid "&Repeat label increment:"
msgstr "Incémentation des labels en répétition:"
#: eeschema/dialog_eeschema_options_base.cpp:118
msgid "Show g&rid"
msgstr "Afficher g&rille"
#: eeschema/dialog_eeschema_options_base.cpp:122
msgid "Show hi&dden pins"
msgstr "Force affichage des pins &invisibles"
#: eeschema/dialog_eeschema_options_base.cpp:126
msgid "Enable automatic &panning"
msgstr "Active le \"&panning\" automatique"
#: eeschema/dialog_eeschema_options_base.cpp:130
msgid "Allow buses and wires to be placed in any &orientation"
msgstr "Autorise les bus et fils a être placés en &orientation quelconque"
#: eeschema/dialog_eeschema_options_base.cpp:134
msgid "Show p&age limits"
msgstr " Afficher limites de p&age"
#: eeschema/component_wizard/dialog_component_setup.cpp:137
msgid "Quick KICAD Library Component Builder"
msgstr ""
......@@ -11110,7 +11073,7 @@ msgstr "Masque soudure composant (*.GTS)|*.GTS;*.gts|"
#: gerbview/files.cpp:122
msgid "Bottom overlay (*.GBO)|*.GBO;*.gbo|"
msgstr ""
msgstr "Simple face, CMS coté Cuivre."
#: gerbview/files.cpp:123
msgid "Top overlay (*.GTO)|*.GTO;*.gto|"
......@@ -11665,6 +11628,10 @@ msgstr "Tous les fichiers (*)|*"
msgid " (\"):"
msgstr " (\"):"
#: common/common.cpp:257
msgid "inches"
msgstr "Pouces"
#: common/common.cpp:265
msgid "centimeters"
msgstr "centimètres"
......@@ -12016,12 +11983,10 @@ msgid "Back View"
msgstr "Vue arrière"
#: 3d-viewer/3d_canvas.cpp:353
#: 3d-viewer/3d_toolbar.cpp:85
msgid "Move left <-"
msgstr "Vers la gauche <-"
#: 3d-viewer/3d_canvas.cpp:358
#: 3d-viewer/3d_toolbar.cpp:88
msgid "Move right ->"
msgstr "Vers la droite ->"
......@@ -12315,7 +12280,6 @@ msgid "Exchange Modules"
msgstr "Echange modules:"
#: pcbnew/dialog_edit_module_for_Modedit_base.h:105
#: pcbnew/dialog_edit_module_for_BoardEditor_base.h:118
msgid "Module properties"
msgstr "Propriétés du Module"
......@@ -12331,10 +12295,6 @@ msgstr "Edition Globale de Pistes et Vias"
msgid "Sheet properties"
msgstr "Propriétés de la feuille"
#: eeschema/dialog_options.h:55
msgid "General Options"
msgstr "Options Générales"
#: eeschema/eelayer.h:35
msgid "EESchema Colors"
msgstr "Couleurs dans EESchema"
......@@ -12451,6 +12411,10 @@ msgstr "Propriétés des Champs"
msgid "Pin Properties"
msgstr "Propriétés des Pins"
#: eeschema/dialog_annotate_base.h:77
msgid "Annotate Schematic"
msgstr "Annotation de la Schématique"
#: eeschema/dialog_edit_component_in_lib_base.h:107
msgid "Lib Component Properties"
msgstr "Propriétés du composant librairie"
......@@ -12463,6 +12427,10 @@ msgstr "Propriétés de l'Elément Graphique"
msgid "EESchema Erc"
msgstr "EESchema Erc"
#: eeschema/dialog_eeschema_options_base.h:77
msgid "Schematic Editor Options"
msgstr "Options de l'Editeur de Schematique"
#: eeschema/dialog_build_BOM_base.h:69
msgid "List of Material"
msgstr "Liste du Matériel"
......@@ -12623,6 +12591,42 @@ msgstr "Options d'Affichage"
msgid "Page Settings"
msgstr "Ajustage opt Page"
#~ msgid "Delta Step X"
#~ msgstr "Incrément X"
#~ msgid "Delta Step Y"
#~ msgstr "Incrément Y"
#~ msgid "Draw Options:"
#~ msgstr "Options de Tracé:"
#~ msgid "Normal (50 mils)"
#~ msgstr "Normal (50 mils)"
#~ msgid "Small (25 mils)"
#~ msgstr "Petit (25 mils)"
#~ msgid "Very small (10 mils)"
#~ msgstr "Très petit (10 mils)"
#~ msgid "Special (5 mils)"
#~ msgstr "Spécial (5 mils)"
#~ msgid "Special (2 mils)"
#~ msgstr "Spécial (2 mils)"
#~ msgid "Special (1 mil)"
#~ msgstr "Spécial (1 mil)"
#~ msgid "Show alls"
#~ msgstr "Tout Afficher"
#~ msgid "Show pins"
#~ msgstr "Montrer Pins"
#~ msgid "millimeter"
#~ msgstr "millimètre"
#~ msgid "Horiz/Vertical"
#~ msgstr "Horiz/Vertical"
#~ msgid "Wires - Bus orient"
#~ msgstr "Fils-Bus Orient"
#~ msgid "Auto increment params"
#~ msgstr "Auto incrément params"
#~ msgid "Delta Label:"
#~ msgstr "Incrément Label:"
#~ msgid "Default Label Size"
#~ msgstr "Taille Label par défaut"
#~ msgid "General Options"
#~ msgstr "Options Générales"
#~ msgid ""
#~ "Check this option for power symbols.\n"
#~ "Power symbols have specific properties"
......@@ -12756,8 +12760,6 @@ msgstr "Ajustage opt Page"
#~ msgstr "Ceci est l'espace entre pads et le masque"
#~ msgid "Schematic hierarchy navigator"
#~ msgstr "Navigation dans la hiérarchie"
#~ msgid "Schematic Annotation"
#~ msgstr "Annotation des composants"
#~ msgid "Show Hidden Pins"
#~ msgstr "Force affichage des pins invisibles"
#~ msgid "Setting Libraries, Directories and others..."
......@@ -13038,8 +13040,6 @@ msgstr "Ajustage opt Page"
#~ msgstr "Entrer la largeur de piste courante"
#~ msgid "This is the clearance between tracks, vias and pads for DRC."
#~ msgstr "Ceci est l'isolation entre pistes, vias et pads pour le calcul DRC."
#~ msgid "Delete units"
#~ msgstr "Supprimer unité"
#~ msgid "Create pins for convert items."
#~ msgstr "Créér les pins des unitées converties."
#~ msgid "Part as \"De Morgan\" anymore"
......
......@@ -34,111 +34,151 @@
/* local variables */
/* Hotkey list: */
static Ki_HotkeyInfo HkSwitch2CopperLayer(wxT("Switch to Copper layer"),
HK_SWITCH_LAYER_TO_COPPER, WXK_PAGEUP);
static Ki_HotkeyInfo HkSwitch2ComponentLayer(wxT("Switch to Component layer"),
HK_SWITCH_LAYER_TO_COMPONENT, WXK_PAGEDOWN);
static Ki_HotkeyInfo HkSwitch2InnerLayer1(wxT("Switch to Inner layer 1"),
HK_SWITCH_LAYER_TO_INNER1, WXK_F5);
static Ki_HotkeyInfo HkSwitch2InnerLayer2(wxT("Switch to Inner layer 2"),
HK_SWITCH_LAYER_TO_INNER2, WXK_F6);
static Ki_HotkeyInfo HkSwitch2InnerLayer3(wxT("Switch to Inner layer 3"),
HK_SWITCH_LAYER_TO_INNER3, WXK_F7);
static Ki_HotkeyInfo HkSwitch2InnerLayer4(wxT("Switch to Inner layer 4"),
HK_SWITCH_LAYER_TO_INNER4, WXK_F8);
static Ki_HotkeyInfo HkSwitch2InnerLayer5(wxT("Switch to Inner layer 5"),
HK_SWITCH_LAYER_TO_INNER5, WXK_F9);
static Ki_HotkeyInfo HkSwitch2InnerLayer6(wxT("Switch to Inner layer 6"),
HK_SWITCH_LAYER_TO_INNER6, WXK_F10);
static Ki_HotkeyInfo HkSwitch2NextCopperLayer(wxT("Switch to Next Layer"),
HK_SWITCH_LAYER_TO_NEXT, '+');
static Ki_HotkeyInfo HkSwitch2PreviousCopperLayer(wxT(
"Switch to Previous Layer"), HK_SWITCH_LAYER_TO_PREVIOUS, '-');
static Ki_HotkeyInfo HkSavefile(wxT("Save board"), HK_SAVE_BOARD, 'S'
+ GR_KB_CTRL);
static Ki_HotkeyInfo HkLoadfile(wxT("Load board"), HK_LOAD_BOARD, 'L'
+ GR_KB_CTRL);
static Ki_HotkeyInfo HkFindItem(wxT("Find Item"), HK_FIND_ITEM, 'F'
+ GR_KB_CTRL);
static Ki_HotkeyInfo HkBackspace(wxT("Delete track segment"), HK_BACK_SPACE,
WXK_BACK);
static Ki_HotkeyInfo HkAddVia(wxT("Add Via"), HK_ADD_VIA, 'V');
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);
static Ki_HotkeyInfo HkFlipFootprint(wxT("Flip Footprint"), HK_FLIP_FOOTPRINT,
'F');
static Ki_HotkeyInfo HkRotateFootprint(wxT("Rotate Footprint"),
HK_ROTATE_FOOTPRINT, 'R');
static Ki_HotkeyInfo HkMoveFootprint(wxT("Move Footprint"), HK_MOVE_FOOTPRINT,
'M');
static Ki_HotkeyInfo HkDragFootprint(wxT("Drag Footprint"), HK_DRAG_FOOTPRINT,
'G');
static Ki_HotkeyInfo HkGetAndMoveFootprint(wxT("Get and Move Footprint"),
HK_GET_AND_MOVE_FOOTPRINT, 'T');
static Ki_HotkeyInfo HkLock_Unlock_Footprint(wxT("Lock/Unlock Footprint"),
HK_LOCK_UNLOCK_FOOTPRINT, 'L');
static Ki_HotkeyInfo HkDelete(wxT("Delete Track or Footprint"), HK_DELETE,
WXK_DELETE);
static Ki_HotkeyInfo HkResetLocalCoord(wxT("Reset local coord."),
HK_RESET_LOCAL_COORD, ' ');
static Ki_HotkeyInfo HkSwitch2CopperLayer( wxT( "Switch to Copper layer" ),
HK_SWITCH_LAYER_TO_COPPER, WXK_PAGEUP );
static Ki_HotkeyInfo HkSwitch2ComponentLayer( wxT( "Switch to Component layer" ),
HK_SWITCH_LAYER_TO_COMPONENT, WXK_PAGEDOWN );
static Ki_HotkeyInfo HkSwitch2InnerLayer1( wxT( "Switch to Inner layer 1" ),
HK_SWITCH_LAYER_TO_INNER1, WXK_F5 );
static Ki_HotkeyInfo HkSwitch2InnerLayer2( wxT( "Switch to Inner layer 2" ),
HK_SWITCH_LAYER_TO_INNER2, WXK_F6 );
static Ki_HotkeyInfo HkSwitch2InnerLayer3( wxT( "Switch to Inner layer 3" ),
HK_SWITCH_LAYER_TO_INNER3, WXK_F7 );
static Ki_HotkeyInfo HkSwitch2InnerLayer4( wxT( "Switch to Inner layer 4" ),
HK_SWITCH_LAYER_TO_INNER4, WXK_F8 );
static Ki_HotkeyInfo HkSwitch2InnerLayer5( wxT( "Switch to Inner layer 5" ),
HK_SWITCH_LAYER_TO_INNER5, WXK_F9 );
static Ki_HotkeyInfo HkSwitch2InnerLayer6( wxT( "Switch to Inner layer 6" ),
HK_SWITCH_LAYER_TO_INNER6, WXK_F10 );
static Ki_HotkeyInfo HkSwitch2NextCopperLayer( wxT( "Switch to Next Layer" ),
HK_SWITCH_LAYER_TO_NEXT, '+' );
static Ki_HotkeyInfo HkSwitch2PreviousCopperLayer( wxT(
"Switch to Previous Layer" ),
HK_SWITCH_LAYER_TO_PREVIOUS, '-' );
static Ki_HotkeyInfo HkSavefile( wxT( "Save board" ), HK_SAVE_BOARD, 'S'
+ GR_KB_CTRL );
static Ki_HotkeyInfo HkLoadfile( wxT( "Load board" ), HK_LOAD_BOARD, 'L'
+ GR_KB_CTRL );
static Ki_HotkeyInfo HkFindItem( wxT( "Find Item" ), HK_FIND_ITEM, 'F'
+ GR_KB_CTRL );
static Ki_HotkeyInfo HkBackspace( wxT( "Delete track segment" ), HK_BACK_SPACE,
WXK_BACK );
static Ki_HotkeyInfo HkAddVia( wxT( "Add Via" ), HK_ADD_VIA, 'V' );
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 );
static Ki_HotkeyInfo HkFlipFootprint( wxT( "Flip Footprint" ), HK_FLIP_FOOTPRINT,
'F' );
static Ki_HotkeyInfo HkRotateFootprint( wxT( "Rotate Footprint" ),
HK_ROTATE_FOOTPRINT, 'R' );
static Ki_HotkeyInfo HkMoveFootprint( wxT( "Move Footprint" ), HK_MOVE_FOOTPRINT,
'M' );
static Ki_HotkeyInfo HkDragFootprint( wxT( "Drag Footprint" ), HK_DRAG_FOOTPRINT,
'G' );
static Ki_HotkeyInfo HkGetAndMoveFootprint( wxT( "Get and Move Footprint" ),
HK_GET_AND_MOVE_FOOTPRINT, 'T' );
static Ki_HotkeyInfo HkLock_Unlock_Footprint( wxT( "Lock/Unlock Footprint" ),
HK_LOCK_UNLOCK_FOOTPRINT, 'L' );
static Ki_HotkeyInfo HkDelete( wxT( "Delete Track or Footprint" ), HK_DELETE,
WXK_DELETE );
static Ki_HotkeyInfo HkResetLocalCoord( wxT( "Reset local coord." ),
HK_RESET_LOCAL_COORD, ' ' );
static Ki_HotkeyInfo HkZoomAuto( wxT( "Zoom Auto" ), HK_ZOOM_AUTO, WXK_HOME );
static Ki_HotkeyInfo HkZoomCenter(wxT("Zoom Center"), HK_ZOOM_CENTER, WXK_F4);
static Ki_HotkeyInfo HkZoomRedraw(wxT("Zoom Redraw"), HK_ZOOM_REDRAW, WXK_F3);
static Ki_HotkeyInfo HkZoomOut(wxT("Zoom Out"), HK_ZOOM_OUT, WXK_F2);
static Ki_HotkeyInfo HkZoomIn(wxT("Zoom In"), HK_ZOOM_IN, WXK_F1);
static Ki_HotkeyInfo HkHelp(wxT("Help: this message"), HK_HELP, '?');
static Ki_HotkeyInfo HkSwitchUnits(wxT("Switch Units"), HK_SWITCH_UNITS, 'U'
+ GR_KB_CTRL);
static Ki_HotkeyInfo HkTrackDisplayMode(wxT("Track Display Mode"),
HK_SWITCH_TRACK_DISPLAY_MODE, 'K');
static Ki_HotkeyInfo HkAddModule(wxT("Add Module"), HK_ADD_MODULE, 'O');
static Ki_HotkeyInfo HkAddTrack(wxT("Add Track or Via"), HK_ADD_TRACK, 'J');
static Ki_HotkeyInfo HkZoomCenter( wxT( "Zoom Center" ), HK_ZOOM_CENTER, WXK_F4 );
static Ki_HotkeyInfo HkZoomRedraw( wxT( "Zoom Redraw" ), HK_ZOOM_REDRAW, WXK_F3 );
static Ki_HotkeyInfo HkZoomOut( wxT( "Zoom Out" ), HK_ZOOM_OUT, WXK_F2 );
static Ki_HotkeyInfo HkZoomIn( wxT( "Zoom In" ), HK_ZOOM_IN, WXK_F1 );
static Ki_HotkeyInfo HkHelp( wxT( "Help: this message" ), HK_HELP, '?' );
static Ki_HotkeyInfo HkSwitchUnits( wxT( "Switch Units" ), HK_SWITCH_UNITS, 'U'
+ GR_KB_CTRL );
static Ki_HotkeyInfo HkTrackDisplayMode( wxT( "Track Display Mode" ),
HK_SWITCH_TRACK_DISPLAY_MODE, 'K' );
static Ki_HotkeyInfo HkAddModule( wxT( "Add Module" ), HK_ADD_MODULE, 'O' );
static Ki_HotkeyInfo HkAddTrack( wxT( "Add Track or Via" ), HK_ADD_TRACK, 'J' );
// List of common hotkey descriptors
Ki_HotkeyInfo
* s_Common_Hotkey_List[] = { &HkHelp, &HkZoomIn, &HkZoomOut,
&HkZoomRedraw, &HkZoomCenter, &HkZoomAuto,
&HkSwitchUnits, &HkResetLocalCoord, NULL };
* s_Common_Hotkey_List[] =
{
&HkHelp, &HkZoomIn, &HkZoomOut,
&HkZoomRedraw, &HkZoomCenter, &HkZoomAuto,
&HkSwitchUnits, &HkResetLocalCoord, NULL
};
// List of hotkey descriptors for pcbnew
Ki_HotkeyInfo* s_board_edit_Hotkey_List[] = { &HkTrackDisplayMode, &HkDelete,
&HkBackspace, &HkAddVia, &HkAddMicroVia, &HkEndTrack, &HkMoveFootprint,
&HkFlipFootprint, &HkRotateFootprint, &HkDragFootprint,
&HkGetAndMoveFootprint, &HkLock_Unlock_Footprint, &HkSavefile,
&HkLoadfile, &HkFindItem, &HkSwitch2CopperLayer, &HkSwitch2InnerLayer1,
&HkSwitch2InnerLayer2, &HkSwitch2InnerLayer3, &HkSwitch2InnerLayer4,
&HkSwitch2InnerLayer5, &HkSwitch2InnerLayer6, &HkSwitch2ComponentLayer,
&HkSwitch2NextCopperLayer, &HkSwitch2PreviousCopperLayer, &HkAddModule,
&HkAddTrack, NULL };
Ki_HotkeyInfo* s_board_edit_Hotkey_List[] =
{
&HkTrackDisplayMode, &HkDelete,
&HkBackspace, &HkAddVia, &HkAddMicroVia,
&HkEndTrack, &HkMoveFootprint,
&HkFlipFootprint, &HkRotateFootprint, &HkDragFootprint,
&HkGetAndMoveFootprint, &HkLock_Unlock_Footprint, &HkSavefile,
&HkLoadfile, &HkFindItem, &HkSwitch2CopperLayer,
&HkSwitch2InnerLayer1,
&HkSwitch2InnerLayer2, &HkSwitch2InnerLayer3, &HkSwitch2InnerLayer4,
&HkSwitch2InnerLayer5, &HkSwitch2InnerLayer6, &HkSwitch2ComponentLayer,
&HkSwitch2NextCopperLayer, &HkSwitch2PreviousCopperLayer,&HkAddModule,
&HkAddTrack, NULL
};
// List of hotkey descriptors for the module editor
Ki_HotkeyInfo* s_module_edit_Hotkey_List[] = { NULL };
// list of sections and corresponding hotkey list for pcbnew (used to create an hotkey config file)
struct Ki_HotkeyInfoSectionDescriptor s_Pcbnew_Editor_Hokeys_Descr[] = { {
&g_CommonSectionTag, s_Common_Hotkey_List, "Common keys" },
{ &g_BoardEditorSectionTag, s_board_edit_Hotkey_List,
"Board editor keys" }, { &g_ModuleEditSectionTag,
s_module_edit_Hotkey_List, "Footprint editor keys" }, { NULL,
NULL, NULL } };
&g_CommonSectionTag,
s_Common_Hotkey_List,
"Common keys"
},
{
&
g_BoardEditorSectionTag,
s_board_edit_Hotkey_List,
"Board editor keys"
}, {
&
g_ModuleEditSectionTag,
s_module_edit_Hotkey_List,
"Footprint editor keys"
}, {
NULL,
NULL, NULL
} };
// list of sections and corresponding hotkey list for the board editor (used to list current hotkeys)
struct Ki_HotkeyInfoSectionDescriptor s_Board_Editor_Hokeys_Descr[] = { {
&g_CommonSectionTag, s_Common_Hotkey_List, NULL }, {
&g_BoardEditorSectionTag, s_board_edit_Hotkey_List, NULL }, { NULL,
NULL, NULL } };
&g_CommonSectionTag,
s_Common_Hotkey_List,
NULL
}, {
&
g_BoardEditorSectionTag,
s_board_edit_Hotkey_List,
NULL
}, {
NULL,
NULL, NULL
} };
// list of sections and corresponding hotkey list for the footprint editor (used to list current hotkeys)
struct Ki_HotkeyInfoSectionDescriptor s_Module_Editor_Hokeys_Descr[] = { {
&g_CommonSectionTag, s_Common_Hotkey_List, NULL }, {
&g_ModuleEditSectionTag, s_module_edit_Hotkey_List, NULL }, { NULL,
NULL, NULL } };
&g_CommonSectionTag,
s_Common_Hotkey_List,
NULL
}, {
&
g_ModuleEditSectionTag,
s_module_edit_Hotkey_List,
NULL
}, {
NULL,
NULL, NULL
} };
/***********************************************************/
void WinEDA_PcbFrame::OnHotKey(wxDC* DC, int hotkey, EDA_BaseStruct* DrawStruct)
void WinEDA_PcbFrame::OnHotKey( wxDC* DC, int hotkey, EDA_BaseStruct* DrawStruct )
/***********************************************************/
/* Hot keys. Some commands are relatives to the item under the mouse cursor
......@@ -149,463 +189,497 @@ void WinEDA_PcbFrame::OnHotKey(wxDC* DC, int hotkey, EDA_BaseStruct* DrawStruct)
*/
{
wxCommandEvent cmd(wxEVT_COMMAND_MENU_SELECTED);
cmd.SetEventObject(this);
bool PopupOn = (GetCurItem() && GetCurItem()->m_Flags);
bool ItemFree = (GetCurItem() == 0 || GetCurItem()->m_Flags == 0);
if (hotkey == 0)
return;
MODULE* module = NULL;
// Remap the control key Ctrl A (0x01) to GR_KB_CTRL + 'A' (just easier to handle...)
if ((hotkey & GR_KB_CTRL) != 0)
hotkey += 'A' - 1;
/* Convert lower to upper case (the usual toupper function has problem with non ascii codes like function keys */
if ((hotkey >= 'a') && (hotkey <= 'z'))
hotkey += 'A' - 'a';
Ki_HotkeyInfo * HK_Descr = GetDescriptorFromHotkey(hotkey,
s_Common_Hotkey_List);
if (HK_Descr == NULL)
HK_Descr = GetDescriptorFromHotkey(hotkey, s_board_edit_Hotkey_List);
if (HK_Descr == NULL)
return;
int ll;
switch (HK_Descr->m_Idcommand) {
default:
case HK_NOT_FOUND:
return;
break;
case HK_SWITCH_LAYER_TO_PREVIOUS:
ll = GetScreen()->m_Active_Layer;
if ((ll <= COPPER_LAYER_N) || (ll > CMP_N))
break;
if (GetBoard()->m_BoardSettings->GetCopperLayerCount() < 2) // Single layer
ll = COPPER_LAYER_N;
else if (ll == CMP_N)
ll = MAX(COPPER_LAYER_N,
GetBoard()->m_BoardSettings->GetCopperLayerCount() - 2);
else
ll--;
SwitchLayer(DC, ll);
break;
case HK_SWITCH_LAYER_TO_NEXT:
ll = GetScreen()->m_Active_Layer;
if ((ll < COPPER_LAYER_N) || (ll >= CMP_N))
break;
if (GetBoard()->m_BoardSettings->GetCopperLayerCount() < 2) // Single layer
ll = COPPER_LAYER_N;
else if (ll >= GetBoard()->m_BoardSettings->GetCopperLayerCount() - 2)
ll = CMP_N;
else
ll++;
SwitchLayer(DC, ll);
break;
case HK_SWITCH_LAYER_TO_COMPONENT:
SwitchLayer(DC, CMP_N);
break;
case HK_SWITCH_LAYER_TO_COPPER:
SwitchLayer(DC, COPPER_LAYER_N);
break;
case HK_SWITCH_LAYER_TO_INNER1:
SwitchLayer(DC, LAYER_N_2);
break;
case HK_SWITCH_LAYER_TO_INNER2:
SwitchLayer(DC, LAYER_N_3);
break;
case HK_SWITCH_LAYER_TO_INNER3:
SwitchLayer(DC, LAYER_N_4);
break;
case HK_SWITCH_LAYER_TO_INNER4:
SwitchLayer(DC, LAYER_N_5);
break;
case HK_SWITCH_LAYER_TO_INNER5:
SwitchLayer(DC, LAYER_N_6);
break;
case HK_SWITCH_LAYER_TO_INNER6:
SwitchLayer(DC, LAYER_N_7);
break;
case HK_HELP: // Display Current hotkey list
DisplayHotkeyList(this, s_Board_Editor_Hokeys_Descr);
break;
case HK_ZOOM_IN:
cmd.SetId(ID_POPUP_ZOOM_IN);
GetEventHandler()->ProcessEvent(cmd);
break;
case HK_ZOOM_OUT:
cmd.SetId(ID_POPUP_ZOOM_OUT);
GetEventHandler()->ProcessEvent(cmd);
break;
case HK_ZOOM_REDRAW:
cmd.SetId(ID_ZOOM_REDRAW);
GetEventHandler()->ProcessEvent(cmd);
break;
case HK_ZOOM_CENTER:
cmd.SetId(ID_POPUP_ZOOM_CENTER);
GetEventHandler()->ProcessEvent(cmd);
break;
case HK_ADD_MODULE:
cmd.SetId(ID_COMPONENT_BUTT);
GetEventHandler()->ProcessEvent(cmd);
break;
case HK_ADD_TRACK:
cmd.SetId(ID_TRACK_BUTT);
GetEventHandler()->ProcessEvent(cmd);
break;
case HK_ZOOM_AUTO:
cmd.SetId(ID_ZOOM_PAGE);
GetEventHandler()->ProcessEvent(cmd);
break;
case HK_RESET_LOCAL_COORD: /*Reset the relative coord */
GetScreen()->m_O_Curseur = GetScreen()->m_Curseur;
break;
case HK_SWITCH_UNITS:
g_UnitMetric = (g_UnitMetric == INCHES) ? MILLIMETRE : INCHES;
break;
case HK_SWITCH_TRACK_DISPLAY_MODE:
DisplayOpt.DisplayPcbTrackFill ^= 1;
DisplayOpt.DisplayPcbTrackFill &= 1;
m_DisplayPcbTrackFill = DisplayOpt.DisplayPcbTrackFill;
GetScreen()->SetRefreshReq();
break;
case HK_DELETE:
OnHotkeyDeleteItem(DC, DrawStruct);
break;
case HK_BACK_SPACE:
if (m_ID_current_state == ID_TRACK_BUTT && GetScreen()->m_Active_Layer
<= CMP_N) {
if (ItemFree) {
// no track is currently being edited - select a segment and remove it.
// @todo: possibly? pass the HK command code to PcbGeneralLocateAndDisplay() so it can restrict its search to specific item types.
// @todo: use PcbGeneralLocateAndDisplay() everywhere in this source file.
DrawStruct = PcbGeneralLocateAndDisplay();
// don't let backspace delete modules!!
if (DrawStruct && (DrawStruct->Type() == TYPE_TRACK
|| DrawStruct->Type() == TYPE_VIA)) {
Delete_Segment(DC, (TRACK*) DrawStruct);
SetCurItem(NULL);
}
GetScreen()->SetModify();
} else if (GetCurItem()->Type() == TYPE_TRACK) {
// then an element is being edited - remove the last segment.
// simple lines for debugger:
TRACK* track = (TRACK*) GetCurItem();
track = Delete_Segment(DC, track);
SetCurItem(track);
GetScreen()->SetModify();
}
}
break;
case HK_END_TRACK:
if (!ItemFree && (GetCurItem()->Type() == TYPE_TRACK)
&& ((GetCurItem()->m_Flags & IS_NEW) != 0)) {
// A new track is in progress: call to End_Route()
DrawPanel->MouseToCursorSchema();
End_Route((TRACK*) GetCurItem(), DC);
}
break;
case HK_GET_AND_MOVE_FOOTPRINT:
if (ItemFree) {
wxCommandEvent evt;
evt.SetId(ID_POPUP_PCB_GET_AND_MOVE_MODULE_REQUEST);
Process_Special_Functions(evt);
}
break;
case HK_FIND_ITEM:
if (ItemFree) {
wxCommandEvent evt;
evt.SetId(ID_FIND_ITEMS);
Process_Special_Functions(evt);
}
break;
case HK_LOAD_BOARD:
if (ItemFree) {
// try not to duplicate save, load code etc.
wxCommandEvent evt;
evt.SetId(ID_LOAD_FILE);
Files_io(evt);
}
break;
case HK_SAVE_BOARD:
if (ItemFree) {
// try not to duplicate save, load code etc.
wxCommandEvent evt;
evt.SetId(ID_SAVE_BOARD);
Files_io(evt);
}
break;
case HK_ADD_MICROVIA: // Place a micro via if a track is in progress
if (m_ID_current_state != ID_TRACK_BUTT)
return;
if (ItemFree) // no track in progress: nothing to do
break;
if (GetCurItem()->Type() != TYPE_TRACK) // Should not occur
return;
if ((GetCurItem()->m_Flags & IS_NEW) == 0)
return;
// place micro via and switch layer
if (GetScreen()->IsMicroViaAcceptable()) {
int v_type = g_DesignSettings.m_CurrentViaType;
g_DesignSettings.m_CurrentViaType = VIA_MICROVIA;
Other_Layer_Route((TRACK*) GetCurItem(), DC);
g_DesignSettings.m_CurrentViaType = v_type;
if (DisplayOpt.ContrastModeDisplay)
GetScreen()->SetRefreshReq();
}
break;
case HK_ADD_VIA: // Switch to alternate layer and Place a via if a track is in progress
if (m_ID_current_state != ID_TRACK_BUTT)
return;
if (ItemFree) // no track in progress: switch layer only
{
Other_Layer_Route(NULL, DC);
break;
}
if (GetCurItem()->Type() != TYPE_TRACK)
return;
if ((GetCurItem()->m_Flags & IS_NEW) == 0)
return;
Other_Layer_Route((TRACK*) GetCurItem(), DC); // place via and switch layer
if (DisplayOpt.ContrastModeDisplay)
GetScreen()->SetRefreshReq();
break;
// Footprint edition:
case HK_LOCK_UNLOCK_FOOTPRINT: // toggle module "MODULE_is_LOCKED" status:
// get any module, locked or not locked and toggle its locked status
if (ItemFree)
module = Locate_Prefered_Module(GetBoard(), CURSEUR_OFF_GRILLE
| VISIBLE_ONLY);
else if (GetCurItem()->Type() == TYPE_MODULE)
module = (MODULE*) GetCurItem();
if (module) {
SetCurItem(module);
module->SetLocked(!module->IsLocked());
module->DisplayInfo(this);
}
break;
case HK_DRAG_FOOTPRINT: // Start move (and drag) module
case HK_MOVE_FOOTPRINT: // Start move module
if (PopupOn)
break;
case HK_ROTATE_FOOTPRINT: // Rotation
case HK_FLIP_FOOTPRINT: // move to other side
int exit = 0;
if (m_ID_current_state == ID_TRACK_BUTT) {
if (ItemFree)
DrawStruct = PcbGeneralLocateAndDisplay();
else
DrawStruct = GetCurItem();
if (DrawStruct && (DrawStruct->Type() == TYPE_TRACK
|| DrawStruct->Type() == TYPE_VIA))
switch (HK_Descr->m_Idcommand) {
case HK_DRAG_FOOTPRINT: // Start move (and drag) module
DrawPanel->MouseToCursorSchema();
//Start_DragTrackSegmentAndKeepSlope( (TRACK*) DrawStruct,DC );
Start_MoveOneNodeOrSegment((TRACK*) DrawStruct, DC,
ID_POPUP_PCB_DRAG_TRACK_SEGMENT);
break;
// fall through
case HK_MOVE_FOOTPRINT: // Start move module
DrawPanel->MouseToCursorSchema();
Start_MoveOneNodeOrSegment((TRACK*) DrawStruct, DC,
ID_POPUP_PCB_MOVE_TRACK_NODE);
break;
}
else
exit = 1;
} else if (!exit) {
if (ItemFree) {
module = Locate_Prefered_Module(GetBoard(), CURSEUR_OFF_GRILLE
| IGNORE_LOCKED | VISIBLE_ONLY
#if defined (USE_MATCH_LAYER)
| MATCH_LAYER
wxCommandEvent cmd( wxEVT_COMMAND_MENU_SELECTED );
cmd.SetEventObject( this );
bool PopupOn = (GetCurItem() && GetCurItem()->m_Flags);
bool ItemFree = (GetCurItem() == 0 || GetCurItem()->m_Flags == 0);
if( hotkey == 0 )
return;
MODULE* module = NULL;
// Remap the control key Ctrl A (0x01) to GR_KB_CTRL + 'A' (just easier to handle...)
if( (hotkey & GR_KB_CTRL) != 0 )
hotkey += 'A' - 1;
/* Convert lower to upper case (the usual toupper function has problem with non ascii codes like function keys */
if( (hotkey >= 'a') && (hotkey <= 'z') )
hotkey += 'A' - 'a';
Ki_HotkeyInfo* HK_Descr = GetDescriptorFromHotkey( hotkey,
s_Common_Hotkey_List );
if( HK_Descr == NULL )
HK_Descr = GetDescriptorFromHotkey( hotkey, s_board_edit_Hotkey_List );
if( HK_Descr == NULL )
return;
int ll;
switch( HK_Descr->m_Idcommand )
{
default:
case HK_NOT_FOUND:
return;
break;
case HK_SWITCH_LAYER_TO_PREVIOUS:
ll = GetScreen()->m_Active_Layer;
if( (ll <= COPPER_LAYER_N) || (ll > CMP_N) )
break;
if( GetBoard()->m_BoardSettings->GetCopperLayerCount() < 2 ) // Single layer
ll = COPPER_LAYER_N;
else if( ll == CMP_N )
ll = MAX( COPPER_LAYER_N,
GetBoard()->m_BoardSettings->GetCopperLayerCount() - 2 );
else
ll--;
SwitchLayer( DC, ll );
break;
case HK_SWITCH_LAYER_TO_NEXT:
ll = GetScreen()->m_Active_Layer;
if( (ll < COPPER_LAYER_N) || (ll >= CMP_N) )
break;
if( GetBoard()->m_BoardSettings->GetCopperLayerCount() < 2 ) // Single layer
ll = COPPER_LAYER_N;
else if( ll >= GetBoard()->m_BoardSettings->GetCopperLayerCount() - 2 )
ll = CMP_N;
else
ll++;
SwitchLayer( DC, ll );
break;
case HK_SWITCH_LAYER_TO_COMPONENT:
SwitchLayer( DC, CMP_N );
break;
case HK_SWITCH_LAYER_TO_COPPER:
SwitchLayer( DC, COPPER_LAYER_N );
break;
case HK_SWITCH_LAYER_TO_INNER1:
SwitchLayer( DC, LAYER_N_2 );
break;
case HK_SWITCH_LAYER_TO_INNER2:
SwitchLayer( DC, LAYER_N_3 );
break;
case HK_SWITCH_LAYER_TO_INNER3:
SwitchLayer( DC, LAYER_N_4 );
break;
case HK_SWITCH_LAYER_TO_INNER4:
SwitchLayer( DC, LAYER_N_5 );
break;
case HK_SWITCH_LAYER_TO_INNER5:
SwitchLayer( DC, LAYER_N_6 );
break;
case HK_SWITCH_LAYER_TO_INNER6:
SwitchLayer( DC, LAYER_N_7 );
break;
case HK_HELP: // Display Current hotkey list
DisplayHotkeyList( this, s_Board_Editor_Hokeys_Descr );
break;
case HK_ZOOM_IN:
cmd.SetId( ID_POPUP_ZOOM_IN );
GetEventHandler()->ProcessEvent( cmd );
break;
case HK_ZOOM_OUT:
cmd.SetId( ID_POPUP_ZOOM_OUT );
GetEventHandler()->ProcessEvent( cmd );
break;
case HK_ZOOM_REDRAW:
cmd.SetId( ID_ZOOM_REDRAW );
GetEventHandler()->ProcessEvent( cmd );
break;
case HK_ZOOM_CENTER:
cmd.SetId( ID_POPUP_ZOOM_CENTER );
GetEventHandler()->ProcessEvent( cmd );
break;
case HK_ADD_MODULE:
cmd.SetId( ID_COMPONENT_BUTT );
GetEventHandler()->ProcessEvent( cmd );
break;
case HK_ADD_TRACK:
cmd.SetId( ID_TRACK_BUTT );
GetEventHandler()->ProcessEvent( cmd );
break;
case HK_ZOOM_AUTO:
cmd.SetId( ID_ZOOM_PAGE );
GetEventHandler()->ProcessEvent( cmd );
break;
case HK_RESET_LOCAL_COORD: /*Reset the relative coord */
GetScreen()->m_O_Curseur = GetScreen()->m_Curseur;
break;
case HK_SWITCH_UNITS:
g_UnitMetric = (g_UnitMetric == INCHES) ? MILLIMETRE : INCHES;
break;
case HK_SWITCH_TRACK_DISPLAY_MODE:
DisplayOpt.DisplayPcbTrackFill ^= 1;
DisplayOpt.DisplayPcbTrackFill &= 1;
m_DisplayPcbTrackFill = DisplayOpt.DisplayPcbTrackFill;
GetScreen()->SetRefreshReq();
break;
case HK_DELETE:
OnHotkeyDeleteItem( DC, DrawStruct );
break;
case HK_BACK_SPACE:
if( m_ID_current_state == ID_TRACK_BUTT && GetScreen()->m_Active_Layer
<= CMP_N )
{
if( ItemFree )
{
// no track is currently being edited - select a segment and remove it.
// @todo: possibly? pass the HK command code to PcbGeneralLocateAndDisplay() so it can restrict its search to specific item types.
// @todo: use PcbGeneralLocateAndDisplay() everywhere in this source file.
DrawStruct = PcbGeneralLocateAndDisplay();
// don't let backspace delete modules!!
if( DrawStruct && (DrawStruct->Type() == TYPE_TRACK
|| DrawStruct->Type() == TYPE_VIA) )
{
Delete_Segment( DC, (TRACK*) DrawStruct );
SetCurItem( NULL );
}
GetScreen()->SetModify();
}
else if( GetCurItem()->Type() == TYPE_TRACK )
{
// then an element is being edited - remove the last segment.
// simple lines for debugger:
TRACK* track = (TRACK*) GetCurItem();
track = Delete_Segment( DC, track );
SetCurItem( track );
GetScreen()->SetModify();
}
}
break;
case HK_END_TRACK:
if( !ItemFree && (GetCurItem()->Type() == TYPE_TRACK)
&& ( (GetCurItem()->m_Flags & IS_NEW) != 0 ) )
{
// A new track is in progress: call to End_Route()
DrawPanel->MouseToCursorSchema();
End_Route( (TRACK*) GetCurItem(), DC );
}
break;
case HK_GET_AND_MOVE_FOOTPRINT:
if( ItemFree )
{
wxCommandEvent evt;
evt.SetId( ID_POPUP_PCB_GET_AND_MOVE_MODULE_REQUEST );
Process_Special_Functions( evt );
}
break;
case HK_FIND_ITEM:
if( ItemFree )
{
wxCommandEvent evt;
evt.SetId( ID_FIND_ITEMS );
Process_Special_Functions( evt );
}
break;
case HK_LOAD_BOARD:
if( ItemFree )
{
// try not to duplicate save, load code etc.
wxCommandEvent evt;
evt.SetId( ID_LOAD_FILE );
Files_io( evt );
}
break;
case HK_SAVE_BOARD:
if( ItemFree )
{
// try not to duplicate save, load code etc.
wxCommandEvent evt;
evt.SetId( ID_SAVE_BOARD );
Files_io( evt );
}
break;
case HK_ADD_MICROVIA: // Place a micro via if a track is in progress
if( m_ID_current_state != ID_TRACK_BUTT )
return;
if( ItemFree ) // no track in progress: nothing to do
break;
if( GetCurItem()->Type() != TYPE_TRACK ) // Should not occur
return;
if( (GetCurItem()->m_Flags & IS_NEW) == 0 )
return;
// place micro via and switch layer
if( GetScreen()->IsMicroViaAcceptable() )
{
int v_type = g_DesignSettings.m_CurrentViaType;
g_DesignSettings.m_CurrentViaType = VIA_MICROVIA;
Other_Layer_Route( (TRACK*) GetCurItem(), DC );
g_DesignSettings.m_CurrentViaType = v_type;
if( DisplayOpt.ContrastModeDisplay )
GetScreen()->SetRefreshReq();
}
break;
case HK_ADD_VIA: // Switch to alternate layer and Place a via if a track is in progress
if( m_ID_current_state != ID_TRACK_BUTT )
return;
if( ItemFree ) // no track in progress: switch layer only
{
Other_Layer_Route( NULL, DC );
break;
}
if( GetCurItem()->Type() != TYPE_TRACK )
return;
if( (GetCurItem()->m_Flags & IS_NEW) == 0 )
return;
Other_Layer_Route( (TRACK*) GetCurItem(), DC ); // place via and switch layer
if( DisplayOpt.ContrastModeDisplay )
GetScreen()->SetRefreshReq();
break;
// Footprint edition:
case HK_LOCK_UNLOCK_FOOTPRINT: // toggle module "MODULE_is_LOCKED" status:
// get any module, locked or not locked and toggle its locked status
if( ItemFree )
module = Locate_Prefered_Module( GetBoard(), CURSEUR_OFF_GRILLE
| VISIBLE_ONLY );
else if( GetCurItem()->Type() == TYPE_MODULE )
module = (MODULE*) GetCurItem();
if( module )
{
SetCurItem( module );
module->SetLocked( !module->IsLocked() );
module->DisplayInfo( this );
}
break;
case HK_DRAG_FOOTPRINT: // Start move (and drag) module
case HK_MOVE_FOOTPRINT: // Start move module
if( PopupOn )
break;
case HK_ROTATE_FOOTPRINT: // Rotation
case HK_FLIP_FOOTPRINT: // move to other side
int exit = 0;
if( m_ID_current_state == ID_TRACK_BUTT )
{
if( ItemFree )
DrawStruct = PcbGeneralLocateAndDisplay();
else
DrawStruct = GetCurItem();
if( DrawStruct && (DrawStruct->Type() == TYPE_TRACK
|| DrawStruct->Type() == TYPE_VIA) )
switch( HK_Descr->m_Idcommand )
{
case HK_DRAG_FOOTPRINT: // Start move (and drag) module
DrawPanel->MouseToCursorSchema();
//Start_DragTrackSegmentAndKeepSlope( (TRACK*) DrawStruct,DC );
Start_MoveOneNodeOrSegment( (TRACK*) DrawStruct, DC,
ID_POPUP_PCB_DRAG_TRACK_SEGMENT );
break;
// fall through
case HK_MOVE_FOOTPRINT: // Start move module
DrawPanel->MouseToCursorSchema();
Start_MoveOneNodeOrSegment( (TRACK*) DrawStruct, DC,
ID_POPUP_PCB_MOVE_TRACK_NODE );
break;
}
else
exit = 1;
}
else if( !exit )
{
if( ItemFree )
{
module = Locate_Prefered_Module( GetBoard(), CURSEUR_OFF_GRILLE
| IGNORE_LOCKED | VISIBLE_ONLY
#if defined(USE_MATCH_LAYER)
| MATCH_LAYER
#endif
);
if (module == NULL) // no footprint found
{
module = Locate_Prefered_Module(GetBoard(),
CURSEUR_OFF_GRILLE | VISIBLE_ONLY);
if (module) {
// a footprint is found, but locked or on an other layer
if (module->IsLocked()) {
wxString msg;
msg.Printf(_("Footprint %s found, but locked"),
module->m_Reference->m_Text.GetData());
DisplayInfoMessage(this, msg);
}
module = NULL;
}
}
} else if (GetCurItem()->Type() == TYPE_MODULE) {
module = (MODULE*) GetCurItem();
// @todo: might need to add a layer check in if() below
if ((GetCurItem()->m_Flags == 0) && module->IsLocked())
module = NULL; // do not move, rotate ... it.
}
if (module == NULL)
break;
/* I'd like to make sending to EESCHEMA edge triggered, but the
* simple mouse click on a module when the arrow icon is in play
* does not set GetCurItem() at this time, nor does a mouse click
* when the local ratsnest icon is in play set GetCurItem(), and these
* actions also call SendMessageToEESCHEMA().
* if( GetCurItem() != module )
*/
{
// Send the module via socket to EESCHEMA's search facility.
SendMessageToEESCHEMA(module);
SetCurItem(module);
}
switch (HK_Descr->m_Idcommand) {
case HK_ROTATE_FOOTPRINT: // Rotation
Rotate_Module(DC, module, 900, TRUE);
break;
case HK_FLIP_FOOTPRINT: // move to other side
Change_Side_Module(module, DC);
break;
case HK_DRAG_FOOTPRINT: // Start move (and drag) module
g_Drag_Pistes_On = TRUE;
// fall through
case HK_MOVE_FOOTPRINT: // Start move module
StartMove_Module(module, DC);
break;
}
module->DisplayInfo(this);
break;
}
}
);
if( module == NULL ) // no footprint found
{
module = Locate_Prefered_Module( GetBoard(),
CURSEUR_OFF_GRILLE | VISIBLE_ONLY );
if( module )
{
// a footprint is found, but locked or on an other layer
if( module->IsLocked() )
{
wxString msg;
msg.Printf( _( "Footprint %s found, but locked" ),
module->m_Reference->m_Text.GetData() );
DisplayInfoMessage( this, msg );
}
module = NULL;
}
}
}
else if( GetCurItem()->Type() == TYPE_MODULE )
{
module = (MODULE*) GetCurItem();
// @todo: might need to add a layer check in if() below
if( (GetCurItem()->m_Flags == 0) && module->IsLocked() )
module = NULL; // do not move, rotate ... it.
}
if( module == NULL )
break;
/* I'd like to make sending to EESCHEMA edge triggered, but the
* simple mouse click on a module when the arrow icon is in play
* does not set GetCurItem() at this time, nor does a mouse click
* when the local ratsnest icon is in play set GetCurItem(), and these
* actions also call SendMessageToEESCHEMA().
* if( GetCurItem() != module )
*/
{
// Send the module via socket to EESCHEMA's search facility.
SendMessageToEESCHEMA( module );
SetCurItem( module );
}
switch( HK_Descr->m_Idcommand )
{
case HK_ROTATE_FOOTPRINT: // Rotation
if( module->m_Flags == 0 ) // not currently in edit, prepare undo command
SaveCopyInUndoList( module, UR_ROTATED, module->m_Pos );
Rotate_Module( DC, module, 900, TRUE );
break;
case HK_FLIP_FOOTPRINT: // move to other side
if( module->m_Flags == 0 ) // not currently in edit, prepare undo command
SaveCopyInUndoList( module, UR_FLIPPED, module->m_Pos );
Change_Side_Module( module, DC );
break;
case HK_DRAG_FOOTPRINT: // Start move (and drag) module
g_Drag_Pistes_On = TRUE;
// fall through
case HK_MOVE_FOOTPRINT: // Start move module
StartMove_Module( module, DC );
break;
}
module->DisplayInfo( this );
break;
}
}
}
/***********************************************************/
void WinEDA_ModuleEditFrame::OnHotKey(wxDC* DC, int hotkey,
EDA_BaseStruct* DrawStruct)
void WinEDA_ModuleEditFrame::OnHotKey( wxDC* DC, int hotkey,
EDA_BaseStruct* DrawStruct )
/***********************************************************/
/* Hot keys. Some commands are relative to the item under the mouse cursor
* Commands are case insensitive
*/
{
if (hotkey == 0)
return;
wxCommandEvent cmd(wxEVT_COMMAND_MENU_SELECTED);
cmd.SetEventObject(this);
/* Convert lower to upper case (the usual toupper function has problem with non ascii codes like function keys */
if ((hotkey >= 'a') && (hotkey <= 'z'))
hotkey += 'A' - 'a';
Ki_HotkeyInfo * HK_Descr = GetDescriptorFromHotkey(hotkey,
s_Common_Hotkey_List);
if (HK_Descr == NULL)
HK_Descr = GetDescriptorFromHotkey(hotkey, s_module_edit_Hotkey_List);
if (HK_Descr == NULL)
return;
switch (HK_Descr->m_Idcommand) {
default:
case HK_NOT_FOUND:
return;
break;
case HK_HELP: // Display Current hotkey list
DisplayHotkeyList(this, s_Module_Editor_Hokeys_Descr);
break;
case HK_RESET_LOCAL_COORD: /*Reset the relative coord */
GetScreen()->m_O_Curseur = GetScreen()->m_Curseur;
break;
case HK_SWITCH_UNITS:
g_UnitMetric = (g_UnitMetric == INCHES) ? MILLIMETRE : INCHES;
break;
case HK_ZOOM_IN:
cmd.SetId(ID_POPUP_ZOOM_IN);
GetEventHandler()->ProcessEvent(cmd);
break;
case HK_ZOOM_OUT:
cmd.SetId(ID_POPUP_ZOOM_OUT);
GetEventHandler()->ProcessEvent(cmd);
break;
case HK_ZOOM_REDRAW:
cmd.SetId(ID_ZOOM_REDRAW);
GetEventHandler()->ProcessEvent(cmd);
break;
case HK_ZOOM_CENTER:
cmd.SetId(ID_POPUP_ZOOM_CENTER);
GetEventHandler()->ProcessEvent(cmd);
break;
case HK_ZOOM_AUTO:
cmd.SetId(ID_ZOOM_PAGE);
GetEventHandler()->ProcessEvent(cmd);
break;
}
if( hotkey == 0 )
return;
wxCommandEvent cmd( wxEVT_COMMAND_MENU_SELECTED );
cmd.SetEventObject( this );
/* Convert lower to upper case (the usual toupper function has problem with non ascii codes like function keys */
if( (hotkey >= 'a') && (hotkey <= 'z') )
hotkey += 'A' - 'a';
Ki_HotkeyInfo* HK_Descr = GetDescriptorFromHotkey( hotkey,
s_Common_Hotkey_List );
if( HK_Descr == NULL )
HK_Descr = GetDescriptorFromHotkey( hotkey, s_module_edit_Hotkey_List );
if( HK_Descr == NULL )
return;
switch( HK_Descr->m_Idcommand )
{
default:
case HK_NOT_FOUND:
return;
break;
case HK_HELP: // Display Current hotkey list
DisplayHotkeyList( this, s_Module_Editor_Hokeys_Descr );
break;
case HK_RESET_LOCAL_COORD: /*Reset the relative coord */
GetScreen()->m_O_Curseur = GetScreen()->m_Curseur;
break;
case HK_SWITCH_UNITS:
g_UnitMetric = (g_UnitMetric == INCHES) ? MILLIMETRE : INCHES;
break;
case HK_ZOOM_IN:
cmd.SetId( ID_POPUP_ZOOM_IN );
GetEventHandler()->ProcessEvent( cmd );
break;
case HK_ZOOM_OUT:
cmd.SetId( ID_POPUP_ZOOM_OUT );
GetEventHandler()->ProcessEvent( cmd );
break;
case HK_ZOOM_REDRAW:
cmd.SetId( ID_ZOOM_REDRAW );
GetEventHandler()->ProcessEvent( cmd );
break;
case HK_ZOOM_CENTER:
cmd.SetId( ID_POPUP_ZOOM_CENTER );
GetEventHandler()->ProcessEvent( cmd );
break;
case HK_ZOOM_AUTO:
cmd.SetId( ID_ZOOM_PAGE );
GetEventHandler()->ProcessEvent( cmd );
break;
}
}
/******************************************************************************/
bool WinEDA_PcbFrame::OnHotkeyDeleteItem(wxDC* DC, EDA_BaseStruct* DrawStruct)
bool WinEDA_PcbFrame::OnHotkeyDeleteItem( wxDC* DC, EDA_BaseStruct* DrawStruct )
/******************************************************************************/
/* Delete the item foun under the mouse cursor
......@@ -617,46 +691,51 @@ bool WinEDA_PcbFrame::OnHotkeyDeleteItem(wxDC* DC, EDA_BaseStruct* DrawStruct)
* Delete the module.
*/
{
bool ItemFree = (GetCurItem() == NULL) || (GetCurItem()->m_Flags == 0);
switch (m_ID_current_state) {
case ID_TRACK_BUTT:
if (GetScreen()->m_Active_Layer > CMP_N)
return FALSE;
if (ItemFree) {
DrawStruct = PcbGeneralLocateAndDisplay();
if (DrawStruct && DrawStruct->Type() != TYPE_TRACK)
return FALSE;
Delete_Track(DC, (TRACK*) DrawStruct);
} else if (GetCurItem()->Type() == TYPE_TRACK) {
// simple lines for debugger:
TRACK* track = (TRACK*) GetCurItem();
track = Delete_Segment(DC, track);
SetCurItem(track);
GetScreen()->SetModify();
return TRUE;
}
break;
case ID_COMPONENT_BUTT:
if (ItemFree) {
MODULE* module = Locate_Prefered_Module(GetBoard(),
CURSEUR_ON_GRILLE);
if (module == NULL)
return FALSE;
if (!IsOK(this, _("Delete module?")))
return FALSE;
RemoveStruct(module, DC);
} else
return FALSE;
break;
default:
return FALSE;
}
GetScreen()->SetModify();
SetCurItem(NULL);
return TRUE;
bool ItemFree = (GetCurItem() == NULL) || (GetCurItem()->m_Flags == 0);
switch( m_ID_current_state )
{
case ID_TRACK_BUTT:
if( GetScreen()->m_Active_Layer > CMP_N )
return FALSE;
if( ItemFree )
{
DrawStruct = PcbGeneralLocateAndDisplay();
if( DrawStruct && DrawStruct->Type() != TYPE_TRACK )
return FALSE;
Delete_Track( DC, (TRACK*) DrawStruct );
}
else if( GetCurItem()->Type() == TYPE_TRACK )
{
// simple lines for debugger:
TRACK* track = (TRACK*) GetCurItem();
track = Delete_Segment( DC, track );
SetCurItem( track );
GetScreen()->SetModify();
return TRUE;
}
break;
case ID_COMPONENT_BUTT:
if( ItemFree )
{
MODULE* module = Locate_Prefered_Module( GetBoard(),
CURSEUR_ON_GRILLE );
if( module == NULL )
return FALSE;
if( !IsOK( this, _( "Delete module?" ) ) )
return FALSE;
RemoveStruct( module, DC );
}
else
return FALSE;
break;
default:
return FALSE;
}
GetScreen()->SetModify();
SetCurItem( NULL );
return TRUE;
}
......@@ -21,11 +21,11 @@ enum hotkey_id_commnand {
HK_MOVE_FOOTPRINT,
HK_DRAG_FOOTPRINT,
HK_FLIP_FOOTPRINT,
HK_GET_AND_MOVE_FOOTPRINT,
HK_GET_AND_MOVE_FOOTPRINT,
HK_LOCK_UNLOCK_FOOTPRINT,
HK_ADD_VIA,
HK_ADD_MICROVIA,
HK_END_TRACK,
HK_ADD_MICROVIA,
HK_END_TRACK,
HK_SAVE_BOARD, HK_LOAD_BOARD,
HK_SWITCH_UNITS,
HK_SWITCH_TRACK_DISPLAY_MODE,
......@@ -56,9 +56,11 @@ enum hotkey_id_commnand {
// List of hotkey descriptors for pcbnew
extern struct Ki_HotkeyInfoSectionDescriptor s_Pcbnew_Editor_Hokeys_Descr[];
// List of hotkey descriptors for the board editor only
extern struct Ki_HotkeyInfoSectionDescriptor s_Board_Editor_Hokeys_Descr[];
// List of hotkey descriptors for the footprint editor only
extern struct Ki_HotkeyInfoSectionDescriptor s_Module_Editor_Hokeys_Descr[];
#endif // KOTKEYS_H
#endif // KOTKEYS_H
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment