InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
IDialogMgr Class Referenceabstract

#include <IDialogMgr.h>

Inheritance diagram for IDialogMgr:
IPMUnknown

Public Types

enum  { kDefaultIID = IID_IDIALOGMGR }
 
enum  {
  kAllowMultipleCopies = kTrue, kDontAllowMultipleCopies = kFalse, kCacheDialog = kTrue, kDontCacheDialog = kFalse,
  kAllowUserResize = kTrue, kDontAllowUserResize = kFalse
}
 

Public Member Functions

virtual IDialogCreateNewDialog (const RsrcSpec &spec, const IDialog::DialogType &dialogType, bool16 allowMultipleCopies=kAllowMultipleCopies, bool16 okToCacheDialog=kCacheDialog, bool16 allowResize=kDontAllowUserResize)=0
 
virtual IDialogCreateNewDialog (ClassID windowClass, const RsrcSpec &spec, const IDialog::DialogType &dialogType, bool16 allowMultipleCopies=kAllowMultipleCopies, bool16 okToCacheDialog=kCacheDialog, bool16 allowResize=kDontAllowUserResize)=0
 
virtual bool16 IsModalDialogOpen () const =0
 
virtual bool16 IsModelessDialogInFront () const =0
 
virtual bool16 IsAnyDialogInFront () const =0
 
virtual IWindowGetFrontmostDialogWindow () const =0
 
virtual void IncrementModalDialogCnt ()=0
 
virtual void DecrementModalDialogCnt ()=0
 
virtual uint16 GetModalDialogCnt () const =0
 
virtual void SetSuppressDialogs (bool16 suppress)=0
 
virtual bool16 GetSuppressDialogs () const =0
 
virtual uint64 ClearDialogInstanceList (bool16 reportMemoryUsed=kFalse)=0
 
virtual bool16 CanProcessDelayedWaitForDialog (IDialog *iDialog)=0
 
virtual void ClearDialogFromInstanceList (IDialog *iDialog)=0
 
- Public Member Functions inherited from IPMUnknown
virtual IPMUnknownQueryInterface (PMIID interfaceID) const =0
 
virtual void AddRef () const =0
 
virtual void Release () const =0
 

Detailed Description

Interface for the Dialog manager. The Dialog Manager interface is found on the Application boss object.

See Also
IDialog

Member Enumeration Documentation

anonymous enum

The following are const parameters for the CreateNewDialog method. Description of how the parmeters function can be found in the documentation for CreateNewDialog.

See Also
CreateNewDialog

Member Function Documentation

virtual IDialog* IDialogMgr::CreateNewDialog (const RsrcSpecspec,
const IDialog::DialogTypedialogType,
bool16 allowMultipleCopies = kAllowMultipleCopies,
bool16 okToCacheDialog = kCacheDialog,
bool16 allowResize = kDontAllowUserResize 
)
pure virtual

CreateNewDialog will create the specified dialog and return a pointer to the dialog. Don't "AddRef" the pointer, the dialog will take care of destructing itself when the dialog is closed.

If "allowMultipleCopies" is true, this function will create another copy of the dialog if a previous copy of the dialog is currently open. If "allowMultipleCopies" is false and the dialog is already open, the existing dialog is returned. If the dialog is modeless, only one copy of the dialog can be opened at a time, regardless of the value of allowMultipleCopies.

If okToCacheDialog is true, a cached copy of the dialog will be returned, if one exists. If okToCacheDialog is false, the dialog will be reread from the specified resource.

Parameters
specIN locator for the resource description
dialogTypeIN the type of the dialog (kModal, kMovableModal, or kModeless)
allowMultipleCopiesIN can multiple copies of the dialog exist simultaneously
okToCacheDialogIN can this dialog be cached, or must it be reread from disk.
allowResizeIN can this dialog be resized
Returns
the dialog, or nil.
virtual IDialog* IDialogMgr::CreateNewDialog (ClassID windowClass,
const RsrcSpecspec,
const IDialog::DialogTypedialogType,
bool16 allowMultipleCopies = kAllowMultipleCopies,
bool16 okToCacheDialog = kCacheDialog,
bool16 allowResize = kDontAllowUserResize 
)
pure virtual

Same as above version except specify the window class ID in addition to the dialog type (why? there is a 1 to 1 mapping)

Parameters
windowClassIN window class ID for the window (kModalWindowBoss, kMovableModalWindowBoss, or kModelessWindowBoss)
specIN locator for the resource description
dialogTypeIN the type of the dialog (kModal, kMovableModal, or kModeless)
allowMultipleCopiesIN can multiple copies of the dialog exist simultaneously
okToCacheDialogIN can this dialog be cached, or must it be reread from disk.
allowResizeIN can this dialog be resized
Returns
the dialog, or nil.
virtual IWindow* IDialogMgr::GetFrontmostDialogWindow () const
pure virtual
Returns
the IWindow of the frontmost dialog. If there are no dialogs, this function returns nil.
virtual bool16 IDialogMgr::GetSuppressDialogs () const
pure virtual
Returns
kTrue if dialogs are suppressed, kFalse otherwise
virtual bool16 IDialogMgr::IsAnyDialogInFront () const
pure virtual
Returns
kTrue if any type of dialog is currently the frontmost window
virtual bool16 IDialogMgr::IsModalDialogOpen () const
pure virtual
Returns
kTrue if a modal dialog is current open (i.e. being displayed)
virtual bool16 IDialogMgr::IsModelessDialogInFront () const
pure virtual
Returns
kTrue if a modeless dialog is currently the frontmost window
virtual void IDialogMgr::SetSuppressDialogs (bool16 suppress)
pure virtual

Suppress display of dialogs (by auto-pressing the default button). Does not suppress progress bars.

Parameters
suppressspecifies whether to suppress dialogs