summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: c94d06d)
raw | patch | inline | side by side (parent: c94d06d)
author | Kalle Wallin <kaw@linux.se> | |
Wed, 15 Jun 2005 20:36:50 +0000 (20:36 +0000) | ||
committer | Kalle Wallin <kaw@linux.se> | |
Wed, 15 Jun 2005 20:36:50 +0000 (20:36 +0000) |
ChangeLog | patch | blob | history | |
doc/config.sample | patch | blob | history | |
src/conf.c | patch | blob | history | |
src/options.h | patch | blob | history | |
src/screen_utils.c | patch | blob | history |
diff --git a/ChangeLog b/ChangeLog
index ed3e6127aea4b8cd9964a50436bb74b18896d746..41df37818989f65101b941c792acbaa3ea90068e 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
2005-06-15: Kalle Wallin <kaw@linux.se>
* Added configuraton option screen-list
+ * Added configuraton option find-show-last
2005-06-14: Kalle Wallin <kaw@linux.se>
* Moved list window state code to list_window.c
* Added Russian translations from Nikolay Pavlov
2004-12-19: Kalle Wallin <kaw@linux.se>
- * Bugfixes from Niko Tyni, survive select/find operations on an empty
- list
+ * Bugfixes from Niko Tyni, survive select/find operations on an
+ empty list
2004-12-12 Kalle Wallin <kaw@linux.se>
* screen_play.c: Fixed abort (Ctrl-G) handling in the save playlist
* command.c: added my_wgetch() function,
Ctrl-C, Ctrl-Z are now hard coded to SIGINT and SIGSTOP
* options.c: added options --mouse and --no-mouse
- * Crossfade time can now be definied in the conf file (crossfade-time)
+ * crossfade-time can now be definied in the conf file
* r1865
2004-07-12 Kalle Wallin <kaw@linux.se>
2004-07-02 Kalle Wallin <kaw@linux.se>
* options.c: improved error handling in the argv parser
* screen_play.c: scroll up when moving a item uppwards
- * mpdclient.c: redesigned the plchanges code (its now based on qball's)
+ * mpdclient.c: redesigned the plchanges code (its now based on
+ qball's)
* Added ncurses basic mouse support (playlist and browse screens)
2004-07-01 Kalle Wallin <kaw@linux.se>
2004-06-17 Kalle Wallin <kaw@linux.se>
* screen_file.c: let mpd add directories (just send the path)
* main.c: only set xterm title if DEBUG is defined
- * mpdclient.[c|h]: added _utf8 suffix to all functions that take utf8
- arguments.
+ * mpdclient.[c|h]: added _utf8 suffix to all functions that take
+ utf8 arguments.
* command.c: Support cursor/down with j and k
2004-06-17 Kalle Wallin <kaw@linux.se>
* wreadln.c: try to complete even if the line is empty
* utils.c: added type argument to gcmp_list_from_path()
* screen_play.c: added completion support to handle_save_playlist()
- * command.[c|h]: check_key_bindings() can now write an error messages
- to a buffer instead of stderr
+ * command.[c|h]: check_key_bindings() can now write an error messages
+ to a buffer instead of stderr
* main.c: display errors without exiting when key bindings are broken
* screen_help.c: added the add command to the help screen
2004-06-17 Kalle Wallin <kaw@linux.se>
- * Added a add command, used to add urls or files to the playlist, with
- file completion.
+ * Added a add command, used to add urls or files to the playlist,
+ with file completion.
2004-06-16 Kalle Wallin <kaw@linux.se>
2004-06-16 Kalle Wallin <kaw@linux.se>
* libmpdclient updated (r1507)
* mpdclient: add path to mpdclient_cmd_db_update()
- * screen_file.c: Use current path when updating the db (browse screen)
+ * screen_file.c: Use current path when updating the db
2004-06-15 Kalle Wallin <kaw@linux.se>
* conf.c: Replaced '_' with '-' in configuration field names
flow control characters)
* command.*: Added the get_keyboard_command_with_timeout() function
* main.c: Redesigned the reconnect code to allow user interrupt
- * screen*: Changed arguments to the get_title callback (and the title)
+ * screen*: Changed title and arguments for get_title callback()
* support.c: moved utility function for scrolling
* list_window.c: fixed a small layout bug in list_window_paint()
diff --git a/doc/config.sample b/doc/config.sample
index 7be4181c68ccd7054a1725b6eb64f459e1da09ac..3c80c2f530668be2edcc75fc5a375f68f22a1a55 100644 (file)
--- a/doc/config.sample
+++ b/doc/config.sample
## wrapped find mode
#find-wrap = yes
+## show last pattern when using find
+#find-show-last = no
+
## list-format
#list-format = "%name%|[%artist% - ]%title%|%file%"
diff --git a/src/conf.c b/src/conf.c
index 73135b8f64ce8875c9e407a9673fc8dbef054bb7..4b5e49230e1b8820527d33fd05776c925c528edf 100644 (file)
--- a/src/conf.c
+++ b/src/conf.c
#define CONF_XTERM_TITLE_FORMAT "xterm-title-format"
#define CONF_LIST_WRAP "wrap-around"
#define CONF_FIND_WRAP "find-wrap"
+#define CONF_FIND_SHOW_LAST "find-show-last"
#define CONF_AUDIBLE_BELL "audible-bell"
#define CONF_VISIBLE_BELL "visible-bell"
#define CONF_XTERM_TITLE "set-xterm-title"
{
options->find_wrap = str2bool(value);
}
+ else if( !strcasecmp(CONF_FIND_SHOW_LAST,name) )
+ {
+ options->find_show_last_pattern = str2bool(value);
+ }
else if( !strcasecmp(CONF_AUDIBLE_BELL, name) )
{
options->audible_bell = str2bool(value);
diff --git a/src/options.h b/src/options.h
index 6acf88b0902ccc03a9754d33fdab619abb61be5e..10aba1441b43313c096be706a866066c2e23c463 100644 (file)
--- a/src/options.h
+++ b/src/options.h
gboolean reconnect;
gboolean debug;
gboolean find_wrap;
+ gboolean find_show_last_pattern;
gboolean list_wrap;
gboolean auto_center;
gboolean wide_cursor;
diff --git a/src/screen_utils.c b/src/screen_utils.c
index 09ce857873a874f02b17e4c8bbba4a896a38fd6f..86b77924567087d27ad04440f85ffc9b6213396f 100644 (file)
--- a/src/screen_utils.c
+++ b/src/screen_utils.c
int reversed = 0;
int retval = 0;
char *prompt = FIND_PROMPT;
+ char *value = options.find_show_last_pattern ? (char *) -1 : NULL;
if( findcmd==CMD_LIST_RFIND ||findcmd==CMD_LIST_RFIND_NEXT )
{
if( !screen->findbuf )
screen->findbuf=screen_readln(screen->status_window.w,
prompt,
- (char *) -1, //NULL,
+ value,
&screen->find_history,
NULL);
if( !screen->findbuf || !screen->findbuf[0] )