Merge "Close tipsies when closing interface"

This commit is contained in:
jenkins-bot 2014-06-27 22:30:07 +00:00 committed by Gerrit Code Review
commit b79f3a8392
4 changed files with 20 additions and 0 deletions

View file

@ -202,6 +202,8 @@
this.canvas.unattach();
this.buttons.unattach();
this.panel.fileReuse.closeDialog();
this.clearEvents();

View file

@ -192,5 +192,14 @@
}
};
/**
* Removes all UI things from the DOM, or hides them
*/
CBP.unattach = function () {
this.$viewFile.tipsy( 'hide' );
this.$close.tipsy( 'hide' );
this.$fullscreen.tipsy( 'hide' );
};
mw.mmv.ui.CanvasButtons = CanvasButtons;
}( mediaWiki, jQuery, OO ) );

View file

@ -60,6 +60,11 @@
};
MPP.unattach = function() {
this.$title.tipsy( 'hide' );
this.$mmvOptOutLink.tipsy( 'hide' );
this.$titleAndCredit.find( '.mw-mmv-author' ).tipsy( 'hide' );
this.$titleAndCredit.find( '.mw-mmv-source' ).tipsy( 'hide' );
this.scroller.unattach();
this.buttons.unattach();
this.fileReuse.unattach();

View file

@ -417,6 +417,10 @@
this.buttons.$reuse.off( 'click.mmv-stripeButtons' );
this.clearTimer( 'feedbackTooltip.show' );
$.each( this.buttons, function ( name, $button ) {
$button.tipsy( 'hide' );
} );
};
mw.mmv.ui.StripeButtons = StripeButtons;