|
|
|
@ -32,7 +32,7 @@ import { EVENT_SELECTION_CHANGED } from './model/events';
|
|
|
|
|
/** |
|
|
|
|
* 工作区 |
|
|
|
|
*/ |
|
|
|
|
export class WorkingAreaComponent extends EventEmitter implements OnInit, AfterViewInit,OnDestroy { |
|
|
|
|
export class WorkingAreaComponent extends EventEmitter implements OnInit, AfterViewInit, OnDestroy { |
|
|
|
|
|
|
|
|
|
constructor(private eventManager: EventManager, public canvasData: CanvasShareDataService) { |
|
|
|
|
super(); |
|
|
|
@ -158,7 +158,7 @@ export class WorkingAreaComponent extends EventEmitter implements OnInit, AfterV
|
|
|
|
|
* RC版: 该版本已经相当成熟了,基本上不存在导致错误的BUG,与即将发行的正式版相差无几。 |
|
|
|
|
* Release版: 该版本意味“最终版本”,在前面版本的一系列测试版之后,终归会有一个正式版本,是最终交付用户使用的一个版本。该版本有时也称为标准版。一般情况下,Release不会以单词形式出现在软件封面上,取而代之的是符号®。 |
|
|
|
|
*/ |
|
|
|
|
public VERSION = '1.0.17.20210204_beta'; |
|
|
|
|
public VERSION = '1.0.18.20210205_beta'; |
|
|
|
|
/** |
|
|
|
|
* 数据初始化 |
|
|
|
|
*/ |
|
|
|
@ -389,7 +389,7 @@ export class WorkingAreaComponent extends EventEmitter implements OnInit, AfterV
|
|
|
|
|
// 判断2个矩形是否相交
|
|
|
|
|
const rect1 = this.rectToolGraphics.getBounds(); |
|
|
|
|
const rect2 = item.getBounds(); |
|
|
|
|
if (this.isOverlap(rect1, rect2)) { |
|
|
|
|
if (this.isOverlap(rect1, rect2) && item.interactive) { |
|
|
|
|
shapes.push(item); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
@ -408,7 +408,7 @@ export class WorkingAreaComponent extends EventEmitter implements OnInit, AfterV
|
|
|
|
|
// 判断2个矩形是否相交
|
|
|
|
|
const rect1 = this.rectToolGraphics.getBounds(); |
|
|
|
|
const rect2 = item.getBounds(); |
|
|
|
|
if (this.isOverlap(rect1, rect2)) { |
|
|
|
|
if (this.isOverlap(rect1, rect2) && item.interactive) { |
|
|
|
|
shapes.push(item); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
@ -458,7 +458,7 @@ export class WorkingAreaComponent extends EventEmitter implements OnInit, AfterV
|
|
|
|
|
/** |
|
|
|
|
* 重置相机 |
|
|
|
|
*/ |
|
|
|
|
private resetCamera2D() { |
|
|
|
|
public resetCamera2D() { |
|
|
|
|
this.camera2D.scale.set(1); |
|
|
|
|
this.camera2D.x = (this.app.view.width - this.backgroundImage.width) / 2; |
|
|
|
|
this.camera2D.y = (this.app.view.height - this.backgroundImage.height) / 2; |
|
|
|
@ -1021,7 +1021,9 @@ export class WorkingAreaComponent extends EventEmitter implements OnInit, AfterV
|
|
|
|
|
// 创建处置预案图形
|
|
|
|
|
this.createNodeShape(this.canvasData.selectPanelPoint.Data); |
|
|
|
|
this.createAxLegend(); |
|
|
|
|
|
|
|
|
|
if (this.canvasData.gameMode == GameMode.Assignment) { |
|
|
|
|
this.setLegendVisible(false); |
|
|
|
|
} |
|
|
|
|
this.updateCamera2D(); |
|
|
|
|
} |
|
|
|
|
/** |
|
|
|
@ -1409,7 +1411,7 @@ export class WorkingAreaComponent extends EventEmitter implements OnInit, AfterV
|
|
|
|
|
* 考生点击楼层 |
|
|
|
|
*/ |
|
|
|
|
public async onExamineeClickFloor() { |
|
|
|
|
await this.refreshBackgroundImage(this.canvasData.selectStorey.imageUrl,this.canvasData.selectStorey.imageAngle); |
|
|
|
|
await this.refreshBackgroundImage(this.canvasData.selectStorey.imageUrl, this.canvasData.selectStorey.imageAngle); |
|
|
|
|
// 清空所有图形
|
|
|
|
|
this.deselectAll(); |
|
|
|
|
const itemList = []; |
|
|
|
@ -1438,7 +1440,7 @@ export class WorkingAreaComponent extends EventEmitter implements OnInit, AfterV
|
|
|
|
|
* 考官点击楼层-阅卷 |
|
|
|
|
*/ |
|
|
|
|
public async onExaminerClickFloor() { |
|
|
|
|
await this.refreshBackgroundImage(this.canvasData.selectStorey.imageUrl,this.canvasData.selectStorey.imageAngle); |
|
|
|
|
await this.refreshBackgroundImage(this.canvasData.selectStorey.imageUrl, this.canvasData.selectStorey.imageAngle); |
|
|
|
|
// 清空所有图形
|
|
|
|
|
this.deselectAll(); |
|
|
|
|
const itemList = []; |
|
|
|
@ -1466,7 +1468,7 @@ export class WorkingAreaComponent extends EventEmitter implements OnInit, AfterV
|
|
|
|
|
* 考官点击楼层-创建试卷 |
|
|
|
|
*/ |
|
|
|
|
public async onExaminerClickFloor_CreateTestpaper() { |
|
|
|
|
await this.refreshBackgroundImage(this.canvasData.selectStorey.imageUrl,this.canvasData.selectStorey.imageAngle); |
|
|
|
|
await this.refreshBackgroundImage(this.canvasData.selectStorey.imageUrl, this.canvasData.selectStorey.imageAngle); |
|
|
|
|
// 清空所有图形
|
|
|
|
|
this.deselectAll(); |
|
|
|
|
const itemList = []; |
|
|
|
@ -1595,13 +1597,14 @@ export class WorkingAreaComponent extends EventEmitter implements OnInit, AfterV
|
|
|
|
|
shape.hideBorder(); |
|
|
|
|
shape.setPointVisiable(false); |
|
|
|
|
} |
|
|
|
|
////////////////////////////////////////////////////////////////////////////////////////////////图例
|
|
|
|
|
//////////////////////////////////////////////////////////////////////////////////////////////// 图例
|
|
|
|
|
/** |
|
|
|
|
* 设置图例显示隐藏 |
|
|
|
|
* @param b true 显示,false隐藏 |
|
|
|
|
*/ |
|
|
|
|
public setLegendVisible(b: boolean): void { |
|
|
|
|
const legend = this.backgroundImage.getChildByName('图例') as AxLegend; |
|
|
|
|
legend.interactive = b; |
|
|
|
|
legend.visible = b; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|