{"action":"created","issue":{"url":"https://api.github.com/repos/florent37/MaterialViewPager/issues/8","labels_url":"https://api.github.com/repos/florent37/MaterialViewPager/issues/8/labels{/name}","comments_url":"https://api.github.com/repos/florent37/MaterialViewPager/issues/8/comments","events_url":"https://api.github.com/repos/florent37/MaterialViewPager/issues/8/events","html_url":"https://github.com/florent37/MaterialViewPager/issues/8","id":73106985,"number":8,"title":"[Question] NullPointerException in AS Preview","user":{"login":"DDerTyp","id":4542310,"avatar_url":"https://avatars.githubusercontent.com/u/4542310?v=3","gravatar_id":"","url":"https://api.github.com/users/DDerTyp","html_url":"https://github.com/DDerTyp","followers_url":"https://api.github.com/users/DDerTyp/followers","following_url":"https://api.github.com/users/DDerTyp/following{/other_user}","gists_url":"https://api.github.com/users/DDerTyp/gists{/gist_id}","starred_url":"https://api.github.com/users/DDerTyp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DDerTyp/subscriptions","organizations_url":"https://api.github.com/users/DDerTyp/orgs","repos_url":"https://api.github.com/users/DDerTyp/repos","events_url":"https://api.github.com/users/DDerTyp/events{/privacy}","received_events_url":"https://api.github.com/users/DDerTyp/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2015-05-04T19:28:52Z","updated_at":"2015-05-04T20:46:06Z","closed_at":null,"body":"Hey,\r\nI am new to your Material ViewPager and not sure if it is an issue or not. When copying your code (from README, \"Usage\") into my layout, this error appears in the Android Studio Design Tab:\r\n\r\n`java.lang.NullPointerException\r\n\tat com.github.florent37.materialviewpager.MaterialViewPager.onFinishInflate(MaterialViewPager.java:70)\r\n\tat android.view.LayoutInflater.rInflate_Original(LayoutInflater.java:814)\r\n\tat android.view.LayoutInflater_Delegate.rInflate(LayoutInflater_Delegate.java:64)\r\n\tat android.view.LayoutInflater.rInflate(LayoutInflater.java:782)\r\n\tat android.view.LayoutInflater.rInflate_Original(LayoutInflater.java:809)\r\n\tat android.view.LayoutInflater_Delegate.rInflate(LayoutInflater_Delegate.java:64)\r\n\tat android.view.LayoutInflater.rInflate(LayoutInflater.java:782)\r\n\tat android.view.LayoutInflater.inflate(LayoutInflater.java:504)\r\n\tat android.view.LayoutInflater.inflate(LayoutInflater.java:385)\r\n\tat com.android.layoutlib.bridge.impl.RenderSessionImpl.inflate(RenderSessionImpl.java:400)\r\n\tat com.android.layoutlib.bridge.Bridge.createSession(Bridge.java:332)\r\n\tat com.android.ide.common.rendering.LayoutLibrary.createSession(LayoutLibrary.java:350)\r\n\tat com.android.tools.idea.rendering.RenderTask$2.compute(RenderTask.java:497)\r\n\tat com.android.tools.idea.rendering.RenderTask$2.compute(RenderTask.java:485)\r\n\tat com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:894)\r\n\tat com.android.tools.idea.rendering.RenderTask.createRenderSession(RenderTask.java:485)\r\n\tat com.android.tools.idea.rendering.RenderTask.render(RenderTask.java:590)\r\n\tat com.intellij.android.designer.designSurface.AndroidDesignerEditorPanel$6.run(AndroidDesignerEditorPanel.java:480)\r\n\tat com.intellij.util.ui.update.MergingUpdateQueue.execute(MergingUpdateQueue.java:320)\r\n\tat com.intellij.util.ui.update.MergingUpdateQueue.execute(MergingUpdateQueue.java:310)\r\n\tat com.intellij.util.ui.update.MergingUpdateQueue$2.run(MergingUpdateQueue.java:254)\r\n\tat com.intellij.util.ui.update.MergingUpdateQueue.flush(MergingUpdateQueue.java:269)\r\n\tat com.intellij.util.ui.update.MergingUpdateQueue.flush(MergingUpdateQueue.java:227)\r\n\tat com.intellij.util.ui.update.MergingUpdateQueue.run(MergingUpdateQueue.java:217)\r\n\tat com.intellij.util.concurrency.QueueProcessor.runSafely(QueueProcessor.java:238)\r\n\tat com.intellij.util.Alarm$Request$1.run(Alarm.java:351)\r\n\tat java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)\r\n\tat java.util.concurrent.FutureTask.run(FutureTask.java:266)\r\n\tat java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)\r\n\tat java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)\r\n\tat java.lang.Thread.run(Thread.java:745)`\r\n\r\nMy Code in Android Studio:\r\n`<RelativeLayout xmlns:android=\"http://schemas.android.com/apk/res/android\"\r\n    xmlns:tools=\"http://schemas.android.com/tools\" xmlns:app=\"http://schemas.android.com/apk/res-auto\"\r\n    android:layout_width=\"match_parent\"\r\n    android:layout_height=\"match_parent\" tools:context=\".MainActivity\">\r\n\r\n    <com.github.florent37.materialviewpager.MaterialViewPager\r\n        android:id=\"@+id/materialViewPager\"\r\n        android:layout_width=\"match_parent\"\r\n        android:layout_height=\"match_parent\"\r\n        app:viewpager_logo=\"@layout/header_logo\"\r\n        app:viewpager_logoMarginTop=\"100dp\"\r\n        app:viewpager_color=\"@color/colorPrimary\"\r\n        app:viewpager_headerHeight=\"200dp\"\r\n        app:viewpager_headerAlpha=\"1.0\"\r\n        app:viewpager_hideLogoWithFade=\"true\"\r\n        app:viewpager_hideToolbarAndTitle=\"true\"\r\n        app:viewpager_enableToolbarElevation=\"true\"\r\n        />\r\n\r\n</RelativeLayout>\r\n`\r\n\r\nWhat can I do?\r\n\r\nRegards,\r\nDDerTyp"},"comment":{"url":"https://api.github.com/repos/florent37/MaterialViewPager/issues/comments/98845558","html_url":"https://github.com/florent37/MaterialViewPager/issues/8#issuecomment-98845558","issue_url":"https://api.github.com/repos/florent37/MaterialViewPager/issues/8","id":98845558,"user":{"login":"DDerTyp","id":4542310,"avatar_url":"https://avatars.githubusercontent.com/u/4542310?v=3","gravatar_id":"","url":"https://api.github.com/users/DDerTyp","html_url":"https://github.com/DDerTyp","followers_url":"https://api.github.com/users/DDerTyp/followers","following_url":"https://api.github.com/users/DDerTyp/following{/other_user}","gists_url":"https://api.github.com/users/DDerTyp/gists{/gist_id}","starred_url":"https://api.github.com/users/DDerTyp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DDerTyp/subscriptions","organizations_url":"https://api.github.com/users/DDerTyp/orgs","repos_url":"https://api.github.com/users/DDerTyp/repos","events_url":"https://api.github.com/users/DDerTyp/events{/privacy}","received_events_url":"https://api.github.com/users/DDerTyp/received_events","type":"User","site_admin":false},"created_at":"2015-05-04T20:46:06Z","updated_at":"2015-05-04T20:46:06Z","body":"Works fine now, thanks!\r\nOne last (issue?):\r\nI got a \"AppCompat does not support the current theme features\"-bug. Had to add ´<item name=\"windowNoTitle\">true</item>´ to the styles under windowActionBar.\r\n\r\nThanks for your patience!"}}