未验证 提交 789d6dd1 编写于 作者: B Boris Sekachev 提交者: GitHub

Fixed: Issue with point region doesn't work in Firefox (#2727)

* Fixed: Issue with point region doesn't work in Firefox

* Updated changelog & version

* Fixed license header
上级 b279824c
......@@ -32,8 +32,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Fixed filters select overflow (<https://github.com/openvinotoolkit/cvat/pull/2614>)
- Fixed tasks in project autoannotation (<https://github.com/openvinotoolkit/cvat/pull/2725>)
- Cuboids are missed in annotations statistics (<https://github.com/openvinotoolkit/cvat/pull/2704>)
- The list of files attached to the task is not displayed (<https://github.com/openvinotoolkit/cvat/pull/2706>)
- The list of files attached to the task is not displayed (<https://github.com/openvinotoolkit/cvat/pul
- A couple of css-related issues (top bar disappear, wrong arrow position on collapse elements) (<https://github.com/openvinotoolkit/cvat/pull/2736>)
- Issue with point region doesn't work in Firefox (<https://github.com/openvinotoolkit/cvat/pull/2727>)
### Security
......
{
"name": "cvat-canvas",
"version": "2.2.1",
"version": "2.2.2",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
......
{
"name": "cvat-canvas",
"version": "2.2.1",
"version": "2.2.2",
"description": "Part of Computer Vision Annotation Tool which presents its canvas library",
"main": "src/canvas.ts",
"scripts": {
......
// Copyright (C) 2020 Intel Corporation
// Copyright (C) 2020-2021 Intel Corporation
//
// SPDX-License-Identifier: MIT
......@@ -66,7 +66,7 @@ export class RegionSelectorImpl implements RegionSelector {
'stroke-width': consts.BASE_STROKE_WIDTH / this.geometry.scale,
})
.addClass('cvat_canvas_shape_region_selection');
this.selectionRect.attr({ ...this.startSelectionPoint });
this.selectionRect.attr({ ...this.startSelectionPoint, width: 1, height: 1 });
}
};
......@@ -78,7 +78,7 @@ export class RegionSelectorImpl implements RegionSelector {
} = this.selectionRect.bbox();
this.selectionRect.remove();
this.selectionRect = null;
if (w === 0 && h === 0) {
if (w <= 1 && h <= 1) {
this.onRegionSelected([x - offset, y - offset]);
} else {
this.onRegionSelected([x - offset, y - offset, x2 - offset, y2 - offset]);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册