#include <zordops.h>
Inheritance diagram for FrameBehindOpDescriptor:
Public Member Functions | |
FrameBehindOpDescriptor (const TCHAR *pcszToken, CCRuntimeClass *pClass=CC_RUNTIME_CLASS(FrameBehindOpDescriptor), pfnGetState gs=FrameBehindOpDescriptor::GetState) | |
Constructs the new FrameInFrontOpDescriptor. | |
virtual BOOL | GetText (String_256 *Description, OpTextFlags WhichText) |
Depending upon the document Mode, (i.e Frame or Layer), this function will obtain the String resource describing an operation. String resources may have one or more text descriptions in them, therefore, a TextFlag can be used to identify the the appropriate text required. | |
Static Public Member Functions | |
static OpState | GetState (String_256 *psName, OpDescriptor *pOpDesc) |
Returns the state that this operation should appear in the menus or as a buttom, for example - greyed out, or ticked. | |
Private Member Functions | |
CC_DECLARE_DYNAMIC (FrameBehindOpDescriptor) |
Definition at line 366 of file zordops.h.
|
Constructs the new FrameInFrontOpDescriptor.
Definition at line 3452 of file zordops.cpp. 03454 : OpDescriptor( 0, // tool ID 03455 _R(IDS_MOVELAYERBEHIND), // String resource ID (use same for all) 03456 pClass, //CC_RUNTIME_CLASS(PlugInOp), Runtime class 03457 (TCHAR*) pcszToken, // OpToken 03458 gs, // GetState function 03459 0, // help ID 03460 _R(IDBBL_MOVELAYERBEHIND), // bubble help 03461 _R(IDD_ANIMATIONBAR), // resource ID 03462 _R(IDC_FRAME_MOVEDOWNAFRAME), // control ID 03463 TRUE, // Recieve system messages 03464 FALSE, // Smart duplicate operation 03465 TRUE, // Clean operation 03466 0, // String for one copy only error 03467 (GREY_WHEN_NO_SELECTION | GREY_WHEN_NO_CURRENT_DOC) // Auto state flags 03468 ) 03469 {}
|
|
|
|
Returns the state that this operation should appear in the menus or as a buttom, for example - greyed out, or ticked.
Definition at line 3488 of file zordops.cpp. 03489 { 03490 // At present, this item is always available. 03491 OpState OpSt; 03492 return OpSt; 03493 }
|
|
Depending upon the document Mode, (i.e Frame or Layer), this function will obtain the String resource describing an operation. String resources may have one or more text descriptions in them, therefore, a TextFlag can be used to identify the the appropriate text required.
Reimplemented from OpDescriptor. Definition at line 3512 of file zordops.cpp. 03513 { 03514 // Assume we are in layer mode. 03515 BOOL LayerMode = TRUE; 03516 TCHAR* ok; 03517 03518 //Determine the document mode. 03519 Document* pDoc = Document::GetSelected(); 03520 03521 // Ensure a valid ptr. 03522 if(pDoc) 03523 { 03524 // Get a ptr to the selected spread 03525 Spread* pSpread = pDoc->GetSelectedSpread(); 03526 03527 // Ensure a valid spread ptr. 03528 if(pSpread) 03529 { 03530 // Are there any frame layers? 03531 Layer* pFrameLayer = pSpread->FindFirstFrameLayer(); 03532 03533 //If a frame layer exists, then this is an animation doc. 03534 if (pFrameLayer) 03535 LayerMode = FALSE; 03536 } 03537 } 03538 03539 if(LayerMode) 03540 { 03541 // In layer mode. 03542 String_256 ResourceText( _R(IDS_MOVELAYERBEHIND), ModuleID ); 03543 03544 // Explicitly cast return value from GetDescription from a TCHAR* to a String_256 03545 ok = GetDescription((TCHAR*) ResourceText, WhichText); 03546 } 03547 else 03548 { 03549 // In frame mode. 03550 String_256 ResourceText( _R(IDS_MOVERFAMEBEHIND), ModuleID ); 03551 03552 // Explicitly cast return value from GetDescription from a TCHAR* to a String_256 03553 ok = GetDescription((TCHAR*) ResourceText, WhichText); 03554 } 03555 03556 // if description is found then return true else return false 03557 if (ok) 03558 { 03559 *Description = String_256(ok); 03560 return TRUE; 03561 } 03562 else 03563 return FALSE; 03564 03565 }
|