InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
IKeyBoard Class Referenceabstract
Inheritance diagram for IKeyBoard:
IPMUnknown

Public Types

enum  { kDefaultIID = IID_IKEYBOARD }
 

Public Member Functions

virtual bool16 AcquireKeyFocus (IEventHandler *newKeyFocus, bool16 validate=kTrue)=0
 
virtual bool16 RelinquishKeyFocus (bool16 validate=kTrue)=0
 
virtual bool16 RelinquishKeyFocusForWindow (IWindow *window, bool16 validate=kTrue)=0
 
virtual void RemoveEventHandlersForWindow (IWindow *window)=0
 
virtual IEventHandlerGetKeyFocus () const =0
 
virtual void RememberLastEditboxKeyFocusInPalette (IEventHandler *eh)=0
 
virtual bool16 RestoreLastEditboxKeyFocusInPalette ()=0
 
virtual void AppSuspend ()=0
 
virtual void AppResume ()=0
 
virtual bool16 ValidateCurrentKeyFocus ()=0
 
virtual void OpenExternalModalWindow (bool isDVAOwnedWindow=false)=0
 
virtual void ExternalModalWindowClosed ()=0
 
- Public Member Functions inherited from IPMUnknown
virtual IPMUnknownQueryInterface (PMIID interfaceID) const =0
 
virtual void AddRef () const =0
 
virtual void Release () const =0
 

Member Function Documentation

virtual bool16 IKeyBoard::AcquireKeyFocus (IEventHandlernewKeyFocus,
bool16 validate = kTrue 
)
pure virtual

Set a new key focus. newKeyFocus will get all subsequent keyboard events until RelinquishKeyFocus is called. If the focus can't be acquired because the current focus handler won't let go, this function returns kFalse. If you pass kFalse for the "validate" parameter, validation of the current handler won't occur.

virtual void IKeyBoard::AppResume ()
pure virtual

Handle necessary key focus job after application has been resumed

Returns
none
virtual void IKeyBoard::AppSuspend ()
pure virtual

Handle necessary key focus job after application has been suspended

Returns
none
virtual void IKeyBoard::ExternalModalWindowClosed ()
pure virtual

Handle necessary key focus job after external modal window such as Open/Save dialog, alert box et al. closed

Returns
none
virtual IEventHandler* IKeyBoard::GetKeyFocus () const
pure virtual

Return the event handler that has key focus.

virtual void IKeyBoard::OpenExternalModalWindow (bool isDVAOwnedWindow = false)
pure virtual

Handle necessary key focus job before open external modal window such as Open/Save dialog, alert box et al. isDVAOwnedWindow:Internal Use only, is this window external(false) or dvaowned(true)

virtual bool16 IKeyBoard::RelinquishKeyFocus (bool16 validate = kTrue)
pure virtual

Remove the key focus. Restores key focus to the previous holder of the key focus. Returns kFalse if the current focus event handler won't let go of the focus. If you pass kFalse for the "validate" parameter, validation of the current handler won't occur. If you pass kTrue for the "rememberFocus" parameter, a keyboard shortcut will restore the keyboard focus to the focus that is being relinquished.

virtual bool16 IKeyBoard::RelinquishKeyFocusForWindow (IWindowwindow,
bool16 validate = kTrue 
)
pure virtual

If any event handler belonging to "window" has the key focus, give it up. If you pass kFalse for the "validate" parameter, validation of the current handler won't occur.

virtual void IKeyBoard::RememberLastEditboxKeyFocusInPalette (IEventHandlereh)
pure virtual

Remember the last editbox in palette with key focus so we can restore it with shortcut. This is specified in Adobe Common UI for palette (Ctrl+~). Note: Ctrl+~ is defualt one in window but on onger available after OS X 10.2.x

Returns
none
virtual void IKeyBoard::RemoveEventHandlersForWindow (IWindowwindow)
pure virtual

Call RemoveEventHandlersForWindow before closing a window. This function makes sure that any event handlers on the event handler stack belonging to the referenced window are removed.

virtual bool16 IKeyBoard::RestoreLastEditboxKeyFocusInPalette ()
pure virtual

This function attempts to restore the last editbox with key focus in palette

Returns
kTrue if keyboard focus (if there was one) was successfully restored.
virtual bool16 IKeyBoard::ValidateCurrentKeyFocus ()
pure virtual

Try to validate widget which hold key focus. Right now, only editbox link its validation to loss of key focus

Returns
kTrue if widget hold keyboard focus (if there was one) was successfully validated.