Skip to content

Commit 12b7dcb

Browse files
authored
Actually pass the flags for message bus listeners (#5750)
* Actually pass the flags for message bus listeners * bump common and core
1 parent 37896cc commit 12b7dcb

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

libs/core/codal.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ static void initCodal() {
9898

9999
void registerWithDal(int id, int event, Action a, int flags) {
100100
uBit.messageBus.ignore(id, event, dispatchForeground);
101-
uBit.messageBus.listen(id, event, dispatchForeground, a);
101+
uBit.messageBus.listen(id, event, dispatchForeground, a, (uint16_t) flags);
102102
incr(a);
103103
registerGCPtr(a);
104104
}

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@
4545
"typescript": "4.8.3"
4646
},
4747
"dependencies": {
48-
"pxt-common-packages": "12.0.1",
49-
"pxt-core": "10.0.23"
48+
"pxt-common-packages": "12.0.3",
49+
"pxt-core": "10.2.3"
5050
}
5151
}

sim/state/misc.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,15 +35,15 @@ namespace pxsim.basic {
3535
namespace pxsim.control {
3636
export var inBackground = thread.runInBackground;
3737

38-
export function onEvent(id: number, evid: number, handler: RefAction) {
38+
export function onEvent(id: number, evid: number, handler: RefAction, flags: number) {
3939
if (id == DAL.MICROBIT_ID_BUTTON_AB) {
4040
const b = board().buttonPairState;
4141
if (!b.usesButtonAB) {
4242
b.usesButtonAB = true;
4343
runtime.queueDisplayUpdate();
4444
}
4545
}
46-
pxtcore.registerWithDal(id, evid, handler)
46+
pxtcore.registerWithDal(id, evid, handler, flags)
4747
}
4848

4949
export function eventTimestamp() {

0 commit comments

Comments
 (0)