2013-06-05 32 views
0

我正尝试使用org.panel包在android中实现自上而下滑动抽屉。但是我收到了一些错误。使用org.panel包时出现资源标识符错误

Multiple annotations found at this line: 
- error: No resource identifier found for attribute 'linearFlying' in package 'org.panel' 
- error: No resource identifier found for attribute 'position' in package 'org.panel' 
- error: No resource identifier found for attribute 'closedHandle' in package 
'org.panel' 
- error: No resource identifier found for attribute 'animationDuration' in package 
'org.panel' 
- error: No resource identifier found for attribute 'openedHandle' in package 
'org.panel' 

下面是我找到的XML代码,我试图运行:

<?xml version="1.0" encoding="utf-8"?> 
    <FrameLayout 
xmlns:android="http://schemas.android.com/apk/res/android" 
xmlns:panel="http://schemas.android.com/apk/res/org.panel" 
android:layout_width="fill_parent" 
android:layout_height="fill_parent"> 

<LinearLayout 
    android:orientation="vertical" 
    android:layout_width="fill_parent" 
    android:layout_height="fill_parent"> 
    <org.panel.Panel 
     android:layout_width="fill_parent" 
     android:layout_height="wrap_content" 
     android:id="@+id/topPanel" 
     android:paddingBottom="20dip" 
     panel:position="top" 
     panel:animationDuration="1000" 
     panel:linearFlying="true" 
     panel:openedHandle="@drawable/ribbon" 
     panel:closedHandle="@drawable/ribbon"> 
     <Button 
      android:id="@+id/panelHandle" 
      android:layout_width="fill_parent" 
      android:layout_height="33dip" /> 
     <LinearLayout 
      android:id="@+id/panelContent" 
      android:orientation="vertical" 
      android:layout_width="fill_parent" 
      android:layout_height="wrap_content"> 
      <TextView 
       android:layout_width="fill_parent" 
       android:layout_height="wrap_content" 
       android:gravity="center" 
       android:text="From the Top -> Down" 
       android:textSize="16dip" 
       android:padding="4dip" 
       android:textStyle="bold" /> 

      <ImageView 
       android:src="@drawable/ribbon" 
       android:layout_gravity="center" 
       android:layout_width="wrap_content" 
       android:layout_height="wrap_content" /> 

     </LinearLayout> 
    </org.panel.Panel> 

</LinearLayout> 
</FrameLayout> 

如何摆脱这些错误的?

回答

0

图片资源?

我没有在您的XML中找到对这些名称的引用。

那些看起来像图像名称。

您是否在图像名称或其他资源文件(在res目录中)中使用了大写字母。使用的可能是[a-z1-9_]

+0

不,他们不是图像名称。它们是XML中的属性 –

+0

糟糕!我的不好,让我再看看。 –

1

变化

xmlns:panel="http://schemas.android.com/apk/res/org.panel 

一个

xmlns:panel="http://schemas.android.com/apk/src/org.panel 

字符它的ressrc的变化。

相关问题