diff options
Diffstat (limited to 'rt.lua')
| -rw-r--r-- | rt.lua | 13 |
1 files changed, 11 insertions, 2 deletions
@@ -621,6 +621,9 @@ function rt.open_option_info(opt) end end +local F_NAME = {name = true} +local F_INFO = {info = true} +local F_BOTH = {name = true, info = true} local function search_text_transform(f, ...) local menu = state:menu() local str, pos = f(menu.search_text, menu.search_cursor, ...) @@ -642,14 +645,20 @@ local function search_text_transform(f, ...) local fm = prefix:find('m') local fs = prefix:find('s') local fg = prefix:find('g') + local fe = prefix:find('e') filter = function(v) - return fc and (v.stream_type == 'live' or - v.stream_type == 'radio_streams') or + local fields + local ch = v.stream_type == 'live' or + v.stream_type == 'radio_streams' + local name = fc and ch or fm and v.stream_type == 'movie' or fs and v.group_type == 'series' or fg and v.type == 'group' and v.group_type ~= 'series' + local info = fe and ch and v.info + return name and (info and F_BOTH or F_NAME) or + info and F_INFO end end |
