fix fullscreen polyfill util
This commit is contained in:
parent
a2b48ccc34
commit
b985651e33
1 changed files with 2 additions and 2 deletions
|
@ -42,8 +42,8 @@ export const exitFullscreen = () => {
|
||||||
document[prefix] && document[prefix]();
|
document[prefix] && document[prefix]();
|
||||||
};
|
};
|
||||||
|
|
||||||
export const onFullscreenChange = (event, callback) => {
|
export const onFullscreenChange = (target, action, callback) => {
|
||||||
const index = getPrefix();
|
const index = getPrefix();
|
||||||
const prefix = prefixes.fullscreenChange[index];
|
const prefix = prefixes.fullscreenChange[index];
|
||||||
document[`${event}EventListener`](prefix, callback, false);
|
target[`${action}EventListener`](prefix, callback, false);
|
||||||
};
|
};
|
||||||
|
|
Loading…
Add table
Reference in a new issue