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

#include <ISelectableDialogSwitcher.h>

Inheritance diagram for ISelectableDialogSwitcher:
IPMUnknownCSelectableDialogSwitcherBscSlDlgTreeViewDlgSwitcher

Public Types

enum  { kDefaultIID = IID_ISELECTABLEDIALOGSWITCHER }
 
enum  { kNextPanel = -1, kPreviousPanel = -2 }
 

Public Member Functions

virtual void SwitchDialogPanel (int32 dialogNumber, bool16 validate=kTrue)=0
 
virtual void SwitchDialogPanelByID (WidgetID panelsWidgetID)=0
 
virtual void AddDialogPanel (IControlView *dialogPanel, const PMString &panelName, int32 at=-1, bool16 autoVisible=kTrue)=0
 
virtual IControlViewGetDialogPanel (WidgetID panelsWidgetID)=0
 
virtual void SetDialogServiceID (const ServiceID &dialogServiceID, const WidgetID dialogGroupPanelWidgetID=kDialogGroupPanelWidgetID, const WidgetID dialogSelectionWidgetID=kSelectDialogSelectionWidgetID, const WidgetID dialogTitleTextWidgetID=kSelectDialogTitleTextWidgetID)=0
 
virtual ServiceID GetDialogServiceID () const =0
 
virtual WidgetID GetGroupPanelWidgetID () const =0
 
virtual WidgetID GetSelectionListWidgetID () const =0
 
virtual WidgetID GetTitleTextWidgetID () const =0
 
virtual IPanelControlDataQueryGroupPanelControlData ()=0
 
virtual void LoadDialogPanels ()=0
 
virtual void ShowDialogPanel (const WidgetID panelWidgetID, const bool16 show=kTrue)=0
 
virtual void HideNonAutoShownPanels ()=0
 
virtual int32 GetCurrentPanelIndex () const =0
 
virtual WidgetID GetPanelWidgetID (int32 index) const =0
 
virtual bool16 GetAutoResizable () const =0
 
virtual void SetAutoResizable (const bool16 bAutoSize)=0
 
virtual void RemoveDialogPanel (IControlView *dialogPanel)=0
 
virtual int32 GetDialogPanelIndex (WidgetID panelWidgetID) const =0
 
virtual int32 GetNumDialogPanels () const =0
 
virtual void UnloadDialogPanels ()=0
 
virtual bool16 SetKeyFocusToSelectionList ()=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

This interface is used to maintain the various dialogs which combine to form a selectable dialog. It's rare for 3rd parties to want to implement this interface, but it's common to use it when opening a selectable dialog. Typically code to do that would look like so:


    InterfacePtr<const IPanelControlData> panelData(mySelectableDialog, UseDefaultIID());

    IControlView *dialogView = panelData->FindWidget(kMyTopLevelDialogWidgetID);

    InterfacePtr<ISelectableDialogSwitcher> dialogSwitcher(dialogView, UseDefaultIID());
    dialogSwitcher->SetDialogServiceID(kMySelectableDialogServiceImpl);

    dialogSwitcher->SwitchDialogPanelByID(kMySpecialDialogPanelWidgetID);
    mySelectableDialog->Open();
See Also
IDialogCreator
IDialog

Member Function Documentation

virtual void ISelectableDialogSwitcher::AddDialogPanel (IControlViewdialogPanel,
const PMStringpanelName,
int32 at = -1,
bool16 autoVisible = kTrue 
)
pure virtual

Adds the dialog panel to the selectable dialog. "at" specifies the position of the panel relative to the others. If "at" is -1, the panel is appended to the end of the list of panels. If autoVisible is true, the panel is added to the dialog's selection list.

Implemented in CSelectableDialogSwitcher.

virtual bool16 ISelectableDialogSwitcher::GetAutoResizable () const
pure virtual

Does the parent panel auto-resize in height as you switch to each panel.

Implemented in CSelectableDialogSwitcher.

virtual int32 ISelectableDialogSwitcher::GetCurrentPanelIndex () const
pure virtual

Returns the index of the currently displayed panel.

Implemented in CSelectableDialogSwitcher.

virtual IControlView* ISelectableDialogSwitcher::GetDialogPanel (WidgetID panelsWidgetID)
pure virtual

Finds the dialog panel in the selectable dialog.

Implemented in CSelectableDialogSwitcher.

virtual int32 ISelectableDialogSwitcher::GetDialogPanelIndex (WidgetID panelWidgetID) const
pure virtual

Given the dialog panel's WidgetID, return its current position in the panel list.

Implemented in CSelectableDialogSwitcher.

virtual ServiceID ISelectableDialogSwitcher::GetDialogServiceID () const
pure virtual

Gets the service ID for this dialog.

Implemented in CSelectableDialogSwitcher.

virtual WidgetID ISelectableDialogSwitcher::GetGroupPanelWidgetID () const
pure virtual

Gets the widget ID of the group panel that holds the dialog panels.

Implemented in CSelectableDialogSwitcher.

virtual int32 ISelectableDialogSwitcher::GetNumDialogPanels () const
pure virtual

Returns the number of selectable dialog panels.

Implemented in CSelectableDialogSwitcher.

virtual WidgetID ISelectableDialogSwitcher::GetPanelWidgetID (int32 index) const
pure virtual

Given an index to a panel, this function returns the widget id of the panel.

Implemented in CSelectableDialogSwitcher.

virtual WidgetID ISelectableDialogSwitcher::GetSelectionListWidgetID () const
pure virtual

Gets the widget ID of the list box used to select the dialog panels.

Implemented in CSelectableDialogSwitcher.

virtual WidgetID ISelectableDialogSwitcher::GetTitleTextWidgetID () const
pure virtual

Gets the widget ID of the TextWidget that is to display the name of the currently active dialog panel.

Implemented in CSelectableDialogSwitcher.

virtual void ISelectableDialogSwitcher::HideNonAutoShownPanels ()
pure virtual

Call this function when the selectable dialog is closed to hide any non auto shown panels that were made visible after the dialog was opened.

Implemented in CSelectableDialogSwitcher.

virtual void ISelectableDialogSwitcher::LoadDialogPanels ()
pure virtual

Forces a dynamic load of all the dialog panels associated with this selectable dialog

Implemented in CSelectableDialogSwitcher, and BscSlDlgTreeViewDlgSwitcher.

virtual IPanelControlData* ISelectableDialogSwitcher::QueryGroupPanelControlData ()
pure virtual

Returns the panel control data associated with the group panel widget. The group panel widget is the widget that holds all of the dialog sub panels.

Implemented in CSelectableDialogSwitcher.

virtual void ISelectableDialogSwitcher::RemoveDialogPanel (IControlViewdialogPanel)
pure virtual

Remove a dialog panel.

Implemented in CSelectableDialogSwitcher.

virtual void ISelectableDialogSwitcher::SetAutoResizable (const bool16 bAutoSize)
pure virtual

Sets auto-resize for parent panel.

Implemented in CSelectableDialogSwitcher.

virtual void ISelectableDialogSwitcher::SetDialogServiceID (const ServiceIDdialogServiceID,
const WidgetID dialogGroupPanelWidgetID = kDialogGroupPanelWidgetID,
const WidgetID dialogSelectionWidgetID = kSelectDialogSelectionWidgetID,
const WidgetID dialogTitleTextWidgetID = kSelectDialogTitleTextWidgetID 
)
pure virtual

Set the service ID for this dialog. Used to find the sub dialog panels

Implemented in CSelectableDialogSwitcher.

virtual void ISelectableDialogSwitcher::ShowDialogPanel (const WidgetID panelWidgetID,
const bool16 show = kTrue 
)
pure virtual

Call ShowDialogPanel to show a dialog panel and add its name to the selectable dialog's selection list.

Implemented in CSelectableDialogSwitcher.

virtual void ISelectableDialogSwitcher::SwitchDialogPanel (int32 dialogNumber,
bool16 validate = kTrue 
)
pure virtual

Changes the displayed dialog panel to that of dialogNumber. Normally, validation takes place on the panel that will get hidden. Validation can be turned off by passing in false. Pass in "kNextPanel" to switch to the next panel or "kPreviousPanel" to go to the previous panel.

Implemented in CSelectableDialogSwitcher.

virtual void ISelectableDialogSwitcher::SwitchDialogPanelByID (WidgetID panelsWidgetID)
pure virtual

Changes the displayed dialog panel to the panel with the specified widget id.

Implemented in CSelectableDialogSwitcher.

virtual void ISelectableDialogSwitcher::UnloadDialogPanels ()
pure virtual

Forces a dynamic unload of all the dialog panels associated with this selectable dialog

Implemented in CSelectableDialogSwitcher.