Solved issue T48992
This commit is contained in:
parent
38ccb54b50
commit
2c70ceb489
@ -968,6 +968,11 @@ def _hdri_download_panel(self, current_image):
|
|||||||
props.file_uuid = current_image.hdri_variation
|
props.file_uuid = current_image.hdri_variation
|
||||||
|
|
||||||
|
|
||||||
|
# Storage for variation labels, as the strings in EnumProperty items
|
||||||
|
# MUST be kept in Python memory.
|
||||||
|
variation_label_storage = {}
|
||||||
|
|
||||||
|
|
||||||
def hdri_variation_choices(self, context):
|
def hdri_variation_choices(self, context):
|
||||||
if context.area.type == 'IMAGE_EDITOR':
|
if context.area.type == 'IMAGE_EDITOR':
|
||||||
image = context.edit_image
|
image = context.edit_image
|
||||||
@ -979,8 +984,11 @@ def hdri_variation_choices(self, context):
|
|||||||
if 'bcloud_node' not in image:
|
if 'bcloud_node' not in image:
|
||||||
return []
|
return []
|
||||||
|
|
||||||
choices = [(file_doc['file'], file_doc['resolution'], '')
|
choices = []
|
||||||
for file_doc in image['bcloud_node']['properties']['files']]
|
for file_doc in image['bcloud_node']['properties']['files']:
|
||||||
|
label = file_doc['resolution']
|
||||||
|
variation_label_storage[label] = label
|
||||||
|
choices.append((file_doc['file'], label, ''))
|
||||||
|
|
||||||
return choices
|
return choices
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user