windowmanager
Version:
A framework to manage multiple dockable, HTML windows
4,456 lines (926 loc) • 59.7 kB
HTML
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Window - Documentation</title>
<script src="scripts/prettify/prettify.js"></script>
<script src="scripts/prettify/lang-css.js"></script>
<!--[if lt IE 9]>
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<link type="text/css" rel="stylesheet" href="https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css">
<link type="text/css" rel="stylesheet" href="styles/prettify-tomorrow.css">
<link type="text/css" rel="stylesheet" href="styles/jsdoc-default.css">
</head>
<body>
<input type="checkbox" id="nav-trigger" class="nav-trigger" />
<label for="nav-trigger" class="navicon-button x">
<div class="navicon"></div>
</label>
<label for="nav-trigger" class="overlay"></label>
<nav>
<h2><a href="index.html">Home</a></h2><h3>Classes</h3><ul><li><a href="BoundingBox.html">BoundingBox</a><ul class='methods'><li data-type='method'><a href="BoundingBox.html#clone">clone</a></li><li data-type='method'><a href="BoundingBox.html#difference">difference</a></li><li data-type='method'><a href="BoundingBox.html#getArea">getArea</a></li><li data-type='method'><a href="BoundingBox.html#getBoundingBox">getBoundingBox</a></li><li data-type='method'><a href="BoundingBox.html#getCenteredOnPosition">getCenteredOnPosition</a></li><li data-type='method'><a href="BoundingBox.html#getCenterPosition">getCenterPosition</a></li><li data-type='method'><a href="BoundingBox.html#getColliding">getColliding</a></li><li data-type='method'><a href="BoundingBox.html#getCollisionMesh">getCollisionMesh</a></li><li data-type='method'><a href="BoundingBox.html#getDistanceSquaredToPoint">getDistanceSquaredToPoint</a></li><li data-type='method'><a href="BoundingBox.html#getDistanceToPoint">getDistanceToPoint</a></li><li data-type='method'><a href="BoundingBox.html#getEdgeClosest">getEdgeClosest</a></li><li data-type='method'><a href="BoundingBox.html#getEdgeClosestOrder">getEdgeClosestOrder</a></li><li data-type='method'><a href="BoundingBox.html#getEdgeTouching">getEdgeTouching</a></li><li data-type='method'><a href="BoundingBox.html#getHeight">getHeight</a></li><li data-type='method'><a href="BoundingBox.html#getIntersection">getIntersection</a></li><li data-type='method'><a href="BoundingBox.html#getOtherEdgeTouching">getOtherEdgeTouching</a></li><li data-type='method'><a href="BoundingBox.html#getPosition">getPosition</a></li><li data-type='method'><a href="BoundingBox.html#getSize">getSize</a></li><li data-type='method'><a href="BoundingBox.html#getSnapDelta">getSnapDelta</a></li><li data-type='method'><a href="BoundingBox.html#getWidth">getWidth</a></li><li data-type='method'><a href="BoundingBox.html#isColliding">isColliding</a></li><li data-type='method'><a href="BoundingBox.html#isContains">isContains</a></li><li data-type='method'><a href="BoundingBox.html#isNaN">isNaN</a></li><li data-type='method'><a href="BoundingBox.html#isTouching">isTouching</a></li><li data-type='method'><a href="BoundingBox.html#moveBy">moveBy</a></li><li data-type='method'><a href="BoundingBox.html#moveTo">moveTo</a></li><li data-type='method'><a href="BoundingBox.html#resizeTo">resizeTo</a></li><li data-type='method'><a href="BoundingBox.html#set">set</a></li><li data-type='method'><a href="BoundingBox.html#someColliding">someColliding</a></li><li data-type='method'><a href="BoundingBox.html#someContains">someContains</a></li><li data-type='method'><a href="BoundingBox.html#someTouching">someTouching</a></li></ul></li><li><a href="CollisionMesh.html">CollisionMesh</a><ul class='methods'><li data-type='method'><a href="CollisionMesh.html#clone">clone</a></li><li data-type='method'><a href="CollisionMesh.html#getBoundingBox">getBoundingBox</a></li><li data-type='method'><a href="CollisionMesh.html#getColliding">getColliding</a></li><li data-type='method'><a href="CollisionMesh.html#getCollisionMesh">getCollisionMesh</a></li><li data-type='method'><a href="CollisionMesh.html#getHeight">getHeight</a></li><li data-type='method'><a href="CollisionMesh.html#getPosition">getPosition</a></li><li data-type='method'><a href="CollisionMesh.html#getSize">getSize</a></li><li data-type='method'><a href="CollisionMesh.html#getWidth">getWidth</a></li><li data-type='method'><a href="CollisionMesh.html#isColliding">isColliding</a></li><li data-type='method'><a href="CollisionMesh.html#isContains">isContains</a></li><li data-type='method'><a href="CollisionMesh.html#isTouching">isTouching</a></li><li data-type='method'><a href="CollisionMesh.html#moveBy">moveBy</a></li><li data-type='method'><a href="CollisionMesh.html#moveTo">moveTo</a></li><li data-type='method'><a href="CollisionMesh.html#someColliding">someColliding</a></li><li data-type='method'><a href="CollisionMesh.html#someContains">someContains</a></li><li data-type='method'><a href="CollisionMesh.html#someTouching">someTouching</a></li></ul></li><li><a href="EventHandler.html">EventHandler</a><ul class='methods'><li data-type='method'><a href="EventHandler.html#addPipe">addPipe</a></li><li data-type='method'><a href="EventHandler.html#clearEvent">clearEvent</a></li><li data-type='method'><a href="EventHandler.html#emit">emit</a></li><li data-type='method'><a href="EventHandler.html#off">off</a></li><li data-type='method'><a href="EventHandler.html#on">on</a></li><li data-type='method'><a href="EventHandler.html#once">once</a></li><li data-type='method'><a href="EventHandler.html#removePipe">removePipe</a></li></ul></li><li><a href="Position.html">Position</a></li><li><a href="Size.html">Size</a></li><li><a href="Vector.html">Vector</a><ul class='methods'><li data-type='method'><a href="Vector.html#add">add</a></li><li data-type='method'><a href="Vector.html#clone">clone</a></li><li data-type='method'><a href="Vector.html#distance">distance</a></li><li data-type='method'><a href="Vector.html#distanceSquared">distanceSquared</a></li><li data-type='method'><a href="Vector.html#getBoundingBox">getBoundingBox</a></li><li data-type='method'><a href="Vector.html#getCollisionMesh">getCollisionMesh</a></li><li data-type='method'><a href="Vector.html#getVector">getVector</a></li><li data-type='method'><a href="Vector.html#isNaN">isNaN</a></li><li data-type='method'><a href="Vector.html#moveBy">moveBy</a></li><li data-type='method'><a href="Vector.html#moveTo">moveTo</a></li><li data-type='method'><a href="Vector.html#set">set</a></li><li data-type='method'><a href="Vector.html#setMax">setMax</a></li><li data-type='method'><a href="Vector.html#setMin">setMin</a></li><li data-type='method'><a href="Vector.html#subtract">subtract</a></li></ul></li><li><a href="Window.html">Window</a><ul class='methods'><li data-type='method'><a href="Window.html#.getAll">getAll</a></li><li data-type='method'><a href="Window.html#.getByID">getByID</a></li><li data-type='method'><a href="Window.html#.getCurrent">getCurrent</a></li><li data-type='method'><a href="Window.html#addPipe">addPipe</a></li><li data-type='method'><a href="Window.html#bringToFront">bringToFront</a></li><li data-type='method'><a href="Window.html#clearEvent">clearEvent</a></li><li data-type='method'><a href="Window.html#close">close</a></li><li data-type='method'><a href="Window.html#dock">dock</a></li><li data-type='method'><a href="Window.html#emit">emit</a></li><li data-type='method'><a href="Window.html#focus">focus</a></li><li data-type='method'><a href="Window.html#getBounds">getBounds</a></li><li data-type='method'><a href="Window.html#getHeight">getHeight</a></li><li data-type='method'><a href="Window.html#getPosition">getPosition</a></li><li data-type='method'><a href="Window.html#getSize">getSize</a></li><li data-type='method'><a href="Window.html#getTitle">getTitle</a></li><li data-type='method'><a href="Window.html#getWidth">getWidth</a></li><li data-type='method'><a href="Window.html#hide">hide</a></li><li data-type='method'><a href="Window.html#isClosed">isClosed</a></li><li data-type='method'><a href="Window.html#isHidden">isHidden</a></li><li data-type='method'><a href="Window.html#isMaximized">isMaximized</a></li><li data-type='method'><a href="Window.html#isMinimized">isMinimized</a></li><li data-type='method'><a href="Window.html#isReady">isReady</a></li><li data-type='method'><a href="Window.html#isRestored">isRestored</a></li><li data-type='method'><a href="Window.html#isShown">isShown</a></li><li data-type='method'><a href="Window.html#maximize">maximize</a></li><li data-type='method'><a href="Window.html#minimize">minimize</a></li><li data-type='method'><a href="Window.html#moveBy">moveBy</a></li><li data-type='method'><a href="Window.html#moveTo">moveTo</a></li><li data-type='method'><a href="Window.html#off">off</a></li><li data-type='method'><a href="Window.html#on">on</a></li><li data-type='method'><a href="Window.html#once">once</a></li><li data-type='method'><a href="Window.html#onReady">onReady</a></li><li data-type='method'><a href="Window.html#removePipe">removePipe</a></li><li data-type='method'><a href="Window.html#resizeTo">resizeTo</a></li><li data-type='method'><a href="Window.html#restore">restore</a></li><li data-type='method'><a href="Window.html#setBounds">setBounds</a></li><li data-type='method'><a href="Window.html#setTitle">setTitle</a></li><li data-type='method'><a href="Window.html#show">show</a></li><li data-type='method'><a href="Window.html#undock">undock</a></li></ul></li></ul><h3>Namespaces</h3><ul><li><a href="geometry.html">geometry</a></li><li><a href="messagebus.html">messagebus</a><ul class='methods'><li data-type='method'><a href="messagebus.html#.off">off</a></li><li data-type='method'><a href="messagebus.html#.on">on</a></li><li data-type='method'><a href="messagebus.html#.send">send</a></li></ul></li><li><a href="windowmanager.html">windowmanager</a><ul class='methods'><li data-type='method'><a href="windowmanager.html#.isReady">isReady</a></li><li data-type='method'><a href="windowmanager.html#.onReady">onReady</a></li></ul></li></ul><h3><a href="global.html">Global</a></h3>
</nav>
<div id="main">
<h1 class="page-title">Window</h1>
<section>
<header>
<h2>
Window
</h2>
<div class="class-description"><p>A Window class.</p></div>
</header>
<article>
<div class="container-overview">
<h2>Constructor</h2>
<h4 class="name" id="Window"><span class="type-signature"></span>new Window<span class="signature">(config)</span><span class="type-signature"></span></h4>
<div class="description">
<p>Wraps a window object.</p>
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>config</code></td>
<td class="type">
<span class="param-type">Object</span>
</td>
<td class="description last"><p>Configuration</p></td>
</tr>
</tbody>
</table>
<dl class="details">
</dl>
</div>
<h3 class="subsection-title">Extends</h3>
<ul>
<li><a href="EventHandler.html">EventHandler</a></li>
</ul>
<h3 class="subsection-title">Methods</h3>
<h4 class="name" id=".getAll"><span class="type-signature">(static) </span>getAll<span class="signature">()</span><span class="type-signature"> → {Array.<<a href="Window.html">Window</a>>}</span></h4>
<div class="description">
<p>Returns a list of all <a href="Window.html">Window</a> instances open.</p>
</div>
<dl class="details">
</dl>
<h5>Returns:</h5>
<dl class="param-type">
<dt>
Type
</dt>
<dd>
<span class="param-type">Array.<<a href="Window.html">Window</a>></span>
</dd>
</dl>
<h4 class="name" id=".getByID"><span class="type-signature">(static) </span>getByID<span class="signature">(id)</span><span class="type-signature"> → {<a href="Window.html">Window</a>|undefined}</span></h4>
<div class="description">
<p>Returns the <a href="Window.html">Window</a> instance that has <code>id</code>.</p>
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>id</code></td>
<td class="type">
<span class="param-type">String</span>
|
<span class="param-type">Number</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
</dl>
<h5>Returns:</h5>
<dl class="param-type">
<dt>
Type
</dt>
<dd>
<span class="param-type"><a href="Window.html">Window</a></span>
|
<span class="param-type">undefined</span>
</dd>
</dl>
<h4 class="name" id=".getCurrent"><span class="type-signature">(static) </span>getCurrent<span class="signature">()</span><span class="type-signature"> → {<a href="Window.html">Window</a>}</span></h4>
<div class="description">
<p>Returns the <a href="Window.html">Window</a> instance that calls this function.</p>
</div>
<dl class="details">
</dl>
<h5>Returns:</h5>
<dl class="param-type">
<dt>
Type
</dt>
<dd>
<span class="param-type"><a href="Window.html">Window</a></span>
</dd>
</dl>
<h4 class="name" id="addPipe"><span class="type-signature"></span>addPipe<span class="signature">(eventHandler)</span><span class="type-signature"></span></h4>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>eventHandler</code></td>
<td class="type">
<span class="param-type"><a href="EventHandler.html">EventHandler</a></span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="inherited-from">Inherited From:</dt>
<dd class="inherited-from"><ul class="dummy"><li>
<a href="EventHandler.html#addPipe">EventHandler#addPipe</a>
</li></ul></dd>
</dl>
<h4 class="name" id="bringToFront"><span class="type-signature"></span>bringToFront<span class="signature">(callback<span class="signature-attributes">opt</span>)</span><span class="type-signature"></span></h4>
<div class="description">
<p>Brings the window instance to the front of all windows.</p>
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Attributes</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>callback</code></td>
<td class="type">
<span class="param-type"><a href="global.html#Callback">Callback</a></span>
</td>
<td class="attributes">
<optional><br>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
</dl>
<h4 class="name" id="clearEvent"><span class="type-signature"></span>clearEvent<span class="signature">(eventNames)</span><span class="type-signature"></span></h4>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>eventNames</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="inherited-from">Inherited From:</dt>
<dd class="inherited-from"><ul class="dummy"><li>
<a href="EventHandler.html#clearEvent">EventHandler#clearEvent</a>
</li></ul></dd>
</dl>
<h4 class="name" id="close"><span class="type-signature"></span>close<span class="signature">(callback<span class="signature-attributes">opt</span>)</span><span class="type-signature"></span></h4>
<div class="description">
<p>Closes the window instance.</p>
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Attributes</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>callback</code></td>
<td class="type">
<span class="param-type"><a href="global.html#Callback">Callback</a></span>
</td>
<td class="attributes">
<optional><br>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
</dl>
<h4 class="name" id="dock"><span class="type-signature"></span>dock<span class="signature">(other)</span><span class="type-signature"></span></h4>
<div class="description">
<p>Force docking this window to another. They don't need to be touching.</p>
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Attributes</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>other</code></td>
<td class="type">
<span class="param-type"><a href="Window.html">Window</a></span>
</td>
<td class="attributes">
</td>
<td class="description last"></td>
</tr>
<tr>
<td class="name"><code></code></td>
<td class="type">
<span class="param-type"><a href="global.html#Callback">Callback</a></span>
</td>
<td class="attributes">
<optional><br>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
</dl>
<h4 class="name" id="emit"><span class="type-signature"></span>emit<span class="signature">(eventName, …args)</span><span class="type-signature"> → {Boolean}</span></h4>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Attributes</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>eventName</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="attributes">
</td>
<td class="description last"></td>
</tr>
<tr>
<td class="name"><code>args</code></td>
<td class="type">
<span class="param-type">*</span>
</td>
<td class="attributes">
<repeatable><br>
</td>
<td class="description last"><p>Arguments to pass to listeners</p></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="inherited-from">Inherited From:</dt>
<dd class="inherited-from"><ul class="dummy"><li>
<a href="EventHandler.html#emit">EventHandler#emit</a>
</li></ul></dd>
</dl>
<h5>Returns:</h5>
<div class="param-desc">
<p>true if all handlers return true, else false</p>
</div>
<dl class="param-type">
<dt>
Type
</dt>
<dd>
<span class="param-type">Boolean</span>
</dd>
</dl>
<h4 class="name" id="focus"><span class="type-signature"></span>focus<span class="signature">(callback<span class="signature-attributes">opt</span>)</span><span class="type-signature"></span></h4>
<div class="description">
<p>Sets focus to the window instance.</p>
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Attributes</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>callback</code></td>
<td class="type">
<span class="param-type"><a href="global.html#Callback">Callback</a></span>
</td>
<td class="attributes">
<optional><br>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
</dl>
<h4 class="name" id="getBounds"><span class="type-signature"></span>getBounds<span class="signature">()</span><span class="type-signature"> → {<a href="BoundingBox.html">BoundingBox</a>}</span></h4>
<div class="description">
<p>Returns window's bounding box.</p>
</div>
<dl class="details">
</dl>
<h5>Returns:</h5>
<dl class="param-type">
<dt>
Type
</dt>
<dd>
<span class="param-type"><a href="BoundingBox.html">BoundingBox</a></span>
</dd>
</dl>
<h4 class="name" id="getHeight"><span class="type-signature"></span>getHeight<span class="signature">()</span><span class="type-signature"> → {Number}</span></h4>
<div class="description">
<p>Returns window's height.</p>
</div>
<dl class="details">
</dl>
<h5>Returns:</h5>
<dl class="param-type">
<dt>
Type
</dt>
<dd>
<span class="param-type">Number</span>
</dd>
</dl>
<h4 class="name" id="getPosition"><span class="type-signature"></span>getPosition<span class="signature">()</span><span class="type-signature"> → {<a href="Vector.html">Vector</a>}</span></h4>
<div class="description">
<p>Returns window's current position.</p>
</div>
<dl class="details">
</dl>
<h5>Returns:</h5>
<dl class="param-type">
<dt>
Type
</dt>
<dd>
<span class="param-type"><a href="Vector.html">Vector</a></span>
</dd>
</dl>
<h4 class="name" id="getSize"><span class="type-signature"></span>getSize<span class="signature">()</span><span class="type-signature"> → {<a href="Size.html">Size</a>}</span></h4>
<div class="description">
<p>Returns window's size.</p>
</div>
<dl class="details">
</dl>
<h5>Returns:</h5>
<dl class="param-type">
<dt>
Type
</dt>
<dd>
<span class="param-type"><a href="Size.html">Size</a></span>
</dd>
</dl>
<h4 class="name" id="getTitle"><span class="type-signature"></span>getTitle<span class="signature">()</span><span class="type-signature"> → {String}</span></h4>
<div class="description">
<p>Returns window's title.</p>
</div>
<dl class="details">
</dl>
<h5>Returns:</h5>
<dl class="param-type">
<dt>
Type
</dt>
<dd>
<span class="param-type">String</span>
</dd>
</dl>
<h4 class="name" id="getWidth"><span class="type-signature"></span>getWidth<span class="signature">()</span><span class="type-signature"> → {Number}</span></h4>
<div class="description">
<p>Returns window's width.</p>
</div>
<dl class="details">
</dl>
<h5>Returns:</h5>
<dl class="param-type">
<dt>
Type
</dt>
<dd>
<span class="param-type">Number</span>
</dd>
</dl>
<h4 class="name" id="hide"><span class="type-signature"></span>hide<span class="signature">(callback<span class="signature-attributes">opt</span>)</span><span class="type-signature"></span></h4>
<div class="description">
<p>Hides the window instance.</p>
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Attributes</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>callback</code></td>
<td class="type">
<span class="param-type"><a href="global.html#Callback">Callback</a></span>
</td>
<td class="attributes">
<optional><br>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
</dl>
<h4 class="name" id="isClosed"><span class="type-signature"></span>isClosed<span class="signature">()</span><span class="type-signature"> → {Boolean}</span></h4>
<div class="description">
<p>Returns whether window has been closed already.</p>
</div>
<dl class="details">
</dl>
<h5>Returns:</h5>
<dl class="param-type">
<dt>
Type
</dt>
<dd>
<span class="param-type">Boolean</span>
</dd>
</dl>
<h4 class="name" id="isHidden"><span class="type-signature"></span>isHidden<span class="signature">()</span><span class="type-signature"> → {Boolean}</span></h4>
<div class="description">
<p>Returns true if window is hidden.</p>
</div>
<dl class="details">
</dl>
<h5>Returns:</h5>
<dl class="param-type">
<dt>
Type
</dt>
<dd>
<span class="param-type">Boolean</span>
</dd>
</dl>
<h4 class="name" id="isMaximized"><span class="type-signature"></span>isMaximized<span class="signature">()</span><span class="type-signature"> → {Boolean}</span></h4>
<div class="description">
<p>Returns true if window is maximized.</p>
</div>
<dl class="details">
</dl>
<h5>Returns:</h5>
<dl class="param-type">
<dt>
Type
</dt>
<dd>
<span class="param-type">Boolean</span>
</dd>
</dl>
<h4 class="name" id="isMinimized"><span class="type-signature"></span>isMinimized<span class="signature">()</span><span class="type-signature"> → {Boolean}</span></h4>
<div class="description">
<p>Returns true if window is minimized.</p>
</div>
<dl class="details">
</dl>
<h5>Returns:</h5>
<dl class="param-type">
<dt>
Type
</dt>
<dd>
<span class="param-type">Boolean</span>
</dd>
</dl>
<h4 class="name" id="isReady"><span class="type-signature"></span>isReady<span class="signature">()</span><span class="type-signature"> → {Boolean}</span></h4>
<div class="description">
<p>Returns true if the <a href="Window.html">Window</a> instance is created, not closed, and ready for method calls.</p>
</div>
<dl class="details">
</dl>
<h5>Returns:</h5>
<dl class="param-type">
<dt>
Type
</dt>
<dd>
<span class="param-type">Boolean</span>
</dd>
</dl>
<h4 class="name" id="isRestored"><span class="type-signature"></span>isRestored<span class="signature">()</span><span class="type-signature"> → {Boolean}</span></h4>
<div class="description">
<p>Returns true if window is not hidden or minimize or maximized.</p>
</div>
<dl class="details">
</dl>
<h5>Returns:</h5>
<dl class="param-type">
<dt>
Type
</dt>
<dd>
<span class="param-type">Boolean</span>
</dd>
</dl>
<h4 class="name" id="isShown"><span class="type-signature"></span>isShown<span class="signature">()</span><span class="type-signature"> → {Boolean}</span></h4>
<div class="description">
<p>Returns true if window is not hidden.</p>
</div>
<dl class="details">
</dl>
<h5>Returns:</h5>
<dl class="param-type">
<dt>
Type
</dt>
<dd>
<span class="param-type">Boolean</span>
</dd>
</dl>
<h4 class="name" id="maximize"><span class="type-signature"></span>maximize<span class="signature">(callback<span class="signature-attributes">opt</span>)</span><span class="type-signature"></span></h4>
<div class="description">
<p>Maximizes the window instance.</p>
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Attributes</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>callback</code></td>
<td class="type">
<span class="param-type"><a href="global.html#Callback">Callback</a></span>
</td>
<td class="attributes">
<optional><br>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
</dl>
<h4 class="name" id="minimize"><span class="type-signature"></span>minimize<span class="signature">(callback<span class="signature-attributes">opt</span>)</span><span class="type-signature"></span></h4>
<div class="description">
<p>Minimizes the window instance.</p>
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Attributes</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>callback</code></td>
<td class="type">
<span class="param-type"><a href="global.html#Callback">Callback</a></span>
</td>
<td class="attributes">
<optional><br>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
</dl>
<h4 class="name" id="moveBy"><span class="type-signature"></span>moveBy<span class="signature">(deltaLeft, deltaTop, callback<span class="signature-attributes">opt</span>)</span><span class="type-signature"></span></h4>
<div class="description">
<p>Moves the window instance relative to its current position.</p>
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Attributes</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>deltaLeft</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="attributes">
</td>
<td class="description last"></td>
</tr>
<tr>
<td class="name"><code>deltaTop</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="attributes">
</td>
<td class="description last"></td>
</tr>
<tr>
<td class="name"><code>callback</code></td>
<td class="type">
<span class="param-type"><a href="global.html#Callback">Callback</a></span>
</td>
<td class="attributes">
<optional><br>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
</dl>
<h4 class="name" id="moveTo"><span class="type-signature"></span>moveTo<span class="signature">(left, top, callback<span class="signature-attributes">opt</span>)</span><span class="type-signature"></span></h4>
<div class="description">
<p>Moves the window instance.</p>
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Attributes</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>left</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="attributes">
</td>
<td class="description last"></td>
</tr>
<tr>
<td class="name"><code>top</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="attributes">
</td>
<td class="description last"></td>
</tr>
<tr>
<td class="name"><code>callback</code></td>
<td class="type">
<span class="param-type"><a href="global.html#Callback">Callback</a></span>
</td>
<td class="attributes">
<optional><br>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
</dl>
<h4 class="name" id="off"><span class="type-signature"></span>off<span class="signature">(eventNames, eventListener)</span><span class="type-signature"></span></h4>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>eventNames</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last"></td>
</tr>
<tr>
<td class="name"><code>eventListener</code></td>
<td class="type">
<span class="param-type">callback</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="inherited-from">Inherited From:</dt>
<dd class="inherited-from"><ul class="dummy"><li>
<a href="EventHandler.html#off">EventHandler#off</a>
</li></ul></dd>
</dl>
<h4 class="name" id="on"><span class="type-signature"></span>on<span class="signature">(eventNames, eventListener)</span><span class="type-signature"></span></h4>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>eventNames</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last"></td>
</tr>
<tr>
<td class="name"><code>eventListener</code></td>
<td class="type">
<span class="param-type">callback</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="inherited-from">Inherited From:</dt>
<dd class="inherited-from"><ul class="dummy"><li>
<a href="EventHandler.html#on">EventHandler#on</a>
</li></ul></dd>
</dl>
<h4 class="name" id="once"><span class="type-signature"></span>once<span class="signature">(eventName, eventListener)</span><span class="type-signature"></span></h4>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>eventName</code></td>
<td class="type">
<span class="param-type">String</span>
</td>
<td class="description last"></td>
</tr>
<tr>
<td class="name"><code>eventListener</code></td>
<td class="type">
<span class="param-type">callback</span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="inherited-from">Inherited From:</dt>
<dd class="inherited-from"><ul class="dummy"><li>
<a href="EventHandler.html#once">EventHandler#once</a>
</li></ul></dd>
</dl>
<h4 class="name" id="onReady"><span class="type-signature"></span>onReady<span class="signature">(callback<span class="signature-attributes">opt</span>)</span><span class="type-signature"></span></h4>
<div class="description">
<p>Calls a callback when window is ready and setup.</p>
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Attributes</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>callback</code></td>
<td class="type">
<span class="param-type"><a href="global.html#Callback">Callback</a></span>
</td>
<td class="attributes">
<optional><br>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
</dl>
<h4 class="name" id="removePipe"><span class="type-signature"></span>removePipe<span class="signature">(eventHandler)</span><span class="type-signature"></span></h4>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>eventHandler</code></td>
<td class="type">
<span class="param-type"><a href="EventHandler.html">EventHandler</a></span>
</td>
<td class="description last"></td>
</tr>
</tbody>
</table>
<dl class="details">
<dt class="inherited-from">Inherited From:</dt>
<dd class="inherited-from"><ul class="dummy"><li>
<a href="EventHandler.html#removePipe">EventHandler#removePipe</a>
</li></ul></dd>
</dl>
<h4 class="name" id="resizeTo"><span class="type-signature"></span>resizeTo<span class="signature">(width, height, callback<span class="signature-attributes">opt</span>)</span><span class="type-signature"></span></h4>
<div class="description">
<p>Resizes the window instance.</p>
</div>
<h5>Parameters:</h5>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Attributes</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>width</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="attributes">
</td>
<td class="description last"></td>
</tr>
<tr>
<td class="name"><code>height</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="attributes">
</td>
<td class="description last"></td>
</tr>
<tr>