This module was created to support the Gallery View
to allow thumbnails to be resized.
- Copyright:
- Copyright (C) 2005-2020 Alfresco Software Limited
- License:
- GNU Lesser General Public License, see: Open Source Licensing
- Source:
Mixes In
Members
-
columns :number
-
The number of columns to be represented by the slider.
Type:
- number
- Default Value:
- 4
- Source:
-
columnsPreferenceProperty :string
-
The preference property to use for retrieving and setting the users preferred number of columns
Type:
- string
- Since:
- 1.0.35
- Default Value:
- "org.alfresco.share.documentList.galleryColumns"
- Source:
-
cssRequirements :object[]
-
An array of the CSS files to use with this widget.
Type:
- object[]
- Default Value:
- [{cssFile:"./css/AlfGalleryViewSlider.css"}]
- Source:
-
discreteValues :integer
-
The number of steps (including the beginning and end positions) on the slider
Type:
- integer
- Default Value:
- 4
- Source:
-
maximum :integer
-
The maximum value on the slider.
Type:
- integer
- Default Value:
- 60
- Source:
-
minimum :number
-
The minimum value on the slider
Type:
- number
- Default Value:
- 0
- Source:
-
showButtons :boolean
-
Indicates whether or not to show the bigger/smaller buttons at either end of the slider
Type:
- boolean
- Default Value:
- true
- Source:
Methods
-
_setSelected(selected)
-
This method is required in order for the slider to "behave" itself without causing errors when placed as an item in a menu.
Parameters:
Name Type Description selected
boolean -
getColumnsFromSliderValue() → {number}
-
Maps the value provided by the slider to the number of columns that the gallery view should display.
Returns:
The number of columns to display.- Type
- number
-
getSliderValueFromColumns() → {number}
-
Maps the columns provided to the value for the slider.
Returns:
The slider position based on the input- Type
- number
-
onChange(value)
-
Parameters:
Name Type Description value
number The value provided from the change to the slider. Fires:
-
onColumnPreferences(value)
-
This is called when column user preferences are provided.
Parameters:
Name Type Description value
number The number of columns to set. Fires:
-
onControlDisplayed()
-
This is called whenever the control is displayed to ensure that sizes are initialised.
Fires:
-
postCreate()
-
Fires:
-
setColumns(value)
-
Parameters:
Name Type Description value
number The number of columns to set.