InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
IBehaviorSuite.h
1 //========================================================================================
2 //
3 // $File$
4 //
5 // Owner: Michael Brubidge
6 //
7 // $Author$
8 //
9 // $DateTime$
10 //
11 // $Revision$
12 //
13 // $Change$
14 //
15 // Copyright 1997-2010 Adobe Systems Incorporated. All rights reserved.
16 //
17 // NOTICE: Adobe permits you to use, modify, and distribute this file in accordance
18 // with the terms of the Adobe license agreement accompanying it. If you have received
19 // this file from a source other than Adobe, then your use, modification, or
20 // distribution of it requires the prior written permission of Adobe.
21 //
22 //========================================================================================
23 
24 #ifndef __IBehaviorSuite_h__
25 #define __IBehaviorSuite_h__
26 
27 #include "IPMUnknown.h"
28 #include "BehaviorID.h"
29 #include "BehaviorTypes.h"
30 #include <vector>
31 
32 class IBehaviorData;
33 class IBehaviorEvent;
34 
42 class IBehaviorSuite : public IPMUnknown
43 {
44 public:
45  enum { kDefaultIID = IID_IBEHAVIORSUITE };
46 
49  virtual bool16 CanApplyActions() const = 0;
50 
54  virtual bool16 IsEventSupported(IBehaviorEvent* inEvent) const = 0;
55 
64  virtual bool16 CanMoveAction(const UID& actionToMove, const ActionEvent& newEvent, int32 newPosition) = 0;
65 
71  virtual void GetActions(const ActionEvent& forEvent, IDataBase*& db, std::vector<UID>& actions) const = 0;
72 
77  virtual void GetEventAndActions(IDataBase*& db, std::vector< std::pair<ActionEvent, UID> >& actions) const = 0;
78 
84  virtual ErrorCode AddAction(const ActionEvent& forEvent, IBehaviorData* actionData, UID& newAction) = 0;
85 
92  virtual ErrorCode ReplaceAction(const ActionEvent& forEvent, const UID& actionToReplace, IBehaviorData* actionData) = 0;
93 
99  virtual ErrorCode DuplicateAction(const ActionEvent& forEvent, const UID& actionToDuplicate, UID& newAction) = 0;
100 
105  virtual ErrorCode DeleteAction(const UID& actionToDelete) = 0;
106 
115  virtual ErrorCode MoveAction(const UID& actionToMove, const ActionEvent& newEvent, int32 newPosition) = 0;
116 
124  virtual ErrorCode EnableAction(const UID& actionToEnable, const bool16& enable = kTrue) = 0;
125 
129  virtual ErrorCode DeleteAllActions() = 0;
130 };
131 
132 #endif // __IBehaviorSuite_h__