-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Done #1 #35
Open
dmilkov97
wants to merge
3
commits into
Android-Developer-Basic:master
Choose a base branch
from
dmilkov97:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Done #1 #35
Changes from 1 commit
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
package otus.gpb.recyclerview | ||
|
||
import android.view.LayoutInflater | ||
import android.view.View | ||
import android.view.ViewGroup | ||
import android.widget.ImageButton | ||
import android.widget.ImageView | ||
import android.widget.TextView | ||
import androidx.constraintlayout.widget.ConstraintLayout | ||
import androidx.recyclerview.widget.RecyclerView | ||
import com.google.android.material.imageview.ShapeableImageView | ||
|
||
class ChatAdapter (private val items: MutableList<ChatItem>) : RecyclerView.Adapter<ChatAdapter.ChatViewHolder>() { | ||
|
||
override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): ChatViewHolder { | ||
val view: View = LayoutInflater.from(parent.context).inflate(R.layout.chat_item, parent, false) | ||
return ChatViewHolder(view) | ||
} | ||
|
||
fun removeAt(index: Int) { | ||
items.removeAt(index) | ||
notifyItemRemoved(index) | ||
} | ||
|
||
override fun getItemCount(): Int { | ||
return items.size | ||
} | ||
|
||
override fun onBindViewHolder(holder: ChatViewHolder, position: Int) { | ||
holder.bind(items[position]) | ||
} | ||
|
||
class ChatViewHolder(itemView: View) : RecyclerView.ViewHolder(itemView) { | ||
|
||
private val mainImg: ShapeableImageView by lazy { itemView.findViewById(R.id.image_icon) } | ||
private val mainName: TextView by lazy { itemView.findViewById(R.id.text_view_name) } | ||
private val bottomName: TextView by lazy { itemView.findViewById(R.id.text_view_name_bottom) } | ||
private val imgMessage: ImageView by lazy {itemView.findViewById(R.id.img_message) } | ||
private val message: TextView by lazy { itemView.findViewById(R.id.text_view_message) } | ||
private val imgVerified: ImageView by lazy { itemView.findViewById(R.id.img_verified) } | ||
private val imgMuted: ImageView by lazy { itemView.findViewById(R.id.img_noise) } | ||
private val time: TextView by lazy { itemView.findViewById(R.id.text_view_time) } | ||
private val imgFixed: ImageButton by lazy { itemView.findViewById(R.id.img_button_fixed) } | ||
private val imgStateMessage: ImageView by lazy { itemView.findViewById(R.id.img_readed) } | ||
|
||
fun bind(itemChat: ChatItem) { | ||
mainName.text = itemChat.mainName | ||
mainImg.setImageResource(itemChat.mainImg) | ||
message.text = itemChat.textMessage | ||
time.text = itemChat.textTime | ||
imgStateMessage.setImageResource(itemChat.stateMessage) | ||
|
||
if (itemChat.isVerified) { | ||
imgVerified.setImageResource(R.drawable.verif) | ||
} | ||
else { | ||
imgVerified.visibility = View.GONE | ||
} | ||
if (itemChat.isMuted) { | ||
imgMuted.setImageResource(R.drawable.muted) | ||
} | ||
if (itemChat.isFavour) { | ||
imgFixed.setImageResource(R.drawable.favour) | ||
} | ||
if (itemChat.secondaryName != null) { | ||
bottomName.text = itemChat.secondaryName | ||
} | ||
else { | ||
bottomName.visibility = View.GONE | ||
} | ||
if (itemChat.messageImg != null) { | ||
imgMessage.setImageResource(itemChat.messageImg) | ||
} | ||
else { | ||
val params = message.layoutParams as ConstraintLayout.LayoutParams | ||
params.marginStart = 0 | ||
message.layoutParams = params | ||
} | ||
} | ||
} | ||
|
||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
package otus.gpb.recyclerview | ||
|
||
import androidx.annotation.DrawableRes | ||
|
||
data class ChatItem( | ||
val mainName: String, | ||
val secondaryName: String?, | ||
val textMessage: String, | ||
val textTime: String, | ||
val isMuted: Boolean, | ||
val isVerified: Boolean, | ||
@DrawableRes val messageImg: Int?, | ||
@DrawableRes val stateMessage: Int, | ||
val isFavour: Boolean, | ||
@DrawableRes val mainImg: Int | ||
) |
53 changes: 53 additions & 0 deletions
53
app/src/main/java/otus/gpb/recyclerview/GenerateChatItems.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
package otus.gpb.recyclerview | ||
|
||
import kotlin.random.Random | ||
|
||
class GenerateChatItems { | ||
private val list = mutableListOf<ChatItem>() | ||
|
||
fun getList(): MutableList<ChatItem>{ | ||
for (i in 1..20) { | ||
val mainName = getRandomMainName() | ||
val secondaryName = getRandomSecondaryName() | ||
val textMessage = getRandomMessage() | ||
val textTime = getTextTime() | ||
val isMuted = Random.nextBoolean() | ||
val isVerified = Random.nextBoolean() | ||
val messageImg = getRandomImgMessage() | ||
val stateMessage = getRandomState() | ||
val isFavour = Random.nextBoolean() | ||
val mainImg = getRandomAvatar() | ||
list.add(ChatItem(mainName, secondaryName, textMessage, textTime, isMuted, isVerified, messageImg, stateMessage, isFavour, mainImg)) | ||
} | ||
return list | ||
} | ||
|
||
private fun getRandomMainName(): String { | ||
val list = listOf("Denis Milkov", "Elton", "Ivan Ivanov", "Elon Mask", "Oliver", "Grozny", "Kotlin", "Petr", "Hozy") | ||
return list.random() | ||
} | ||
private fun getRandomSecondaryName() : String? { | ||
val list = listOf("Boss", "Friend", "No name", "Doctor", "Developer", "Funny man", null, null, null) | ||
return list.random() | ||
} | ||
private fun getRandomMessage() : String { | ||
val list = listOf("Hello!", "How are you?", "Cant answer right now", "What are you doing?", "Im watching TV", "...") | ||
return list.random() | ||
} | ||
private fun getTextTime() : String { | ||
val list = listOf("12:46", "Fri", "Mon", "18:56", "00:00", "Wen", "15:33", "19:00", "09:00") | ||
return list.random() | ||
} | ||
private fun getRandomAvatar(): Int { | ||
val list = listOf(R.drawable.avatar4, R.drawable.avata2r, R.drawable.avata22r, R.drawable.ava) | ||
return list.random() | ||
} | ||
private fun getRandomState(): Int { | ||
val list = listOf(R.drawable.readed, R.drawable.not_readed, R.drawable.state_null) | ||
return list.random() | ||
} | ||
private fun getRandomImgMessage(): Int? { | ||
val list = listOf(R.drawable.avatar, null, null, null) | ||
return list.random() | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,57 @@ | ||
package otus.gpb.recyclerview | ||
|
||
import androidx.appcompat.app.AppCompatActivity | ||
import android.os.Bundle | ||
import android.widget.SimpleAdapter | ||
import android.widget.Toast | ||
import androidx.appcompat.app.AppCompatActivity | ||
import androidx.appcompat.content.res.AppCompatResources | ||
import androidx.recyclerview.widget.DividerItemDecoration | ||
import androidx.recyclerview.widget.ItemTouchHelper | ||
import androidx.recyclerview.widget.LinearLayoutManager | ||
import androidx.recyclerview.widget.RecyclerView | ||
|
||
class MainActivity : AppCompatActivity() { | ||
|
||
private lateinit var recyclerView: RecyclerView | ||
private lateinit var adapter: ChatAdapter | ||
private var items = GenerateChatItems().getList() | ||
|
||
override fun onCreate(savedInstanceState: Bundle?) { | ||
super.onCreate(savedInstanceState) | ||
setContentView(R.layout.activity_main) | ||
|
||
val manager = LinearLayoutManager(this) | ||
|
||
recyclerView = findViewById<RecyclerView>(R.id.recyclerView) | ||
adapter = ChatAdapter(items) | ||
recyclerView.adapter = adapter | ||
recyclerView.layoutManager = manager | ||
|
||
val swipeHandler = object : SwipeCallback(this) { | ||
override fun onSwiped(viewHolder: RecyclerView.ViewHolder, direction: Int) { | ||
adapter.removeAt(viewHolder.adapterPosition) | ||
} | ||
} | ||
val itemTouchHelper = ItemTouchHelper(swipeHandler) | ||
itemTouchHelper.attachToRecyclerView(recyclerView) | ||
|
||
val divider = AppCompatResources.getDrawable(this, R.drawable.decoration) | ||
|
||
recyclerView.addItemDecoration( | ||
DividerItemDecoration(this, DividerItemDecoration.VERTICAL).apply { | ||
divider?.let { setDrawable(it) } | ||
} | ||
) | ||
|
||
val paging = PageScrollListener(manager).apply { | ||
onLoadMore = { | ||
Toast.makeText(this@MainActivity, "Load more", Toast.LENGTH_LONG).show() | ||
val newChatItems = GenerateChatItems().getList().subList(0, 9).toMutableList() | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. просто добавляй новый список, без getList и саблиста |
||
items.addAll(newChatItems) | ||
adapter.notifyDataSetChanged() | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
isLoading = false | ||
} | ||
} | ||
recyclerView.addOnScrollListener(paging) | ||
} | ||
} |
25 changes: 25 additions & 0 deletions
25
app/src/main/java/otus/gpb/recyclerview/PageScrollListener.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
package otus.gpb.recyclerview | ||
|
||
import androidx.recyclerview.widget.LinearLayoutManager | ||
import androidx.recyclerview.widget.RecyclerView | ||
|
||
class PageScrollListener( | ||
private val layoutManager: LinearLayoutManager | ||
): RecyclerView.OnScrollListener() { | ||
|
||
var isLoading = false | ||
var onLoadMore: (() -> Unit)? = null | ||
|
||
override fun onScrolled(recyclerView: RecyclerView, dx: Int, dy: Int) { | ||
super.onScrolled(recyclerView, dx, dy) | ||
val totalItemCount = layoutManager.itemCount | ||
val visibleItemCount = layoutManager.childCount | ||
val firstVisiblePosition = layoutManager.findFirstVisibleItemPosition() | ||
if (!isLoading) { | ||
if ((visibleItemCount + firstVisiblePosition) >= totalItemCount) { | ||
isLoading = true | ||
onLoadMore?.invoke() | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
package otus.gpb.recyclerview | ||
|
||
import android.content.Context | ||
import android.graphics.Canvas | ||
import android.graphics.Color | ||
import android.graphics.Paint | ||
import android.graphics.PorterDuff | ||
import android.graphics.PorterDuffXfermode | ||
import android.graphics.drawable.ColorDrawable | ||
import androidx.core.content.ContextCompat | ||
import androidx.recyclerview.widget.ItemTouchHelper | ||
import androidx.recyclerview.widget.RecyclerView | ||
import androidx.recyclerview.widget.RecyclerView.ViewHolder | ||
|
||
|
||
abstract class SwipeCallback (context: Context) : ItemTouchHelper.SimpleCallback(0, ItemTouchHelper.LEFT) { | ||
private val deleteIcon = ContextCompat.getDrawable(context, R.drawable.archive) | ||
private val intrinsicWidth = deleteIcon?.intrinsicWidth | ||
private val intrinsicHeight = deleteIcon?.intrinsicHeight | ||
private val background = ColorDrawable() | ||
private val backgroundColor = Color.parseColor("#66A9E0") | ||
private val clearPaint = Paint().apply { xfermode = PorterDuffXfermode(PorterDuff.Mode.CLEAR) } | ||
|
||
|
||
override fun getMovementFlags(recyclerView: RecyclerView, viewHolder: ViewHolder): Int { | ||
if (viewHolder.adapterPosition == 10) return 0 | ||
return super.getMovementFlags(recyclerView, viewHolder) | ||
} | ||
|
||
override fun onMove( | ||
recyclerView: RecyclerView, | ||
viewHolder: ViewHolder, | ||
target: ViewHolder | ||
): Boolean { | ||
return false | ||
} | ||
|
||
override fun onChildDraw( | ||
c: Canvas, | ||
recyclerView: RecyclerView, | ||
viewHolder: ViewHolder, | ||
dX: Float, | ||
dY: Float, | ||
actionState: Int, | ||
isCurrentlyActive: Boolean | ||
) { | ||
|
||
val itemView = viewHolder.itemView | ||
val itemHeight = itemView.bottom - itemView.top | ||
val isCanceled = dX == 0f && !isCurrentlyActive | ||
|
||
if (isCanceled) { | ||
clearCanvas(c, itemView.right + dX, itemView.top.toFloat(), itemView.right.toFloat(), itemView.bottom.toFloat()) | ||
super.onChildDraw(c, recyclerView, viewHolder, dX, dY, actionState, isCurrentlyActive) | ||
return | ||
} | ||
background.color = backgroundColor | ||
background.setBounds(itemView.right + dX.toInt(), itemView.top, itemView.right, itemView.bottom) | ||
background.draw(c) | ||
|
||
val deleteIconTop = itemView.top + (itemHeight - intrinsicHeight!!) / 2 | ||
val deleteIconMargin = (itemHeight - intrinsicHeight) / 2 | ||
val deleteIconLeft = itemView.right - deleteIconMargin - intrinsicWidth!! | ||
val deleteIconRight = itemView.right - deleteIconMargin | ||
val deleteIconBottom = deleteIconTop + intrinsicHeight | ||
|
||
deleteIcon?.setBounds(deleteIconLeft, deleteIconTop, deleteIconRight, deleteIconBottom) | ||
deleteIcon?.draw(c) | ||
|
||
super.onChildDraw(c, recyclerView, viewHolder, dX, dY, actionState, isCurrentlyActive) | ||
} | ||
|
||
private fun clearCanvas(c: Canvas?, left: Float, top: Float, right: Float, bottom: Float) { | ||
c?.drawRect(left, top, right, bottom, clearPaint) | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<vector xmlns:android="http://schemas.android.com/apk/res/android" | ||
android:width="48dp" | ||
android:height="48dp" | ||
android:viewportWidth="48" | ||
android:viewportHeight="48"> | ||
<path | ||
android:pathData="M8.22,42.848H4.64L3.891,45H2.221L5.712,35.758H7.153L10.651,45H8.975L8.22,42.848ZM5.09,41.553H7.769L6.43,37.719L5.09,41.553ZM15.151,39.541C14.948,39.507 14.739,39.49 14.523,39.49C13.816,39.49 13.34,39.761 13.095,40.303V45H11.552V38.132H13.025L13.063,38.9C13.435,38.303 13.952,38.005 14.612,38.005C14.832,38.005 15.014,38.035 15.158,38.094L15.151,39.541ZM18.82,43.896C19.205,43.896 19.525,43.783 19.779,43.559C20.033,43.335 20.168,43.058 20.185,42.728H21.639C21.622,43.155 21.488,43.555 21.239,43.927C20.989,44.295 20.651,44.587 20.223,44.803C19.796,45.019 19.334,45.127 18.839,45.127C17.879,45.127 17.117,44.816 16.554,44.194C15.991,43.572 15.71,42.713 15.71,41.617V41.458C15.71,40.413 15.989,39.577 16.548,38.951C17.106,38.32 17.868,38.005 18.833,38.005C19.65,38.005 20.314,38.244 20.826,38.722C21.342,39.196 21.613,39.82 21.639,40.595H20.185C20.168,40.201 20.033,39.877 19.779,39.624C19.529,39.37 19.21,39.243 18.82,39.243C18.321,39.243 17.936,39.425 17.665,39.789C17.394,40.148 17.257,40.696 17.252,41.433V41.68C17.252,42.425 17.386,42.981 17.652,43.35C17.923,43.714 18.313,43.896 18.82,43.896ZM24.324,38.881C24.827,38.297 25.464,38.005 26.234,38.005C27.699,38.005 28.441,38.841 28.462,40.512V45H26.92V40.569C26.92,40.095 26.816,39.761 26.609,39.566C26.406,39.368 26.105,39.268 25.708,39.268C25.09,39.268 24.628,39.543 24.324,40.093V45H22.781V35.25H24.324V38.881ZM31.668,45H30.125V38.132H31.668V45ZM30.03,36.348C30.03,36.111 30.104,35.914 30.252,35.758C30.405,35.601 30.621,35.523 30.9,35.523C31.179,35.523 31.395,35.601 31.547,35.758C31.7,35.914 31.776,36.111 31.776,36.348C31.776,36.581 31.7,36.776 31.547,36.932C31.395,37.084 31.179,37.161 30.9,37.161C30.621,37.161 30.405,37.084 30.252,36.932C30.104,36.776 30.03,36.581 30.03,36.348ZM35.775,43.045L37.229,38.132H38.822L36.441,45H35.102L32.703,38.132H34.302L35.775,43.045ZM42.726,45.127C41.748,45.127 40.955,44.82 40.345,44.207C39.74,43.589 39.438,42.768 39.438,41.744V41.553C39.438,40.868 39.569,40.256 39.831,39.719C40.098,39.177 40.47,38.756 40.948,38.456C41.426,38.155 41.96,38.005 42.548,38.005C43.483,38.005 44.205,38.303 44.712,38.9C45.224,39.497 45.48,40.341 45.48,41.433V42.055H40.993C41.039,42.622 41.228,43.07 41.558,43.4C41.892,43.73 42.311,43.896 42.814,43.896C43.521,43.896 44.097,43.61 44.541,43.039L45.373,43.832C45.097,44.243 44.729,44.562 44.268,44.791C43.811,45.015 43.297,45.127 42.726,45.127ZM42.542,39.243C42.118,39.243 41.776,39.391 41.513,39.687C41.255,39.983 41.09,40.396 41.018,40.925H43.957V40.811C43.923,40.294 43.786,39.905 43.544,39.643C43.303,39.376 42.969,39.243 42.542,39.243Z" | ||
android:fillColor="#ffffff"/> | ||
<path | ||
android:pathData="M34,21.292V7.415C34,7.133 34,6.4 33.661,6.061L29.935,2.338C29.823,2.226 29.461,2 28.919,2H18.081C17.539,2 17.177,2.226 17.065,2.338L13.339,6.061C13,6.4 13,7.133 13,7.415V21.292C13,22.788 14.213,24 15.71,24H31.29C32.787,24 34,22.788 34,21.292ZM28.919,3.692H18.081L16.048,5.723H30.952L28.919,3.692ZM25.532,12.154V13.507H28.455C28.751,13.507 28.899,13.866 28.69,14.075L23.5,19.261L18.31,14.075C18.101,13.866 18.249,13.507 18.545,13.507H21.468V12.154C21.468,11.612 21.919,11.477 22.145,11.477H24.855C25.397,11.477 25.532,11.928 25.532,12.154Z" | ||
android:fillColor="#ffffff" | ||
android:fillType="evenOdd"/> | ||
</vector> |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<inset xmlns:android="http://schemas.android.com/apk/res/android" | ||
android:insetLeft="75dp" > | ||
<shape> | ||
<size android:height="0.35px" /> | ||
<solid android:color="#D9D9D9" /> | ||
</shape> | ||
</inset> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<vector xmlns:android="http://schemas.android.com/apk/res/android" | ||
android:width="23dp" | ||
android:height="23dp" | ||
android:viewportWidth="23" | ||
android:viewportHeight="23"> | ||
<path | ||
android:pathData="M11.5,23C17.851,23 23,17.851 23,11.5C23,5.149 17.851,0 11.5,0C5.149,0 0,5.149 0,11.5C0,17.851 5.149,23 11.5,23ZM11.5,22C17.299,22 22,17.299 22,11.5C22,5.701 17.299,1 11.5,1C5.701,1 1,5.701 1,11.5C1,17.299 5.701,22 11.5,22Z" | ||
android:fillColor="#868686" | ||
android:fillType="evenOdd"/> | ||
<path | ||
android:pathData="M11.528,14.481C11.291,14.235 10.91,14.201 10.633,14.4L7.779,16.451C7.749,16.473 7.721,16.497 7.692,16.521C7.644,16.562 7.589,16.595 7.531,16.619C7.455,16.65 7.374,16.667 7.291,16.667C7.209,16.667 7.128,16.65 7.052,16.619C6.977,16.588 6.908,16.542 6.85,16.484C6.792,16.426 6.746,16.357 6.714,16.281C6.683,16.205 6.667,16.124 6.667,16.042C6.667,15.96 6.683,15.878 6.714,15.803C6.746,15.727 6.792,15.658 6.85,15.6L9.054,12.891C9.278,12.616 9.255,12.214 9,11.966L7.565,10.568C7.291,10.301 7.287,9.858 7.605,9.644C8.217,9.234 9.198,8.821 10.616,8.856C10.814,8.861 11.009,8.79 11.149,8.65L13.25,6.55L13.648,6.152C13.916,5.884 14.35,5.884 14.618,6.152L15.016,6.55L16.783,8.316L17.181,8.714C17.449,8.982 17.449,9.417 17.181,9.685L16.783,10.083L14.703,12.163C14.551,12.315 14.482,12.53 14.5,12.744C14.628,14.25 14.164,15.174 13.718,15.748C13.482,16.052 13.031,16.039 12.765,15.763L11.528,14.481Z" | ||
android:fillColor="#868686"/> | ||
<path | ||
android:pathData="M11.528,14.481C11.291,14.235 10.91,14.201 10.633,14.4L7.779,16.451C7.749,16.473 7.721,16.497 7.692,16.521C7.644,16.562 7.589,16.595 7.531,16.619C7.455,16.65 7.374,16.667 7.291,16.667C7.209,16.667 7.128,16.65 7.052,16.619C6.977,16.588 6.908,16.542 6.85,16.484C6.792,16.426 6.746,16.357 6.714,16.281C6.683,16.205 6.667,16.124 6.667,16.042C6.667,15.96 6.683,15.878 6.714,15.803C6.746,15.727 6.792,15.658 6.85,15.6L9.054,12.891C9.278,12.616 9.255,12.214 9,11.966L7.565,10.568C7.291,10.301 7.287,9.858 7.605,9.644C8.217,9.234 9.198,8.821 10.616,8.856C10.814,8.861 11.009,8.79 11.149,8.65L13.25,6.55L13.648,6.152C13.916,5.884 14.35,5.884 14.618,6.152L15.016,6.55L16.783,8.316L17.181,8.714C17.449,8.982 17.449,9.417 17.181,9.685L16.783,10.083L14.703,12.163C14.551,12.315 14.482,12.53 14.5,12.744C14.628,14.25 14.164,15.174 13.718,15.748C13.482,16.052 13.031,16.039 12.765,15.763L11.528,14.481Z" | ||
android:fillColor="#868686" | ||
android:fillType="evenOdd"/> | ||
</vector> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<vector xmlns:android="http://schemas.android.com/apk/res/android" | ||
android:width="9dp" | ||
android:height="12dp" | ||
android:viewportWidth="9" | ||
android:viewportHeight="12"> | ||
<path | ||
android:pathData="M0,4.434C0,4.154 0.212,3.927 0.472,3.927H1.283L6.142,9.439V10.791C6.142,11.482 5.67,11.742 5.197,11.235L2.097,8.332H0.472C0.212,8.332 0,8.104 0,7.825V4.434Z" | ||
android:fillColor="#BDC1C4" | ||
android:fillType="evenOdd"/> | ||
<path | ||
android:pathData="M0.563,0.502C0.477,0.519 0.397,0.561 0.331,0.624C0.266,0.687 0.218,0.769 0.194,0.859C0.169,0.95 0.169,1.046 0.192,1.137C0.216,1.228 0.263,1.31 0.327,1.374L8.16,9.785C8.202,9.84 8.254,9.885 8.313,9.917C8.372,9.95 8.437,9.968 8.503,9.972C8.569,9.976 8.635,9.964 8.697,9.939C8.759,9.913 8.815,9.874 8.862,9.824C8.909,9.774 8.945,9.713 8.969,9.647C8.992,9.581 9.003,9.51 8.999,9.439C8.996,9.368 8.979,9.298 8.948,9.235C8.918,9.171 8.876,9.116 8.825,9.071L6.942,7.05V1.515C6.942,0.534 6.03,0.544 5.365,1.15L3.222,3.056L0.992,0.66C0.943,0.604 0.883,0.561 0.817,0.534C0.75,0.506 0.679,0.495 0.608,0.502C0.593,0.501 0.578,0.501 0.563,0.502Z" | ||
android:fillColor="#BDC1C4"/> | ||
</vector> |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
здесь нет смысла использовать потокобезопасный lazy, это замедлит работу