fix(backdrop): flicker in UIWebView

This commit is contained in:
Manu Mtz.-Almeida
2016-07-19 22:33:44 +02:00
committed by Adam Bradley
parent ac8e4dce06
commit 44ab527f74
2 changed files with 8 additions and 3 deletions

View File

@ -95,12 +95,16 @@ export class App {
/** /**
* @private * @private
*/ */
setScrollDisabled(disabled: boolean) { setScrollDisabled(disableScroll: boolean) {
let enabled = this._config.get('canDisableScroll', true);
if (!enabled) {
return;
}
if (!this.appRoot) { if (!this.appRoot) {
console.error('appRoot is missing, scrolling can not be enabled/disabled'); console.error('appRoot is missing, scrolling can not be enabled/disabled');
return; return;
} }
this.appRoot.disableScroll = disabled; this.appRoot.disableScroll = disableScroll;
} }
/** /**

View File

@ -104,7 +104,8 @@ Platform.register({
swipeBackEnabled: isIOSDevice, swipeBackEnabled: isIOSDevice,
swipeBackThreshold: 40, swipeBackThreshold: 40,
tapPolyfill: isIOSDevice, tapPolyfill: isIOSDevice,
virtualScrollEventAssist: !(win.indexedDB) virtualScrollEventAssist: !(win.indexedDB),
canDisableScroll: !!(win.indexedDB),
}, },
isMatch(p: Platform): boolean { isMatch(p: Platform): boolean {
return p.isPlatformMatch('ios', ['iphone', 'ipad', 'ipod'], ['windows phone']); return p.isPlatformMatch('ios', ['iphone', 'ipad', 'ipod'], ['windows phone']);