Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Thompson <quornian@googlemail.com>2008-07-15 11:04:31 +0400
committerIan Thompson <quornian@googlemail.com>2008-07-15 11:04:31 +0400
commitdbb61988fdaa6085912dee6ab8f5569e63ef88fb (patch)
tree2b1334417dbe2536851bed215777f89e416b6007 /source/blender/python/BPY_extern.h
parent14c1ed08108df6178a55f6d7f818f19a926ae1df (diff)
Any script can now register a unique key combination as part of its bpy header. For a supported space type, the user may press this shortcut to invoke the script.
Space types that are to support shortcuts like this should call BPY_menu_do_shortcut(...) from the event queue read method (See winqreadtextspace in drawtext.c for example)
Diffstat (limited to 'source/blender/python/BPY_extern.h')
-rw-r--r--source/blender/python/BPY_extern.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/python/BPY_extern.h b/source/blender/python/BPY_extern.h
index f6a27b80733..3a826d49542 100644
--- a/source/blender/python/BPY_extern.h
+++ b/source/blender/python/BPY_extern.h
@@ -91,6 +91,8 @@ extern "C" {
int BPY_txt_do_python_Text( struct Text *text );
int BPY_menu_do_python( short menutype, int event );
+ int BPY_menu_do_shortcut( short menutype, unsigned short key, unsigned short modifiers );
+ int BPY_menu_invoke( struct BPyMenu *pym, short menutype );
void BPY_run_python_script( char *filename );
int BPY_run_script(struct Script *script);
void BPY_free_compiled_text( struct Text *text );