mirror of
https://github.com/openseadragon/openseadragon.git
synced 2024-11-22 05:06:09 +03:00
Merge pull request #1332 from robhicks/master
Doc clarification for getting instance of TitledImage
This commit is contained in:
commit
324ed1f045
@ -35,8 +35,8 @@
|
||||
(function( $ ){
|
||||
|
||||
/**
|
||||
* You shouldn't have to create a TiledImage directly; use {@link OpenSeadragon.Viewer#open}
|
||||
* or {@link OpenSeadragon.Viewer#addTiledImage} instead.
|
||||
* You shouldn't have to create a TiledImage instance directly; get it asynchronously by
|
||||
* using {@link OpenSeadragon.Viewer#open} or {@link OpenSeadragon.Viewer#addTiledImage} instead.
|
||||
* @class TiledImage
|
||||
* @memberof OpenSeadragon
|
||||
* @extends OpenSeadragon.EventSource
|
||||
|
@ -481,6 +481,9 @@ $.extend( $.Viewer.prototype, $.EventSource.prototype, $.ControlDock.prototype,
|
||||
|
||||
/**
|
||||
* Open tiled images into the viewer, closing any others.
|
||||
* To get the TiledImage instance created by open, add an event listener for
|
||||
* {@link OpenSeadragon.Viewer.html#.event:open}, which when fired can be used to get access
|
||||
* to the instance, i.e., viewer.world.getItemAt(0).
|
||||
* @function
|
||||
* @param {Array|String|Object|Function} tileSources - This can be a TiledImage
|
||||
* specifier, a TileSource specifier, or an array of either. A TiledImage specifier
|
||||
@ -1263,7 +1266,7 @@ $.extend( $.Viewer.prototype, $.EventSource.prototype, $.ControlDock.prototype,
|
||||
* requests.
|
||||
* @param {Function} [options.success] A function that gets called when the image is
|
||||
* successfully added. It's passed the event object which contains a single property:
|
||||
* "item", the resulting TiledImage.
|
||||
* "item", which is the resulting instance of TiledImage.
|
||||
* @param {Function} [options.error] A function that gets called if the image is
|
||||
* unable to be added. It's passed the error event object, which contains "message"
|
||||
* and "source" properties.
|
||||
|
Loading…
Reference in New Issue
Block a user