Function declaration for BPY_context_get
This commit is contained in:
parent
de7504807c
commit
d611dd3735
|
@ -46,6 +46,8 @@
|
|||
#include "BKE_screen.h"
|
||||
#include "BKE_global.h"
|
||||
|
||||
#include "BPY_extern.h"
|
||||
|
||||
#include <string.h>
|
||||
|
||||
/* struct */
|
||||
|
@ -413,7 +415,9 @@ static int ctx_data_get(bContext *C, const char *member, bContextDataResult *res
|
|||
memset(result, 0, sizeof(bContextDataResult));
|
||||
|
||||
if(CTX_py_dict_get(C)) {
|
||||
return bpy_context_get(C, member, result);
|
||||
return BPY_context_get(C, member, result);
|
||||
// if (BPY_context_get(C, member, result))
|
||||
// return 1;
|
||||
}
|
||||
|
||||
/* we check recursion to ensure that we do not get infinite
|
||||
|
|
|
@ -49,6 +49,7 @@ struct bConstraintTarget; /* DNA_constraint_types.h*/
|
|||
struct Script; /* DNA_screen_types.h */
|
||||
struct BPyMenu;
|
||||
struct bContext;
|
||||
struct bContextDataResult;
|
||||
struct ReportList;
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
@ -104,7 +105,7 @@ extern "C" {
|
|||
// int BPY_run_script_space_listener(struct bContext *C, struct SpaceScript * sc, struct ARegion *ar, struct wmNotifier *wmn); // 2.5 working
|
||||
void BPY_update_modules( void ); // XXX - annoying, need this for pointers that get out of date
|
||||
|
||||
|
||||
int BPY_context_get(struct bContext *C, const char *member, struct bContextDataResult *result);
|
||||
|
||||
int BPY_run_script(struct Script *script);
|
||||
void BPY_free_compiled_text( struct Text *text );
|
||||
|
|
|
@ -966,7 +966,7 @@ int BPY_button_eval(bContext *C, char *expr, double *value)
|
|||
|
||||
|
||||
|
||||
int bpy_context_get(bContext *C, const char *member, bContextDataResult *result)
|
||||
int BPY_context_get(bContext *C, const char *member, bContextDataResult *result)
|
||||
{
|
||||
PyObject *pyctx= (PyObject *)CTX_py_dict_get(C);
|
||||
PyObject *item= PyDict_GetItemString(pyctx, member);
|
||||
|
|
Loading…
Reference in New Issue