cd = FALSE;
goto begin;
}
+ case SEL_CD: // fallthrough
+ case SEL_COPY:
+ if (!xdiraccess(plgpath)) {
+ printwarn(&presel);
+ goto nochange;
+ }
+ endselection(FALSE);
+ tmp = sel == SEL_CD ? "!_nnn-cd*" : "!_nnn-cp";
+ if (!run_plugin(&path, tmp, (ndents ? pdents[cur].name : NULL),
+ &lastname, &lastdir)) {
+ printwait(messages[MSG_FAILED], &presel);
+ goto nochange;
+ }
+ copycurname();
+ setdirwatch();
+ goto begin;
case SEL_PLUGIN:
/* Check if directory is accessible */
if (!xdiraccess(plgpath)) {
SEL_QUIT,
SEL_QUITERR,
SEL_VIEW,
+ SEL_COPY,
+ SEL_CD,
#ifndef NOMOUSE
SEL_CLICK,
#endif
{ KEY_F(3), SEL_VIEW },
/* Run a plugin */
{ ';', SEL_PLUGIN },
+ /* Call _nnn-cd */
+ { KEY_F(2), SEL_CD },
+ /* Call _nnn-cp */
+ { KEY_F(5), SEL_COPY },
/* Show total size of listed selection */
{ 'S', SEL_SELSIZE },
/* Run command */