SetDefaultAudiencesCommand.h header

#include <ew/core/SetDefaultAudiencesCommand.h>

Namespace ew::core

SetDefaultAudiencesCommand class

class ew::core::SetDefaultAudiencesCommand

Command that replaces the audiences a newly created object starts out visible to (Project::defaultAudiences) – the project-wide policy that makes new content start restricted rather than visible to everyone. An empty set restores the original behaviour. Undo restores the previous default and redo re-applies; existing objects are untouched either way (see ew::app::project::buildApplyAudienceToAllCommand for the retroactive sweep).

Members

ew::core::content::SetDefaultAudiencesCommand::SetDefaultAudiencesCommand(ew::core::project::Project &project, std::set< QString > audiences)

Creates a command that sets project's default visible-audience set to audiences.

ew::core::content::SetDefaultAudiencesCommand::~SetDefaultAudiencesCommand() override

Destroys the command.

void ew::core::content::SetDefaultAudiencesCommand::apply() override

Records the project's current default and applies the new one.

void ew::core::content::SetDefaultAudiencesCommand::undo() override

Restores the previous default.

QString ew::core::content::SetDefaultAudiencesCommand::description() const override

Returns a short description for the undo/redo UI.