Fix deactivating VE after user explicitly decideas to discard changes

Bug: T134794
Bug: T143042
Change-Id: Idf1941793317a6aff9fe57082b85e3ebff0c72b4
(cherry picked from commit 1ba035e053)
This commit is contained in:
Juan Manuel Osorio Gerdts 2016-08-15 21:54:27 +02:00 committed by Jforrester
parent 74458204f7
commit 9da5996c0e

View file

@ -499,7 +499,7 @@ ve.init.mw.DesktopArticleTarget.prototype.deactivate = function ( noDialog, trac
opened.then( function ( closing ) {
closing.then( function ( data ) {
if ( data && data.action === 'discard' ) {
this.emit( 'deactivate' );
target.emit( 'deactivate' );
target.cancel( trackMechanism );
}
} );