User Tools

Site Tools


DzContentFolder

Represents a folder in the content library.

More...

Inherits :

Enumerations

Properties

Methods

Signals

voidaddedFolder ( DzContentFolder newFolder )
voidfileListChanged ()
voidfolderListChanged ()
voidremovedFolder ( DzContentFolder folder )

Detailed Description

Represents a folder in the content library that holds DzContentFile objects as well as other DzContentFolder objects.

See Also:

Enumerations


: FolderType

The possible types of content folders.

  • NATIVE_TYPE - Folder containing native content.
  • POSER_TYPE - Folder containing Poser content.
  • IMPORT_TYPE - Folder containing other importable content.

Properties


Boolean : canAddSubFolder

Holds whether or not a sub folder can be added in this folder. (Read Only)


Boolean : canDelete

Holds whether or not this folder can be deleted. (Read Only)


Boolean : canRename

Holds whether or not this folder can be renamed. (Read Only)


Boolean : filesAreLoaded

Holds whether or not the files of this folder are loaded. (Read Only)


String : folderName

Holds the name of the folder on disk. (Read Only)


Boolean : foldersAreLoaded

Holds whether or not the subfolders of this folder are loaded. (Read Only)

Return Value:

  • true if the child folders of this folder are already loaded, otherwise false.

FolderType : folderType

Holds the type of this folder. (Read Only)


String : fullPath

Holds the full path of the folder on disk. (Read Only)


Boolean : isBuiltInContentFolder

Holds whether or not this folder is a built-in content folder. (Read Only)


String : label

Holds the label of the folder as it is displayed to the user. (Read Only)


Pixmap : thumbnailPixmap

Holds the thumbnail for this folder. (Read Only)

Since:

  • 4.21.1.44

Pixmap : icon

Deprecated

Exists only to keep old code working. Do not use in new code. Use thumbnailPixmap instead.

Methods


Boolean : addSubFolder( String folderName )

Adds a new subfolder with the given name to this folder.

Parameter(s):

  • folderName - The name of the new sub folder.

Return Value:

  • true if the new subfolder was created successfully, otherwise false.

Boolean : canMoveFile( DzContentFile file )

Parameter(s):

  • file - The file to test for moving.

Return Value:

  • true if the file is a type that can be moved or copied to this folder, otherwise false.

Boolean : copyFile( DzContentFile file )

Copies the given content file to this folder.

Parameter(s):

  • file - The file to copy to this folder.

Return Value:

  • true if the file was copied successfully, otherwise false.

Boolean : deleteFolder()

Removes this content folder. The default implementation of this function deletes all files and subfolders in this directory from the disk, so use with care!

Return Value:

  • true if the file was removed successfully, otherwise false.

DzContentFile : getFirstFile()

Return Value:

  • The first file in this folder (if any), otherwise null.

DzContentFolder : getFirstFolder()

Return Value:

  • The first child folder (if any), otherwise null.

DzContentFile : getFirstHiddenFile()

Return Value:

  • The first hidden file in this folder (if any), otherwise null.

DzContentFolder : getFirstHiddenFolder()

Return Value:

  • The first hidden folder (if any), otherwise null.

DzContentFolder : getNext()

Return Value:

  • The next sibling folder (if any), otherwise null.

DzContentFolder : getParent()

Return Value:

  • The parent folder of this folder (if any), otherwise null.

Boolean : hasSubFolders()

Return Value:

  • true if this folder has subfolders, otherwise false.

Boolean : isModifiable()

Return Value:

  • true if the folder can be modified, otherwise false.

void : loadFiles()

Loads file objects for the files that reside in this folder.

Since:

  • 4.20.0.3

void : loadFolders()

Loads folder objects for the folders that reside in this folder.

Since:

  • 4.20.0.3

Boolean : moveFile( DzContentFile file )

Moves the given content file to this folder.

Parameter(s):

  • file - The file to move to this folder.

Return Value:

  • true if the file was moved successfully, otherwise false.

Boolean : refresh( Boolean reloadThumbnails=false )

Checks for changes in sub folders and files (if loaded).

Parameter(s):

  • reloadThumbnails - If true, the thumbnails will be reloaded from disk.

Return Value:

  • true if a change in subfolders was found and the tree needs to be reloaded, otherwise false.

Boolean : rename( String newName )

Rename the folder to the given name.

Parameter(s):

  • newName - The new name for the folder.

Return Value:

  • true if the folder was successfully renamed, otherwise false.

void : unloadFiles()

Removes file objects of this folder.

Since:

  • 4.20.0.3

void : unloadFolders()

Removes child folder objects of this folder object.

Since:

  • 4.20.0.3

Signals


void : addedFolder( DzContentFolder newFolder )

Signature:“addedFolder(DzContentFolder*)”

Emitted when a new folder is added.

Parameter(s):

  • newFolder - The folder that was added.

void : fileListChanged()

Signature:“fileListChanged()”

Emitted when the file list has changed.


void : folderListChanged()

Signature:“folderListChanged()”

Emitted when a folder is added or removed.


void : removedFolder( DzContentFolder folder )

Signature:“removedFolder(DzContentFolder*)”

Emitted when a folder is removed.

Parameter(s):

  • folder - The folder that was removed.