/** * Replaces this manager's information control as defined by * the information control replacer. * <strong>Must only be called when {@link #fInformationControl} instanceof {@link IInformationControlExtension3}!</strong> * * @param takeFocus <code>true</code> iff the replacing information control should take focus * * @since 3.4 */ void replaceInformationControl(boolean takeFocus) { if (fInformationControlReplacer != null && canReplace(fInformationControl)) { IInformationControlExtension3 iControl3= (IInformationControlExtension3) fInformationControl; Rectangle b= iControl3.getBounds(); Rectangle t= iControl3.computeTrim(); Rectangle contentBounds= new Rectangle(b.x - t.x, b.y - t.y, b.width - t.width, b.height - t.height); IInformationControlCreator informationPresenterControlCreator= ((IInformationControlExtension5) fInformationControl).getInformationPresenterControlCreator(); fInformationControlReplacer.replaceInformationControl(informationPresenterControlCreator, contentBounds, fInformation, fSubjectArea, takeFocus); } hideInformationControl(); }
/** * Replaces this manager's information control as defined by * the information control replacer. * <strong>Must only be called when {@link #fInformationControl} instanceof {@link IInformationControlExtension3}!</strong> * * @param takeFocus <code>true</code> iff the replacing information control should take focus * * @since 3.4 */ void replaceInformationControl(boolean takeFocus) { if (fInformationControlReplacer != null && canReplace(fInformationControl)) { IInformationControlExtension3 iControl3= (IInformationControlExtension3) fInformationControl; Rectangle b= iControl3.getBounds(); Rectangle t= iControl3.computeTrim(); Rectangle contentBounds= new Rectangle(b.x - t.x, b.y - t.y, b.width - t.width, b.height - t.height); IInformationControlCreator informationPresenterControlCreator= ((IInformationControlExtension5) fInformationControl).getInformationPresenterControlCreator(); fInformationControlReplacer.replaceInformationControl(informationPresenterControlCreator, contentBounds, fInformation, fSubjectArea, takeFocus); } hideInformationControl(); }