@devexperts/dxcharts-lite 2.7.27 → 2.7.28
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -58,6 +58,10 @@ export declare class HoverProducerComponent extends ChartBaseElement {
|
|
|
58
58
|
hoverSubject: BehaviorSubject<Hover | null>;
|
|
59
59
|
get hover(): Hover | null;
|
|
60
60
|
longTouchActivatedSubject: BehaviorSubject<boolean>;
|
|
61
|
+
/**
|
|
62
|
+
* When true, mobile long-touch (e.g. 200ms) does not activate crosshair / disable pan.
|
|
63
|
+
*/
|
|
64
|
+
private longTouchCrosshairSuppressed;
|
|
61
65
|
private hoverProducerParts;
|
|
62
66
|
xFormatter: DateTimeFormatter;
|
|
63
67
|
constructor(crossEventProducer: CrossEventProducerComponent, scale: ScaleModel, config: FullChartConfig, chartModel: ChartModel, canvasInputListener: CanvasInputListenerComponent, canvasBoundsContainer: CanvasBoundsContainer, paneManager: PaneManager, timeZoneModel: TimeZoneModel, mainCanvasTouchHandler: MainCanvasTouchHandler, formatterFactory: (format: string) => (timestamp: number) => string);
|
|
@@ -125,6 +129,7 @@ export declare class HoverProducerComponent extends ChartBaseElement {
|
|
|
125
129
|
* Fires the last hover update if there is a last cross.
|
|
126
130
|
*/
|
|
127
131
|
fireLastCross(): void;
|
|
132
|
+
setLongTouchCrosshairSuppressed(value: boolean): void;
|
|
128
133
|
/**
|
|
129
134
|
* Registers a hover producer part with the given id.
|
|
130
135
|
*
|
|
@@ -34,6 +34,10 @@ export class HoverProducerComponent extends ChartBaseElement {
|
|
|
34
34
|
this.formatterFactory = formatterFactory;
|
|
35
35
|
this.hoverSubject = new BehaviorSubject(null);
|
|
36
36
|
this.longTouchActivatedSubject = new BehaviorSubject(false);
|
|
37
|
+
/**
|
|
38
|
+
* When true, mobile long-touch (e.g. 200ms) does not activate crosshair / disable pan.
|
|
39
|
+
*/
|
|
40
|
+
this.longTouchCrosshairSuppressed = false;
|
|
37
41
|
this.xFormatter = () => '';
|
|
38
42
|
const candleHoverProducerPart = new CandleHoverProducerPart(this.chartModel);
|
|
39
43
|
const compareSeriesHoverProducerPart = new CompareSeriesHoverProducerPart(this.chartModel);
|
|
@@ -104,6 +108,9 @@ export class HoverProducerComponent extends ChartBaseElement {
|
|
|
104
108
|
const hitTest = this.canvasBoundsContainer.getBoundsHitTest(CanvasElement.ALL_PANES);
|
|
105
109
|
this.addRxSubscription(this.canvasInputListener.observeLongTouchStart(hitTest).subscribe(event => {
|
|
106
110
|
var _a;
|
|
111
|
+
if (this.longTouchCrosshairSuppressed) {
|
|
112
|
+
return;
|
|
113
|
+
}
|
|
107
114
|
this.crossEventProducer.crossToolHover = null;
|
|
108
115
|
this.crossEventProducer.crossToolTouchInfo.isCommonTap = false;
|
|
109
116
|
// don't lock chart and show crosshair if chart is being moved, crosstool is not enabled or we do pinch event
|
|
@@ -283,6 +290,9 @@ export class HoverProducerComponent extends ChartBaseElement {
|
|
|
283
290
|
this.createAndFireHover(lastCross);
|
|
284
291
|
}
|
|
285
292
|
}
|
|
293
|
+
setLongTouchCrosshairSuppressed(value) {
|
|
294
|
+
this.longTouchCrosshairSuppressed = value;
|
|
295
|
+
}
|
|
286
296
|
/**
|
|
287
297
|
* Registers a hover producer part with the given id.
|
|
288
298
|
*
|