Beispiel #1
0
	def duplicateGroup(self, path):
		index, = path
		group, = self.getObjsByPath(path)
		newGroup = group.copy()
		ui.duplicateGroupTitle(newGroup)
		newGroup.afterModify()
		newGroup.save()
		ui.eventGroups.insert(index + 1, newGroup)
		ui.eventGroups.save()
		self.groupIterById[newGroup.id] = self.trees.insert(
			None,
			index + 1,
			self.getGroupRow(newGroup),
		)
Beispiel #2
0
	def duplicateGroup(self, path):
		index, = path
		group, = self.getObjsByPath(path)
		newGroup = group.copy()
		ui.duplicateGroupTitle(newGroup)
		newGroup.afterModify()
		newGroup.save()
		ui.eventGroups.insert(index+1, newGroup)
		ui.eventGroups.save()
		self.groupIterById[newGroup.id] = self.trees.insert(
			None,
			index+1,
			self.getGroupRow(newGroup),
		)
Beispiel #3
0
	def duplicateGroupWithEvents(self, path):
		index, = path
		group, = self.getObjsByPath(path)
		newGroup = group.deepCopy()
		ui.duplicateGroupTitle(newGroup)
		newGroup.save()
		ui.eventGroups.insert(index + 1, newGroup)
		ui.eventGroups.save()
		newGroupIter = self.groupIterById[newGroup.id] = self.trees.insert(
			None,
			index + 1,
			self.getGroupRow(newGroup),
		)
		for event in newGroup:
			self.appendEventRow(newGroupIter, event)
		self.loadedGroupIds.add(newGroup.id)
Beispiel #4
0
	def duplicateGroupWithEvents(self, path):
		index, = path
		group, = self.getObjsByPath(path)
		newGroup = group.deepCopy()
		ui.duplicateGroupTitle(newGroup)
		newGroup.save()
		ui.eventGroups.insert(index+1, newGroup)
		ui.eventGroups.save()
		newGroupIter = self.groupIterById[newGroup.id] = self.trees.insert(
			None,
			index+1,
			self.getGroupRow(newGroup),
		)
		for event in newGroup:
			self.appendEventRow(newGroupIter, event)
		self.loadedGroupIds.add(newGroup.id)