a
    ¦ˆcW  ã                   @   st   d Z ddlZddlmZmZmZmZmZmZ ddl	m
Z
 ddlmZ ddlmZ G dd„ deƒZG d	d
„ d
eƒZdS )ú$ The interface for a splash screen. é    N)ÚAnyÚBoolÚ	HasTraitsÚIntÚTupleÚStr)ÚImage)ÚSplashScreenLogHandler)ÚIWindowc                   @   sD   e Zd ZdZeƒ ZeejƒZ	e
dƒZeƒ Zeƒ Zeƒ ZeddƒZdS )ÚISplashScreenr   Té   N)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r	   Úimager   ÚloggingÚDEBUGÚ	log_levelr   Úshow_log_messagesr   Útextr   Z
text_colorZ	text_fontr   Ztext_location© r   r   úY/home/yuhw/wc/wire-cell-python/wcpy/lib/python3.9/site-packages/pyface/i_splash_screen.pyr      s   
r   c                       s,   e Zd ZdZ‡ fdd„Z‡ fdd„Z‡  ZS )ÚMSplashScreenz› The mixin class that contains common code for toolkit specific
    implementations of the ISplashScreen interface.

    Reimplements: open(), close()
    c                    s@   t ƒ  ¡  | jr<t| ƒ| _| j | j¡ t ¡ }| 	| j¡ dS )z6 Creates the toolkit-specific control for the widget. N)
ÚsuperÚopenr   r
   Ú_log_handlerÚsetLevelr   r   Ú	getLoggerÚ
addHandler©ÚselfÚlogger©Ú	__class__r   r   r   H   s    

zMSplashScreen.openc                    s(   | j rt ¡ }| | j¡ tƒ  ¡  dS )z Close the window. N)r   r   r   ÚremoveHandlerr   r   Úcloser!   r$   r   r   r'   U   s    zMSplashScreen.close)r   r   r   r   r   r'   Ú__classcell__r   r   r$   r   r   =   s   
r   )r   r   Z
traits.apir   r   r   r   r   r   Zpyface.ui_traitsr	   Z pyface.splash_screen_log_handlerr
   Zpyface.i_windowr   r   r   r   r   r   r   Ú<module>   s    $