} else {
ap->mf_Status.flagNoContent = EINA_TRUE;
}
- }
- else {
+ } else {
mf_error();
MF_TA_ACUM_ITEM_BEGIN(" mf_util_generate_file_list", 0);
error_code = mf_util_generate_file_list(ap);
myfileNaviBar *pNavi_s = mf_navi_bar_get_in_use(ap);
- if (ap->mf_Status.more == MORE_CREATE_FOLDER || ap->mf_Status.more == MORE_THUMBNAIL_RENAME || ap->mf_Status.more == MORE_SEARCH) {
+ if (ap->mf_Status.more == MORE_CREATE_FOLDER
+ || ap->mf_Status.more == MORE_THUMBNAIL_RENAME
+ || ap->mf_Status.more == MORE_SEARCH
+ || ap->mf_Status.more == MORE_EDIT
+ || ap->mf_Status.more == MORE_SHARE_EDIT) {
__mf_navi_bar_title(ap);
} else if (more != MORE_EDIT && more != MORE_SEARCH) {
if (ap->mf_Status.view_type != mf_view_root) {
MF_TA_ACUM_ITEM_BEGIN(" set control bar", 0);
if (ap->mf_Status.flagNoContent == 1) {
mf_navi_bar_button_set_disable(ap->mf_MainWindow.pNaviItem, CTRL_DISABLE_NOCONTENT_VIEW, true);
- //mf_ctrl_bar_item_set_disable(ap->mf_MainWindow.pNaviCtrlBar, CTRL_DISABLE_NOCONTENT_VIEW, TRUE);
} else {
mf_navi_bar_button_set_disable(ap->mf_MainWindow.pNaviItem, CTRL_DISABLE_NOCONTENT_VIEW, FALSE);
- //mf_ctrl_bar_item_set_disable(ap->mf_MainWindow.pNaviCtrlBar, CTRL_DISABLE_NOCONTENT_VIEW, FALSE);
}
#ifdef MYFILE_USB_OTG
if(mf_fm_svc_wrapper_is_root_path(ap->mf_Status.path->str) == MYFILE_OTG) {
Evas_Object *pSearchViewLayout = NULL;
//ap->mf_MainWindow.pNaviLayout = mf_widget_create_layout(ap->mf_MainWindow.pNaviBox, EDJ_NAME, "selectinfo_layout");
-#if 1
ap->mf_MainWindow.pNaviLayout = mf_widget_create_layout(ap->mf_MainWindow.pNaviBar, EDJ_NAME, "search_view_layout");
ap->mf_MainWindow.pNaviSearchBar = mf_navi_bar_create_search_bar(ap->mf_MainWindow.pNaviLayout, ap);
pSearchViewLayout = ap->mf_MainWindow.pNaviLayout;
elm_object_part_content_set(pSearchViewLayout, "search_bar", ap->mf_MainWindow.pNaviSearchBar);
elm_object_part_content_set(pSearchViewLayout, "content", path_label);
-#else
- ap->mf_MainWindow.pNaviBox = mf_widget_create_box(ap->mf_MainWindow.pNaviBar);
-
- Evas_Object *pSearchbarLayout = NULL;
- pSearchbarLayout = mf_widget_create_layout(ap->mf_MainWindow.pNaviBox, EDJ_NAME, "search_bar_layout");
- evas_object_size_hint_weight_set(pSearchbarLayout, EVAS_HINT_EXPAND, 0);
- evas_object_size_hint_align_set(pSearchbarLayout, EVAS_HINT_FILL, 0.0);
-
- ap->mf_MainWindow.pNaviSearchBar = mf_navi_bar_create_search_bar(pSearchbarLayout, ap);
- pSearchViewLayout = mf_widget_create_layout(ap->mf_MainWindow.pNaviBox, EDJ_NAME, "selectinfo_layout");
- ap->mf_MainWindow.pNaviLayout = pSearchViewLayout;
-
- /*set content*/
- /*2. create path label for the start of search view*/
- /*2.1 create path label*/
-
- path_label = elm_entry_add(pSearchViewLayout);
-
- elm_object_style_set(path_label, "default");
- elm_entry_single_line_set(path_label, EINA_FALSE);
- elm_object_focus_set(path_label, EINA_FALSE);
-
- evas_object_show(path_label);
- /*2.2 contribute label content*/
- char *path_in_label = mf_fm_svc_wrapper_translate_path(ap->mf_Status.path->str, MF_TRANS_OPTION_LABEL);
- char *label_content = g_strconcat(GET_SYS_STR(MF_LABEL_SEARCH), ":", "<br>", path_in_label, NULL);
- /*2.3 set style for path_label*/
- elm_entry_editable_set(path_label, EINA_FALSE);
- elm_entry_entry_set(path_label, label_content);
-
- /*set title segment or title*/
- /*navigation view integration*/
- elm_object_part_content_set(pSearchbarLayout, "content", ap->mf_MainWindow.pNaviSearchBar);
- elm_object_part_content_set(pSearchViewLayout, "content", path_label);
- elm_box_pack_start(ap->mf_MainWindow.pNaviBox, pSearchbarLayout);
- elm_box_pack_end(ap->mf_MainWindow.pNaviBox, pSearchViewLayout);
-#endif
-
title = g_string_new(GET_SYS_STR(MF_LABEL_SEARCH));
if (title != NULL) {
pNavi_s->pNaviTitle = g_strdup(title->str);
void mf_navi_bar_button_set_disable(Elm_Object_Item *navi_it, int disable_item, bool disable)
{
+ MF_TRACE_BEGIN;
mf_retm_if(navi_it == NULL, "navi_it is NULL");
Evas_Object *btn = NULL;
if (disable_item & CTRL_DISABLE_EDIT) {
const char *button_label = elm_object_text_get(btn);
if (g_strcmp0(button_label, GET_SYS_STR(MF_LABEL_CREATE_FOLDER)) == 0)
elm_object_disabled_set(btn, disable);
-
}
if (disable_item & CTRL_DISABLE_MORE) {
btn = elm_object_item_part_content_get(navi_it, NAVI_MORE_BUTTON_PART);
elm_object_disabled_set(btn, disable);
}
+ if (disable_item & CTRL_DISABLE_SEARCH) {
+ btn = elm_object_item_part_content_get(navi_it, NAVI_BOTTOM_BUTTON_1_PART);
+ elm_object_disabled_set(btn, disable);
+ }
+
+ MF_TRACE_END;
+
}
+
int mf_navi_bar_button_get_disable(Elm_Object_Item *navi_it)
{
mf_retvm_if(navi_it == NULL, 0, "navi_it is NULL");