Setting addon keymaps in 2.59

Ok, I’m struggling with adding a new keymap for my addon with the new 2.59 para-dime. Basically, I want to override functionality in edit mode only.

If I do:

    wm = bpy.context.window_manager
    km ='3D View', space_type='VIEW_3D')
    kmi ='wm.call_menu', 'SPACE', 'PRESS', ctrl=True) = "VIEW3D_MT_Multiselect_Menu"

It will add my keymap to the ‘3D View’ {Global} section in the keymaps, but I have no idea how to access the ‘Mesh’ subsection to add my keymap there. Any ideas?

Ok, Zeffii gave me a half solution: Basically I do the checks for the EditMode/Object Mode in a different part of the script. Now my problem is with this line:

kmi ='wm.call_menu', 'TAB', 'PRESS', ctrl=True)

It won’t work. If I fill the TAB in with SPACE or J or another letter it works fine, but I’m attempting to override the ctrl-tab functionality only in edit mode and that one keybinding does not seem to work for me. Ideas?

Without any script to test with, there’s not too much to go with here. You added some constraints to your original question, by forcing a certain key combo, which is already defined in input->3dview->mesh-> Call Menu ( where ctrl+tab displays the mesh selection type menu (vertex/edge/face)) . I’m thinking you need to remove that entry entirely, then your ctrl+tab assignment in the script will probably be ok.