INI option log_file_entry.
This commit is contained in:
@@ -157,3 +157,8 @@ shared_folder=
|
||||
; Set to 0 for name mapping (jn) (e.g. A button in SNES core = A button on controller regardless of position on pad)
|
||||
; Set to 1 for positional mapping (jp) (e.g. A button in SNES core = East button on controller regardless of button name)
|
||||
gamepad_defaults=0
|
||||
|
||||
; Write out file name under the cursor in browser for external integration
|
||||
; External application or script may parse the info and do some additional actions and/or send info to 3rd party server.
|
||||
; Warning: it may slowdown the system or add lag while browsing the files in OSD depending on external app/script.
|
||||
log_file_entry=0
|
||||
|
||||
1
cfg.cpp
1
cfg.cpp
@@ -82,6 +82,7 @@ static const ini_var_t ini_vars[] =
|
||||
{ "SPINNER_THROTTLE", (void*)(&(cfg.spinner_throttle)), INT32, -10000, 10000 },
|
||||
{ "AFILTER_DEFAULT", (void*)(&(cfg.afilter_default)), STRING, 0, sizeof(cfg.afilter_default) - 1 },
|
||||
{ "VFILTER_DEFAULT", (void*)(&(cfg.vfilter_default)), STRING, 0, sizeof(cfg.vfilter_default) - 1 },
|
||||
{ "LOG_FILE_ENTRY", (void*)(&(cfg.log_file_entry)), UINT8, 0, 1 },
|
||||
};
|
||||
|
||||
static const int nvars = (int)(sizeof(ini_vars) / sizeof(ini_var_t));
|
||||
|
||||
1
cfg.h
1
cfg.h
@@ -51,6 +51,7 @@ typedef struct {
|
||||
uint8_t sniper_mode;
|
||||
uint8_t browse_expand;
|
||||
uint8_t logo;
|
||||
uint8_t log_file_entry;
|
||||
char bootcore[256];
|
||||
char video_conf[1024];
|
||||
char video_conf_pal[1024];
|
||||
|
||||
20
menu.cpp
20
menu.cpp
@@ -4415,15 +4415,17 @@ void HandleUI(void)
|
||||
if (flist_nDirEntries())
|
||||
{
|
||||
ScrollLongName(); // scrolls file name if longer than display line
|
||||
|
||||
//Write out paths infos for external integration
|
||||
FILE* filePtr = fopen("/tmp/CURRENTPATH","w");
|
||||
FILE* pathPtr = fopen("/tmp/FULLPATH","w");
|
||||
fprintf(filePtr, "%s", flist_SelectedItem()->altname);
|
||||
fprintf(pathPtr, "%s", selPath);
|
||||
fclose(filePtr);
|
||||
fclose(pathPtr);
|
||||
|
||||
|
||||
if (cfg.log_file_entry)
|
||||
{
|
||||
//Write out paths infos for external integration
|
||||
FILE* filePtr = fopen("/tmp/CURRENTPATH", "w");
|
||||
FILE* pathPtr = fopen("/tmp/FULLPATH", "w");
|
||||
fprintf(filePtr, "%s", flist_SelectedItem()->altname);
|
||||
fprintf(pathPtr, "%s", selPath);
|
||||
fclose(filePtr);
|
||||
fclose(pathPtr);
|
||||
}
|
||||
|
||||
if (c == KEY_HOME)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user