DzContentReplaceMgr Class Reference
[Manager ObjectsContent Access Objects]

Content replacement manager. More...

Inheritance diagram for DzContentReplaceMgr:

QObject Object List of all members.

Enums

enum  ContentReplaceMode { ALWAYS_REPLACE, ASK_TO_REPLACE, NEVER_REPLACE }

Methods

void clearReplaceData ()
void doReplace ()
String getNewContentPath ()
String getNewContentType ()
ContentReplaceMode getReplaceMode ()
void initReplaceForContentLoad (String path, DzNode baseNode)
void removeReplaceNodes ()
void setNewContentPath (String contentPath)
void setNewContentType (String contentType)
void setReplaceMode (ContentReplaceMode mode)
void updateReplaceNodes (DzNode baseNode)

Signals

void contentReplaceModeChanged (DzContentReplaceMgr::ContentReplaceMode mode)
 Signature: "contentReplaceModeChanged(DzContentReplaceMgr::ContentReplaceMode)"

Detailed Description

Content replacement manager.

See also:
DzContentMgr::getContentReplaceMgr()


Member Enumeration Documentation

enum DzContentReplaceMgr::ContentReplaceMode

Replacing methods when loading content

Enumerator:
ALWAYS_REPLACE  When a piece of content of a specific type is loaded, any content already in the scene of the same type is removed, so the new item replaces the old one.
ASK_TO_REPLACE  When a piece of content is loaded, a dialog propmts the user to choose which (if any) items already in the scene should be removed.
NEVER_REPLACE  Items already in the scene are never removed when loading a piece of content.


Member Function Documentation

void DzContentReplaceMgr::clearReplaceData (  ) 

Resets all replace data to default values, excluding replace mode.

void DzContentReplaceMgr::contentReplaceModeChanged ( DzContentReplaceMgr::ContentReplaceMode  mode  )  [signal]

Signature: "contentReplaceModeChanged(DzContentReplaceMgr::ContentReplaceMode)"

Emitted when the content replace mode has changed.

void DzContentReplaceMgr::doReplace (  ) 

Performs all the necessary steps to remove content marked for replacement.

QString DzContentReplaceMgr::getNewContentPath (  ) 

Returns:
The path of the new content.

QString DzContentReplaceMgr::getNewContentType (  ) 

Returns:
The type of the new content.

DzContentReplaceMgr::ContentReplaceMode DzContentReplaceMgr::getReplaceMode (  ) 

Returns:
The content replace mode.

void DzContentReplaceMgr::initReplaceForContentLoad ( String  path,
DzNode  baseNode 
)

Performs all the necessary initialization for doing content replacement when the given file will be loaded, using items attached to baseNode as potential items to replace.

void DzContentReplaceMgr::removeReplaceNodes (  ) 

Removes all nodes in the replace list from the scene.

void DzContentReplaceMgr::setNewContentPath ( String  contentPath  ) 

Parameters:
contentPath The path of the new content.

void DzContentReplaceMgr::setNewContentType ( String  contentType  ) 

Parameters:
contentType The type of the new content.

void DzContentReplaceMgr::setReplaceMode ( ContentReplaceMode  mode  ) 

Sets the content replace mode.

void DzContentReplaceMgr::updateReplaceNodes ( DzNode  baseNode  ) 

Updates the replace list to contain all items that should be removed during content load. If the replace mode is ALWAYS_REPLACE, the list will contain all nodes attached (conformed, parented, etc.) to baseNode whose type matches the current "New Content Type" (as set through setNewContentType()). If the replace mode is ASK_TO_REPLACE, a dialog will allow the user to select what nodes should be replaced.


Generated on Thu Sep 24 12:21:11 2009

Copyright © 2002 - 2009 DAZ 3D, Inc.