Commit 7d367710 authored by David Lawrence Ramsey's avatar David Lawrence Ramsey
Browse files

add DB's overhaul of the file browser code to increase efficiency and

add multibyte character support, plus a few tweaks of mine


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@2320 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
No related merge requests found
Showing with 388 additions and 337 deletions
+388 -337
......@@ -149,13 +149,15 @@ CVS code -
get the value of totsize in a few more places. Changes to
read_line(), read_file(), do_delete(), do_input(),
get_totals(), and do_cursorpos(). (DLR)
- Overhaul the tab completion code and a few related functions
to increase efficiency and support multibyte characters. New
functions strrchrn() and is_dir(); changes to get_full_path(),
check_writable_directory(), safe_tempnam(), diralphasort(),
username_tab_completion(), cwd_tab_completion(), input_tab(),
tail(), and striponedir(); removal of append_slash_if_dir()
and check_wildcard_match(). (David Benbennick) DLR: Move the
- Overhaul the tab completion code, the file browser code, and
related functions to increase efficiency and support multibyte
characters. New functions strrchrn() and is_dir(); changes to
get_full_path(), check_writable_directory(), safe_tempnam(),
diralphasort(), username_tab_completion(),
cwd_tab_completion(), input_tab(), tail(), striponedir(),
browser_init(), do_browser(), and do_browse_from(); removal of
append_slash_if_dir(), readable_dir(), and
check_wildcard_match(). (David Benbennick) DLR: Move the
routine to get the current user's home directory into the new
function get_homedir(), and use it where necessary. Also add
a few miscellaneous tweaks.
......
This diff is collapsed.
......@@ -23,6 +23,7 @@
#include <sys/types.h>
#include <sys/stat.h>
#include <dirent.h>
#ifdef HAVE_REGEX_H
#include <regex.h>
#endif
......@@ -298,10 +299,10 @@ char *input_tab(char *buf, size_t *place, bool *lastwastab, bool *list);
const char *tail(const char *foo);
#ifndef DISABLE_BROWSER
void free_charptrarray(char **array, size_t len);
void striponedir(char *foo);
int readable_dir(const char *path);
char **browser_init(const char *path, int *longest, int *numents);
char *do_browser(const char *inpath);
void striponedir(char *path);
char **browser_init(const char *path, int *longest, size_t *numents, DIR
*dir);
char *do_browser(char *path, DIR *dir);
char *do_browse_from(const char *inpath);
#endif
#if !defined(NANO_SMALL) && defined(ENABLE_NANORC)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment