Worker file manager

Context menus

Arbitrary commands can be assigned to file types and accessed with the context menu. Read on to learn about how to add new entries to the context menu.

How to modify the context menu for files

The context menu (introduced in Worker 2.16.0) allows easy access to the file type actions defined for a file type. You can also add additional actions to be available via the context menu. The following example illustrates the necessary steps.

Let's consider the following situation. For video files there's already a "show" action defined which executes mplayer for playing the actual file. Now you want to have an option to play a file with some specific arguments (like "-forceidx"). If you add another action for the corresponding file type you will be able to select it from the context menu.

1. Open the configuration for the video file type. There are several video formats defined in the default configuration but we want to add this action for all video files so select the parent type "video".
2. When you edit this file type you see a list of actions defined for this type. There are many predefined actions like the "show" action. Now click on "New action" to create another custom action.
3. Enter some appropriate name (e.g. "mplayer -forceidx") and click "Okay".
4. Add a new command for this action, in our case the "own command". Enter "mplayer -forceidx {f}" as program name and close the dialog again.
5. Close all dialogs and save the configuration.
6. Now you can go to a video file and open the context menu by right clicking on it. You should see the newly created action in the menu and it should start mplayer with the argument "-forceidx" when selected.
Tips: