AllowOpScan Class Reference

Performs an AllowOp test and update on all the objects which are members of highlighted 'Used Name' items in the Attribute gallery; performs the same, but only on members of a specified set. Notes: The present implementation is not reentrant or thread-safe. More...

#include <ngscan.h>

Inheritance diagram for AllowOpScan:

UndoableNodeScan NodeScan AllowOpSingleScan List of all members.

Public Member Functions

 AllowOpScan (UndoableOperation *pOp, Source *ps)
virtual BOOL Update ()
 Defines the ObjChangeParam as FINISHED and calls UpdateChangedNodes.

Protected Member Functions

virtual BOOL Do (Node *)
 Tests if the given node is a member of a set that the user has highlighted in the Name Gallery and if so, calls AllowOp on it.

Static Protected Attributes

static ObjChangeParam m_OCP

Classes

class  IsLitUsedName

Detailed Description

Performs an AllowOp test and update on all the objects which are members of highlighted 'Used Name' items in the Attribute gallery; performs the same, but only on members of a specified set. Notes: The present implementation is not reentrant or thread-safe.

Author:
Justin_Flude (Xara Group Ltd) <camelotdev@xara.com>
Date:
21/5/99

Definition at line 233 of file ngscan.h.


Constructor & Destructor Documentation

AllowOpScan::AllowOpScan UndoableOperation pOp,
Source *  ps
 


Member Function Documentation

BOOL AllowOpScan::Do Node pNode  )  [protected, virtual]
 

Tests if the given node is a member of a set that the user has highlighted in the Name Gallery and if so, calls AllowOp on it.

Author:
Justin_Flude (Xara Group Ltd) <camelotdev@xara.com>
Date:
27/5/99
Parameters:
pNode --- the node to call AllowOp for if it is a member of [INPUTS] a highlighted set in the Name Gallery.
See also:
AllowOpScan::IsLitUsedName; Node::AllowOp

Implements NodeScan.

Reimplemented in AllowOpSingleScan.

Definition at line 531 of file ngscan.cpp.

00532 {
00533     // If the node is a highlighted member of a "used names" set then call it's AllowOp
00534     // function and stop the iteration if it refuses the op.  If it isn't a member then
00535     // ignore it.
00536     return IsLitUsedName(pNode).ForEach() == 0 || pNode->AllowOp(&m_OCP);
00537 }

BOOL AllowOpScan::Update  )  [virtual]
 

Defines the ObjChangeParam as FINISHED and calls UpdateChangedNodes.

Author:
Justin_Flude (Xara Group Ltd) <camelotdev@xara.com>
Date:
27/5/99
Parameters:
pOp --- the UndoableOperation to scan for "allowance". [INPUTS] pOCP --- the ObjChangeParam block to use
Returns:
TRUE if successful.
See also:
ObjChangeParam; UndoableOperation

Definition at line 553 of file ngscan.cpp.

00554 {
00555     // Update all parents of changed nodes.
00556     m_OCP.Define(OBJCHANGE_FINISHED, ObjChangeFlags(FALSE, FALSE, FALSE, TRUE), 0, m_pOp);
00557     return m_pOp->UpdateChangedNodes(&m_OCP);
00558 
00559 }


Member Data Documentation

ObjChangeParam AllowOpScan::m_OCP [static, protected]
 

Definition at line 250 of file ngscan.h.


The documentation for this class was generated from the following files:
Generated on Sat Nov 10 03:49:55 2007 for Camelot by  doxygen 1.4.4