package Ġme . jack . kotlin . library . extension Ċ Ċ import Ġandroid . content . Context Ċ import Ġandroid . graphics . Color Ċ import Ġandroid . os . Build Ċ import Ġandroid . support . annotation . Color Int Ċ import Ġandroid . view . View Ċ import Ġandroid . view . Window Ċ import Ġandroid . view . WindowManager Ċ import Ġandroid . view . input method . Input Method Manager Ċ Ċ /** Ċ Ġ* ĠCreated Ġby ĠJack Ġon Ġ 2 0 1 8 / 1 / 7 . Ċ Ġ*/ Ċ val ĠView . ctx : ĠContext ĊĠĠĠ Ġget () Ġ= Ġcontext Ċ Ċ fun ĠView . hide Soft Input () Ġ{ ĊĠĠĠ Ġval Ġmanager Ġ= Ġctx . getSystem Service ( Context . INPUT _ METHOD _ SERVICE ) Ġas ĠInput Method Manager ĊĠĠĠ Ġmanager . hide Soft Input From Window ( this . window Token , Ġ 0 ) Ċ } Ċ Ċ fun ĠWindow . trans luc ent Status (@ Color Int Ġcolor : ĠInt Ġ= ĠColor . TRANSP ARENT ) Ġ{ ĊĠĠĠ Ġif Ġ( Build . VERSION . SDK _ INT Ġ>= ĠBuild . VERSION _ CODES . LO L LI POP ) Ġ{ ĊĠĠĠĠĠĠĠ Ġclear Flags ( WindowManager . LayoutParams . FLAG _ TRANSL UC ENT _ STATUS ) ĊĠĠĠĠĠĠĠ Ġval Ġvisibility Ġ= Ġdecor View . system Ui Visibility ĊĠĠĠĠĠĠĠ Ġdecor View . system Ui Visibility Ġ= Ġvisibility Ġor ĠView . SYSTEM _ UI _ FLAG _ LAYOUT _ FULL SCREEN Ġor ĠView . SYSTEM _ UI _ FLAG _ LAYOUT _ ST ABLE ĊĠĠĠĠĠĠĠ Ġadd Flags ( WindowManager . LayoutParams . FLAG _ DR AWS _ SYSTEM _ BAR _ BACK GRO UN DS ) ĊĠĠĠĠĠĠĠ Ġstatus Bar Color Ġ= Ġcolor ĊĠĠĠ Ġ} Ċ }