Browse Source

Fix issue with toolbox operators clobbering page settings.

This happens in ZLZ-imported Ages, probably due to object name
collisions from multiple pages.
pull/197/head
Adam Johnson 4 years ago
parent
commit
79f81fc63a
Signed by: Hoikas
GPG Key ID: 0B6515D6FF6F271E
  1. 10
      korman/properties/prop_object.py

10
korman/properties/prop_object.py

@ -19,13 +19,11 @@ from PyHSPlasma import *
class PlasmaObject(bpy.types.PropertyGroup):
def _enabled(self, context):
# This makes me sad
if not self.is_inited:
if not self.is_property_set("page"):
self._init(context)
self.is_inited = True
def _init(self, context):
o = context.object
o = self.id_data
age = context.scene.world.plasma_age
# We want to encourage the pages = layers paradigm.
@ -47,8 +45,8 @@ class PlasmaObject(bpy.types.PropertyGroup):
page = StringProperty(name="Page",
description="Page this object will be exported to")
# Implementation Details
is_inited = BoolProperty(description="INTERNAL: Init proc complete",
# DEAD - leaving in just in case external code uses it
is_inited = BoolProperty(description="DEAD",
default=False,
options={"HIDDEN"})

Loading…
Cancel
Save