mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-22 05:21:52 +08:00
Merge pull request #9194 from amuramoto/gesture
fix(gesture): pass type to hammer.get() so pinch and rotate can be en…
This commit is contained in:
@ -38,7 +38,7 @@ export class Gesture {
|
||||
|
||||
on(type: string, cb: Function) {
|
||||
if (type === 'pinch' || type === 'rotate') {
|
||||
this._hammer.get('pinch').set({enable: true});
|
||||
this._hammer.get(type).set({enable: true});
|
||||
}
|
||||
this._hammer.on(type, cb);
|
||||
(this._callbacks[type] || (this._callbacks[type] = [])).push(cb);
|
||||
|
Reference in New Issue
Block a user