InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
ILiveEditFacade.h
1 //========================================================================================
2 //
3 // $File$
4 //
5 // Owner: Bill Tislar
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 __ILIVEEDITFACADE__
25 #define __ILIVEEDITFACADE__
26 
27 #include "InCopyBridgeID.h"
28 #include "Utils.h"
29 #include "IPMUnknown.h"
30 
31 
49 class TaskProgressBar;
50 
51 namespace Facade
52  {
53  class ILiveEditFacade : public IPMUnknown
54  {
55  public:
56  enum { kDefaultIID = IID_ILIVEEDITFACADE };
57 
58  enum LiveEditError
59  {
60  kNoError = kICBErr_NoError,
61  kUnknown = kICBErr_Unknown,
62  kInvalidParameter = kICBErr_InvalidParameter,
63  kNoDataLink = kICBErr_NoDataLink,
64  kBrokenLink = kICBErr_BrokenLink,
65  kLinkIsEmbedded = kICBErr_LinkIsEmbedded,
66  kNotNormalLink = kICBErr_NotNormalLink,
67  kCantGetLinkFile = kICBErr_CantGetLinkFile,
68  kInvalidUserName = kICBErr_kInvalidUserName,
69  kLinkIsMissing = kICBErr_kLinkIsMissing,
70  kLastInCopyBridgeError = kLinkIsMissing
71  };
72 
86  virtual ErrorCode CancelCheckOut( const UIDList& storyList, bool16 updateStoryLink = kTrue, ICommand::Undoability undoabilityFlag = ICommand::kRegularUndo, const PMString *userName = nil, UIFlags uiFlags = kFullUI ) = 0;
87 
91  {
93  enUnlockAsset = 0x00000001,
95  enExportStory = 0x00000002,
97  enSaveVersion = 0x00000004,
99  enKeepUndoStack = 0x00000008,
100  enLast = 0x7FFFFFFF // Force enum to 32 bits
101  };
102 
120  virtual ErrorCode CheckIn( const UIDList& storyList, ILiveEditFacade::CheckInOptions opts = ILiveEditFacade::enUnlockAsset, const PMString * comment = nil, const PMString *userName = nil, ICommand::Undoability undoabilityFlag = ICommand::kAutoUndo, UIFlags uiFlags = kFullUI ) = 0;
121 
138  virtual ErrorCode CheckOut( const UIDList& storyList, ICommand::Undoability undoabilityFlag = ICommand::kRegularUndo, const PMString *userName = nil, bool16 displayConflictAlert = kFalse, UIFlags uiFlags = kFullUI ) = 0;
139 
148  virtual ErrorCode RelockStories( const UIDList& storyList, UIFlags uiFlags = kFullUI ) = 0;
149 
156  virtual ErrorCode SaveStories( const UIDList& storyList, UIFlags uiFlags = kFullUI ) = 0;
157 
168  virtual ErrorCode SynchronizeLocks( const UIDList& storyList, ICommand::Undoability undoabilityFlag = ICommand::kRegularUndo, TaskProgressBar * progressBar = nil, UIFlags uiFlags = kFullUI ) = 0;
169 
180  virtual ErrorCode UpdateStoryLink( const UIDList& storyList, ICommand::Undoability undoabilityFlag = ICommand::kRegularUndo, PMString * commandName = nil, UIFlags uiFlags = kFullUI ) = 0;
181 
182  }; // end ILiveEditFacade interface
183 
184 
185 
188  inline bool IsLiveEditAvailable()
189  {
190  return Utils<Facade::ILiveEditFacade>() == nil ? false : true;
191  }
192 } // end namespace Facade
193 
194 #endif // __ILIVEEDITFACADE__