fix: world

This commit is contained in:
Swann Martinez 2019-09-27 17:16:02 +02:00
parent 19aaee01a7
commit 3fbc925bc7
No known key found for this signature in database
GPG Key ID: 414CCAFD8DA720E1
2 changed files with 11 additions and 9 deletions

View File

@ -36,7 +36,9 @@ class BlWorld(BlDatablock):
"preview",
"original",
"uuid",
"color"
"color",
"cycles",
"light_settings"
]
data = world_dumper.dump(pointer)
if pointer.use_nodes:
@ -85,7 +87,6 @@ class BlWorld(BlDatablock):
def diff(self):
diff_rev = diff(self.dump(pointer=self.pointer), self.buffer)
print(diff_rev)
return (self.bl_diff() or
len(diff_rev.keys()) > 0)
@ -98,7 +99,6 @@ class BlWorld(BlDatablock):
deps.append(node.image)
if self.is_library:
deps.append(self.pointer.library)
return deps
def is_valid(self):

14
ui.py
View File

@ -271,12 +271,14 @@ def draw_property(context, parent, property_uuid, level=0):
have_right_to_modify = settings.is_admin or \
item.owner == settings.username or \
item.owner == RP_COMMON
detail_item_box.operator(
"session.commit",
text="",
icon='TRIA_UP').target = item.uuid
detail_item_box.separator()
if have_right_to_modify:
detail_item_box.operator(
"session.commit",
text="",
icon='TRIA_UP').target = item.uuid
detail_item_box.separator()
if item.state in [FETCHED, UP]:
detail_item_box.operator(
"session.apply",