Efl_Ui_Focus_Manager *redirect_manager;
Eo *focusable;
Node_Type type;
- Eina_Bool was_redirect = EINA_FALSE;
EINA_SAFETY_ON_NULL_RETURN(focus);
}
}
+ if (eina_list_last_data_get(pd->focus_stack) == node)
+ {
+ //the correct one is focused
+ if (node->redirect_manager == pd->redirect)
+ return;
+ }
+
if (pd->redirect)
{
//reset the history of that manager
//first unset the redirect
efl_ui_focus_manager_redirect_set(obj, NULL);
-
- //we have been redirecting
- was_redirect = EINA_TRUE;
}
redirect_manager = node->redirect_manager;
//check if this is already the focused object
old_focus = eina_list_last_data_get(pd->focus_stack);
- //check if this is already at the top
- if (!was_redirect && old_focus && old_focus->focusable == focus) return;
-
//remove the object from the list and add it again
pd->focus_stack = eina_list_remove(pd->focus_stack, node);
pd->focus_stack = eina_list_append(pd->focus_stack, node);