Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/intern
diff options
context:
space:
mode:
authorRomain Toumi <ToumiX>2021-07-21 00:22:59 +0300
committerAaron Carlisle <carlisle.b3d@gmail.com>2021-07-21 00:23:34 +0300
commit14d5a45750e0b71c2795949dfbe94dbc552435a7 (patch)
treebf11a75e5cdd7baf2d38f66a7ddc7813ae6990df /intern
parent807bb450a0f09c77e8ac894da39a9c574c24dbd5 (diff)
UI: Fix Cycles Materials menu Layout
Fix an incoherence between the Eevee Materials menu and the Cycles Materials menu : Eevee : {F10230448} Cycles : {F10230449} Simply Fixed by replacing the Cycles UI code by the Eevee UI code. Thanks to @Brainzman for helping me create this diff and translate Reviewed By: Blendify Differential Revision: https://developer.blender.org/D11979
Diffstat (limited to 'intern')
-rw-r--r--intern/cycles/blender/addon/ui.py13
1 files changed, 6 insertions, 7 deletions
diff --git a/intern/cycles/blender/addon/ui.py b/intern/cycles/blender/addon/ui.py
index 30892cdbbc0..058528aeff5 100644
--- a/intern/cycles/blender/addon/ui.py
+++ b/intern/cycles/blender/addon/ui.py
@@ -1136,7 +1136,7 @@ class CYCLES_PT_context_material(CyclesButtonsPanel, Panel):
col = row.column(align=True)
col.operator("object.material_slot_add", icon='ADD', text="")
col.operator("object.material_slot_remove", icon='REMOVE', text="")
-
+ col.separator()
col.menu("MATERIAL_MT_context_menu", icon='DOWNARROW_HLT', text="")
if is_sortable:
@@ -1151,16 +1151,15 @@ class CYCLES_PT_context_material(CyclesButtonsPanel, Panel):
row.operator("object.material_slot_select", text="Select")
row.operator("object.material_slot_deselect", text="Deselect")
- split = layout.split(factor=0.65)
+ row = layout.row()
if ob:
- split.template_ID(ob, "active_material", new="material.new")
- row = split.row()
+ row.template_ID(ob, "active_material", new="material.new")
if slot:
- row.prop(slot, "link", text="")
- else:
- row.label()
+ icon_link = 'MESH_DATA' if slot.link == 'DATA' else 'OBJECT_DATA'
+ row.prop(slot, "link", text="", icon=icon_link, icon_only=True)
+
elif mat:
split.template_ID(space, "pin_id")
split.separator()