Skip to content
Snippets Groups Projects
Commit c9ab68e6 authored by mifth's avatar mifth
Browse files

[UVUtility] other fixes of IdeasMan_42 suggestions

parent 6edc78ca
No related branches found
No related tags found
No related merge requests found
...@@ -141,7 +141,7 @@ class UV_IC_SelectIndex(UV_IC_Panel, Operator): ...@@ -141,7 +141,7 @@ class UV_IC_SelectIndex(UV_IC_Panel, Operator):
indexNew = scene.UVTexIndex - 1 indexNew = scene.UVTexIndex - 1
if theObj.type == 'MESH': if theObj.type == 'MESH':
if len(meshData.uv_textures) > indexNew and len(meshData.uv_textures) > 0: if len(meshData.uv_textures) > indexNew and meshData.uv_textures:
meshData.uv_textures.active_index = indexNew meshData.uv_textures.active_index = indexNew
if scene.UVTexRenderActive: if scene.UVTexRenderActive:
...@@ -162,7 +162,7 @@ class UV_IC_SelectName(UV_IC_Panel, Operator): ...@@ -162,7 +162,7 @@ class UV_IC_SelectName(UV_IC_Panel, Operator):
uvName = scene.UVTexGetName uvName = scene.UVTexGetName
if theObj.type == 'MESH': if theObj.type == 'MESH':
if len(meshData.uv_textures) > 0: if meshData.uv_textures:
uvToGet = meshData.uv_textures.get(uvName) uvToGet = meshData.uv_textures.get(uvName)
if uvToGet is not None: if uvToGet is not None:
...@@ -185,7 +185,7 @@ class UV_IC_RemoveActiveUV(UV_IC_Panel, Operator): ...@@ -185,7 +185,7 @@ class UV_IC_RemoveActiveUV(UV_IC_Panel, Operator):
meshData = theObj.data meshData = theObj.data
if theObj.type == 'MESH': if theObj.type == 'MESH':
if len(meshData.uv_textures) > 0: if meshData.uv_textures:
activeIndex = meshData.uv_textures.active_index activeIndex = meshData.uv_textures.active_index
if len(meshData.uv_textures) > activeIndex: if len(meshData.uv_textures) > activeIndex:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment