add dark/light theming for activities headline

Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
This commit is contained in:
Andy Scherzinger 2019-09-13 17:22:07 +02:00
parent 9eb6fe838e
commit 8aaf29a7c3
No known key found for this signature in database
GPG key ID: 6CADC7E3523C308B
2 changed files with 24 additions and 5 deletions

View file

@ -99,7 +99,6 @@ public class StickyHeaderItemDecoration extends RecyclerView.ItemDecoration {
int headerPosition = adapter.getHeaderPositionForItem(itemPosition);
int layoutId = adapter.getHeaderLayout(itemPosition);
View header = LayoutInflater.from(parent.getContext()).inflate(layoutId, parent, false);
header.setBackgroundColor(Color.WHITE);
adapter.bindHeaderData(header, headerPosition);
return header;
}

View file

@ -1,16 +1,36 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Nextcloud Android client application
Copyright (C) 2019 Sevastyan Savanyuk
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE
License as published by the Free Software Foundation; either
version 3 of the License, or any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU AFFERO GENERAL PUBLIC LICENSE for more details.
You should have received a copy of the GNU Affero General Public
License along with this program. If not, see <http://www.gnu.org/licenses/>.
-->
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical" android:layout_width="match_parent"
android:layout_height="wrap_content">
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:background="@color/bg_default">
<TextView
android:id="@+id/title_header"
android:layout_width="match_parent"
android:layout_height="60dp"
android:layout_marginLeft="@dimen/standard_list_item_size"
android:layout_marginStart="@dimen/standard_list_item_size"
android:layout_marginLeft="@dimen/standard_list_item_size"
android:layout_marginTop="10dp"
android:text="@string/placeholder_filename"
android:textSize="@dimen/activity_list_item_title_header_text_size"/>
android:textSize="@dimen/activity_list_item_title_header_text_size" />
</LinearLayout>