Catch Filer Open Window
Stefan Fröhling (7826) 167 posts |
Is there a way to link into the the opening of the Filer window by the multiple FS (ADFS; SCSIFS,RAMFS etc.). |
Rick Murray (539) 13850 posts |
Apparently not. There’s a message that is sent to tell the filer to open a directory, however the documentation states: Filing system modules use Service_StartFiler to record the Filer’s task handle and hence do not use a broadcast message.Perhaps by replacing the iconbar icon for the nominated filesystems, then you can handle it all yourself? |
Steve Pampling (1551) 8172 posts |
Certainly been done before, usually to gather multiple drive icons across multiple file systems into one iconbar icon. |
David J. Ruck (33) 1636 posts |
You could use a Wimp Filter to intercept clicks on the drive icons of various filing systems. You would also need to trap *Filer_OpenDir commands from scripts. |
Fred Graute (114) 645 posts |
You could set up a Wimp filter for the messages FilerOpenDir and FilerOpenDirAt, as well DataOpen (for filetypes &1000 and &2000). Not sure if this captures all, but it provides a starting point. |
Stefan Fröhling (7826) 167 posts |
Ok thanks for the ideas. Will not be done in short time but in the next major update. |
Chris Hall (132) 3558 posts |
The code below will set the current directory to the last file double-clicked by intercepting the DataOpen message. It is the method used by !MultiTask to make sure that if you double-click a file, the csd is set to the directory it came from so that you don’t have to bother about path names:
|
Stefan Fröhling (7826) 167 posts |
Thanks Chris for the code example. Surely a good example how you can interfere in RISC OS. |
Chris Hall (132) 3558 posts |
The example intercepts the ‘double click’ (&005 DataOpen) message from a filer window. The message &400 Message_FilerOpenDir is sent to ask the Filer to open a new directory see PRM 3-233. Filer modules send this message directly to the filer for the relevant filesystem and do not broadcast it (but the double click will already have been captured) so this will pick up any Filer_OpenDir commands (which have to be broadcast as the full pathname is part of the message). |
Stefan Fröhling (7826) 167 posts |
Now I got it! Thanks! |