hqchart 1.1.13973 → 1.1.13981

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.
@@ -345,22 +345,23 @@ function JSDialogTooltip()
345
345
  this.onmouseup = null;
346
346
  }
347
347
 
348
- this.Show=function()
348
+ this.Show=function(x, y)
349
349
  {
350
+ if (this.IsShow()) return;
351
+
350
352
  if (!this.DivDialog) return;
351
353
  if (!this.HQChart) return;
352
354
 
353
- if (!this.DivDialog.style.top || !this.DivDialog.style.left) //上一次显示的位置
354
- {
355
- var top=this.HQChart.Frame.ChartBorder.GetTop();
356
- var left=this.HQChart.Frame.ChartBorder.GetLeft();
357
- var rtClient=this.HQChart.UIElement.getBoundingClientRect();
358
-
359
- var x=left+rtClient.left+5;
360
- var y=top+rtClient.top+10;
361
- this.DivDialog.style.top = y + "px";
362
- this.DivDialog.style.left = x + "px";
363
- }
355
+
356
+ var top=this.HQChart.Frame.ChartBorder.GetTop();
357
+ var left=this.HQChart.Frame.ChartBorder.GetLeft();
358
+ var rtClient=this.HQChart.UIElement.getBoundingClientRect();
359
+
360
+ var x=left+rtClient.left+5;
361
+ var y=top+rtClient.top+10;
362
+ this.DivDialog.style.top = y + "px";
363
+ this.DivDialog.style.left = x + "px";
364
+
364
365
 
365
366
  this.DivDialog.style.visibility='visible';
366
367
  }
@@ -56322,6 +56322,8 @@ HQData.RequestOverlayHistoryData=function(data, callback)
56322
56322
  aryData=HQData.GetKLineDataByDate(fullData, first.date, 20999999)
56323
56323
  }
56324
56324
 
56325
+ //aryData=aryData.slice(aryData.length-20);
56326
+
56325
56327
  var hqchartData={ code:0, symbol: symbol,name: symbol, ver:2.0, data:aryData };
56326
56328
 
56327
56329
  callback(hqchartData);
@@ -18,6 +18,7 @@ function JSPopKeyboard()
18
18
  this.Title="HQChart 键盘精灵"
19
19
  this.ID=Guid();
20
20
  this.ActiveDOM=null; //启动键盘精灵是的控件
21
+ this.InputStatus=0; //0=空闲 1=输入中
21
22
 
22
23
  this.Keyboard=
23
24
  {
@@ -74,6 +75,10 @@ function JSPopKeyboard()
74
75
  input.addEventListener("keydown", (event)=>{ this.OnKeydown(event); });
75
76
  input.addEventListener("keyup", (event)=>{ this.OnKeyup(event); });
76
77
 
78
+ input.addEventListener("compositionstart", (event)=>{ this.OnCompositionStart(event); });
79
+ input.addEventListener("compositionupdate", (event)=>{ this.OnCompositionUpdate(event);} );
80
+ input.addEventListener("compositionend", (event)=>{ this.OnCompositionEnd(event);} );
81
+
77
82
  divInput.appendChild(input);
78
83
 
79
84
  var divChart=document.createElement("div");
@@ -104,8 +109,26 @@ function JSPopKeyboard()
104
109
 
105
110
  }
106
111
 
112
+
113
+ this.OnCompositionStart=function(event)
114
+ {
115
+ this.InputStatus=1;
116
+ }
117
+
118
+ this.OnCompositionUpdate=function(event)
119
+ {
120
+
121
+ }
122
+
123
+ this.OnCompositionEnd=function(event)
124
+ {
125
+ this.InputStatus=0;
126
+ }
127
+
107
128
  this.OnKeydown=function(event)
108
129
  {
130
+ if (this.InputStatus!=0) return;
131
+
109
132
  var aryKey=new Set([
110
133
  40,
111
134
  38,
@@ -127,6 +150,8 @@ function JSPopKeyboard()
127
150
 
128
151
  this.OnKeyup=function(event)
129
152
  {
153
+ if (this.InputStatus!=0) return;
154
+
130
155
  var code=event.keyCode;
131
156
  if ((code>=48 && code<=57) || (code>=65 && code<=90) || (code>=97 && code<=122) || code==8)
132
157
  {
@@ -599,10 +599,11 @@ function JSTReportChartContainer(uielement)
599
599
 
600
600
  this.RecvStockListData=function(data)
601
601
  {
602
+ this.MapExePriceData=new Map();
603
+ this.MapStockData=new Map();
604
+
602
605
  if (IFrameSplitOperator.IsNonEmptyArray(data.data))
603
606
  {
604
- this.MapExePriceData=new Map();
605
- this.MapStockData=new Map();
606
607
  //0=行权价格 1=左边期权代码 2=右侧期权代码 3=左侧期权名称 4=右侧期权名称
607
608
  for(var i=0;i<data.data.length;++i)
608
609
  {
@@ -766,7 +767,7 @@ function JSTReportChartContainer(uielement)
766
767
 
767
768
  if (rightData && IFrameSplitOperator.IsNumber(rightData.Position))
768
769
  {
769
- if (leftMaxPosition.Max==null || leftMaxPosition.Max<rightData.Position)
770
+ if (rightMaxPosition.Max==null || rightMaxPosition.Max<rightData.Position)
770
771
  {
771
772
  rightMaxPosition.Max=rightData.Position;
772
773
  rightMaxPosition.ExePrice=mapItem[0];