- Actor rootActor = Stage::GetCurrent().GetRootLayer();
- return rootActor.FindChildById(mCurrentFocusActor);
+ Actor actor = mCurrentFocusActor.GetHandle();
+ if( actor && ! actor.OnStage() )
+ {
+ // If the actor has been removed from the stage, then it should not be focused
+
+ actor.Reset();
+ mCurrentFocusActor.Reset();
+ }
+ return actor;