mirror of
https://github.com/nextcloud/talk-android
synced 2025-06-20 20:19:42 +01:00
Icons & support for pass exposure
Signed-off-by: Mario Danic <mario@lovelyhq.com>
This commit is contained in:
parent
955de43b45
commit
5dd6ca776c
@ -114,6 +114,11 @@ public class CallItem extends AbstractFlexibleItem<CallItem.RoomItemViewHolder>
|
||||
System.currentTimeMillis(), 0, DateUtils.FORMAT_ABBREV_RELATIVE));
|
||||
}
|
||||
|
||||
if (room.hasPassword) {
|
||||
holder.passwordProtectedImageView.setVisibility(View.VISIBLE);
|
||||
} else {
|
||||
holder.passwordProtectedImageView.setVisibility(View.GONE);
|
||||
}
|
||||
|
||||
switch (room.getType()) {
|
||||
case ROOM_TYPE_ONE_TO_ONE_CALL:
|
||||
@ -140,12 +145,26 @@ public class CallItem extends AbstractFlexibleItem<CallItem.RoomItemViewHolder>
|
||||
}
|
||||
break;
|
||||
case ROOM_GROUP_CALL:
|
||||
GlideApp.with(NextcloudTalkApplication.getSharedApplication().getApplicationContext())
|
||||
.asBitmap()
|
||||
.skipMemoryCache(true)
|
||||
.diskCacheStrategy(DiskCacheStrategy.NONE)
|
||||
.load(R.drawable.ic_group_white_24px)
|
||||
.centerInside()
|
||||
.apply(RequestOptions.bitmapTransform(new CircleCrop()))
|
||||
.into(holder.avatarImageView);
|
||||
holder.avatarImageView.setVisibility(View.VISIBLE);
|
||||
holder.avatarImageView.setImageResource(R.drawable.ic_group_black_24dp);
|
||||
break;
|
||||
case ROOM_PUBLIC_CALL:
|
||||
GlideApp.with(NextcloudTalkApplication.getSharedApplication().getApplicationContext())
|
||||
.asBitmap()
|
||||
.skipMemoryCache(true)
|
||||
.diskCacheStrategy(DiskCacheStrategy.NONE)
|
||||
.load(R.drawable.ic_link_white_24px)
|
||||
.centerInside()
|
||||
.apply(RequestOptions.bitmapTransform(new CircleCrop()))
|
||||
.into(holder.avatarImageView);
|
||||
holder.avatarImageView.setVisibility(View.VISIBLE);
|
||||
holder.avatarImageView.setImageResource(R.drawable.ic_link_black_24dp);
|
||||
break;
|
||||
default:
|
||||
holder.avatarImageView.setVisibility(View.GONE);
|
||||
@ -172,6 +191,8 @@ public class CallItem extends AbstractFlexibleItem<CallItem.RoomItemViewHolder>
|
||||
public ImageView avatarImageView;
|
||||
@BindView(R.id.more_menu)
|
||||
public ImageButton moreMenuButton;
|
||||
@BindView(R.id.password_protected_image_view)
|
||||
ImageView passwordProtectedImageView;
|
||||
|
||||
/**
|
||||
* Default constructor.
|
||||
|
@ -1,9 +0,0 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:viewportWidth="24.0"
|
||||
android:viewportHeight="24.0">
|
||||
<path
|
||||
android:fillColor="#FF000000"
|
||||
android:pathData="M16,11c1.66,0 2.99,-1.34 2.99,-3S17.66,5 16,5c-1.66,0 -3,1.34 -3,3s1.34,3 3,3zM8,11c1.66,0 2.99,-1.34 2.99,-3S9.66,5 8,5C6.34,5 5,6.34 5,8s1.34,3 3,3zM8,13c-2.33,0 -7,1.17 -7,3.5L1,19h14v-2.5c0,-2.33 -4.67,-3.5 -7,-3.5zM16,13c-0.29,0 -0.62,0.02 -0.97,0.05 1.16,0.84 1.97,1.97 1.97,3.45L17,19h6v-2.5c0,-2.33 -4.67,-3.5 -7,-3.5z"/>
|
||||
</vector>
|
10
app/src/main/res/drawable/ic_group_white_24px.xml
Normal file
10
app/src/main/res/drawable/ic_group_white_24px.xml
Normal file
@ -0,0 +1,10 @@
|
||||
<vector android:autoMirrored="true" android:height="24dp"
|
||||
android:viewportHeight="24.0" android:viewportWidth="24.0"
|
||||
android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<path android:fillColor="#D5D5D5" android:fillType="evenOdd"
|
||||
android:pathData="M0,0l24,0l0,24l-24,0z"
|
||||
android:strokeColor="#00000000" android:strokeWidth="1"/>
|
||||
<path android:fillColor="#FFFFFF" android:fillType="nonZero"
|
||||
android:pathData="M15.273,10.909C16.631,10.909 17.719,9.813 17.719,8.455C17.719,7.096 16.631,6 15.273,6C13.915,6 12.818,7.096 12.818,8.455C12.818,9.813 13.915,10.909 15.273,10.909ZM8.727,10.909C10.085,10.909 11.174,9.813 11.174,8.455C11.174,7.096 10.085,6 8.727,6C7.369,6 6.273,7.096 6.273,8.455C6.273,9.813 7.369,10.909 8.727,10.909ZM8.727,12.545C6.821,12.545 3,13.503 3,15.409L3,17.455L14.455,17.455L14.455,15.409C14.455,13.503 10.634,12.545 8.727,12.545ZM15.273,12.545C15.035,12.545 14.765,12.562 14.479,12.586C15.428,13.274 16.091,14.198 16.091,15.409L16.091,17.455L21,17.455L21,15.409C21,13.503 17.179,12.545 15.273,12.545Z"
|
||||
android:strokeColor="#00000000" android:strokeWidth="1"/>
|
||||
</vector>
|
10
app/src/main/res/drawable/ic_link_white_24px.xml
Normal file
10
app/src/main/res/drawable/ic_link_white_24px.xml
Normal file
@ -0,0 +1,10 @@
|
||||
<vector android:autoMirrored="true" android:height="24dp"
|
||||
android:viewportHeight="24.0" android:viewportWidth="24.0"
|
||||
android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<path android:fillColor="#D5D5D5" android:fillType="evenOdd"
|
||||
android:pathData="M0,0l24,0l0,24l-24,0z"
|
||||
android:strokeColor="#00000000" android:strokeWidth="1"/>
|
||||
<path android:fillColor="#FFFFFF" android:fillType="nonZero"
|
||||
android:pathData="M3.9,12C3.9,10.29 5.29,8.9 7,8.9L11,8.9L11,7L7,7C4.24,7 2,9.24 2,12C2,14.76 4.24,17 7,17L11,17L11,15.1L7,15.1C5.29,15.1 3.9,13.71 3.9,12ZM8,13L16,13L16,11L8,11L8,13ZM17,7L13,7L13,8.9L17,8.9C18.71,8.9 20.1,10.29 20.1,12C20.1,13.71 18.71,15.1 17,15.1L13,15.1L13,17L17,17C19.76,17 22,14.76 22,12C22,9.24 19.76,7 17,7Z"
|
||||
android:strokeColor="#00000000" android:strokeWidth="1"/>
|
||||
</vector>
|
@ -21,5 +21,5 @@
|
||||
<vector android:autoMirrored="true" android:height="24dp"
|
||||
android:viewportHeight="24.0" android:viewportWidth="24.0"
|
||||
android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<path android:fillColor="#FF000000" android:pathData="M3.9,12c0,-1.71 1.39,-3.1 3.1,-3.1h4L11,7L7,7c-2.76,0 -5,2.24 -5,5s2.24,5 5,5h4v-1.9L7,15.1c-1.71,0 -3.1,-1.39 -3.1,-3.1zM8,13h8v-2L8,11v2zM17,7h-4v1.9h4c1.71,0 3.1,1.39 3.1,3.1s-1.39,3.1 -3.1,3.1h-4L13,17h4c2.76,0 5,-2.24 5,-5s-2.24,-5 -5,-5z"/>
|
||||
<path android:fillColor="#FF000000" android:pathData="M17,10.5V7c0,-0.55 -0.45,-1 -1,-1H4c-0.55,0 -1,0.45 -1,1v10c0,0.55 0.45,1 1,1h12c0.55,0 1,-0.45 1,-1v-3.5l4,4v-11l-4,4z"/>
|
||||
</vector>
|
25
app/src/main/res/drawable/ic_vpn_key_black_24dp.xml
Normal file
25
app/src/main/res/drawable/ic_vpn_key_black_24dp.xml
Normal file
@ -0,0 +1,25 @@
|
||||
<!--
|
||||
~ Nextcloud Talk application
|
||||
~
|
||||
~ @author Mario Danic
|
||||
~ Copyright (C) 2017 Mario Danic <mario@lovelyhq.com>
|
||||
~
|
||||
~ This program is free software: you can redistribute it and/or modify
|
||||
~ it under the terms of the GNU General Public License as published by
|
||||
~ the Free Software Foundation, either version 3 of the License, or
|
||||
~ at your option) 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 General Public License for more details.
|
||||
~
|
||||
~ You should have received a copy of the GNU General Public License
|
||||
~ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
-->
|
||||
|
||||
<vector android:autoMirrored="true" android:height="24dp"
|
||||
android:viewportHeight="24.0" android:viewportWidth="24.0"
|
||||
android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<path android:fillColor="#FF000000" android:pathData="M12.65,10C11.83,7.67 9.61,6 7,6c-3.31,0 -6,2.69 -6,6s2.69,6 6,6c2.61,0 4.83,-1.67 5.65,-4H17v4h4v-4h2v-4H12.65zM7,14c-1.1,0 -2,-0.9 -2,-2s0.9,-2 2,-2 2,0.9 2,2 -0.9,2 -2,2z"/>
|
||||
</vector>
|
@ -26,20 +26,38 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/item_height">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/avatar_image"
|
||||
android:layout_width="@dimen/avatar_size"
|
||||
android:layout_height="@dimen/avatar_size"
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/frame_layout"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginEnd="@dimen/margin_between_elements"
|
||||
android:layout_marginStart="@dimen/activity_horizontal_margin"/>
|
||||
android:layout_marginStart="@dimen/activity_horizontal_margin">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/avatar_image"
|
||||
android:layout_width="@dimen/avatar_size"
|
||||
android:layout_height="@dimen/avatar_size"/>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/password_protected_image_view"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_gravity="bottom|end"
|
||||
android:src="@drawable/ic_vpn_key_black_24dp"
|
||||
android:tint="@color/nc_material_yellow"
|
||||
android:tintMode="src_in"
|
||||
android:visibility="visible"/>
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/linear_layout"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerInParent="true"
|
||||
android:layout_toEndOf="@id/avatar_image"
|
||||
android:layout_marginStart="@dimen/margin_between_elements"
|
||||
android:layout_toEndOf="@id/frame_layout"
|
||||
android:layout_toStartOf="@+id/more_menu"
|
||||
android:orientation="vertical">
|
||||
|
||||
|
@ -4,7 +4,7 @@
|
||||
<item
|
||||
android:id="@+id/navigation_calls"
|
||||
android:checked="true"
|
||||
android:icon="@drawable/ic_call_black_24dp"
|
||||
android:icon="@drawable/ic_videocam_black_24dp"
|
||||
android:title="@string/nc_bottom_navigation_title_calls"/>
|
||||
|
||||
<item
|
||||
|
@ -9,5 +9,6 @@
|
||||
<color name="nc_white_color">@color/per70white</color>
|
||||
<color name="nc_white_color_complete">#FFFFFF</color>
|
||||
<color name="nc_light_blue_color">#7FC0E3</color>
|
||||
<color name="nc_material_yellow">#FFEB3B</color>
|
||||
</resources>
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user