[Bf-extensions-cvs] [3a0cc994] master: BlenderKit: fix selected asset panel, got mixed with unfinished fast upload feature.

Vilém Duha noreply at git.blender.org
Thu Oct 10 16:18:57 CEST 2019


Commit: 3a0cc9946f6ce63213fec53876b4fbaed76d8311
Author: Vilém Duha
Date:   Thu Oct 10 16:16:13 2019 +0200
Branches: master
https://developer.blender.org/rBA3a0cc9946f6ce63213fec53876b4fbaed76d8311

BlenderKit: fix selected asset panel, got mixed with unfinished fast upload feature.

===================================================================

M	blenderkit/ui_panels.py

===================================================================

diff --git a/blenderkit/ui_panels.py b/blenderkit/ui_panels.py
index 3e238a71..d7e40714 100644
--- a/blenderkit/ui_panels.py
+++ b/blenderkit/ui_panels.py
@@ -372,14 +372,21 @@ class VIEW3D_PT_blenderkit_model_properties(Panel):
         layout = self.layout
 
         o = bpy.context.active_object
-        ad = o['asset_data']
-        layout.label(text=str(ad['name']))
-        # proxies just don't make it in 2.79... they should stay hidden and used only by pros ...
-        # if 'rig' in ad['tags']:
-        #     # layout.label(text = 'can make proxy')
-        #     layout.operator('object.blenderkit_make_proxy', text = 'Make Armature proxy')
-
-        layout.operator('object.blenderkit_bring_to_scene', text='Bring to scene')
+        if o.get('asset_data') is not None:
+            ad = o['asset_data']
+            layout.label(text=str(ad['name']))
+            if o.instance_type == 'COLLECTION' and o.instance_collection is not None:
+                layout.operator('object.blenderkit_bring_to_scene', text='Bring to scene')
+
+            # if 'rig' in ad['tags']:
+            #     # layout.label(text = 'can make proxy')
+            #     layout.operator('object.blenderkit_make_proxy', text = 'Make Armature proxy')
+        #fast upload, blocked by now
+        # else:
+        #     op = layout.operator("object.blenderkit_upload", text='Store as private', icon='EXPORT')
+        #     op.asset_type = 'MODEL'
+        #     op.fast = True
+        #fun override project, not finished
         # layout.operator('object.blenderkit_color_corrector')



More information about the Bf-extensions-cvs mailing list