Skip to content

Commit

Permalink
Merge pull request #970 from dannyrb/docs/small-updates
Browse files Browse the repository at this point in the history
feat: MEASUREMENT_COMPLETED event to brush
  • Loading branch information
dannyrb authored Jun 11, 2019
2 parents 92a9c42 + a85341c commit a803c15
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions src/tools/base/BaseBrushTool.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import external from './../../externalModules.js';
import EVENTS from './../../events.js';
import BaseTool from './BaseTool.js';
import isToolActive from './../../store/isToolActive.js';
import store from './../../store/index.js';
import EVENTS from './../../events.js';
import external from './../../externalModules.js';
import { getToolState } from '../../stateManagement/toolState.js';
import { globalImageIdSpecificToolStateManager } from '../../stateManagement/imageIdSpecificStateManager.js';
import isToolActive from './../../store/isToolActive.js';
import store from './../../store/index.js';
import triggerEvent from './../../util/triggerEvent.js';

const { state, setters } = store.modules.brush;

Expand Down Expand Up @@ -194,6 +195,8 @@ class BaseBrushTool extends BaseTool {
this._drawing = false;
this._mouseUpRender = true;

triggerEvent(evt.detail.element, EVENTS.MEASUREMENT_COMPLETED, evt.detail);

this._stopListeningForMouseUp(element);
}

Expand Down

0 comments on commit a803c15

Please sign in to comment.