升级后效果:
1.调用编辑器使用8.0.4编辑面板风格;
2.固定的弹出窗口拖动BUG修正(当样式属性Position为FIXED时);
3.增加弹出窗口拖拽控制大小效果。
一、内容的编辑处理程序
org.opencms.ade.containerpage.client.CmsContentEditorHandler
修改openDialog()方法
注释CmsContentEditor打开的编辑器,只使用CmsContentEditorDialog 8.0.4弹出窗口——如取消经典编辑器模式的判断:
m_handler.m_controller.getData().isUseClassicEditor()
二、修改弹出框功能
org.opencms.gwt.client.ui.CmsPopup
增加拖拽控制大小功能,(代码片段):
/** The panel for the resize button. */ private ResizeButton resizeable; /** Flag if resizing. */ private boolean j_resizing; /** panel's offset width. */ private int j_clientWidth; /** panel's offset height. */ private int j_clientHeight; // TODO 用户拖拽动态调整大小 public void addDialogResizeable() { if (resizeable == null) { resizeable = new ResizeButton(); resizeable.setTitle("拖拽控制窗口大小!"); resizeable.addStyleName(I_CmsLayoutBundle.INSTANCE.dialogCss().resizePopup()); resizeable.setImageClass(I_CmsLayoutBundle.INSTANCE.dialogCss().resizeablePopupImage()); resizeable.setButtonStyle(ButtonStyle.TRANSPARENT, null); DOM.appendChild(m_containerElement, resizeable.getElement()); adopt(resizeable); } }
三、编辑器窗口调用
org.opencms.gwt.client.ui.contenteditor.CmsContentEditorDialog
openDialog()方法中增加弹出窗口可拖拽控制调用
m_dialog.addDialogResizeable();