Skip to content

Commit 8123dc8

Browse files
committed
Fix keypad classes to show the events property
It looks like we need the MP_TYPE_FLAG_HAS_SPECIAL_ACCESSORS flag on the class for properties to work, and the Keys, KeyMatrix and ShiftRegisterKeys classes were missing it, so the "events" property didn't appear on the instances.
1 parent a501a21 commit 8123dc8

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

shared-bindings/keypad/KeyMatrix.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,7 @@ STATIC MP_DEFINE_CONST_DICT(keypad_keymatrix_locals_dict, keypad_keymatrix_local
253253
MP_DEFINE_CONST_OBJ_TYPE(
254254
keypad_keymatrix_type,
255255
MP_QSTR_KeyMatrix,
256-
MP_TYPE_FLAG_NONE,
256+
MP_TYPE_FLAG_HAS_SPECIAL_ACCESSORS,
257257
make_new, keypad_keymatrix_make_new
258258
#if CIRCUITPY_KEYPAD_KEYMATRIX
259259
, locals_dict, &keypad_keymatrix_locals_dict

shared-bindings/keypad/Keys.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ STATIC MP_DEFINE_CONST_DICT(keypad_keys_locals_dict, keypad_keys_locals_dict_tab
187187
MP_DEFINE_CONST_OBJ_TYPE(
188188
keypad_keys_type,
189189
MP_QSTR_Keys,
190-
MP_TYPE_FLAG_NONE,
190+
MP_TYPE_FLAG_HAS_SPECIAL_ACCESSORS,
191191
make_new, keypad_keys_make_new
192192
#if CIRCUITPY_KEYPAD_KEYS
193193
, locals_dict, &keypad_keys_locals_dict

shared-bindings/keypad/ShiftRegisterKeys.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,7 @@ STATIC MP_DEFINE_CONST_DICT(keypad_shiftregisterkeys_locals_dict, keypad_shiftre
239239
MP_DEFINE_CONST_OBJ_TYPE(
240240
keypad_shiftregisterkeys_type,
241241
MP_QSTR_ShiftRegisterKeys,
242-
MP_TYPE_FLAG_NONE,
242+
MP_TYPE_FLAG_HAS_SPECIAL_ACCESSORS,
243243
make_new, keypad_shiftregisterkeys_make_new
244244
#if CIRCUITPY_KEYPAD_SHIFTREGISTERKEYS
245245
, locals_dict, &keypad_shiftregisterkeys_locals_dict

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy