Skip to content

Commit 759a2b0

Browse files
committed
Add ajiFillRect
1 parent 00d800b commit 759a2b0

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

example/player/js/main.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ function setup() {
99

1010
function loop() {
1111
ajiContext.fillStyle = "#666666";
12-
ajiContext.fillRect(0, 0, AJIPACK_WIDTH, AJIPACK_HEIGHT);
12+
ajiFillRect(0, 0, AJIPACK_WIDTH, AJIPACK_HEIGHT);
1313
ajiContext.font = "20pt sans-serif";
1414
ajiContext.fillStyle = "#fff";
1515
ajiDrawText("Hello, world!", x, 120);

player.js

+4
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,10 @@ function ajiMain() {
4242
requestAnimationFrame(ajiMain);
4343
}
4444

45+
function ajiFillRect(x, y, w, h) {
46+
ajiContext.fillRect(x, y, w, h);
47+
}
48+
4549
function ajiDrawText(text, x, y) {
4650
ajiContext.fillText(text, x, y);
4751
}

0 commit comments

Comments
 (0)