IntelliJ Idea 12.1 で開発している Android アプリに 2 つの画面があります。データベースの一覧画面と入力・編集画面です。編集画面のレイアウト ファイルは IntelliJ デザイナーでレンダリングされますが、リスト画面はレンダリングされません。
リスト XML:
<?xml version="1.0" encoding="utf-8"?>
<com.tjdroid.taskreminder.views.ReminderListView
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical"
>
<LinearLayout
android:orientation="vertical"
android:layout_width="wrap_content"
android:layout_height="wrap_content">
<ListView android:id="@+id/reminder_list"
android:layout_width="fill_parent"
android:layout_height="fill_parent"/>
<TextView android:id="@+id/reminder_empty"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/no_reminders"/>
</LinearLayout>
</com.tjdroid.taskreminder.views.ReminderListView>
XML を編集します。
<?xml version="1.0" encoding="utf-8"?>
<com.tjdroid.taskreminder.views.ReminderEditView
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical"
>
<LinearLayout
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent">
<TextView android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/title"/>
<EditText android:id="@+id/title"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
/>
<Button android:id="@+id/confirm"
android:text="@string/confirm"
android:layout_width="wrap_content"
android:layout_height="wrap_content"/>
</LinearLayout>
</com.tjdroid.taskreminder.views.ReminderEditView>
レンダリング エラー:
java.lang.Exception: Cannot perform rendering
at com.intellij.android.designer.designSurface.AndroidDesignerEditorPanel.configureError(AndroidDesignerEditorPanel.java:543)
at com.intellij.designer.designSurface.DesignerEditorPanel.showError(DesignerEditorPanel.java:404)
at com.intellij.android.designer.designSurface.AndroidDesignerEditorPanel$8$3.run(AndroidDesignerEditorPanel.java:417)
at com.intellij.openapi.application.impl.LaterInvocator$FlushQueue.run(LaterInvocator.java:343)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:251)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:721)
at java.awt.EventQueue.access$200(EventQueue.java:103)
at java.awt.EventQueue$3.run(EventQueue.java:682)
at java.awt.EventQueue$3.run(EventQueue.java:680)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:691)
at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:686)
at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:511)
at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:334)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:242)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:161)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:150)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:146)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:138)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:91)
Caused by: org.jetbrains.android.uipreview.RenderingException
at org.jetbrains.android.uipreview.RenderUtil.renderLayout(RenderUtil.java:195)
at com.intellij.android.designer.designSurface.AndroidDesignerEditorPanel$8.run(AndroidDesignerEditorPanel.java:346)
at com.intellij.util.ui.update.MergingUpdateQueue.execute(MergingUpdateQueue.java:320)
at com.intellij.util.ui.update.MergingUpdateQueue.execute(MergingUpdateQueue.java:310)
at com.intellij.util.ui.update.MergingUpdateQueue$2.run(MergingUpdateQueue.java:254)
at com.intellij.util.ui.update.MergingUpdateQueue.flush(MergingUpdateQueue.java:269)
at com.intellij.util.ui.update.MergingUpdateQueue.flush(MergingUpdateQueue.java:227)
at com.intellij.util.ui.update.MergingUpdateQueue.run(MergingUpdateQueue.java:217)
at com.intellij.util.Alarm$Request$1.run(Alarm.java:289)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:722)
リスト画面で間違っていることはありますか?
ありがとう