Browse Source

Pull request #8289: REPORT-68175 FR11决策报表-绝对布局frm,鼠标在body没有组件的空白区域,点击然后拖拽,会出现组件大小被拉伸且超出body范围的错乱现象,此时点回退按钮会使模板变为宽度为1的效果

Merge in DESIGN/design from ~FANGLEI/design:release/11.0 to release/11.0

* commit 'ee540035775dc508de3b6c6768f8e59fa9008793':
  REPORT-68175 FR11决策报表-绝对布局frm,鼠标在body没有组件的空白区域,点击然后拖拽,会出现组件大小被拉伸且超出body范围的错乱现象,此时点回退按钮会使模板变为宽度为1的效果
bugfix/11.0
fanglei 3 years ago
parent
commit
0782eb7fe4
  1. 6
      designer-form/src/main/java/com/fr/design/designer/beans/adapters/layout/FRAbsoluteLayoutAdapter.java
  2. 3
      designer-form/src/main/java/com/fr/design/mainframe/FormDesignerUI.java

6
designer-form/src/main/java/com/fr/design/designer/beans/adapters/layout/FRAbsoluteLayoutAdapter.java

@ -4,6 +4,7 @@ import com.fr.design.beans.GroupModel;
import com.fr.design.designer.beans.ConstraintsGroupModel; import com.fr.design.designer.beans.ConstraintsGroupModel;
import com.fr.design.designer.beans.HoverPainter; import com.fr.design.designer.beans.HoverPainter;
import com.fr.design.designer.beans.models.DraggingModel; import com.fr.design.designer.beans.models.DraggingModel;
import com.fr.design.designer.beans.models.StateModel;
import com.fr.design.designer.beans.painters.FRAbsoluteLayoutPainter; import com.fr.design.designer.beans.painters.FRAbsoluteLayoutPainter;
import com.fr.design.designer.creator.*; import com.fr.design.designer.creator.*;
import com.fr.design.designer.properties.BoundsGroupModel; import com.fr.design.designer.properties.BoundsGroupModel;
@ -353,7 +354,10 @@ public class FRAbsoluteLayoutAdapter extends FRBodyLayoutAdapter {
public void dragging(DraggingModel model) { public void dragging(DraggingModel model) {
FormDesigner designer = model.getDesigner(); FormDesigner designer = model.getDesigner();
MouseEvent dragEvent = model.getCurrentDragEvent(); MouseEvent dragEvent = model.getCurrentDragEvent();
designer.getStateModel().dragging(dragEvent); StateModel stateModel = designer.getStateModel();
if (stateModel.dragable()) {
stateModel.dragging(dragEvent);
}
} }
@Override @Override

3
designer-form/src/main/java/com/fr/design/mainframe/FormDesignerUI.java

@ -224,6 +224,9 @@ public class FormDesignerUI extends ComponentUI {
} }
XCreator creator = draggingModel.getCreator(); XCreator creator = draggingModel.getCreator();
if (!creator.isSupportDrag()) {
return false;
}
int leftTopX = draggingModel.getCreatorLeftTopX(); int leftTopX = draggingModel.getCreatorLeftTopX();
int leftTopY = draggingModel.getCreatorLeftTopY(); int leftTopY = draggingModel.getCreatorLeftTopY();

Loading…
Cancel
Save