Skip to content

Conversation

@daj
Copy link

@daj daj commented Oct 17, 2014

Solves this issue: #2

Example XML usage:
<pl.polidea.view.ZoomView
android:layout_width="match_parent"
android:layout_height="match_parent"
/>

Example stack trace from crash without this fix:

Caused by: android.view.InflateException: Binary XML file line #15: Error inflating class pl.polidea.view.ZoomView
at android.view.LayoutInflater.createView(LayoutInflater.java:603)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:696)

 Caused by: java.lang.NoSuchMethodException: <init> [class android.content.Context, interface android.util.AttributeSet]
        at java.lang.Class.getConstructorOrMethod(Class.java:472)
        at java.lang.Class.getConstructor(Class.java:446)

Solves this issue:
Polidea#2

Example usage:
        <pl.polidea.view.ZoomView
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            />

Example crash without this fix:

Caused by: android.view.InflateException: Binary XML file line Polidea#15: Error inflating class pl.polidea.view.ZoomView
            at android.view.LayoutInflater.createView(LayoutInflater.java:603)
            at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:696)

<snip>

     Caused by: java.lang.NoSuchMethodException: <init> [class android.content.Context, interface android.util.AttributeSet]
            at java.lang.Class.getConstructorOrMethod(Class.java:472)
            at java.lang.Class.getConstructor(Class.java:446)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants