efm config now has the no_typebuf_set option to disable typebuf directory changing
SVN revision: 74842
This commit is contained in:
parent
4f87bdcc75
commit
dcc999599e
|
@ -234,7 +234,7 @@ struct _E_Fm2_Context_Menu_Data
|
||||||
E_Fm2_Mime_Handler *handler;
|
E_Fm2_Mime_Handler *handler;
|
||||||
};
|
};
|
||||||
|
|
||||||
static const char *_e_fm2_dev_path_map(const char *dev, const char *path);
|
static const char *_e_fm2_dev_path_map(E_Fm2_Smart_Data *sd, const char *dev, const char *path);
|
||||||
static void _e_fm2_file_add(Evas_Object *obj, const char *file, int unique, const char *file_rel, int after, E_Fm2_Finfo *finf);
|
static void _e_fm2_file_add(Evas_Object *obj, const char *file, int unique, const char *file_rel, int after, E_Fm2_Finfo *finf);
|
||||||
static void _e_fm2_file_del(Evas_Object *obj, const char *file);
|
static void _e_fm2_file_del(Evas_Object *obj, const char *file);
|
||||||
static void _e_fm2_queue_process(Evas_Object *obj);
|
static void _e_fm2_queue_process(Evas_Object *obj);
|
||||||
|
@ -994,7 +994,7 @@ e_fm2_path_set(Evas_Object *obj, const char *dev, const char *path)
|
||||||
sd->config->theme.fixed = EINA_FALSE;
|
sd->config->theme.fixed = EINA_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
real_path = _e_fm2_dev_path_map(dev, path);
|
real_path = _e_fm2_dev_path_map(sd, dev, path);
|
||||||
/* If the path doesn't exist, popup a dialog */
|
/* If the path doesn't exist, popup a dialog */
|
||||||
if (dev && strncmp(dev, "removable:", 10)
|
if (dev && strncmp(dev, "removable:", 10)
|
||||||
&& !ecore_file_exists(real_path))
|
&& !ecore_file_exists(real_path))
|
||||||
|
@ -3068,7 +3068,7 @@ e_fm2_client_del(Ecore_Ipc_Event_Client_Del *e)
|
||||||
|
|
||||||
/* local subsystem functions */
|
/* local subsystem functions */
|
||||||
static const char *
|
static const char *
|
||||||
_e_fm2_dev_path_map(const char *dev, const char *path)
|
_e_fm2_dev_path_map(E_Fm2_Smart_Data *sd, const char *dev, const char *path)
|
||||||
{
|
{
|
||||||
char buf[PATH_MAX] = "", *s, *ss;
|
char buf[PATH_MAX] = "", *s, *ss;
|
||||||
int len;
|
int len;
|
||||||
|
@ -3114,6 +3114,7 @@ _e_fm2_dev_path_map(const char *dev, const char *path)
|
||||||
*/
|
*/
|
||||||
if (e_user_dir_concat_static(buf, "fileman/favorites") >= sizeof(buf))
|
if (e_user_dir_concat_static(buf, "fileman/favorites") >= sizeof(buf))
|
||||||
return NULL;
|
return NULL;
|
||||||
|
if (sd && sd->config) sd->config->view.no_typebuf_set = EINA_TRUE;
|
||||||
ecore_file_mkpath(buf);
|
ecore_file_mkpath(buf);
|
||||||
}
|
}
|
||||||
else if (strcmp(dev, "desktop") == 0)
|
else if (strcmp(dev, "desktop") == 0)
|
||||||
|
@ -5708,11 +5709,11 @@ _e_fm2_typebuf_char_append(Evas_Object *obj, const char *ch)
|
||||||
if (ch[0] == '*')
|
if (ch[0] == '*')
|
||||||
sd->typebuf.wildcard++;
|
sd->typebuf.wildcard++;
|
||||||
_e_fm2_typebuf_match(obj, 0);
|
_e_fm2_typebuf_match(obj, 0);
|
||||||
if (ch[0] == '/')
|
if ((!sd->config->view.no_typebuf_set) && (ch[0] == '/'))
|
||||||
{
|
{
|
||||||
if (sd->typebuf.buf[0] == '/')
|
if (sd->typebuf.buf[0] == '/')
|
||||||
{
|
{
|
||||||
if (e_util_strcmp(sd->dev, "desktop") && e_util_strcmp(sd->dev, "favorites") && ecore_file_is_dir(sd->typebuf.buf))
|
if (ecore_file_is_dir(sd->typebuf.buf))
|
||||||
{
|
{
|
||||||
sd->typebuf.setting = EINA_TRUE;
|
sd->typebuf.setting = EINA_TRUE;
|
||||||
e_fm2_path_set(obj, "/", sd->typebuf.buf);
|
e_fm2_path_set(obj, "/", sd->typebuf.buf);
|
||||||
|
@ -5725,7 +5726,7 @@ _e_fm2_typebuf_char_append(Evas_Object *obj, const char *ch)
|
||||||
|
|
||||||
if (!sd->typebuf.start) sd->typebuf.start = eina_stringshare_ref(sd->realpath);
|
if (!sd->typebuf.start) sd->typebuf.start = eina_stringshare_ref(sd->realpath);
|
||||||
snprintf(buf, sizeof(buf), "%s/%s", sd->typebuf.start, sd->typebuf.buf);
|
snprintf(buf, sizeof(buf), "%s/%s", sd->typebuf.start, sd->typebuf.buf);
|
||||||
if (e_util_strcmp(sd->dev, "desktop") && e_util_strcmp(sd->dev, "favorites") && ecore_file_is_dir(buf))
|
if (ecore_file_is_dir(buf))
|
||||||
{
|
{
|
||||||
sd->typebuf.setting = EINA_TRUE;
|
sd->typebuf.setting = EINA_TRUE;
|
||||||
e_fm2_path_set(obj, "/", buf);
|
e_fm2_path_set(obj, "/", buf);
|
||||||
|
@ -5737,7 +5738,7 @@ _e_fm2_typebuf_char_append(Evas_Object *obj, const char *ch)
|
||||||
char buf[PATH_MAX];
|
char buf[PATH_MAX];
|
||||||
|
|
||||||
snprintf(buf, sizeof(buf), "%s/%s", getenv("HOME"), sd->typebuf.buf + 2);
|
snprintf(buf, sizeof(buf), "%s/%s", getenv("HOME"), sd->typebuf.buf + 2);
|
||||||
if (e_util_strcmp(sd->dev, "desktop") && e_util_strcmp(sd->dev, "favorites") && ecore_file_is_dir(buf))
|
if (ecore_file_is_dir(buf))
|
||||||
{
|
{
|
||||||
sd->typebuf.setting = EINA_TRUE;
|
sd->typebuf.setting = EINA_TRUE;
|
||||||
e_fm2_path_set(obj, "~/", sd->typebuf.buf + 1);
|
e_fm2_path_set(obj, "~/", sd->typebuf.buf + 1);
|
||||||
|
@ -5772,11 +5773,11 @@ _e_fm2_typebuf_char_backspace(Evas_Object *obj)
|
||||||
if (dec == '*')
|
if (dec == '*')
|
||||||
sd->typebuf.wildcard--;
|
sd->typebuf.wildcard--;
|
||||||
if (len) _e_fm2_typebuf_match(obj, 0);
|
if (len) _e_fm2_typebuf_match(obj, 0);
|
||||||
if (dec == '/')
|
if ((!sd->config->view.no_typebuf_set) && (dec == '/'))
|
||||||
{
|
{
|
||||||
if ((len > 1) || (sd->typebuf.buf[0] == '/'))
|
if ((len > 1) || (sd->typebuf.buf[0] == '/'))
|
||||||
{
|
{
|
||||||
if (e_util_strcmp(sd->dev, "desktop") && e_util_strcmp(sd->dev, "favorites") && ecore_file_is_dir(sd->typebuf.buf))
|
if (ecore_file_is_dir(sd->typebuf.buf))
|
||||||
{
|
{
|
||||||
sd->typebuf.setting = EINA_TRUE;
|
sd->typebuf.setting = EINA_TRUE;
|
||||||
e_fm2_path_set(obj, "/", sd->typebuf.buf);
|
e_fm2_path_set(obj, "/", sd->typebuf.buf);
|
||||||
|
@ -5789,7 +5790,7 @@ _e_fm2_typebuf_char_backspace(Evas_Object *obj)
|
||||||
|
|
||||||
if (!sd->typebuf.start) sd->typebuf.start = eina_stringshare_ref(sd->realpath);
|
if (!sd->typebuf.start) sd->typebuf.start = eina_stringshare_ref(sd->realpath);
|
||||||
snprintf(buf, sizeof(buf), "%s/%s", sd->typebuf.start, sd->typebuf.buf);
|
snprintf(buf, sizeof(buf), "%s/%s", sd->typebuf.start, sd->typebuf.buf);
|
||||||
if (e_util_strcmp(sd->dev, "desktop") && e_util_strcmp(sd->dev, "favorites") && ecore_file_is_dir(buf))
|
if (ecore_file_is_dir(buf))
|
||||||
{
|
{
|
||||||
sd->typebuf.setting = EINA_TRUE;
|
sd->typebuf.setting = EINA_TRUE;
|
||||||
e_fm2_path_set(obj, "/", buf);
|
e_fm2_path_set(obj, "/", buf);
|
||||||
|
@ -5801,7 +5802,7 @@ _e_fm2_typebuf_char_backspace(Evas_Object *obj)
|
||||||
char buf[PATH_MAX];
|
char buf[PATH_MAX];
|
||||||
|
|
||||||
snprintf(buf, sizeof(buf), "%s/%s", getenv("HOME"), sd->typebuf.buf + 2);
|
snprintf(buf, sizeof(buf), "%s/%s", getenv("HOME"), sd->typebuf.buf + 2);
|
||||||
if (e_util_strcmp(sd->dev, "desktop") && e_util_strcmp(sd->dev, "favorites") && ecore_file_is_dir(buf))
|
if (ecore_file_is_dir(buf))
|
||||||
{
|
{
|
||||||
sd->typebuf.setting = EINA_TRUE;
|
sd->typebuf.setting = EINA_TRUE;
|
||||||
e_fm2_path_set(obj, "~/", sd->typebuf.buf + 1);
|
e_fm2_path_set(obj, "~/", sd->typebuf.buf + 1);
|
||||||
|
@ -10430,7 +10431,7 @@ e_fm2_overlay_clip_to(Evas_Object *obj, Evas_Object *clip)
|
||||||
EAPI const char *
|
EAPI const char *
|
||||||
e_fm2_real_path_map(const char *dev, const char *path)
|
e_fm2_real_path_map(const char *dev, const char *path)
|
||||||
{
|
{
|
||||||
return _e_fm2_dev_path_map(dev, path);
|
return _e_fm2_dev_path_map(NULL, dev, path);
|
||||||
}
|
}
|
||||||
|
|
||||||
EAPI void
|
EAPI void
|
||||||
|
|
|
@ -68,6 +68,7 @@ struct _E_Fm2_Config
|
||||||
Eina_Bool always_order : 1;
|
Eina_Bool always_order : 1;
|
||||||
Eina_Bool link_drop : 1;
|
Eina_Bool link_drop : 1;
|
||||||
Eina_Bool fit_custom_pos : 1;
|
Eina_Bool fit_custom_pos : 1;
|
||||||
|
Eina_Bool no_typebuf_set : 1;
|
||||||
unsigned int single_click_delay;
|
unsigned int single_click_delay;
|
||||||
} view;
|
} view;
|
||||||
/* display of icons */
|
/* display of icons */
|
||||||
|
|
|
@ -1253,7 +1253,7 @@ _e_fwin_config_set(E_Fwin_Page *page)
|
||||||
fmc.icon.fixed.w = 0;
|
fmc.icon.fixed.w = 0;
|
||||||
fmc.icon.fixed.h = 0;
|
fmc.icon.fixed.h = 0;
|
||||||
#endif
|
#endif
|
||||||
|
fmc.view.no_typebuf_set = 1;
|
||||||
fmc.view.open_dirs_in_place = 0;
|
fmc.view.open_dirs_in_place = 0;
|
||||||
fmc.view.fit_custom_pos = 1;
|
fmc.view.fit_custom_pos = 1;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue