package Ġcom . playground . redux . pages . commit page Ċ Ċ import Ġandroid . databinding . Data Binding Util Ċ import Ġandroid . os . Bundle Ċ import Ġcom . pe tn agy . k ored ux . Store Ċ import Ġcom . pe tn agy . k ored ux . Store Subscriber Ċ import Ġcom . playground . redux . BR Ċ import Ġcom . playground . redux . R Ċ import Ġcom . playground . redux . databinding . Activity Commits Binding Ċ import Ġcom . playground . redux . navigation . Page Ċ import Ġcom . playground . redux . pages . commit page . view model . Commit List ViewModel Ċ import Ġcom . playground . redux . redux . actions . Clear Commit List Action Ċ import Ġcom . playground . redux . redux . actions . Load Commits Action Ċ import Ġcom . playground . redux . redux . actions . Next Page Action Ċ import Ġcom . playground . redux . redux . app state . AppState Ċ import Ġdagger . android . support . D agger AppCompatActivity Ċ import Ġjavax . inject . Inject Ċ Ċ class ĠCommit List Activity Ġ: ĠD agger AppCompatActivity (), ĠStore Subscriber < AppState > Ġ{ ĊĊĠĠĠ Ġ@ Inject ĊĠĠĠ Ġlateinit Ġvar Ġstore : ĠStore < AppState > ĊĊĠĠĠ Ġ@ Inject ĊĠĠĠ Ġlateinit Ġvar ĠviewModel : ĠCommit List ViewModel ĊĊĠĠĠ Ġoverride Ġfun ĠonCreate ( savedInstanceState : ĠBundle ?) Ġ{ ĊĠĠĠĠĠĠĠ Ġsuper . onCreate ( savedInstanceState ) ĊĠĠĠĠĠĠĠ Ġval Ġbinding : ĠActivity Commits Binding Ġ= ĠData Binding Util . set ContentView ( this , ĠR . layout . activity _ commits ) ĊĠĠĠĠĠĠĠ Ġbinding . set Variable ( BR . viewModel , ĠviewModel ) ĊĠĠĠĠĠĠĠ Ġbinding . execute Pending Bindings () ĊĠĠĠĠĠĠĠ Ġbinding . set Lifecycle Owner ( this ) ĊĠĠĠĠĠĠĠ Ġlifecycle . add Observer ( viewModel ) ĊĠĠĠĠĠĠĠ Ġstore . dispatch ( Load Commits Action ( store . state . user . selected UserName , Ġstore . state . repos . selected Repo Name )) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġoverride Ġfun ĠonStart () Ġ{ ĊĠĠĠĠĠĠĠ Ġsuper . onStart () ĊĠĠĠĠĠĠĠ Ġstore . subscribe ( this ) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġoverride Ġfun Ġon Stop () Ġ{ ĊĠĠĠĠĠĠĠ Ġsuper . on Stop () ĊĠĠĠĠĠĠĠ Ġstore . unsubscribe ( this ) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġoverride Ġfun Ġon Back Pressed () Ġ{ ĊĠĠĠĠĠĠĠ Ġsuper . on Back Pressed () ĊĠĠĠĠĠĠĠ Ġstore . dispatch ( Next Page Action ( Page . REPO _ SELECT _ PAGE )) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġoverride Ġfun ĠnewState ( state : ĠApp State ) Ġ{ ĊĠĠĠĠĠĠĠ Ġstate . page State . apply Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠ Ġif Ġ( this . actual Page Ġ!= ĠPage . COMMIT _ LIST _ PAGE ) Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġstore . unsubscribe ( this @ Commit List Activity ) ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ ĠviewModel . on Stop () ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġstore . dispatch ( Clear Commit List Action ()) ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġfinish () ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ} ĊĠĠĠĠĠĠĠ Ġ} ĊĠĠĠ Ġ} Ċ Ċ }