Actions extensions in File Managers - Draft 0.12

PCMan at
Mon Jul 19 11:35:49 PDT 2010

But then we have a bug.
It's not possible to create context menu items which are only shown in
sub menus.
Since any action applied to currently selected files will be displayed
in level 0 no matter they are in submenus or not if they have
TargetContext. This makes submenu totally useless.
So I think this needs to be fixed. A potentially way to solve this:
Replace TargetContext and TargetToolbar with:
Target=Context;Toolbar;...; # then it can be easily extensible in the future.

Then, add this:
If an action got this, it's only shown in submenus, not level 0.

I think this is required for submenus to be really useful.

On Mon, Jul 19, 2010 at 8:12 PM, Pierre Wieser <pwieser at> wrote:
> ----- "PCMan" < at> a écrit :
>> Another potential problem of this spec.
>> When we validate all actions against currently selected files, we can
>> get a list of valid actions.
>> However, if an action is also in ItemList of another menu, should we
>> only show it in that menu and remove it from the context menu, or
>> show
>> it both in the context menu of the file managers and the sub menus
>> defined with ItemList?
>> Or, in this case, we should set TargetContext=false, so it's hidden
>> from the main context menu, but can be shown in sub menus since it's
>> listed in ItemList of another Menu?
> Hi,
> I agree that the spec let an action be potentially referenced in more
> than one place, e.g. as you say, at the level zero of the context menu
> _and_ as a subitem of a menu.
> I would suggest that in such a case the action be actually shown more
> than once, i.e. exactly where .desktop configuration tell us to do so.
> In my mind, if TargetContext=false, the action cannot be displayed in
> the context menu at all, whether it is at the level zero of the tree or
> in a submenu.
> Do you agree on that ?
> Regards
> Pierre

More information about the xdg mailing list