Android Creating Custom Views

阅读更多
换一批

Tip: Use View.isInEditMode() in your custom views

07-09

在哪个地方加上if(!isInEditMode())? 我该怎么找到错误呢nnnnMissing styles. Is the correct theme chosen for this layout?nUse the Theme combo box above the layout to choose a different layout, or fix the theme style references.nnFailed to parse file D:\rupeng.workPlace\androidProject1\appcompat_v7\res\layout\select_dialog_item_material.xmlnCouldn't find theme resource ?attr/listPreferredItemPaddingLeft for the current themenCouldn't find theme resource ?attr/listPreferredItemPaddingRight for the current themenCouldn't find theme resource ?attr/listPreferredItemHeightSmall for the current themen"?attr/listPreferredItemPaddingLeft" in attribute "paddingLeft" is not a valid format.n"?attr/listPreferredItemPaddingRight" in attribute "paddingRight" is not a valid format.n"?attr/listPreferredItemHeightSmall" in attribute "minHeight" is not a valid format.nCouldn't find theme resource ?attr/textAppearanceListItemSmall for the current themenException details are logged in Window > Show View > Error LognThe following classes could not be found:n- TextView (Change to android.widget.TextView, Fix Build Path, Edit XML)nThe following classes could not be instantiated:n- com.handmark.pulltorefresh.library.PullToRefreshListView (Open Class, Show Error Log)nSee the Error Log (Window > Show View) for more details.nTip: Use View.isInEditMode() in your custom views to skip code when shown in Eclipsennandroid.view.InflateExceptionn at android.view.BridgeInflater.createViewFromTag(BridgeInflater.java:135)n at android.view.LayoutInflater.inflate(LayoutInflater.java:466)n at android.view.LayoutInflater.inflate(LayoutInflater.java:372)n at android.view.BridgeInflater.inflate(BridgeInflater.java:183)n at com.handmark.pulltorefresh.library.internal.LoadingLayout.(LoadingLayout.java:78)n at com.handmark.pulltorefresh.library.internal.RotateLoadingLayout.(RotateLoadingLayout.java:42)n at com.handmark.pulltorefresh.library.PullToRefreshBase$AnimationStyle.createLoadingLayout(PullToRefreshBase.java:1545)n at com.handmark.pulltorefresh.library.PullToRefreshBase.createLoadingLayout(PullToRefreshBase.java:676)n at com.handmark.pulltorefresh.library.PullToRefreshBase.init(PullToRefreshBase.java:1286)n at com.handmark.pulltorefresh.library.PullToRefreshBase.(PullToRefreshBase.java:116)n at com.handmark.pulltorefresh.library.PullToRefreshAdapterViewBase.(PullToRefreshAdapterViewBase.java:74)n at com.handmark.pulltorefresh.library.PullToRefreshListView.(PullToRefreshListView.java:49)n at sun.reflect.NativeConstructorAccessorImpl.newInstance0(NativeConstructorAccessorImpl.java:-2)n at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)n at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)n at java.lang.reflect.Constructor.newInstance(Constructor.java:525)n at com.android.ide.eclipse.adt.internal.editors.layout.ProjectCallback.instantiateClass(ProjectCallback.java:438)n at com.android.ide.eclipse.adt.internal.editors.layout.ProjectCallback.loadView(ProjectCallback.java:190)n at android.view.BridgeInflater.loadCustomView(BridgeInflater.java:206)n at android.view.BridgeInflater.createViewFromTag(BridgeInflater.java:131)n at android.view.LayoutInflater.rInflate_Original(LayoutInflater.java:739)n at android.view.LayoutInflater_Delegate.rInflate(LayoutInflater_Delegate.java:64)n at android.view.LayoutInflater.rInflate(LayoutInflater.java:711)n at android.view.LayoutInflater.inflate(LayoutInflater.java:489)n at android.view.LayoutInflater.inflate(LayoutInflater.java:372)n

没有更多推荐了,返回首页