Fix vibration

This commit is contained in:
schmelczerandras 2020-11-03 23:13:52 +01:00
parent f7420777f0
commit b48bf076ad
3 changed files with 24 additions and 11 deletions

View file

@ -28,6 +28,7 @@ import { OptionsHandler } from './scripts/options-handler';
import { hide } from './scripts/helper/hide';
import { show } from './scripts/helper/show';
import { SoundHandler, Sounds } from './scripts/sound-handler';
import { VibrationHandler } from './scripts/vibration-handler';
glMatrix.setMatrixArrayType(Array);
@ -122,6 +123,10 @@ const main = async () => {
};
document.addEventListener('click', firstClickListener);
if (!VibrationHandler.isVibrationEnabledHeuristics) {
hide(document.querySelector("label[for='enable-vibration']") as HTMLElement, true);
}
handleFullScreen(minimize, maximize);
toggleSettingsButton.addEventListener('click', toggleSettings);