Medical Imaging Interaction Toolkit
2024.12.99-d991a09f
Medical Imaging Interaction Toolkit
|
#include <berryCommandCategory.h>
Public Member Functions | |
berryObjectMacro (CommandCategory) | |
void | AddCategoryListener (ICommandCategoryListener *categoryListener) |
void | Define (const QString &name, const QString &description) |
void | RemoveCategoryListener (ICommandCategoryListener *categoryListener) |
QString | ToString () const override |
void | Undefine () override |
![]() | |
berryObjectMacro (NamedHandleObject) | |
virtual QString | GetDescription () const |
virtual QString | GetName () const |
![]() | |
berryObjectMacro (HandleObject) | |
bool | operator== (const Object *object) const override |
QString | GetId () const |
uint | HashCode () const override |
bool | IsDefined () const |
![]() | |
virtual QString | GetClassName () const |
virtual Reflection::TypeInfo | GetTypeInfo () const |
virtual QList< Reflection::TypeInfo > | GetSuperclasses () const |
virtual void | Delete () |
QDebug | Print (QDebug os, Indent Indent=0) const |
virtual bool | operator< (const Object *) const |
void | Register () const |
void | UnRegister (bool del=true) const |
int | GetReferenceCount () const |
void | SetReferenceCount (int) |
void | AddDestroyListener (const MessageAbstractDelegate<> &delegate) const |
void | RemoveDestroyListener (const MessageAbstractDelegate<> &delegate) const |
Protected Member Functions | |
CommandCategory (const QString &id) | |
![]() | |
NamedHandleObject (const QString &id) | |
![]() | |
HandleObject (const QString &id) | |
![]() | |
Object () | |
virtual | ~Object () |
virtual QDebug | PrintSelf (QDebug os, Indent indent) const |
virtual QDebug | PrintHeader (QDebug os, Indent indent) const |
virtual QDebug | PrintTrailer (QDebug os, Indent indent) const |
Additional Inherited Members | |
![]() | |
typedef Object | Self |
typedef berry::SmartPointer< Self > | Pointer |
typedef berry::SmartPointer< const Self > | ConstPointer |
typedef berry::WeakPointer< Self > | WeakPtr |
typedef berry::WeakPointer< const Self > | ConstWeakPtr |
![]() | |
static const char * | GetStaticClassName () |
static Reflection::TypeInfo | GetStaticTypeInfo () |
static QList< Reflection::TypeInfo > | GetStaticSuperclasses () |
![]() | |
QString | description |
QString | name |
![]() | |
bool | defined |
const QString | id |
QString | str |
![]() | |
QAtomicInt | m_ReferenceCount |
QMutex | m_ReferenceCountLock |
A logical group for a set of commands. A command belongs to exactly one category. The category has no functional effect, but may be used in graphical tools that want to group the set of commands somehow.
Definition at line 31 of file berryCommandCategory.h.
|
protected |
Constructs a new instance of Category
based on the given identifier. When a category is first constructed, it is undefined. Category should only be constructed by the CommandManager
to ensure that identifier remain unique.
id | The identifier for the category. This value must not be null , and must be unique amongst all categories. |
void berry::CommandCategory::AddCategoryListener | ( | ICommandCategoryListener * | categoryListener | ) |
Adds a listener to this category that will be notified when this category's state changes.
categoryListener | The listener to be added; must not be null . |
berry::CommandCategory::berryObjectMacro | ( | CommandCategory | ) |
void berry::CommandCategory::Define | ( | const QString & | name, |
const QString & | description | ||
) |
Defines this category by giving it a name, and possibly a description as well. The defined property automatically becomes true
.
Notification is sent to all listeners that something has changed.
name | The name of this command; must not be null . |
description | The description for this command; may be null . |
void berry::CommandCategory::RemoveCategoryListener | ( | ICommandCategoryListener * | categoryListener | ) |
Removes a listener from this category.
categoryListener | The listener to be removed; must not be null . |
|
overridevirtual |
Returns a string representation of this object. The default implementation returns an empty string.
Reimplemented from berry::Object.
|
overridevirtual |
Makes this object becomes undefined. This method should make any defined properties null
. It should also send notification to any listeners that these properties have changed.
Implements berry::HandleObject.