Skip to content

Commit

Permalink
fix(画布): 修改尺寸时发出外部通知
Browse files Browse the repository at this point in the history
  • Loading branch information
nihaojob committed Feb 20, 2024
1 parent 376e787 commit f192033
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/core/plugin/WorkspacePlugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* @Author: 秦少卫
* @Date: 2023-06-27 12:26:41
* @LastEditors: 秦少卫
* @LastEditTime: 2023-11-19 21:05:33
* @LastEditTime: 2024-02-20 12:54:10
* @Description: 画布区域插件
*/

Expand Down Expand Up @@ -125,6 +125,7 @@ class WorkspacePlugin {
.find((item) => item.id === 'workspace') as fabric.Rect;
this.workspace.set('width', width);
this.workspace.set('height', height);
this.editor.emit('sizeChange', this.workspace.width, this.workspace.height);
this.auto();
}

Expand Down

0 comments on commit f192033

Please sign in to comment.