3
<Ad](  ã               @   s$   d Z ddlmZ G dd„ deƒZdS )zC The default action controller for menus, menu bars and tool bars. é    )Ú	HasTraitsc               @   s8   e Zd ZdZdd„ Zdd„ Zdd„ Zdd	„ Zd
d„ ZdS )ÚActionControllerzC The default action controller for menus, menu bars and tool bars. c             C   s
   |j |ƒS )ad   Control an action invocation.

        Parameters
        ----------
        action : Action instance
            The action to perform.
        event : ActionEvent instance
            The event that triggered the action.

        Returns
        -------
        result : any
            The result of the action's perform method (usually None).
        )Úperform)ÚselfÚactionÚevent© r   úy/home/yuhw/wc/wire-cell-python/wcpy/lib/python3.6/site-packages/pyface-6.1.2-py3.6.egg/pyface/action/action_controller.pyr      s    zActionController.performc             C   s   dS )a   Can add an action to a menu

        Parameters
        ----------
        action : Action instance
            The action to consider.

        Returns
        -------
        can_add : bool
            ``True` if the action can be added to a menu/menubar.
        Tr   )r   r   r   r   r	   Úcan_add_to_menu    s    z ActionController.can_add_to_menuc             C   s   dS )z± Called when an action is added to the a menu/menubar.

        Parameters
        ----------
        action : Action instance
            The action added to the menu.
        Nr   )r   r   r   r   r	   Úadd_to_menu/   s    zActionController.add_to_menuc             C   s   dS )a    Returns True if the action can be added to a toolbar.

        Parameters
        ----------
        action : Action instance
            The action to consider.

        Returns
        -------
        can_add : bool
            ``True` if the action can be added to a toolbar.
        Tr   )r   r   r   r   r	   Úcan_add_to_toolbar9   s    z#ActionController.can_add_to_toolbarc             C   s   dS )z¯ Called when an action is added to the a toolbar.

        Parameters
        ----------
        action : Action instance
            The action added to the toolbar.
        Nr   )r   r   r   r   r	   Úadd_to_toolbarH   s    zActionController.add_to_toolbarN)	Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   r
   r   r   r   r   r   r   r	   r      s   
r   N)r   Z
traits.apir   r   r   r   r   r	   Ú<module>   s   