I suggest to edit the plugin file \applications\core\dev\ckeditor\plugins\ipsautolink\plugin.js like following code:
CKEDITOR.plugins.add( 'ipsautolink', {
init: function( editor ) {
editor.widgets.add( 'ipsembedded', {
inline: false, //WHY NOT INLINE?????
upcast: function( element ) {
if ( ( element.name == 'div' && element.hasClass( 'ipsEmbeddedVideo' ) ) || ( element.name == 'iframe' && !_.isUndefined( element.attributes['data-embedcontent'] ) ) ) {
return true;
}
},
//+++ADDED http://origin-docs.ckeditor.com/ckeditor4/docs/?print=/api/CKEDITOR.plugins.widget.definition#property-styleToAllowedContentRules
styleableElements: 'div(ipsEmbeddedVideo); iframe{data-embedcontent}'
//add data function for control align style ,data:function(){}
});
ips.utils.emoji.getEmoji(function(emoji){
new CKEDITOR.plugins.ipsautolink( editor, emoji );
});
},
//+++ADDED
afterInit: function ( editor ) {
function setupAlignCommand (value) {
var command = editor.getCommand('justify' + value);
if (command) {
if (value in { right:1,left:1,center:1 }) {
command.on('exec', function (event) {
var widget = getSelectedWidget(editor);
if (widget && widget.name === 'ipsembedded') {
widget.setData({ 'align': value });
event.cancel();
}
});
}
command.on('refresh', function (event) {
var widget = getSelectedWidget(editor),
allowed = { left:1,center:1,right:1 },
align;
if (widget) {
align = widget.data.align;
/*if ( enabled === undefined )
enabled = editor.filter.checkFeature( editor.widgets.registered.ipsembedded.features.align );
if ( !enabled )
this.setState( CKEDITOR.TRISTATE_DISABLED );
else {*/
this.setState(
( align == value ) ? (
CKEDITOR.TRISTATE_ON
) : (
( value in allowed ) ? CKEDITOR.TRISTATE_OFF : CKEDITOR.TRISTATE_DISABLED
)
);
//}
event.cancel();
}
});
}
}
function getSelectedWidget (editor) {
var widget = editor.widgets.focused;
if (widget && widget.name === 'ipsembedded') {
return widget;
}
return null;
}
setupAlignCommand('left');
setupAlignCommand('right');
setupAlignCommand('center');
}
} );
I don't test it