11import { Injectable } from '@angular/core' ;
2- import { Cordova , CordovaFunctionOverride , AwesomeCordovaNativePlugin , Plugin } from '@awesome-cordova-plugins/core' ;
2+ import { Cordova , AwesomeCordovaNativePlugin , Plugin } from '@awesome-cordova-plugins/core' ;
33import { Observable } from 'rxjs' ;
44
55export interface ThreeDeeTouchQuickAction {
66 /**
7- * Type that can be used in the onHomeIconPressed callback
7+ * Type that can be used in the registerQuickActionListener callback
88 */
99 type ?: string ;
1010
@@ -105,7 +105,7 @@ export interface ThreeDeeTouchForceTouch {
105105 *
106106 * this.threeDeeTouch.configureQuickActions(actions);
107107 *
108- * this.threeDeeTouch.onHomeIconPressed ().subscribe(
108+ * this.threeDeeTouch.registerQuickActionListener ().subscribe(
109109 * (payload) => {
110110 * // returns an object that is the button you presed
111111 * console.log('Pressed the ${payload.title} button')
@@ -120,9 +120,9 @@ export interface ThreeDeeTouchForceTouch {
120120 */
121121@Plugin ( {
122122 pluginName : 'ThreeDeeTouch' ,
123- plugin : 'cordova-plugin-3dtouch' ,
123+ plugin : '@herdwatch/ cordova-plugin-3dtouch' ,
124124 pluginRef : 'ThreeDeeTouch' ,
125- repo : 'https://github.com/EddyVerbruggen /cordova-plugin-3dtouch' ,
125+ repo : 'https://github.com/herdwatch-apps /cordova-plugin-3dtouch' ,
126126 platforms : [ 'iOS' ] ,
127127} )
128128@Injectable ( )
@@ -169,8 +169,10 @@ export class ThreeDeeTouch extends AwesomeCordovaNativePlugin {
169169 *
170170 * @returns {Observable<any> } returns an observable that notifies you when he user presses on the home screen icon
171171 */
172- @CordovaFunctionOverride ( )
173- onHomeIconPressed ( ) : Observable < any > {
172+ @Cordova ( {
173+ observable : true ,
174+ } )
175+ registerQuickActionListener ( ) : Observable < ThreeDeeTouchQuickAction > {
174176 return ;
175177 }
176178
0 commit comments