package Ġcom Ċ Ċ import Ġandroid . graphics . drawable . Animated Vector Drawable Ċ import Ġandroid . graphics . drawable . Drawable Ċ import Ġandroid . os . Bundle Ċ import Ġandroid . widget . ImageView Ċ import Ġandroidx . annotation . Drawable Res Ċ import Ġandroidx . appcompat . app . AppCompatActivity Ċ import Ġandroidx . vect ord raw able . graphics . drawable . Anim atable 2 Compat Ċ import Ġandroidx . vect ord raw able . graphics . drawable . Animated Vector Drawable Compat Ċ import Ġcom . canvas . R Ċ import Ġkotlinx . android . synt hetic . main . activity _ animated _ icons .* Ċ Ċ class ĠAnimated Icons Activity : ĠAppCompatActivity () Ġ{ ĊĊĠĠĠ Ġoverride Ġfun ĠonCreate ( savedInstanceState : ĠBundle ?) Ġ{ ĊĠĠĠĠĠĠĠ Ġsuper . onCreate ( savedInstanceState ) ĊĠĠĠĠĠĠĠ ĠsetContentView ( R . layout . activity _ animated _ icons ) ĊĊĠĠĠĠĠĠĠ ĠimageView . setOnClickListener Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠ ĠimageView . apply Loop ing Animated Vector Drawable ( R . drawable . av d _ notification _ bell _ 2 ) ĊĠĠĠĠĠĠĠ Ġ} ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġinternal Ġfun ĠImageView . apply Loop ing Animated Vector Drawable (@ Drawable Res Ġav d Res Id : ĠInt ) Ġ{ ĊĠĠĠĠĠĠĠ Ġval Ġanimated Ġ= ĠAnimated Vector Drawable Compat . create ( context , Ġav d Res Id ) ĊĠĠĠĠĠĠĠ Ġanimated ?. register Animation Callback ( object Ġ: ĠAnim atable 2 Compat . Animation Callback () Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠ Ġoverride Ġfun Ġon Animation End ( drawable : ĠDrawable ?) Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġthis @ apply Loop ing Animated Vector Drawable . post Ġ{ Ġanimated . start () Ġ} ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ} ĊĠĠĠĠĠĠĠ Ġ}) ĊĠĠĠĠĠĠĠ Ġthis . setImage Drawable ( animated ) ĊĠĠĠĠĠĠĠ Ġanimated ?. start () ĊĠĠĠ Ġ} Ċ }