RecyclerViewで区切り線をつけるとき、今まではRecyclerView.ItemDecorationを継承して自前でクラスを実装する必要がありましたが、 Support Library 25.0.0からはandroid.v7.widget.RecyclerView.DividerItemDecoration というAPIが提供されたので、 以下のような感じで簡単に区切り線がつけられるようになりました。 DividerItemDecoration dividerItemDecoration = new DividerItemDecoration(recyclerView.getContext(), new LinearLayoutManager(getActivity()).getOrientation()); recyclerView.addItemDecoration(divi
I am using a android.support.v7.widget.Toolbar and learned from this post how to change the color of the hamburger icon to white, but the up/back arrow remains a dark color when I call setDisplayHomeAsUpEnabled(true); How can I make the arrow white as well? Here is what my toolbar looks like when I call setDisplayHomeAsUpEnabled(): ...and here is the relevant portion of my styles.xml file: <style
これは、カエルコールの送信履歴を削除する機能を開発している時の話です。 ListActivity + ArrayAdapter + カスタムレイアウトの組み合わせで、送信履歴の削除画面を作ってたのですが、どうも onListItemClick のイベントが発生しないのです。 同じ症状に悩んでいる人は、これから紹介する方法を試してみてはどうでしょうか? 下図の CheckBox と TextView をもつリストビューを作成します。 このリストビューの主な動作 ・行をタップすると何行目かをテキストビューに表示します。 ・チェックボックスのON/OFFはスクロールしても保持しています。 ・チェックボックス以外の場所をタップしてもチェックボックスのON/OFFを切り替えます。 行のレイアウトを定義します。 <?xml version="1.0" encoding="utf-8"?> <Linea
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く