a
    §ˆcC	  ã                   @   s,   d dl mZ d dlmZ G dd„ deƒZdS )é    )ÚInstance)ÚDockPanec                   @   s0   e Zd ZdZedƒZdd„ Zdd„ Zdd„ Zd	S )
ÚEnamlDockPanez* Create a Dock pane for Enaml Components. z*enaml.widgets.toolkit_object.ToolkitObjectc                 C   s
   t ƒ ‚dS )z� Return an Enaml component defining the contents of the DockPane.

        Returns
        -------
        component : ToolkitObject
        N)ÚNotImplementedError)Úself© r   ú_/home/yuhw/wc/wire-cell-python/wcpy/lib/python3.9/site-packages/pyface/tasks/enaml_dock_pane.pyÚcreate_component   s    zEnamlDockPane.create_componentc                 C   s4   |   ¡ | _| j ¡  | jjs&| j ¡  | jjj}|S )z? Return the toolkit-specific control that represents the pane. )r	   Ú	componentZ
initializeZproxy_is_activeZactivate_proxyÚproxyZwidget)r   ÚparentÚcontentsr   r   r   Úcreate_contents(   s    



zEnamlDockPane.create_contentsc                 C   sB   | j }|dur2| ¡  | j ¡  | d¡ | ¡  d| _ d| _dS )z@ Destroy the toolkit-specific control that represents the pane. N)ÚcontrolÚhider
   ÚdestroyÚ	setParentZdeleteLater)r   r   r   r   r   r   =   s    

zEnamlDockPane.destroyN)	Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   r
   r	   r   r   r   r   r   r   r      s
   r   N)Z
traits.apir   Zpyface.tasks.dock_paner   r   r   r   r   r   Ú<module>   s   