A boolean indicating whether or not to automatically insert a view switcher to supported regions hosted by this MultiRegionViewModel. Defaults to false.
A collection of region descriptors for all regions created by this MultiRegionViewModel
The libraryId to be used to construct the RegionViewSwitcherWidget for supported regions. Defaults to Framework.UI
The markup resource to be used to construct the RegionViewSwitcherWidget for supported regions. Defaults to Framework.UI/geocortex/framework/ui/ViewSwitcher/ViewSwitcherView.html
The markup type to be used for the RegionViewSwitcherWidget for supported regions. Defaults to geocortex.framework.ui.ViewSwitcher.ViewSwitcherView
An array containing the types of supported region adapters to which we can attach a view switcher
Binds a handler to an Observable or to a dojo.connect. Binding to an Observable:
``` this.auto(someObservable, function (newValue) { });
with explicit scope:
this.auto(someObservable, this, function (newValue) { });
Alternately, pass an event name as a string to use dojo.connect:
this.auto(window, "onclick", function () { }); ```
Either an Observable (for observable bindings) or a regular object (if arg1 is a string)
If arg0 is an Observable, a function or scope object. Otherwise, an event name (to use with dojo.connect).
If arg0 is an Observable, a function handler.
Creates and returns a descriptor for a given region. Override this method to return a custom region descriptor
A string denoting the name of the region for which this descriptor is being created
A string denoting the type of the region for which this descriptor is being created
An optional string which defines any custom css to be applied to the new region
A descriptor for newly constructed region
Creates and returns a view model for a view switcher for this region. Override this method to return a custom view switcher.
The region whose views the created view switcher view model should target.
An initialized ViewSwitcherViewModel.
Destroys the object completely
Disposes any bindings tracked by this object.
Gets a language resource from the Application's resource dictionary, given a key, and optional locale. Returns null if the resource does not exist.
The locale of the resource to fetch. Defaults to the current application locale.
Initializes the MultiRegionViewModel.
A configuration object containing an array of region definitions. Each definition will contain a regionName, optional regionType and optional regionCss. An optional property - autoInsertViewSwitcher - can be set to false to disable automatic insertion of view switchers into regions.
Override or attach to provide custom clean-up behaviour.
Process each region created by the MultiRegionViewModel. May be overridden to provide custom behaviour.
The region descriptor describing the newly created region
Returns true if a specified region supports a view switcher
The region descriptor for the region
Returns true if the region supports a view switcher, false otherwise.
Tracks a subscription to an {@link geocortex.framework.commands.Command}, disposing it when this object is disposed with the destroy method.
Tracks a subscription to an {@link geocortex.framework.events.Event}, disposing it when this object is disposed with the destroy method.
The MultiRegionView is intended to host a simple view containing various user configured regions. The regions are MultiDivRegionAdapters by default but can be configured as any type. If a region of type MultiDivRegionAdapter detects more than a single view hosted in it, it will automatically insert a view switcher so users can switch between views - unless configured otherwise.