Fixed an issue where double click to open a file in the file manager is not working. #9196

pull/9460/head
Aditya Toshniwal 2025-12-15 13:28:00 +05:30
parent 491fbe8a36
commit 5dd07d5d4b
3 changed files with 6 additions and 2 deletions

View File

@ -29,6 +29,7 @@ Housekeeping
Bug fixes
*********
| `Issue #9196 <https://github.com/pgadmin-org/pgadmin4/issues/9196>`_ - Fixed an issue where double click to open a file in the file manager is not working.
| `Issue #9380 <https://github.com/pgadmin-org/pgadmin4/issues/9380>`_ - Fixed an issue where the Query History panel would auto-scroll to the top and did not preserve the scroll bar position for the selected entry.

View File

@ -690,7 +690,7 @@ export default function FileManager({params, closeModal, onOK, onCancel, sharedS
const onItemEnter = useCallback(async (row)=>{
if(row.file_type == 'dir' || row.file_type == 'drive') {
await openDir(row.Path, selectedSS);
} else if(params.dialog_type == 'select_file') {
} else if(params.dialog_type == 'select_file' || params.dialog_type == 'open_file') {
onOkClick();
}
}, [finalItems]);

View File

@ -113,7 +113,10 @@ export function CustomRow({inTest=false, ...props}) {
props.onRowClick?.(args.row);
};
const onCellDoubleClick = (args) => {
const onCellDoubleClick = (args, e) => {
// check if grid default is prevented.
props.onCellDoubleClick?.(args, e);
if(e.isGridDefaultPrevented()) return;
gridUtils.onItemEnter?.(args.row);
};