mirror of
https://github.com/rkd77/elinks.git
synced 2025-01-03 14:57:44 -05:00
[menu] Added "Remove temporary files" menu entry.
This commit is contained in:
parent
f351f66f84
commit
664b85418e
@ -14,6 +14,7 @@ ACTION_(MAIN, "backspace-prefix", BACKSPACE_PREFIX, N__("Backspace the last ente
|
|||||||
ACTION_(MAIN, "bookmark-manager", BOOKMARK_MANAGER, N__("Open bookmark manager"), 0),
|
ACTION_(MAIN, "bookmark-manager", BOOKMARK_MANAGER, N__("Open bookmark manager"), 0),
|
||||||
ACTION_(MAIN, "cache-manager", CACHE_MANAGER, N__("Open cache manager"), 0),
|
ACTION_(MAIN, "cache-manager", CACHE_MANAGER, N__("Open cache manager"), 0),
|
||||||
ACTION_(MAIN, "cache-minimize", CACHE_MINIMIZE, N__("Free unused cache entries"), 0),
|
ACTION_(MAIN, "cache-minimize", CACHE_MINIMIZE, N__("Free unused cache entries"), 0),
|
||||||
|
ACTION_(MAIN, "clean-temporary-files", CLEAN_TEMPORARY_FILES, N__("Remove temporary files"), 0),
|
||||||
ACTION_(MAIN, "cookie-manager", COOKIE_MANAGER, N__("Open cookie manager"), 0),
|
ACTION_(MAIN, "cookie-manager", COOKIE_MANAGER, N__("Open cookie manager"), 0),
|
||||||
ACTION_(MAIN, "cookies-load", COOKIES_LOAD, N__("Reload cookies file"), ACTION_RESTRICT_ANONYMOUS),
|
ACTION_(MAIN, "cookies-load", COOKIES_LOAD, N__("Reload cookies file"), ACTION_RESTRICT_ANONYMOUS),
|
||||||
ACTION_(MAIN, "copy-clipboard", COPY_CLIPBOARD, N__("Copy text to clipboard"), ACTION_REQUIRE_VIEW_STATE | ACTION_REQUIRE_LOCATION),
|
ACTION_(MAIN, "copy-clipboard", COPY_CLIPBOARD, N__("Copy text to clipboard"), ACTION_REQUIRE_VIEW_STATE | ACTION_REQUIRE_LOCATION),
|
||||||
|
@ -333,6 +333,7 @@ static struct menu_item file_menu22[] = {
|
|||||||
BAR_MENU_ITEM,
|
BAR_MENU_ITEM,
|
||||||
INIT_MENU_ACTION(N_("~Kill background connections"), ACT_MAIN_KILL_BACKGROUNDED_CONNECTIONS),
|
INIT_MENU_ACTION(N_("~Kill background connections"), ACT_MAIN_KILL_BACKGROUNDED_CONNECTIONS),
|
||||||
INIT_MENU_ACTION(N_("Flush all ~caches"), ACT_MAIN_CACHE_MINIMIZE),
|
INIT_MENU_ACTION(N_("Flush all ~caches"), ACT_MAIN_CACHE_MINIMIZE),
|
||||||
|
INIT_MENU_ACTION(N_("Re~move temporary files"), ACT_MAIN_CLEAN_TEMPORARY_FILES),
|
||||||
INIT_MENU_ACTION(N_("Resource ~info"), ACT_MAIN_RESOURCE_INFO),
|
INIT_MENU_ACTION(N_("Resource ~info"), ACT_MAIN_RESOURCE_INFO),
|
||||||
BAR_MENU_ITEM,
|
BAR_MENU_ITEM,
|
||||||
};
|
};
|
||||||
|
@ -155,6 +155,10 @@ do_action(struct session *ses, main_action_T action_id, int verbose)
|
|||||||
shrink_memory(1);
|
shrink_memory(1);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case ACT_MAIN_CLEAN_TEMPORARY_FILES:
|
||||||
|
clean_temporary_files();
|
||||||
|
break;
|
||||||
|
|
||||||
case ACT_MAIN_COOKIES_LOAD:
|
case ACT_MAIN_COOKIES_LOAD:
|
||||||
#ifdef CONFIG_COOKIES
|
#ifdef CONFIG_COOKIES
|
||||||
if (!get_opt_bool("cookies.save", NULL)) break;
|
if (!get_opt_bool("cookies.save", NULL)) break;
|
||||||
|
Loading…
Reference in New Issue
Block a user