From c9ce2f63498df1e841af683066597d6edd6a277e Mon Sep 17 00:00:00 2001 From: Andre Miras Date: Fri, 9 Feb 2024 21:53:44 +0100 Subject: [PATCH] :rotating_light: Format fix Most likely a `black` update --- examples/audio_controller_class_example.py | 1 + examples/audio_endpoint_volume_example.py | 1 + examples/session_callback_example.py | 1 + examples/simple_audio_volume_example.py | 1 + examples/volume_by_process_example.py | 1 + examples/volume_callback_example.py | 1 + pycaw/pycaw.py | 1 + tests/test_core.py | 1 + tests/test_examples.py | 1 + 9 files changed, 9 insertions(+) diff --git a/examples/audio_controller_class_example.py b/examples/audio_controller_class_example.py index 92adaa9..e87784c 100644 --- a/examples/audio_controller_class_example.py +++ b/examples/audio_controller_class_example.py @@ -2,6 +2,7 @@ Per session GetMute() SetMute() GetMasterVolume() SetMasterVolume() using SimpleAudioVolume. """ + from pycaw.pycaw import AudioUtilities diff --git a/examples/audio_endpoint_volume_example.py b/examples/audio_endpoint_volume_example.py index eb8bd2a..a72058a 100644 --- a/examples/audio_endpoint_volume_example.py +++ b/examples/audio_endpoint_volume_example.py @@ -1,6 +1,7 @@ """ Get and set access to master volume example. """ + from ctypes import POINTER, cast from comtypes import CLSCTX_ALL diff --git a/examples/session_callback_example.py b/examples/session_callback_example.py index 4a2d153..2a0163c 100644 --- a/examples/session_callback_example.py +++ b/examples/session_callback_example.py @@ -20,6 +20,7 @@ https://docs.microsoft.com/en-us/windows/win32/api/audiopolicy/nn-audiopolicy-iaudiosessionevents """ + import time from comtypes import COMError diff --git a/examples/simple_audio_volume_example.py b/examples/simple_audio_volume_example.py index fa94ed9..eed5b78 100644 --- a/examples/simple_audio_volume_example.py +++ b/examples/simple_audio_volume_example.py @@ -1,6 +1,7 @@ """ Per session GetMute() SetMute() using ISimpleAudioVolume. """ + from pycaw.pycaw import AudioUtilities, ISimpleAudioVolume diff --git a/examples/volume_by_process_example.py b/examples/volume_by_process_example.py index a9f1b7c..3ec709e 100644 --- a/examples/volume_by_process_example.py +++ b/examples/volume_by_process_example.py @@ -1,6 +1,7 @@ """ Mutes the volume of all processes, but unmutes chrome.exe process. """ + from pycaw.pycaw import AudioUtilities diff --git a/examples/volume_callback_example.py b/examples/volume_callback_example.py index 13a4293..7d6dd91 100644 --- a/examples/volume_callback_example.py +++ b/examples/volume_callback_example.py @@ -2,6 +2,7 @@ IAudioEndpointVolumeCallback.OnNotify() example. The OnNotify() callback method gets called on volume change. """ + from ctypes import POINTER, cast from comtypes import CLSCTX_ALL, COMObject diff --git a/pycaw/pycaw.py b/pycaw/pycaw.py index 0f2f826..e4339eb 100644 --- a/pycaw/pycaw.py +++ b/pycaw/pycaw.py @@ -1,6 +1,7 @@ """ Python wrapper around the Core Audio Windows API. """ + # import here all newly split up modules, # to keep backwards compatibility diff --git a/tests/test_core.py b/tests/test_core.py index 5448c81..437aa4a 100644 --- a/tests/test_core.py +++ b/tests/test_core.py @@ -1,6 +1,7 @@ """ Verifies core features run as expected. """ + import sys import warnings from contextlib import contextmanager diff --git a/tests/test_examples.py b/tests/test_examples.py index f229c35..8c53e73 100644 --- a/tests/test_examples.py +++ b/tests/test_examples.py @@ -1,6 +1,7 @@ """ Verifies examples run as expected. """ + import pytest from examples import (