fixed resources and remove openpype icons

This commit is contained in:
Jakub Trllo 2024-02-06 14:18:22 +01:00
parent eef157363e
commit a7133d870b
26 changed files with 47 additions and 39 deletions

View file

@ -14,7 +14,7 @@ from ayon_core.hosts.fusion.api.lib import (
set_asset_resolution,
)
from ayon_core.pipeline import get_current_asset_name
from ayon_core.resources import get_openpype_icon_filepath
from ayon_core.resources import get_ayon_icon_filepath
from .pipeline import FusionEventHandler
from .pulse import FusionPulse
@ -33,7 +33,7 @@ class OpenPypeMenu(QtWidgets.QWidget):
self.setObjectName(f"{MENU_LABEL}Menu")
icon_path = get_openpype_icon_filepath()
icon_path = get_ayon_icon_filepath()
icon = QtGui.QIcon(icon_path)
self.setWindowIcon(icon)

View file

@ -15,7 +15,7 @@ import os
from ayon_core.client import get_asset_by_name
from ayon_core.pipeline import registered_host
from ayon_core.pipeline.create import CreateContext
from ayon_core.resources import get_openpype_icon_filepath
from ayon_core.resources import get_ayon_icon_filepath
import hou
import stateutils
@ -172,7 +172,7 @@ def install():
# and update the tools file if creator identifiers change
os.remove(filepath)
icon = get_openpype_icon_filepath()
icon = get_ayon_icon_filepath()
tab_menu_label = os.environ.get("AVALON_LABEL") or "AYON"
# Create context only to get creator plugins, so we don't reset and only

View file

@ -31,7 +31,7 @@ class ShaderDefinitionsEditor(QtWidgets.QWidget):
self.setObjectName("shaderDefinitionEditor")
self.setWindowTitle("OpenPype shader name definition editor")
icon = QtGui.QIcon(resources.get_openpype_icon_filepath())
icon = QtGui.QIcon(resources.get_ayon_icon_filepath())
self.setWindowIcon(icon)
self.setWindowFlags(QtCore.Qt.Window)
self.setParent(parent)

View file

@ -65,7 +65,7 @@ class ToolsDialog(QtWidgets.QDialog):
super(ToolsDialog, self).__init__(*args, **kwargs)
self.setWindowTitle("Ayon tools")
icon = QtGui.QIcon(resources.get_openpype_icon_filepath())
icon = QtGui.QIcon(resources.get_ayon_icon_filepath())
self.setWindowIcon(icon)
self.setWindowFlags(

View file

@ -37,10 +37,10 @@ class SplashScreen(QtWidgets.QDialog):
super(SplashScreen, self).__init__()
if splash_icon is None:
splash_icon = resources.get_openpype_icon_filepath()
splash_icon = resources.get_ayon_icon_filepath()
if window_icon is None:
window_icon = resources.get_openpype_icon_filepath()
window_icon = resources.get_ayon_icon_filepath()
self.splash_icon = splash_icon
self.setWindowIcon(QtGui.QIcon(window_icon))

View file

@ -13,7 +13,7 @@ class MessageWidget(QtWidgets.QWidget):
super(MessageWidget, self).__init__()
# Icon
icon = QtGui.QIcon(resources.get_openpype_icon_filepath())
icon = QtGui.QIcon(resources.get_ayon_icon_filepath())
self.setWindowIcon(icon)
self.setWindowFlags(
@ -90,7 +90,7 @@ class ClockifySettings(QtWidgets.QWidget):
self.validated = False
# Icon
icon = QtGui.QIcon(resources.get_openpype_icon_filepath())
icon = QtGui.QIcon(resources.get_ayon_icon_filepath())
self.setWindowIcon(icon)
self.setWindowTitle("Clockify settings")

View file

@ -335,7 +335,7 @@ class PythonInterpreterWidget(QtWidgets.QWidget):
super(PythonInterpreterWidget, self).__init__(parent)
self.setWindowTitle("AYON Console")
self.setWindowIcon(QtGui.QIcon(resources.get_openpype_icon_filepath()))
self.setWindowIcon(QtGui.QIcon(resources.get_ayon_icon_filepath()))
self.ansi_escape = re.compile(
r"(?:\x1B[@-_]|[\x80-\x9F])[0-?]*[ -/]*[@-~]"

View file

@ -11,7 +11,7 @@ class WidgetUserIdle(QtWidgets.QWidget):
self.setWindowTitle("OpenPype - Stop timers")
icon = QtGui.QIcon(resources.get_openpype_icon_filepath())
icon = QtGui.QIcon(resources.get_ayon_icon_filepath())
self.setWindowIcon(icon)
self.setWindowFlags(

View file

@ -61,7 +61,7 @@ class DeliveryOptionsDialog(QtWidgets.QDialog):
super(DeliveryOptionsDialog, self).__init__(parent=parent)
self.setWindowTitle("OpenPype - Deliver versions")
icon = QtGui.QIcon(resources.get_openpype_icon_filepath())
icon = QtGui.QIcon(resources.get_ayon_icon_filepath())
self.setWindowIcon(icon)
self.setWindowFlags(

View file

@ -1,5 +1,5 @@
import os
from ayon_core.lib.openpype_version import is_staging_enabled
from ayon_core.lib import is_staging_enabled
RESOURCES_DIR = os.path.dirname(os.path.abspath(__file__))
@ -39,15 +39,15 @@ def get_liberation_font_path(bold=False, italic=False):
return font_path
def get_openpype_production_icon_filepath():
def get_ayon_production_icon_filepath():
return get_resource("icons", "AYON_icon.png")
def get_openpype_staging_icon_filepath():
def get_ayon_staging_icon_filepath():
return get_resource("icons", "AYON_icon_staging.png")
def get_openpype_icon_filepath(staging=None):
def get_ayon_icon_filepath(staging=None):
if os.getenv("AYON_USE_DEV") == "1":
return get_resource("icons", "AYON_icon_dev.png")
@ -55,11 +55,11 @@ def get_openpype_icon_filepath(staging=None):
staging = is_staging_enabled()
if staging:
return get_openpype_staging_icon_filepath()
return get_openpype_production_icon_filepath()
return get_ayon_staging_icon_filepath()
return get_ayon_production_icon_filepath()
def get_openpype_splash_filepath(staging=None):
def get_ayon_splash_filepath(staging=None):
if staging is None:
staging = is_staging_enabled()
@ -72,9 +72,17 @@ def get_openpype_splash_filepath(staging=None):
return get_resource("icons", splash_file_name)
def pype_icon_filepath(staging=None):
return get_openpype_icon_filepath(staging)
def get_openpype_production_icon_filepath():
return get_ayon_production_icon_filepath()
def pype_splash_filepath(staging=None):
return get_openpype_splash_filepath(staging)
def get_openpype_staging_icon_filepath():
return get_ayon_staging_icon_filepath()
def get_openpype_icon_filepath(staging=None):
return get_ayon_icon_filepath(staging)
def get_openpype_splash_filepath(staging=None):
return get_ayon_splash_filepath(staging)

Binary file not shown.

Before

Width:  |  Height:  |  Size: 113 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 112 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 33 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 84 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 86 KiB

View file

@ -208,7 +208,7 @@ def load_stylesheet():
def get_app_icon_path():
"""Path to OpenPype icon."""
return resources.get_openpype_icon_filepath()
return resources.get_ayon_icon_filepath()
def app_icon_path():

View file

@ -102,7 +102,7 @@ class ApplicationAction(LauncherAction):
from ayon_core import style
dialog = QtWidgets.QMessageBox()
icon = QtGui.QIcon(resources.get_openpype_icon_filepath())
icon = QtGui.QIcon(resources.get_ayon_icon_filepath())
dialog.setWindowIcon(icon)
dialog.setStyleSheet(style.load_stylesheet())
dialog.setWindowTitle(title)

View file

@ -22,7 +22,7 @@ class LauncherWindow(QtWidgets.QWidget):
if controller is None:
controller = BaseLauncherController()
icon = QtGui.QIcon(resources.get_openpype_icon_filepath())
icon = QtGui.QIcon(resources.get_ayon_icon_filepath())
self.setWindowIcon(icon)
self.setWindowTitle("Launcher")
self.setFocusPolicy(QtCore.Qt.StrongFocus)

View file

@ -1,6 +1,6 @@
from qtpy import QtWidgets, QtCore, QtGui
from ayon_core.resources import get_openpype_icon_filepath
from ayon_core.resources import get_ayon_icon_filepath
from ayon_core.style import load_stylesheet
from ayon_core.tools.utils import (
PlaceholderLineEdit,
@ -119,7 +119,7 @@ class LoaderWindow(QtWidgets.QWidget):
def __init__(self, controller=None, parent=None):
super(LoaderWindow, self).__init__(parent)
icon = QtGui.QIcon(get_openpype_icon_filepath())
icon = QtGui.QIcon(get_ayon_icon_filepath())
self.setWindowIcon(icon)
self.setWindowTitle("AYON Loader")
self.setFocusPolicy(QtCore.Qt.StrongFocus)

View file

@ -8,7 +8,7 @@ import arrow
from qtpy import QtWidgets, QtCore, QtGui
from ayon_core import style
from ayon_core.resources import get_openpype_icon_filepath
from ayon_core.resources import get_ayon_icon_filepath
from ayon_core.tools import resources
from ayon_core.tools.utils import (
IconButton,
@ -600,7 +600,7 @@ class PublishReportViewerWindow(QtWidgets.QWidget):
def __init__(self, parent=None):
super(PublishReportViewerWindow, self).__init__(parent)
self.setWindowTitle("Publish report viewer")
icon = QtGui.QIcon(get_openpype_icon_filepath())
icon = QtGui.QIcon(get_ayon_icon_filepath())
self.setWindowIcon(icon)
body = QtWidgets.QSplitter(self)

View file

@ -55,7 +55,7 @@ class PublisherWindow(QtWidgets.QWidget):
self.setWindowTitle("AYON publisher")
icon = QtGui.QIcon(resources.get_openpype_icon_filepath())
icon = QtGui.QIcon(resources.get_ayon_icon_filepath())
self.setWindowIcon(icon)
if reset_on_show is None:
@ -79,7 +79,7 @@ class PublisherWindow(QtWidgets.QWidget):
# Header
header_widget = QtWidgets.QWidget(self)
icon_pixmap = QtGui.QPixmap(resources.get_openpype_icon_filepath())
icon_pixmap = QtGui.QPixmap(resources.get_ayon_icon_filepath())
icon_label = PixmapLabel(icon_pixmap, header_widget)
icon_label.setObjectName("PublishContextLabel")

View file

@ -37,7 +37,7 @@ class SceneInventoryWindow(QtWidgets.QDialog):
controller = SceneInventoryController()
project_name = controller.get_current_project_name()
icon = QtGui.QIcon(resources.get_openpype_icon_filepath())
icon = QtGui.QIcon(resources.get_ayon_icon_filepath())
self.setWindowIcon(icon)
self.setWindowTitle("Scene Inventory - {}".format(project_name))
self.setObjectName("SceneInventory")

View file

@ -215,7 +215,7 @@ class PypeInfoWidget(QtWidgets.QWidget):
self.setStyleSheet(style.load_stylesheet())
icon = QtGui.QIcon(resources.get_openpype_icon_filepath())
icon = QtGui.QIcon(resources.get_ayon_icon_filepath())
self.setWindowIcon(icon)
self.setWindowTitle("AYON info")

View file

@ -308,7 +308,7 @@ class SystemTrayIcon(QtWidgets.QSystemTrayIcon):
doubleclick_time_ms = 100
def __init__(self, parent):
icon = QtGui.QIcon(resources.get_openpype_icon_filepath())
icon = QtGui.QIcon(resources.get_ayon_icon_filepath())
super(SystemTrayIcon, self).__init__(icon, parent)
@ -445,7 +445,7 @@ class PypeTrayStarter(QtCore.QObject):
return self._splash
def _create_splash(self):
splash_pix = QtGui.QPixmap(resources.get_openpype_splash_filepath())
splash_pix = QtGui.QPixmap(resources.get_ayon_splash_filepath())
splash = QtWidgets.QSplashScreen(splash_pix)
splash.setMask(splash_pix.mask())
splash.setEnabled(False)

View file

@ -57,7 +57,7 @@ class WorkfilesToolWindow(QtWidgets.QWidget):
controller = BaseWorkfileController()
self.setWindowTitle(self.title)
icon = QtGui.QIcon(resources.get_openpype_icon_filepath())
icon = QtGui.QIcon(resources.get_ayon_icon_filepath())
self.setWindowIcon(icon)
flags = self.windowFlags() | QtCore.Qt.Window
self.setWindowFlags(flags)

View file

@ -63,7 +63,7 @@ def exec_plugin_install( engine_path: Path, env: dict = None):
example_worker.moveToThread(q_thread)
splash_screen = SplashScreen("Executing process ...",
resources.get_openpype_icon_filepath())
resources.get_ayon_icon_filepath())
# set up the splash screen with necessary events
example_worker.installing.connect(splash_screen.update_top_label_text)