70 virtual void afterCreate(IUIDescription
const *iDescription, IController *iController);
114 explicit Creator(
char const *iViewName =
nullptr,
char const *iDisplayName =
nullptr) :
129 const UIAttributes &iAttributes,
130 const IUIDescription *iDescription);
ParamID getSwitchControlTag() const
id for the parameter tied to switching.
Definition: SwitchViewContainer.h:59
Inherit from this class to provide the factory for a custom view.
Definition: CustomViewCreator.h:1311
SwitchViewContainer(const CRect &iSize)
Definition: SwitchViewContainer.cpp:26
virtual void switchCurrentView()
Called whenever something has changed to switch to a new current view.
Definition: SwitchViewContainer.cpp:67
const std::vector< std::string > & getTemplateNames() const
A comma separated list of template names.
Definition: SwitchViewContainer.h:63
This view offers dynamic switching between multiple views.
Definition: SwitchViewContainer.h:46
std::string fCurrentTemplateName
Definition: SwitchViewContainer.h:108
void viewContainerViewAdded(CViewContainer *container, CView *view) override
The only purpose of this callback (from IViewContainerListenerAdapter) is to catch the unavoidable ca...
Definition: SwitchViewContainer.cpp:113
IController * fUIController
Definition: SwitchViewContainer.h:100
GUIOptionalParam< int32 > fControlSwitch
Definition: SwitchViewContainer.h:103
void registerTagAttribute(std::string const &iName, typename TagAttribute::Getter iGetter, typename TagAttribute::Setter iSetter)
Registers a tag attribute with the given name and getter/setter.
Definition: CustomViewCreator.h:1047
virtual void setSwitchControlTag(ParamID iTag)
Attribute switch-control-tag
Definition: SwitchViewContainer.h:54
Definition: SwitchViewContainer.h:111
virtual void setCurrentView(CView *iCurrentView)
Sets the current view to the one provided (remove previous view from container children and add this ...
Definition: SwitchViewContainer.cpp:96
This class can be used to extend VSTGUI classes directly while still benefiting from the extensions a...
Definition: CustomView.h:335
virtual void afterCreate(IUIDescription const *iDescription, IController *iController)
Definition: SwitchViewContainer.cpp:43
IUIDescription const * fUIDescription
Definition: SwitchViewContainer.h:99
~SwitchViewContainer() override
Definition: SwitchViewContainer.cpp:34
ParamID fSwitchControlTag
Definition: SwitchViewContainer.h:102
Definition: CustomController.h:24
void registerParameters() override
Subclasses should override this method to register each parameter.
Definition: SwitchViewContainer.cpp:52
std::vector< std::string > fTemplateNames
Definition: SwitchViewContainer.h:105
Creator(char const *iViewName=nullptr, char const *iDisplayName=nullptr)
Definition: SwitchViewContainer.h:114
SwitchViewContainer * createCustomView< SwitchViewContainer >(CRect const &iSize, const UIAttributes &iAttributes, const IUIDescription *iDescription)
This specialization is required to inject the IUIDescription object used to dynamically create a view...
Definition: SwitchViewContainer.cpp:138
void onParameterChange(ParamID iParamID) override
This is the callback that should be implemented to handle parameter changes.
Definition: SwitchViewContainer.cpp:86
void registerVectorStringAttribute(std::string const &iName, typename VectorStringAttribute::Getter iGetter, typename VectorStringAttribute::Setter iSetter, char iDelimiter=',', bool iSkipEmptyEntries=false)
Registers a Range attribute with the given name and getter/setter.
Definition: CustomViewCreator.h:1010
void setTemplateNames(const std::vector< std::string > &iNames)
Definition: SwitchViewContainer.h:64
CView * fCurrentView
Definition: SwitchViewContainer.h:107
constexpr ParamID UNDEFINED_PARAM_ID
Constant used throughout the code to test whether the ParamID represents a valid id or an undefined o...
Definition: Types.h:47
virtual std::string computeTemplateName(int iIndex)
Lookup the name of the template in the vector.
Definition: SwitchViewContainer.cpp:125