package Ġsk . mh ole cy . meteor ites . common . extensions Ċ Ċ import Ġandroid . content . Context Ċ import Ġandroid . net . Connectivity Manager Ċ import Ġandroidx . annotation . Color Res Ċ import Ġandroidx . core . content . Context Compat Ċ import Ġcom . google . android . material . sn ackbar . Snackbar Ċ Ċ fun ĠContext . is Online (): ĠBoolean Ġ{ ĊĠĠĠ Ġval Ġconnectivity Manager Ġ= Ġthis . getSystem Service ( Context . CONNECT IVITY _ SERVICE ) Ġas ĠConnect ivity Manager ĊĠĠĠ Ġval Ġactive Network Ġ= Ġconnectivity Manager . active Network Info ĊĠĠĠ Ġreturn Ġactive Network ?. isConnected Ġ== Ġtrue Ċ } Ċ Ċ fun ĠSn ackbar . set BackgroundColor (@ Color Res Ġcolor Id : ĠInt ) Ġ{ ĊĠĠĠ Ġthis . view . set BackgroundColor ( Context Compat . getColor ( this . context , Ġcolor Id )) Ċ } Ċ Ċ fun ĠSn ackbar . setAction TextColor Id (@ Color Res Ġcolor Id : ĠInt ) Ġ{ ĊĠĠĠ Ġthis . setAction TextColor ( Context Compat . getColor ( this . context , Ġcolor Id )) Ċ } Ċ