package Ġcom . there al blue pand ab ear . pix ap encil . activities . main . event listeners Ċ Ċ import Ġandroidx . fragment . app . commit Ċ import Ġcom . there al blue pand ab ear . pix ap encil . R Ċ import Ġcom . there al blue pand ab ear . pix ap encil . activities . main . MainActivity Ċ import Ġcom . there al blue pand ab ear . pix ap encil . fragments . new project . New Project Fragment Ċ Ċ fun ĠMainActivity . new Project Button Set OnClickListener () Ġ{ ĊĠĠĠ Ġbinding . activity Main New Project Button . setOnClickListener Ġ{ ĊĠĠĠĠĠĠĠ Ġmain Spot light ?. finish () ĊĊĠĠĠĠĠĠĠ Ġif Ġ( support FragmentManager . back Stack Entry Count Ġ== Ġ 0 ) Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠ Ġsupport FragmentManager . commit Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġreplace ( R . id . activity Main _ primary Fragment Host , ĠNew Project Fragment . newInstance ( main Spot light Ġ!= Ġnull )) ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ ĠaddTo Back Stack ( null ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ} ĊĠĠĠĠĠĠĠ Ġ} ĊĠĠĠ Ġ} Ċ }