You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

57 lines
1.1 KiB

import functools
import asyncio
import logging
import threading
import time
import uuid
import quamash
from PyQt5.QtCore import Qt
from PyQt5 import QtCore
from PyQt5 import QtWidgets
from PyQt5 import QtGui
from noisicaa import core
from noisicaa.core import ipc
from . import editor_app
from .. import runtime_settings
logger = logging.getLogger(__name__)
class UIProcessMixin(object):
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs) = self.create_app(
self, runtime_settings.RuntimeSettings(), [])
def create_app(self, *args, **kwargs):
return editor_app.EditorApp(*args, **kwargs)
def create_event_loop(self):
return quamash.QEventLoop(
async def setup(self):
self._shutting_down = asyncio.Event()
await super().setup()
async def cleanup(self):
await super().cleanup()
async def run(self):
await self._shutting_down.wait()
def quit(self):
class UIProcess(UIProcessMixin, core.ProcessImpl):