class DisplayerDragComponent implements PerspectiveEditorCoreComponent, HasModalConfiguration {

    protected void adjustSize( DisplayerSettings settings, int containerWidth ) {
        int displayerWidth = settings.getChartWidth();
        int tableWidth = settings.getTableWidth();
        if ( containerWidth > 0 && displayerWidth > containerWidth ) {
            int ratio = containerWidth * 100 / displayerWidth;
            settings.setChartWidth( containerWidth );
            settings.setChartHeight( settings.getChartHeight() * ratio / 100 );
        }
        if ( tableWidth == 0 || tableWidth > containerWidth ) {
            settings.setTableWidth( containerWidth > 20 ? containerWidth - 20 : 0 );
        }
    }

    @Inject public  DisplayerDragComponent( SyncBeanManager beanManager,
                                   DisplayerViewer viewer,
                                   PlaceManager placeManager,
                                   PerspectiveCoordinator perspectiveCoordinator );

}