PopUpSelect
The PopUp Select class offer a way to open a pop up window where there is a list of different options. where for each you can add events.
How to Initialize the PopUp Select?
The initialization of the PopUp Select is an one step process, just call the function Init of the class with its two arguments (see bellow for more details).
Also to be able to open the PopUp the function SetOpening() has to be called
Class Details
Functions:
Initialization & Main Functions
Name |
Arguments |
Return |
Description |
Init |
|
VOID |
This function Initialized every part of the viewer: HMTL, CSS, Data, Events, etc... It will be generated in the defined ID and all HTML IDs used for this PopUp will start by the RegistryName defined in arguments |
SetOpening |
|
VOID |
Setting up all information about the opening animation of the pop up. |
Open |
|
VOID |
Open the popup Note: SetOpening() has to be called first. |
Close |
|
VOID |
Close the popup |
Add |
|
VOID |
Add an option to the select popup |
ClearOptions |
|
VOID |
Remove all options (tool is not opening if there is no option). |
Setters Functions
Name |
Arguments |
Return |
Description |
SetHeight |
|
VOID |
Change the popup height but also reset position to center the window. |
SetHeight |
|
VOID |
Change the popup width but also reset position to center the window. |
SetIndex |
|
VOID |
Change the z-index of the pop up. |
SetTitleText |
|
VOID |
Set the title text of this popup. |
SetTitleSize |
|
VOID |
Resize the title section, the selection part will be automatically resized and moved too. |
SetTitleBackgroundColor |
|
VOID |
Setup the background color of the title section. |
SetSelectBackgroundColor |
|
VOID |
Setup background color of the selection sections. apply for each |
SetBorderStyle |
|
VOID |
Set the border that will be used as separation between two options. |
SetHorizontalAlign |
|
VOID |
Set the options horizontal alignment. |
SetBackColor |
|
VOID |
Set the popup background color. |
Private Details
All private details are usable but its recommended to not use any of those. It might modify the proper functioning of the class.
Variables (Members):
Main Members
Name |
Type |
Default Value |
Description |
id |
String |
undefined |
Global HMTL Id of the viewer (# + name). |
name |
String |
undefined |
Name of this PopUp. |
basedId |
String |
undefined |
Where it is located is the existing DOM (its parent). |
select |
Class[]:
|
[] |
Where all options details are stored. |
scale |
Integer |
0 |
Store the actual size of the PopUp. (Used by animation). |
animation |
Integer |
null |
Store the actual animation (used with ClearInterval). |
curve |
Class:
|
{} |
Hold animation details, this class is set with SetOpening() function. |
selectMargin |
Class:
|
0px |
Hold the text margin for the options |
selectBorder |
String |
none 0px black |
Hold the text border for the options |
NormalBG |
String |
white |
Hold the background color for the options |
HoveredBG |
String |
none |
Hold the background color for the options when hovered |
PressedBG |
String |
none |
Hold the background color for the options when pressed |
Functions:
Updates functions
Name |
Arguments |
Return |
Description |
UpdateTitle |
|
None |
Reset text centering of the title. |
UpdateSelects |
|
None |
Reset text centering of the options. |
UpdateStyle |
|
None |
Set all design of the popup |
Util Functions
Name |
Arguments |
Return |
Description |
GetTitle |
|
JQuery DOM Object |
Get the title div. |
GetTitleP |
|
JQuery DOM Object |
Get the title p (text). |
GetSelect |
|
JQuery DOM Object |
Get select section div. |
GetBG |
|
JQuery DOM Object |
Get background section div. |
Compatibility
LANGUAGE CLASS: Entirely Compatible
Created with the Personal Edition of HelpNDoc: Easily create Qt Help files