package Ġcom . ath lon . common lib . ui Ċ Ċ import Ġandroid . content . res . Xml Resource Parser Ċ import Ġandroid . os . Bundle Ċ import Ġandroid . util . Xml Ċ import Ġandroid . view . LayoutInflater Ċ import Ġandroid . view . View Ċ import Ġandroid . view . ViewGroup Ċ import Ġandroidx . fragment . app . Dialog Fragment Ċ import Ġandroidx . lifecycle . ViewModel Provider Ċ import Ġcom . ath lon . common lib . Layout Id Ċ import Ġkotlinx . android . extensions . Layout Container Ċ Ċ abstract Ġclass ĠBase Dialog : ĠDialog Fragment () Ġ{ ĊĊĠĠĠ Ġlateinit Ġvar ĠviewModel Provider : ĠViewModel Provider ĊĊĠĠĠ Ġoverride Ġfun ĠonCreate ( savedInstanceState : ĠBundle ?) Ġ{ ĊĠĠĠĠĠĠĠ Ġsuper . onCreate ( savedInstanceState ) ĊĠĠĠĠĠĠĠ ĠviewModel Provider Ġ= ĠViewModel Provider ( this . activity !!. viewModel Store , ĠViewModel Provider . New Instance Factory ()) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġoverride Ġfun ĠonCreate View ( in flater : ĠLayoutInflater , Ġcontainer : ĠViewGroup ?, ĠsavedInstanceState : ĠBundle ?): ĠView ? Ġ{ ĊĠĠĠĠĠĠĠ Ġvar Ġlayout Id Anno Ġ= Ġthis :: class . java . getAnnotation ( Layout Id :: class . java ) ĊĠĠĠĠĠĠĠ Ġvar Ġroot View : ĠView Ġ?= Ġnull ĊĠĠĠĠĠĠĠ Ġlayout Id Anno ?. id ?. let Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠ Ġroot View Ġ= Ġlayout Inflater . inflate ( it , Ġcontainer , Ġfalse ) ĊĠĠĠĠĠĠĠ Ġ} ĊĊĠĠĠĠĠĠĠ Ġreturn Ġroot View ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġoverride Ġfun Ġon View Created ( view : ĠView , ĠsavedInstanceState : ĠBundle ?) Ġ{ ĊĠĠĠĠĠĠĠ Ġsuper . on View Created ( view , ĠsavedInstanceState ) ĊĊĠĠĠĠĠĠĠ Ġafter View Init () ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġabstract Ġfun Ġafter View Init () Ċ }