InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
IShortcutUtils.h
1 //========================================================================================
2 //
3 // $File$
4 //
5 // Owner: Bernd Paradies
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 __IShortcutUtils__
25 #define __IShortcutUtils__
26 
27 #include "AppFrameworkID.h"
28 #include "IPMUnknown.h"
29 #include "Utils.h"
30 
31 #include "VirtualKey.h"
32 
33 class IWorkspace;
34 class IShortcutContext;
35 class IEvent;
36 
41 class IShortcutUtils : public IPMUnknown
42 {
43 public:
44  enum { kDefaultIID = IID_ISHORTCUTUTILS };
45 
46 
53  virtual PMString GetShortcutString(ActionID id, bool16 bAddContextStr = kFalse, const bool bGetOnlyOne = false) = 0;
60  virtual PMString GetShortcutString(const VirtualKey& key, int16 mods, const bool& shouldTranslate = true) = 0;
61 
69  virtual void ParseShortcutString(const PMString& shortcutStr, VirtualKey *keyOut, int16 *modsOut, const bool& shouldTranslate = false) = 0;
70 
78  virtual UID FindShortcutStyle(IWorkspace *ws, const VirtualKey& key, int16 mods, ClassID *whichStrand) = 0;
79 
86  virtual int16 GetEventModifiersForKBSC(const IEvent* pEvent, VirtualKey& vkey) = 0;
87 
92 
97  virtual bool16 IsEnabledShortcut(const IEvent* e) = 0;
98 
102  virtual bool16 GetNumLockStatus() const= 0;
103 
107  virtual void SetNumLockStatus(bool16 bStatus) = 0;
108 };
109 
110 
111 #endif // __IShortcutUtils__