Wizcorp / phonegap-plugin-wizCanvas

WizCanvas allows a developer to create a ultra-performant native canvas component. The view is based on the Ejecta framework and has WebGL support.
MIT License
43 stars 13 forks source link

cordova compile error #46

Open bennerhq opened 9 years ago

bennerhq commented 9 years ago

Hello,

I have added wizCanvas to my Cordova (v 5.3.1) projekt ... When "cordova build" i get these compile error:

[...]/platforms/android/src/jp/wizcorp/phonegap/plugin/wizCanvas/WizCanvasPlugin.java:506: error: cannot find symbol int _height = webView.getHeight(); ^ symbol: method getHeight() location: variable webView of type CordovaWebView [...]/platforms/android/src/jp/wizcorp/phonegap/plugin/wizCanvas/WizCanvasPlugin.java:507: error: cannot find symbol int _width = webView.getWidth(); ^ symbol: method getWidth() location: variable webView of type CordovaWebView [...]/platforms/android/src/jp/wizcorp/phonegap/plugin/wizCanvas/WizCanvasPlugin.java:600: error: cannot find symbol LinearLayout.LayoutParams layoutParams = (LinearLayout.LayoutParams) webView.getLayoutParams(); ^ symbol: method getLayoutParams() location: variable webView of type CordovaWebView [...]/platforms/android/src/jp/wizcorp/phonegap/plugin/wizCanvas/WizCanvasPlugin.java:606: error: cannot find symbol webView.setLayoutParams(layoutParams);

Can anybody plase help me?

Cheers BR/benner

LokeshPatel commented 8 years ago

Hi,

Replease : LinearLayout.LayoutParams layoutParams = (LinearLayout.LayoutParams) webView.getLayoutParams();

with

LinearLayout.LayoutParams layoutParams = (LinearLayout.LayoutParams) ((ViewGroup) this.webView.getView().getParent()).getLayoutParams();

WebView is replaced with ((ViewGroup) this.webView.getView().getParent())