added option to receive staging and production icon explicitly

This commit is contained in:
Jakub Trllo 2022-10-26 12:16:10 +02:00
parent 12522aa590
commit ff3325ddc6

View file

@ -39,15 +39,21 @@ def get_liberation_font_path(bold=False, italic=False):
return font_path return font_path
def get_openpype_production_icon_filepath():
return get_resource("icons", "openpype_icon.png")
def get_openpype_staging_icon_filepath():
return get_resource("icons", "openpype_icon_staging.png")
def get_openpype_icon_filepath(staging=None): def get_openpype_icon_filepath(staging=None):
if staging is None: if staging is None:
staging = is_running_staging() staging = is_running_staging()
if staging: if staging:
icon_file_name = "openpype_icon_staging.png" return get_openpype_staging_icon_filepath()
else: return get_openpype_production_icon_filepath()
icon_file_name = "openpype_icon.png"
return get_resource("icons", icon_file_name)
def get_openpype_splash_filepath(staging=None): def get_openpype_splash_filepath(staging=None):