package Ġcom . am ino graphy . prime adapter . sample . tools Ċ Ċ import Ġandroid . graphics . drawable . Drawable Ċ import Ġandroid . support . annotation . Drawable Res Ċ import Ġandroid . widget . ImageView Ċ import Ġcom . am ino graphy . prime adapter . sample . R Ċ import Ġcom . bump tech . glide . G lide Ċ import Ġcom . bump tech . glide . request . RequestOptions Ċ Ċ /** Ċ Ġ* ĠCreated Ġby Ġa mino graphy Ġon Ġ 6 / 6 / 2 0 1 8 . Ċ Ġ*/ Ċ Ċ fun ĠImageView . load Image ( image Drawable : ĠDrawable ?, Ġcircle Crop : ĠBoolean Ġ= Ġfalse , Ġ@ Drawable Res Ġplaceholder Res Id : ĠInt Ġ= ĠR . drawable . default _ placeholder ) Ġ{ ĊĠĠĠ Ġval Ġrequest Builder Ġ= ĠG lide . with ( context ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ. load ( image Drawable ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ. apply ( RequestOptions . placeholder Of ( placeholder Res Id )) ĊĠĠĠ Ġif Ġ( circle Crop ) Ġrequest Builder . apply ( RequestOptions . circle Crop Transform ()) ĊĠĠĠ Ġrequest Builder . into ( this ) Ċ }