Crossfire Server, Trunk
|
#include <ArtifactWrapper.h>
Public Member Functions | |
QStringList | allowed () const |
ArtifactWrapper (AssetWrapper *parent, artifact *art, ResourcesManager *resourcesManager) | |
int | chance () const |
int | difficulty () const |
virtual void | displayFillPanel (QWidget *panel) override |
virtual QIcon | displayIcon () const override |
virtual QString | displayName () const override |
QObject * | item () |
QString | name () const |
void | setChance (int chance) |
void | setSpecificItem (const object *item) |
virtual PossibleUse | uses (const AssetWrapper *asset, std::string &) const override |
![]() | |
AssetTWrapper (AssetWrapper *parent, const QString &panelName, artifact *wrappedItem) | |
artifact * | wrappedItem () const |
![]() | |
AssetWrapper (AssetWrapper *parent, const QString &panelName="empty") | |
virtual bool | canDrag () const |
virtual bool | canDrop (const QMimeData *, int) const |
virtual AssetWrapper * | child (int) |
virtual int | childIndex (AssetWrapper *) |
virtual int | childrenCount () const |
virtual QString | displayPanelName () const |
AssetWrapper * | displayParent () const |
virtual void | drag (QMimeData *) const |
virtual void | drop (const QMimeData *, int) |
virtual void | fillMenu (QMenu *) |
void | markModified (ChangeType change, int extra=0) |
void | setDisplayParent (AssetWrapper *parent) |
virtual | ~AssetWrapper () override |
Protected Attributes | |
ResourcesManager * | myResourcesManager |
const object * | mySpecificItem |
![]() | |
artifact * | myWrappedItem |
![]() | |
QString | myPanelName |
AssetWrapper * | myParent |
Properties | |
QStringList | allowed |
int | chance |
int | difficulty |
QObject | item |
QString | name |
Additional Inherited Members | |
![]() | |
enum | ChangeType { AssetUpdated, BeforeChildAdd, AfterChildAdd, BeforeChildRemove, AfterChildRemove, BeforeLayoutChange, AfterLayoutChange } |
enum | PossibleUse { Uses, ChildrenMayUse, DoesntUse } |
![]() | |
virtual void | removeChild (AssetWrapper *) |
![]() | |
void | dataModified (AssetWrapper *asset, AssetWrapper::ChangeType type, int extra) |
void | modified () |
![]() | |
static bool | compareByDisplayName (const AssetWrapper *left, const AssetWrapper *right) |
![]() | |
static const char * | tipProperty = "_cre_internal" |
![]() | |
virtual void | wasModified (AssetWrapper *asset, ChangeType type, int extra) |
Definition at line 15 of file ArtifactWrapper.h.
ArtifactWrapper::ArtifactWrapper | ( | AssetWrapper * | parent, |
artifact * | art, | ||
ResourcesManager * | resourcesManager | ||
) |
Definition at line 7 of file ArtifactWrapper.cpp.
QStringList ArtifactWrapper::allowed | ( | ) | const |
int ArtifactWrapper::chance | ( | ) | const |
int ArtifactWrapper::difficulty | ( | ) | const |
|
inlineoverridevirtual |
Reimplemented from AssetTWrapper< artifact >.
Definition at line 30 of file ArtifactWrapper.h.
References AssetWrapperPanel::setItem().
|
overridevirtual |
Reimplemented from AssetWrapper.
Definition at line 36 of file ArtifactWrapper.cpp.
References artifact_get_face(), CREPixmap::getIcon(), and AssetTWrapper< artifact >::myWrappedItem.
|
overridevirtual |
Implements AssetWrapper.
Definition at line 12 of file ArtifactWrapper.cpp.
References artifact_compute_chance_for_item(), artifactstruct::chance, find_artifactlist(), artifactstruct::item, guildoracle::list, mySpecificItem, AssetTWrapper< artifact >::myWrappedItem, name, obj::name, and obj::type.
QObject* ArtifactWrapper::item | ( | ) |
QString ArtifactWrapper::name | ( | ) | const |
void ArtifactWrapper::setChance | ( | int | chance | ) |
Definition at line 52 of file ArtifactWrapper.cpp.
References AssetWrapper::AssetUpdated, chance, artifactstruct::chance, AssetWrapper::markModified(), and AssetTWrapper< artifact >::myWrappedItem.
|
inline |
Definition at line 37 of file ArtifactWrapper.h.
References item, and mySpecificItem.
|
overridevirtual |
Reimplemented from AssetWrapper.
Definition at line 74 of file ArtifactWrapper.cpp.
References animate::anim, obj::animation, AssetWrapper::DoesntUse, obj::face, artifactstruct::item, AssetTWrapper< artifact >::myWrappedItem, and AssetWrapper::Uses.
|
protected |
Definition at line 47 of file ArtifactWrapper.h.
|
protected |
Definition at line 48 of file ArtifactWrapper.h.
Referenced by displayName(), and setSpecificItem().
|
read |
Definition at line 22 of file ArtifactWrapper.h.
|
readwrite |
Definition at line 20 of file ArtifactWrapper.h.
Referenced by setChance().
|
read |
Definition at line 21 of file ArtifactWrapper.h.
|
read |
Definition at line 19 of file ArtifactWrapper.h.
Referenced by setSpecificItem().
|
read |
Definition at line 18 of file ArtifactWrapper.h.
Referenced by displayName().