Ejemplo n.º 1
0
void AGOSEngine::setItemParent(Item *item, Item *parent) {
	Item *old_parent = derefItem(item->parent);

	if (item == parent)
		error("setItemParent: Trying to set item as its own parent");

	// unlink it if it has a parent
	if (old_parent)
		unlinkItem(item);
	itemChildrenChanged(old_parent);
	linkItem(item, parent);
	itemChildrenChanged(parent);
}
Ejemplo n.º 2
0
void AGOSEngine::xPlace(Item *x, Item *y) {
    if (derefItem(x->parent))
        unlinkItem(x);

    linkItem(x, y);
}
Ejemplo n.º 3
0
void HotSpotList::remove(HotSpot *hotspot) {
	unlinkItem(hotspot);
	delete hotspot; //TODO: check this?
}