Docs: Improve JS Docs for js/media/controllers/edit-image.js
.
Props jjcomack, nicollle, andizer. Fixes #42680. git-svn-id: https://develop.svn.wordpress.org/trunk@42392 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
726f5f7b2d
commit
c632669438
@ -32,21 +32,37 @@ EditImage = wp.media.controller.State.extend(/** @lends wp.media.controller.Edit
|
||||
},
|
||||
|
||||
/**
|
||||
* Activates a frame for editing a featured image.
|
||||
*
|
||||
* @since 3.9.0
|
||||
*
|
||||
* @returns {void}
|
||||
*/
|
||||
activate: function() {
|
||||
this.frame.on( 'toolbar:render:edit-image', _.bind( this.toolbar, this ) );
|
||||
},
|
||||
|
||||
/**
|
||||
* Deactivates a frame for editing a featured image.
|
||||
*
|
||||
* @since 3.9.0
|
||||
*
|
||||
* @returns {void}
|
||||
*/
|
||||
deactivate: function() {
|
||||
this.frame.off( 'toolbar:render:edit-image' );
|
||||
},
|
||||
|
||||
/**
|
||||
* Adds a toolbar with a back button.
|
||||
*
|
||||
* When the back button is pressed it checks whether there is a previous state.
|
||||
* In case there is a previous state it sets that previous state otherwise it
|
||||
* closes the frame.
|
||||
*
|
||||
* @since 3.9.0
|
||||
*
|
||||
* @returns {void}
|
||||
*/
|
||||
toolbar: function() {
|
||||
var frame = this.frame,
|
||||
|
Loading…
Reference in New Issue
Block a user