structure_floater

Summary
Construct a new floating ‘window’ object (actually a collection of divs).
Opens the floater
Closes the floater, removes it from the canvas.
Moves the floater to a new position.
Canters the floater relative to the borders of the canvas.
Resizes the floater to the specified dimensions.
Closes floater by removing it from the canvas.

Functions

constructor

host.kernel.constructors.structure_floater = function(params_o)

Construct a new floating ‘window’ object (actually a collection of divs).

Parameters

params_o{Object} This single argument is an Object object of parameters containing the name/value pairs listed below.

params_o

height_int(Int) Initial height of floating window, overridden by value from state system
width_int(Int) Initial width of floating window, overridden by value from state system
title_str(String) Title in titlebar of floater
uniqueName_str(String) Unique identifier for instance created by this constructor.  Required by state system.
main_className(String) CSS className general styles
titleBar_className(String) CSS className for floater title bar
body_className(String) CSS className for floater body
borderDiv_className(String) CSS className for floater border divs.
resizeFunction_ref(Function reference) (optional) function called after the floater is resized.  Useful in the instance.
openFunction_ref(Function reference) (optional) function called after the floater opens.  Useful in the instance.

Constructors Used

open

host.kernel.constructors.structure_floater.prototype.open = function(
   center_bool
)

Opens the floater

Parameters

center_bool(Boolean) (optional) if true, the floater gets centered after opening.

close

host.kernel.constructors.structure_floater.prototype.close = function(
   e,
   body_div_ref
)

Closes the floater, removes it from the canvas.  Method takes one parameter, not both.

Parameters

e(Event object) (exclusive) new top value
body_div_ref(Object object) (exclusive) new left value.  Call as this.close(undefined, body_div_ref)

moveTo

host.kernel.constructors.structure_floater.prototype.moveTo = function(top_int,
left_int)

Moves the floater to a new position.  If a value for one axis is not passed, the position in that axis remains tha same.

Parameters

top_int(Int) (optional) new top value
left_int(Int) (optional) new left value

center

host.kernel.constructors.structure_floater.prototype.center = function()

Canters the floater relative to the borders of the canvas.

resize

host.kernel.constructors.structure_floater.prototype.resize = function(
   height_int,
   width_int
)

Resizes the floater to the specified dimensions.  If a value for one dimension is not passed, that dimension remains tha same.

Parameters

height_int(Int) (optional) new height for floater
width_int(Int) (optional) new width for floater

closer

host.kernel.constructors.structure_floater.prototype.closer = function(_this)

Closes floater by removing it from the canvas.

Parameters

_this(Object) Reference to the floater object.  Yes, that’s annoying and needs to be fixed.
host.kernel.constructors.structure_floater = function(params_o)
Construct a new floating ‘window’ object (actually a collection of divs).
host.kernel.constructors.structure_floater.prototype.open = function(
   center_bool
)
Opens the floater
host.kernel.constructors.structure_floater.prototype.close = function(
   e,
   body_div_ref
)
Closes the floater, removes it from the canvas.
host.kernel.constructors.structure_floater.prototype.moveTo = function(top_int,
left_int)
Moves the floater to a new position.
host.kernel.constructors.structure_floater.prototype.center = function()
Canters the floater relative to the borders of the canvas.
host.kernel.constructors.structure_floater.prototype.resize = function(
   height_int,
   width_int
)
Resizes the floater to the specified dimensions.
host.kernel.constructors.structure_floater.prototype.closer = function(_this)
Closes floater by removing it from the canvas.