#include <swfbuttn.h>
Inheritance diagram for FlashButtonRecord:
Public Member Functions | |
FlashButtonRecord (void) | |
Creates a FlashButtonRecord list node, and initialises all member variables. | |
~FlashButtonRecord (void) | |
Destroys this instance of FlashButtonRecord. | |
FlashButtonRecord * | AddElement (void) |
Adds an element to the tail of the list. | |
void | DeleteNextElement (void) |
Deletes the next item in the list. | |
void | DeleteLastElement (void) |
Deletes the previous item in the list. | |
WORD | GetButtonID (void) |
Gets the value of mButtonID. | |
WORD | GetHitID (void) |
Gets the value of mHitID. | |
WORD | GetDownID (void) |
Gets the value of mDownID. | |
WORD | GetOverID (void) |
Gets the value of mOverID. | |
WORD | GetUpID (void) |
Gets the value of mUpID. | |
WORD | GetRawHitID (void) |
Gets the raw value of mHitID. | |
WORD | GetRawDownID (void) |
Gets the raw value of mDownID. | |
WORD | GetRawOverID (void) |
Gets the raw value of mOverID. | |
WORD | GetRawUpID (void) |
Gets the raw value of mUpID. | |
DocCoord | GetHitPosition (void) |
Gets the position of this button state. | |
DocCoord | GetDownPosition (void) |
Gets the position of this button state. | |
DocCoord | GetOverPosition (void) |
Gets the position of this button state. | |
DocCoord | GetUpPosition (void) |
Gets the position of this button state.. | |
BOOL | GetTransformHit (void) |
Do these co-ordinates need to be transformed into Flash co-ordinates? This is included to allow objects to be positioned at (0, 0). | |
BOOL | GetTransformDown (void) |
Do these co-ordinates need to be transformed into Flash co-ordinates? This is included to allow objects to be positioned at (0, 0). | |
BOOL | GetTransformOver (void) |
Do these co-ordinates need to be transformed into Flash co-ordinates? This is included to allow objects to be positioned at (0, 0). | |
BOOL | GetTransformUp (void) |
Do these co-ordinates need to be transformed into Flash co-ordinates? This is included to allow objects to be positioned at (0, 0). | |
FlashType | GetHitType (void) |
Gets the class of object that is to be rendered in this button state. | |
FlashType | GetDownType (void) |
Gets the class of object that is to be rendered in this button state. | |
FlashType | GetOverType (void) |
Gets the class of object that is to be rendered in this button state. | |
FlashType | GetUpType (void) |
Gets the class of object that is to be rendered in this button state. | |
TCHAR * | GetURL (void) |
Gets the contents of mURL. | |
TCHAR * | GetFrame (void) |
Gets the contents of mFrame. | |
TCHAR * | GetName (void) |
Gets the contents of mName. | |
BOOL | IsAMatch (const TCHAR *pName) |
Compares the names of two buttons (which is how Camelot IDs them), and determines whether or not they're identical. | |
FlashButtonRecord * | GetNext (void) |
Gets mpNext. | |
FlashButtonRecord * | GetLast (void) |
Gets mpLast. | |
void | SetButtonID (WORD ID) |
Sets the value of mButtonID. | |
void | SetHitID (WORD ID, FlashType Type) |
Sets the values of mHitID and mHitType. | |
void | SetDownID (WORD ID, FlashType Type) |
Sets the values of mDownID and mDownType. | |
void | SetOverID (WORD ID, FlashType Type) |
Sets the values of mOverID and mOverType. | |
void | SetUpID (WORD ID, FlashType Type) |
Sets the values of mUpID and mUpType. | |
void | SetHitPosition (DocCoord Position, BOOL DoTransform) |
Sets the values of mHitPosition and mTransformHit. | |
void | SetDownPosition (DocCoord Position, BOOL DoTransform) |
Sets the values of mDownPosition and mTransformDown. | |
void | SetOverPosition (DocCoord Position, BOOL DoTransform) |
Sets the values of mOverPosition and mTransformOver. | |
void | SetUpPosition (DocCoord Position, BOOL DoTransform) |
Sets the values of mUpPosition and mTransformUp. | |
void | SetURL (String_256 Address) |
Sets the value of mURL. mHasURL is also set, so that only the first URL string encountered is used. This is to keep it consistent with the Camelot button class. | |
void | SetFrame (TCHAR *pFrame) |
Sets the value of mFrame. | |
void | SetName (const TCHAR *pName) |
Sets the value of mName. | |
void | SetNext (FlashButtonRecord *pNext) |
Sets the value of mpNext. | |
void | SetLast (FlashButtonRecord *pLast) |
Sets the value of mpLast. | |
Private Member Functions | |
WORD | GetActualID (WORD ID, FlashType Type) |
Gets the value of mHitID. | |
Private Attributes | |
WORD | mButtonID |
WORD | mHitID |
WORD | mDownID |
WORD | mOverID |
WORD | mUpID |
FlashType | mHitType |
FlashType | mDownType |
FlashType | mOverType |
FlashType | mUpType |
DocCoord | mHitPosition |
DocCoord | mDownPosition |
DocCoord | mOverPosition |
DocCoord | mUpPosition |
BOOL | mTransformHit |
BOOL | mTransformDown |
BOOL | mTransformOver |
BOOL | mTransformUp |
BOOL | mHasHit |
BOOL | mHasDown |
BOOL | mHasOver |
BOOL | mHasUp |
BOOL | mHasURL |
BOOL | mHasFrame |
String_256 | mURL |
String_256 | mFrame |
String_256 | mName |
FlashButtonRecord * | mpNext |
FlashButtonRecord * | mpLast |
Definition at line 113 of file swfbuttn.h.
|
Creates a FlashButtonRecord list node, and initialises all member variables.
Definition at line 116 of file swfbuttn.cpp. 00117 { 00118 // Create constant variables for initial states. 00119 const DocCoord Position ( 0, 0 ); // Default position for all co-ordinates. 00120 00121 // Pointers should always be initialised to NULL when created. 00122 mpNext = NULL; // No subsequent nodes. 00123 mpLast = NULL; // No previous nodes. 00124 00125 // Attached objects. 00126 mButtonID = 0; 00127 mHitID = 0; 00128 mDownID = 0; 00129 mOverID = 0; 00130 mUpID = 0; 00131 00132 // Clear the strings. 00133 mURL.Empty (); 00134 mFrame.Empty (); 00135 mName.Empty (); 00136 00137 // Place object positions. 00138 mHitPosition = Position; 00139 mDownPosition = Position; 00140 mOverPosition = Position; 00141 mUpPosition = Position; 00142 00143 // Object states. 00144 mHitType = FLASH_SHAPE; 00145 mDownType = FLASH_SHAPE; 00146 mOverType = FLASH_SHAPE; 00147 mUpType = FLASH_SHAPE; 00148 00149 mHasHit = FALSE; 00150 mHasDown = FALSE; 00151 mHasOver = FALSE; 00152 mHasUp = FALSE; 00153 00154 mTransformHit = FALSE; 00155 mTransformDown = FALSE; 00156 mTransformOver = FALSE; 00157 mTransformUp = FALSE; 00158 00159 mHasURL = FALSE; 00160 mHasFrame = FALSE; 00161 }
|
|
Destroys this instance of FlashButtonRecord.
Definition at line 175 of file swfbuttn.cpp.
|
|
Adds an element to the tail of the list.
Definition at line 192 of file swfbuttn.cpp. 00193 { 00194 FlashButtonRecord *pTail = new FlashButtonRecord; 00195 ASSERT ( pTail != NULL ); 00196 00197 // Set the appropriate pointers. 00198 pTail->SetLast ( this ); // Ensure that a reference exists to this object... 00199 pTail->SetNext ( NULL ); // Avoids any problems if mpLast isn't NULL. 00200 mpNext = pTail; // ... and a reference exists to the new one. 00201 00202 return pTail; 00203 }
|
|
Deletes the previous item in the list.
Definition at line 217 of file swfbuttn.cpp. 00218 { 00219 FlashButtonRecord *pToDelete = mpLast; 00220 00221 // Reset mpLast to be mpLast->GetLast (), so that the list isn't broken. 00222 mpLast = mpLast->GetLast (); 00223 00224 delete pToDelete; 00225 }
|
|
Deletes the next item in the list.
Definition at line 239 of file swfbuttn.cpp. 00240 { 00241 FlashButtonRecord *pToDelete = mpNext; 00242 00243 // Reset mpNext to be mpNext->GetNext (), so that the list isn't broken. 00244 mpNext = mpNext->GetNext (); 00245 00246 delete pToDelete; 00247 }
|
|
Gets the value of mHitID.
Definition at line 1021 of file swfbuttn.cpp. 01023 { 01024 // Step 1: Increment the ID value past the font and bitmap records that are never 01025 // rendered directly. 01026 ID += FlashPlaceObject::GetBitmapCount () + FlashPlaceObject::GetFontCount () + 01027 FLASH_FIRST_ID; 01028 01029 // Step 2: If the record is a shape record, increment it past the text records. 01030 if ( Type == FLASH_SHAPE ) 01031 { 01032 ID += FlashPlaceObject::GetTextCount (); 01033 } 01034 else if ( Type == FLASH_SPRITE ) 01035 { 01036 ID += FlashPlaceObject::GetShapeCount (); 01037 } 01038 01039 // Step 3: Return the ID value. 01040 return ID; 01041 }
|
|
Gets the value of mButtonID.
Definition at line 261 of file swfbuttn.cpp. 00262 { 00263 return mButtonID; 00264 }
|
|
Gets the value of mDownID.
Definition at line 295 of file swfbuttn.cpp. 00296 { 00297 return GetActualID ( mDownID, mDownType ); 00298 }
|
|
Gets the position of this button state.
Definition at line 431 of file swfbuttn.cpp. 00432 { 00433 return mDownPosition; 00434 }
|
|
Gets the class of object that is to be rendered in this button state.
Definition at line 571 of file swfbuttn.cpp. 00572 { 00573 return mDownType; 00574 }
|
|
Gets the contents of mFrame.
Definition at line 639 of file swfbuttn.cpp.
|
|
Gets the value of mHitID.
Definition at line 278 of file swfbuttn.cpp. 00279 { 00280 return GetActualID ( mHitID, mHitType ); 00281 }
|
|
Gets the position of this button state.
Definition at line 414 of file swfbuttn.cpp. 00415 { 00416 return mHitPosition; 00417 }
|
|
Gets the class of object that is to be rendered in this button state.
Definition at line 554 of file swfbuttn.cpp. 00555 { 00556 return mHitType; 00557 }
|
|
Gets mpLast.
Definition at line 691 of file swfbuttn.cpp. 00692 { 00693 return mpLast; 00694 }
|
|
Gets the contents of mName.
Definition at line 656 of file swfbuttn.cpp.
|
|
Gets mpNext.
Definition at line 708 of file swfbuttn.cpp. 00709 { 00710 return mpNext; 00711 }
|
|
Gets the value of mOverID.
Definition at line 312 of file swfbuttn.cpp. 00313 { 00314 return GetActualID ( mOverID, mOverType ); 00315 }
|
|
Gets the position of this button state.
Definition at line 448 of file swfbuttn.cpp. 00449 { 00450 return mOverPosition; 00451 }
|
|
Gets the class of object that is to be rendered in this button state.
Definition at line 588 of file swfbuttn.cpp. 00589 { 00590 return mOverType; 00591 }
|
|
Gets the raw value of mDownID.
Definition at line 363 of file swfbuttn.cpp. 00364 { 00365 return mDownID; 00366 }
|
|
Gets the raw value of mHitID.
Definition at line 346 of file swfbuttn.cpp. 00347 { 00348 return mHitID; 00349 }
|
|
Gets the raw value of mOverID.
Definition at line 380 of file swfbuttn.cpp. 00381 { 00382 return mOverID; 00383 }
|
|
Gets the raw value of mUpID.
Definition at line 397 of file swfbuttn.cpp. 00398 { 00399 return mUpID; 00400 }
|
|
Do these co-ordinates need to be transformed into Flash co-ordinates? This is included to allow objects to be positioned at (0, 0).
Definition at line 501 of file swfbuttn.cpp. 00502 { 00503 return mTransformDown; 00504 }
|
|
Do these co-ordinates need to be transformed into Flash co-ordinates? This is included to allow objects to be positioned at (0, 0).
Definition at line 483 of file swfbuttn.cpp. 00484 { 00485 return mTransformHit; 00486 }
|
|
Do these co-ordinates need to be transformed into Flash co-ordinates? This is included to allow objects to be positioned at (0, 0).
Definition at line 519 of file swfbuttn.cpp. 00520 { 00521 return mTransformOver; 00522 }
|
|
Do these co-ordinates need to be transformed into Flash co-ordinates? This is included to allow objects to be positioned at (0, 0).
Definition at line 537 of file swfbuttn.cpp. 00538 { 00539 return mTransformUp; 00540 }
|
|
Gets the value of mUpID.
Definition at line 329 of file swfbuttn.cpp. 00330 { 00331 return GetActualID ( mUpID, mUpType ); 00332 }
|
|
Gets the position of this button state..
Definition at line 465 of file swfbuttn.cpp. 00466 { 00467 return mUpPosition; 00468 }
|
|
Gets the class of object that is to be rendered in this button state.
Definition at line 605 of file swfbuttn.cpp. 00606 { 00607 return mUpType; 00608 }
|
|
Gets the contents of mURL.
Definition at line 622 of file swfbuttn.cpp.
|
|
Compares the names of two buttons (which is how Camelot IDs them), and determines whether or not they're identical.
Definition at line 674 of file swfbuttn.cpp. 00675 { 00676 return mName.IsIdentical ( pName ); 00677 }
|
|
Sets the value of mButtonID.
Definition at line 725 of file swfbuttn.cpp.
|
|
Sets the values of mDownID and mDownType.
Definition at line 766 of file swfbuttn.cpp. 00768 { 00769 mDownID = ID; // Set the ID value for this state. 00770 mDownType = Type; // And whether or not it's a shape. 00771 mHasDown = TRUE; // Record that this state has been set. 00772 }
|
|
Sets the values of mDownPosition and mTransformDown.
Definition at line 863 of file swfbuttn.cpp. 00865 { 00866 mDownPosition = Position; 00867 mTransformDown = DoTransform; 00868 }
|
|
Sets the value of mFrame.
Definition at line 947 of file swfbuttn.cpp. 00948 { 00949 if ( !mHasFrame ) 00950 { 00951 mFrame = pFrame; 00952 mHasFrame = TRUE; 00953 } 00954 }
|
|
Sets the values of mHitID and mHitType.
Definition at line 744 of file swfbuttn.cpp. 00746 { 00747 mHitID = ID; // Set the ID value for this state. 00748 mHitType = Type; // And whether or not it's a shape. 00749 mHasHit = TRUE; // Record that this state has been set. 00750 }
|
|
Sets the values of mHitPosition and mTransformHit.
Definition at line 842 of file swfbuttn.cpp. 00844 { 00845 mHitPosition = Position; 00846 mTransformHit = DoTransform; 00847 }
|
|
Sets the value of mpLast.
Definition at line 985 of file swfbuttn.cpp. 00986 { 00987 mpLast = pLast; 00988 }
|
|
Sets the value of mName.
Definition at line 968 of file swfbuttn.cpp. 00969 { 00970 mName = pName; 00971 }
|
|
Sets the value of mpNext.
Definition at line 1002 of file swfbuttn.cpp. 01003 { 01004 mpNext = pNext; 01005 }
|
|
Sets the values of mOverID and mOverType.
Definition at line 788 of file swfbuttn.cpp. 00790 { 00791 mOverID = ID; // Set the ID value for this state. 00792 mOverType = Type; // And whether or not it's a shape. 00793 mHasOver = TRUE; // Record that this state has been set. 00794 }
|
|
Sets the values of mOverPosition and mTransformOver.
Definition at line 884 of file swfbuttn.cpp. 00886 { 00887 mOverPosition = Position; 00888 mTransformOver = DoTransform; 00889 }
|
|
Sets the values of mUpID and mUpType.
Definition at line 810 of file swfbuttn.cpp. 00812 { 00813 mUpID = ID; // Set the ID value for this state. 00814 mUpType = Type; // And whether or not it's a shape. 00815 mHasUp = TRUE; // Record that this state has been set. 00816 00817 // I'm treating up as the default state, so ensure that all other states are set. 00818 if ( !mHasHit ) 00819 SetHitID ( ID, Type ); 00820 00821 if ( !mHasOver ) 00822 SetOverID ( ID, Type ); 00823 00824 if ( !mHasDown ) 00825 SetDownID ( ID, Type ); 00826 }
|
|
Sets the values of mUpPosition and mTransformUp.
Definition at line 905 of file swfbuttn.cpp. 00907 { 00908 mUpPosition = Position; 00909 mTransformUp = DoTransform; 00910 }
|
|
Sets the value of mURL. mHasURL is also set, so that only the first URL string encountered is used. This is to keep it consistent with the Camelot button class.
Definition at line 926 of file swfbuttn.cpp.
|
|
Definition at line 183 of file swfbuttn.h. |
|
Definition at line 186 of file swfbuttn.h. |
|
Definition at line 196 of file swfbuttn.h. |
|
Definition at line 191 of file swfbuttn.h. |
|
Definition at line 214 of file swfbuttn.h. |
|
Definition at line 206 of file swfbuttn.h. |
|
Definition at line 211 of file swfbuttn.h. |
|
Definition at line 205 of file swfbuttn.h. |
|
Definition at line 207 of file swfbuttn.h. |
|
Definition at line 208 of file swfbuttn.h. |
|
Definition at line 210 of file swfbuttn.h. |
|
Definition at line 185 of file swfbuttn.h. |
|
Definition at line 195 of file swfbuttn.h. |
|
Definition at line 190 of file swfbuttn.h. |
|
Definition at line 215 of file swfbuttn.h. |
|
Definition at line 187 of file swfbuttn.h. |
|
Definition at line 197 of file swfbuttn.h. |
|
Definition at line 192 of file swfbuttn.h. |
|
Definition at line 218 of file swfbuttn.h. |
|
Definition at line 217 of file swfbuttn.h. |
|
Definition at line 201 of file swfbuttn.h. |
|
Definition at line 200 of file swfbuttn.h. |
|
Definition at line 202 of file swfbuttn.h. |
|
Definition at line 203 of file swfbuttn.h. |
|
Definition at line 188 of file swfbuttn.h. |
|
Definition at line 198 of file swfbuttn.h. |
|
Definition at line 193 of file swfbuttn.h. |
|
Definition at line 213 of file swfbuttn.h. |