8
0
Просмотр исходного кода

Changed: Remove `dropdown.buttonView` bindings to `dropdown`.

Maciej Gołaszewski 8 лет назад
Родитель
Сommit
5ee8daa568
1 измененных файлов с 4 добавлено и 3 удалено
  1. 4 3
      packages/ckeditor5-alignment/src/alignmentui.js

+ 4 - 3
packages/ckeditor5-alignment/src/alignmentui.js

@@ -90,12 +90,13 @@ export default class AlignmentUI extends Plugin {
 			addToolbarToDropdown( dropdownView, buttons );
 
 			// Configure dropdown properties an behavior.
-			dropdownView.set( {
+			dropdownView.buttonView.set( {
 				label: t( 'Text alignment' ),
-				isVertical: true,
 				tooltip: true
 			} );
 
+			dropdownView.toolbarView.isVertical = true;
+
 			dropdownView.extendTemplate( {
 				attributes: {
 					class: 'ck-alignment-dropdown'
@@ -106,7 +107,7 @@ export default class AlignmentUI extends Plugin {
 			const defaultIcon = alignLeftIcon;
 
 			// Change icon to reflect current selection's alignment.
-			dropdownView.bind( 'icon' ).toMany( buttons, 'isOn', ( ...areActive ) => {
+			dropdownView.buttonView.bind( 'icon' ).toMany( buttons, 'isOn', ( ...areActive ) => {
 				// Get the index of an active button.
 				const index = areActive.findIndex( value => value );