I have a GlowPadView (https://github.com/nadavfima/GlowPadView/) in my layout's XML but I get the following error:
The following classes could not be instantiated:
- com.fima.glowpadview.GlowPadView (Open Class, Show Error Log) See the Error Log (Window > Show View) for more details. Tip: Use View.isInEditMode() in your custom views to skip code when shown in Eclipse
java.lang.IllegalStateException: Must specify at least one target drawable
at com.fima.glowpadview.GlowPadView.<init>(GlowPadView.java:247)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0( at sun.reflect.NativeConstructorAccessorImpl.newInstance( at sun.reflect.DelegatingConstructorAccessorImpl.newInstance( at java.lang.reflect.Constructor.newInstance( at com.android.ide.eclipse.adt.internal.editors.layout.ProjectCallback.instantiateClass(ProjectCallback.java:422)
at com.android.ide.eclipse.adt.internal.editors.layout.ProjectCallback.loadView(ProjectCallback.java:179)
at android.view.BridgeInflater.loadCustomView(BridgeInflater.java:207)
at android.view.BridgeInflater.createViewFromTag(BridgeInflater.java:135)
at android.view.LayoutInflater.rInflate_Original(LayoutInflater.java:755)
at android.view.LayoutInflater_Delegate.rInflate(LayoutInflater_Delegate.java:64)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:727)
at android.view.LayoutInflater.inflate(LayoutInflater.java:492)
at android.view.LayoutInflater.inflate(LayoutInflater.java:373)
This is the code I wrote in XML:
<com.fima.glowpadview.GlowPadView
android:id="@+id/glow_pad_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_centerHorizontal="true"
android:layout_gravity="center_vertical"
android:layout_marginBottom="@dimen/glowpadview_margin_bottom"
android:focusable="true"
android:gravity="center"
glowpad:directionDescriptions="@array/snooze_dismiss_direction_descriptions"
glowpad:feedbackCount="1"
glowpad:glowRadius="@dimen/glowpadview_glow_radius"
glowpad:handleDrawable="@drawable/ic_alarm_alert_touch_handle"
glowpad:innerRadius="@dimen/glowpadview_inner_radius"
glowpad:outerRadius="@dimen/glowpadview_target_placement_radius"
glowpad:outerRingDrawable="@drawable/ic_alarm_alert_outerring"
glowpad:pointDrawable="@drawable/ic_lockscreen_glowdot"
glowpad:snapMargin="@dimen/glowpadview_snap_margin"
glowpad:targetDescriptions="@array/snooze_dismiss_descriptions"
glowpad:targetDrawables="@array/snooze_dismiss_drawables"
glowpad:vibrationDuration="20" />
I imported the project and added it to my build path as well in Android -> Library.