| Server IP : 217.160.0.135 / Your IP : 216.73.217.85 Web Server : Apache System : Linux www 6.18.52-i1-ampere #1203 SMP Mon Sep 14 18:29:59 CEST 2026 aarch64 User : sws1074145052 ( 1074145052) PHP Version : 8.3.32 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /lib/python3/dist-packages/IPython/terminal/pt_inputhooks/__pycache__/ |
Upload File : |
�
�@�c@ � �v � d Z ddlZddlZddlmZ ddlZej � d� � rd� Z nd� Z d� Z
dS )z;Enable pyglet to be used interactively with prompt_toolkit
� N)�
default_timer�linuxc �R � | � � � d S # t $ r Y d S w xY w�N)�flip�AttributeError��windows �G/usr/lib/python3/dist-packages/IPython/terminal/pt_inputhooks/pyglet.pyr r s: � � ��K�K�M�M�M�M�M��� � � ��D�D� ���s � �
&�&c �. � | � � � d S r )r r s r r r s � ����
�
�
�
�
� c �L � t � � }| � � � s�t j � � � t j j D ]N}|� � � |� � � |� d� � t |� � �Ot � � |z
}|dk rt j d� � n/|dk rt j d� � nt j d� � | � � � ��dS dS # t $ r Y dS w xY w)aE Run the pyglet event loop by processing pending events only.
This keeps processing pending events until stdin is ready. After
processing all pending events, a call to time.sleep is inserted. This is
needed, otherwise, CPU usage is at 100%. This sleep time should be tuned
though for best performance.
�on_drawg $@g �?g�������?g�������?g����MbP?N)
�clock�input_is_ready�pyglet�tick�app�windows� switch_to�dispatch_events�dispatch_eventr �time�sleep�KeyboardInterrupt)�context�tr
� used_times r � inputhookr s8 � �
��G�G���(�(�*�*� "��L������ �*�,�
�
��� � �"�"�"��&�&�(�(�(��%�%�i�0�0�0��V����� ���!��I��4����
�3������S��� �
�4� � � � � �
�5�!�!�!�9 �(�(�*�*� "� "� "� "� "��: �
�
�
����
���s �DD �
D#�"D#)�__doc__�sysr �timeitr r r �platform�
startswithr r � r
r �<module>r&