Skip to content

Commit

Permalink
HAT -> EVENT for non edge activated blocks (#856)
Browse files Browse the repository at this point in the history
  • Loading branch information
GarboMuffin authored Aug 9, 2023
1 parent 6657fbd commit 75289fd
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 23 deletions.
8 changes: 4 additions & 4 deletions extensions/battery.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,25 +81,25 @@
},
{
opcode: 'chargingChanged',
blockType: Scratch.BlockType.HAT,
blockType: Scratch.BlockType.EVENT,
text: 'when charging changed',
isEdgeActivated: false
},
{
opcode: 'levelChanged',
blockType: Scratch.BlockType.HAT,
blockType: Scratch.BlockType.EVENT,
text: 'when battery level changed',
isEdgeActivated: false
},
{
opcode: 'chargeTimeChanged',
blockType: Scratch.BlockType.HAT,
blockType: Scratch.BlockType.EVENT,
text: 'when time until charged changed',
isEdgeActivated: false
},
{
opcode: 'dischargeTimeChanged',
blockType: Scratch.BlockType.HAT,
blockType: Scratch.BlockType.EVENT,
text: 'when time until empty changed',
isEdgeActivated: false
},
Expand Down
4 changes: 2 additions & 2 deletions extensions/clipboard.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,13 +46,13 @@
blocks: [
{
opcode: 'whenCopied',
blockType: Scratch.BlockType.HAT,
blockType: Scratch.BlockType.EVENT,
text: 'when something is copied',
isEdgeActivated: false
},
{
opcode: 'whenPasted',
blockType: Scratch.BlockType.HAT,
blockType: Scratch.BlockType.EVENT,
text: 'when something is pasted',
isEdgeActivated: false
},
Expand Down
4 changes: 2 additions & 2 deletions extensions/gamepad.js
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@
/*
{
opcode: 'buttonPressedReleased',
blockType: Scratch.BlockType.HAT,
blockType: Scratch.BlockType.EVENT,
text: 'button [b] [pr] of pad [i]',
arguments: {
b: {
Expand All @@ -203,7 +203,7 @@
{
opcode: 'axisMoved',
blockType: Scratch.BlockType.HAT,
blockType: Scratch.BlockType.EVENT,
text: 'axis [b] of pad [i] moved',
arguments: {
b: {
Expand Down
16 changes: 2 additions & 14 deletions extensions/godslayerakp/http.js
Original file line number Diff line number Diff line change
Expand Up @@ -289,13 +289,13 @@
'---',
{
opcode: 'onResponse',
blockType: BlockType.HAT,
blockType: BlockType.EVENT,
isEdgeActivated: false,
text: 'when a site responds'
},
{
opcode: 'onFail',
blockType: BlockType.HAT,
blockType: BlockType.EVENT,
isEdgeActivated: false,
text: 'when a request fails'
},
Expand Down Expand Up @@ -593,18 +593,6 @@
return JSON.stringify(object);
}

/* -------- EVENTS -------- */

onResponse() {
// filer olo
return false;
}

onFail() {
// filer olo
return false;
}

/* -------- CONTROL --------- */

setMimeType(args) {
Expand Down
2 changes: 1 addition & 1 deletion extensions/local-storage.js
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@
},
{
opcode: 'whenChanged',
blockType: Scratch.BlockType.HAT,
blockType: Scratch.BlockType.EVENT,
text: 'when another window changes storage',
isEdgeActivated: false
}
Expand Down

0 comments on commit 75289fd

Please sign in to comment.