jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/328308 )

Change subject: [BREAKING CHANGE] ActionWidget: Remove resize event
......................................................................


[BREAKING CHANGE] ActionWidget: Remove resize event

Removed functions that only call the mixin method and that depend on the
resize event.

Bug: T129162
Change-Id: Ie74c49ed9c3bfe23267aa24c21632f30311507c5
---
M src/ActionSet.js
M src/widgets/ActionWidget.js
2 files changed, 0 insertions(+), 105 deletions(-)

Approvals:
  jenkins-bot: Verified
  VolkerE: Looks good to me, approved



diff --git a/src/ActionSet.js b/src/ActionSet.js
index 78c0cef..8bbd23c 100644
--- a/src/ActionSet.js
+++ b/src/ActionSet.js
@@ -133,14 +133,6 @@
  */
 
 /**
- * @event resize
- *
- * A 'resize' event is emitted when an action widget is resized.
- *
- * @param {OO.ui.ActionWidget} action Action that was resized
- */
-
-/**
  * @event add
  *
  * An 'add' event is emitted when actions are {@link #method-add added} to the 
action set.
@@ -378,11 +370,6 @@
                        click: [ 'emit', 'click', action ],
                        toggle: [ 'onActionChange' ]
                } );
-               action.on( 'resizePrivate', function ( action ) {
-                       if ( this.emit( 'resize', action ) ) {
-                               OO.ui.warnDeprecation( 'ActionSet: resize event 
is deprecated. See T129162.' );
-                       }
-               }, [ action ], this );
                this.list.push( action );
        }
        this.organized = false;
diff --git a/src/widgets/ActionWidget.js b/src/widgets/ActionWidget.js
index 5a98fe5..4095efd 100644
--- a/src/widgets/ActionWidget.js
+++ b/src/widgets/ActionWidget.js
@@ -46,14 +46,6 @@
 OO.inheritClass( OO.ui.ActionWidget, OO.ui.ButtonWidget );
 OO.mixinClass( OO.ui.ActionWidget, OO.ui.mixin.PendingElement );
 
-/* Events */
-
-/**
- * A resize event is emitted when the size of the widget changes.
- *
- * @event resize
- */
-
 /* Methods */
 
 /**
@@ -86,88 +78,4 @@
  */
 OO.ui.ActionWidget.prototype.getModes = function () {
        return this.modes.slice();
-};
-
-/**
- * Emit a resize event if the size has changed.
- *
- * @private
- * @chainable
- */
-OO.ui.ActionWidget.prototype.propagateResize = function () {
-       var width, height;
-
-       if ( this.isElementAttached() ) {
-               width = this.$element.width();
-               height = this.$element.height();
-
-               if ( width !== this.width || height !== this.height ) {
-                       this.width = width;
-                       this.height = height;
-                       this.emit( 'resizePrivate' );
-                       if ( this.emit( 'resize' ) ) {
-                               OO.ui.warnDeprecation( 'ActionWidget: resize 
event is deprecated. See T129162.' );
-                       }
-               }
-       }
-
-       return this;
-};
-
-/**
- * @inheritdoc
- */
-OO.ui.ActionWidget.prototype.setIcon = function () {
-       // Mixin method
-       OO.ui.mixin.IconElement.prototype.setIcon.apply( this, arguments );
-       this.propagateResize();
-
-       return this;
-};
-
-/**
- * @inheritdoc
- */
-OO.ui.ActionWidget.prototype.setLabel = function () {
-       // Mixin method
-       OO.ui.mixin.LabelElement.prototype.setLabel.apply( this, arguments );
-       this.propagateResize();
-
-       return this;
-};
-
-/**
- * @inheritdoc
- */
-OO.ui.ActionWidget.prototype.setFlags = function () {
-       // Mixin method
-       OO.ui.mixin.FlaggedElement.prototype.setFlags.apply( this, arguments );
-       this.propagateResize();
-
-       return this;
-};
-
-/**
- * @inheritdoc
- */
-OO.ui.ActionWidget.prototype.clearFlags = function () {
-       // Mixin method
-       OO.ui.mixin.FlaggedElement.prototype.clearFlags.apply( this, arguments 
);
-       this.propagateResize();
-
-       return this;
-};
-
-/**
- * Toggle the visibility of the action button.
- *
- * @param {boolean} [show] Show button, omit to toggle visibility
- * @chainable
- */
-OO.ui.ActionWidget.prototype.toggle = function () {
-       // Parent method
-       OO.ui.ActionWidget.parent.prototype.toggle.apply( this, arguments );
-       this.propagateResize();
-
-       return this;
 };

-- 
To view, visit https://gerrit.wikimedia.org/r/328308
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ie74c49ed9c3bfe23267aa24c21632f30311507c5
Gerrit-PatchSet: 7
Gerrit-Project: oojs/ui
Gerrit-Branch: master
Gerrit-Owner: IvanFon <[email protected]>
Gerrit-Reviewer: Aklapper <[email protected]>
Gerrit-Reviewer: Bartosz DziewoƄski <[email protected]>
Gerrit-Reviewer: Florianschmidtwelzow <[email protected]>
Gerrit-Reviewer: Jforrester <[email protected]>
Gerrit-Reviewer: Prtksxna <[email protected]>
Gerrit-Reviewer: VolkerE <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to