2014-08-28 94 views
0

请我需要拉列表的同样的效果下增加新的空项目并对其进行编辑,并在列表项失去焦点,它将被保存添加新的可编辑的项目列表视图拉列表时向下

请检查以下Android应用明白我想要做

https://play.google.com/store/apps/details?id=com.xuchdeid.clear&hl=en

,如果任何一个知道我可以遵循,使这种行为让我知道任何算法的任何库。

+0

在这部分的功能将可能也有一些你有动画和一些图书馆做。 – Piyush 2014-08-28 08:57:25

回答

0

我发现这一个

https://github.com/47deg/android-swipelistview

https://www.youtube.com/watch?v=E0352OH488M

image

>XML Usage 

如果你决定使用SwipeListView作为视图,您可以像这样在你的XML布局定义它:

<com.fortysevendeg.swipelistview.SwipeListView 
     xmlns:swipe="http://schemas.android.com/apk/res-auto" 
     android:id="@+id/example_lv_list" 
     android:listSelector="#00000000" 
     android:layout_width="fill_parent" 
     android:layout_height="wrap_content" 
     swipe:swipeFrontView="@+id/front" 
     swipe:swipeBackView="@+id/back" 
     swipe:swipeActionLeft="[reveal | dismiss]" 
     swipe:swipeActionRight="[reveal | dismiss]" 
     swipe:swipeMode="[none | both | right | left]" 
     swipe:swipeCloseAllItemsWhenMoveList="[true | false]" 
     swipe:swipeOpenOnLongPress="[true | false]" 
     swipe:swipeAnimationTime="[miliseconds]" 
     swipe:swipeOffsetLeft="[dimension]" 
     swipe:swipeOffsetRight="[dimension]" 
     /> 
  1. swipeFrontView - 需要 - 前视图ID。
  2. swipeBackView - 必需 - 后视图标识。
  3. swipeActionLeft - 可选 - 向左扫动作默认: '揭露'
  4. swipeActionRight - 可选 - 向右扫动作默认: '揭露'
  5. swipeMode - 手势启用或 '无'。默认:'both'
  6. swipeCloseAllItemsWhenMoveList - 关闭列表动作中显示的项目。默认值:'true'
  7. swipeOpenOnLongPress - 长按显示默认值:'true'
  8. swipeAnimationTime - item drop动画时间。默认:Android的配置
  9. swipeOffsetLeft - 左侧偏移
  10. swipeOffsetRight - 右偏移