File tree Expand file tree Collapse file tree 2 files changed +7
-0
lines changed
Expand file tree Collapse file tree 2 files changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -409,9 +409,15 @@ STATIC mp_obj_t mod_jni_cls(mp_obj_t cls_name_in) {
409409}
410410MP_DEFINE_CONST_FUN_OBJ_1 (mod_jni_cls_obj , mod_jni_cls );
411411
412+ STATIC mp_obj_t mod_jni_env () {
413+ return mp_obj_new_int ((mp_int_t )env );
414+ }
415+ MP_DEFINE_CONST_FUN_OBJ_0 (mod_jni_env_obj , mod_jni_env );
416+
412417STATIC const mp_map_elem_t mp_module_jni_globals_table [] = {
413418 { MP_OBJ_NEW_QSTR (MP_QSTR___name__ ), MP_OBJ_NEW_QSTR (MP_QSTR_jni ) },
414419 { MP_OBJ_NEW_QSTR (MP_QSTR_cls ), (mp_obj_t )& mod_jni_cls_obj },
420+ { MP_OBJ_NEW_QSTR (MP_QSTR_env ), (mp_obj_t )& mod_jni_env_obj },
415421};
416422
417423STATIC MP_DEFINE_CONST_DICT (mp_module_jni_globals , mp_module_jni_globals_table );
Original file line number Diff line number Diff line change @@ -106,6 +106,7 @@ Q(B115200)
106106#if MICROPY_PY_JNI
107107Q (jni )
108108Q (cls )
109+ Q (env )
109110Q (jclass )
110111Q (jobject )
111112Q (jmethod )
You can’t perform that action at this time.
0 commit comments