Example usage for android.widget ViewSwitcher setOnClickListener

List of usage examples for android.widget ViewSwitcher setOnClickListener

Introduction

In this page you can find the example usage for android.widget ViewSwitcher setOnClickListener.

Prototype

public void setOnClickListener(@Nullable OnClickListener l) 

Source Link

Document

Register a callback to be invoked when this view is clicked.

Usage

From source file:org.thoughtcrime.securesms.conversation.ConversationFragment.java

private void initializeLoadMoreView(ViewSwitcher loadMoreView) {
    loadMoreView.setOnClickListener(v -> {
        Bundle args = new Bundle();
        args.putInt(KEY_LIMIT, 0);//from  w  ww . j a v  a2  s . c o m
        getLoaderManager().restartLoader(0, args, ConversationFragment.this);
        loadMoreView.showNext();
        loadMoreView.setOnClickListener(null);
    });
}