我正在尝试在 model.eachAttribute((key, meta) => {
const keyType = expected[key];
assert.ok(expected[key], `the "${key}" property is defined.`);
assert.equal(meta.type, keyType, `the "${key}" has the attribute type "${keyType}".`);
});
内执行按钮点击操作,但它第二次正在运行,但第一次没有点击。
有人能说什么错吗?
SwipeRefreshLayout
使用Butter Knife获得它的身份:
<android.support.v4.widget.SwipeRefreshLayout
android:id="@+id/swipeLayout"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:behavior_overlapTop="38dp"
app:layout_behavior="@string/appbar_scrolling_view_behavior">
<android.support.v4.widget.NestedScrollView
android:id="@+id/nestedScrollView"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scrollbars="none">
<android.support.v7.widget.CardView
android:id="@+id/cardview"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_margin="@dimen/margin"
app:cardBackgroundColor="@color/white"
app:cardCornerRadius="10dp"
app:cardElevation="4dp"
app:contentPaddingBottom="16dp"
app:contentPaddingLeft="0dp"
app:contentPaddingRight="0dp">
// My button code is here
<Button
android:id="@+id/loadMore"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/recyclerViewJS"
android:layout_margin="30dp"
android:background="@drawable/dashboard_bg"
android:gravity="center"
android:padding="@dimen/padding"
android:text="Load More"
android:textColor="@color/white"
android:visibility="gone" />
</android.support.v7.widget.CardView>
</android.support.v4.widget.NestedScrollView>
</android.support.v4.widget.SwipeRefreshLayout>
我的按钮点击操作在这里:
@BindView(R.id.loadMore)
Button loadMore;
我提到this但没有用。
提前致谢。