hqchart 1.1.13660 → 1.1.13672

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.
@@ -871,3 +871,24 @@ HQData.Report_RequestStockSortData=function(data, callback)
871
871
  }
872
872
 
873
873
 
874
+
875
+ HQData.Keyboard_RequestSymbolList=function(data, callback)
876
+ {
877
+ //加载数据
878
+ var recv={ symbollist:SYMBOL_LIST };
879
+ var arySymbol=[];
880
+ for(var i=0;i<recv.symbollist.length;++i)
881
+ {
882
+ var item=recv.symbollist[i];
883
+ var shortSymbol=item[0];
884
+ shortSymbol=shortSymbol.replace(".sh", "");
885
+ shortSymbol=shortSymbol.replace(".sz", "");
886
+ var symbolItem={ Symbol:item[0], Name:item[1], ShortSymbol:shortSymbol, Spell:item[3], Type:item[2] };
887
+ if (i%5==0) symbolItem.Color="rgb(255,0,0)";
888
+ arySymbol.push(symbolItem);
889
+ }
890
+
891
+ callback(arySymbol);
892
+ }
893
+
894
+
@@ -45559,9 +45559,17 @@ function MinuteTooltipPaint()
45559
45559
  if (IFrameSplitOperator.IsNumber(close) && IFrameSplitOperator.IsNumber(this.YClose))
45560
45560
  {
45561
45561
  title=g_JSChartLocalization.GetText('Tooltip-Increase',this.LanguageID);
45562
- var value=(close-this.YClose)/this.YClose*100;
45563
- color = this.TitlePaint.GetColor(value, 0);
45564
- text = value.toFixed(2)+'%';
45562
+ if (this.YClose===0)
45563
+ {
45564
+ text = '--.--';
45565
+ color = this.TitleColor;
45566
+ }
45567
+ else
45568
+ {
45569
+ var value=(close-this.YClose)/this.YClose*100;
45570
+ color = this.TitlePaint.GetColor(value, 0);
45571
+ text = value.toFixed(2)+'%';
45572
+ }
45565
45573
  aryText.push({Title:title, TitleColor:this.TitleColor, Text:text, Color:color });
45566
45574
  }
45567
45575
 
@@ -45983,7 +45991,7 @@ function MinuteLeftTooltipPaint()
45983
45991
  this.ForamtIncrease=function(price, TitleID)
45984
45992
  {
45985
45993
  if (!IFrameSplitOperator.IsNumber(price) || price==0) return null;
45986
-
45994
+
45987
45995
  var value=(price-this.YClose)/this.YClose*100;
45988
45996
  var titleItem=
45989
45997
  {
@@ -45993,6 +46001,13 @@ function MinuteLeftTooltipPaint()
45993
46001
  TextColor:this.GetColor(value, 0)
45994
46002
  };
45995
46003
 
46004
+ if (this.YClose===0)
46005
+ {
46006
+ titleItem.Text="--.--";
46007
+ titleItem.TextColor=this.TitleColor
46008
+ }
46009
+
46010
+
45996
46011
  return titleItem;
45997
46012
  }
45998
46013
 
@@ -52709,7 +52724,7 @@ function FrameSplitMinutePriceY()
52709
52724
  var strPrice=price.toFixed(defaultfloatPrecision); //价格刻度字符串
52710
52725
  if (this.IsShowLeftText) coordinate.Message[0]=strPrice;
52711
52726
 
52712
- if (this.YClose)
52727
+ if (this.YClose && this.YClose!=0)
52713
52728
  {
52714
52729
  var per=(price/this.YClose-1)*100;
52715
52730
  if (per>0) coordinate.TextColor=g_JSChartResource.UpTextColor;
@@ -52793,7 +52808,7 @@ function FrameSplitMinutePriceY()
52793
52808
  var strPrice=price.toFixed(defaultfloatPrecision); //价格刻度字符串
52794
52809
  if (this.IsShowLeftText) coordinate.Message[0]=strPrice
52795
52810
 
52796
- if (IFrameSplitOperator.IsNumber(this.YClose))
52811
+ if (IFrameSplitOperator.IsNumber(this.YClose) && this.YClose!=0)
52797
52812
  {
52798
52813
  var per=(price/this.YClose-1)*100;
52799
52814
  if (per>0) coordinate.TextColor=g_JSChartResource.UpTextColor;
@@ -126220,6 +126235,7 @@ function JSReportChart(divElement)
126220
126235
  {
126221
126236
  this.DivElement=divElement;
126222
126237
  this.JSChartContainer; //表格控件
126238
+ this.ResizeListener; //大小变动监听
126223
126239
 
126224
126240
  //h5 canvas
126225
126241
  this.CanvasElement=document.createElement("canvas");
@@ -126346,6 +126362,16 @@ function JSReportChart(divElement)
126346
126362
  this.JSChartContainer=chart;
126347
126363
  this.DivElement.JSChart=this; //div中保存一份
126348
126364
 
126365
+ //注册事件
126366
+ if (option.EventCallback)
126367
+ {
126368
+ for(var i=0;i<option.EventCallback.length;++i)
126369
+ {
126370
+ var item=option.EventCallback[i];
126371
+ chart.AddEventCallback(item);
126372
+ }
126373
+ }
126374
+
126349
126375
  if (option.EnableResize==true) this.CreateResizeListener();
126350
126376
 
126351
126377
  if (option.EnablePopMenuV2===true) chart.InitalPopMenu();
@@ -134303,6 +134329,7 @@ function JSKeyboardChart(divElement)
134303
134329
  {
134304
134330
  this.DivElement=divElement;
134305
134331
  this.JSChartContainer; //表格控件
134332
+ this.ResizeListener; //大小变动监听
134306
134333
 
134307
134334
  //h5 canvas
134308
134335
  this.CanvasElement=document.createElement("canvas");
@@ -134320,9 +134347,18 @@ function JSKeyboardChart(divElement)
134320
134347
  this.OnSize=function()
134321
134348
  {
134322
134349
  //画布大小通过div获取
134323
- var height=parseInt(this.DivElement.style.height.replace("px",""));
134350
+ var height=this.DivElement.offsetHeight;
134351
+ var width=this.DivElement.offsetWidth;
134352
+ if (this.DivElement.style.height && this.DivElement.style.width)
134353
+ {
134354
+ if (this.DivElement.style.height.includes("px"))
134355
+ height=parseInt(this.DivElement.style.height.replace("px",""));
134356
+ if (this.DivElement.style.width.includes("px"))
134357
+ width=parseInt(this.DivElement.style.width.replace("px",""));
134358
+ }
134359
+
134324
134360
  this.CanvasElement.height=height;
134325
- this.CanvasElement.width=parseInt(this.DivElement.style.width.replace("px",""));
134361
+ this.CanvasElement.width=width;
134326
134362
  this.CanvasElement.style.width=this.CanvasElement.width+'px';
134327
134363
  this.CanvasElement.style.height=this.CanvasElement.height+'px';
134328
134364
 
@@ -134349,6 +134385,18 @@ function JSKeyboardChart(divElement)
134349
134385
  this.JSChartContainer=chart;
134350
134386
  this.DivElement.JSChart=this; //div中保存一份
134351
134387
 
134388
+ //注册事件
134389
+ if (option.EventCallback)
134390
+ {
134391
+ for(var i=0;i<option.EventCallback.length;++i)
134392
+ {
134393
+ var item=option.EventCallback[i];
134394
+ chart.AddEventCallback(item);
134395
+ }
134396
+ }
134397
+
134398
+ if (option.EnableResize==true) this.CreateResizeListener();
134399
+
134352
134400
  chart.Draw();
134353
134401
  }
134354
134402
 
@@ -134393,6 +134441,18 @@ function JSKeyboardChart(divElement)
134393
134441
  chart.Frame.ChartBorder.Bottom*=pixelTatio;
134394
134442
  }
134395
134443
 
134444
+ this.CreateResizeListener=function()
134445
+ {
134446
+ this.ResizeListener = new ResizeObserver((entries)=>{ this.OnDivResize(entries); });
134447
+ this.ResizeListener.observe(this.DivElement);
134448
+ }
134449
+
134450
+ this.OnDivResize=function(entries)
134451
+ {
134452
+ JSConsole.Chart.Log("[JSKeyboardChart::OnDivResize] entries=", entries);
134453
+ this.OnSize();
134454
+ }
134455
+
134396
134456
  /////////////////////////////////////////////////////////////////////////////
134397
134457
  //对外接口
134398
134458
  this.SetColumn=function(aryColumn, option)
@@ -137422,7 +137482,7 @@ function ScrollBarBGChart()
137422
137482
 
137423
137483
 
137424
137484
 
137425
- var HQCHART_VERSION="1.1.13659";
137485
+ var HQCHART_VERSION="1.1.13671";
137426
137486
 
137427
137487
  function PrintHQChartVersion()
137428
137488
  {
@@ -5,7 +5,7 @@
5
5
 
6
6
 
7
7
 
8
- var HQCHART_VERSION="1.1.13659";
8
+ var HQCHART_VERSION="1.1.13671";
9
9
 
10
10
  function PrintHQChartVersion()
11
11
  {
@@ -49547,6 +49547,27 @@ HQData.Report_RequestStockSortData=function(data, callback)
49547
49547
 
49548
49548
 
49549
49549
 
49550
+ HQData.Keyboard_RequestSymbolList=function(data, callback)
49551
+ {
49552
+ //加载数据
49553
+ var recv={ symbollist:SYMBOL_LIST };
49554
+ var arySymbol=[];
49555
+ for(var i=0;i<recv.symbollist.length;++i)
49556
+ {
49557
+ var item=recv.symbollist[i];
49558
+ var shortSymbol=item[0];
49559
+ shortSymbol=shortSymbol.replace(".sh", "");
49560
+ shortSymbol=shortSymbol.replace(".sz", "");
49561
+ var symbolItem={ Symbol:item[0], Name:item[1], ShortSymbol:shortSymbol, Spell:item[3], Type:item[2] };
49562
+ if (i%5==0) symbolItem.Color="rgb(255,0,0)";
49563
+ arySymbol.push(symbolItem);
49564
+ }
49565
+
49566
+ callback(arySymbol);
49567
+ }
49568
+
49569
+
49570
+
49550
49571
 
49551
49572
  /*暴露外部用的方法*/
49552
49573
  export default
@@ -45603,9 +45603,17 @@ function MinuteTooltipPaint()
45603
45603
  if (IFrameSplitOperator.IsNumber(close) && IFrameSplitOperator.IsNumber(this.YClose))
45604
45604
  {
45605
45605
  title=g_JSChartLocalization.GetText('Tooltip-Increase',this.LanguageID);
45606
- var value=(close-this.YClose)/this.YClose*100;
45607
- color = this.TitlePaint.GetColor(value, 0);
45608
- text = value.toFixed(2)+'%';
45606
+ if (this.YClose===0)
45607
+ {
45608
+ text = '--.--';
45609
+ color = this.TitleColor;
45610
+ }
45611
+ else
45612
+ {
45613
+ var value=(close-this.YClose)/this.YClose*100;
45614
+ color = this.TitlePaint.GetColor(value, 0);
45615
+ text = value.toFixed(2)+'%';
45616
+ }
45609
45617
  aryText.push({Title:title, TitleColor:this.TitleColor, Text:text, Color:color });
45610
45618
  }
45611
45619
 
@@ -46027,7 +46035,7 @@ function MinuteLeftTooltipPaint()
46027
46035
  this.ForamtIncrease=function(price, TitleID)
46028
46036
  {
46029
46037
  if (!IFrameSplitOperator.IsNumber(price) || price==0) return null;
46030
-
46038
+
46031
46039
  var value=(price-this.YClose)/this.YClose*100;
46032
46040
  var titleItem=
46033
46041
  {
@@ -46037,6 +46045,13 @@ function MinuteLeftTooltipPaint()
46037
46045
  TextColor:this.GetColor(value, 0)
46038
46046
  };
46039
46047
 
46048
+ if (this.YClose===0)
46049
+ {
46050
+ titleItem.Text="--.--";
46051
+ titleItem.TextColor=this.TitleColor
46052
+ }
46053
+
46054
+
46040
46055
  return titleItem;
46041
46056
  }
46042
46057
 
@@ -52753,7 +52768,7 @@ function FrameSplitMinutePriceY()
52753
52768
  var strPrice=price.toFixed(defaultfloatPrecision); //价格刻度字符串
52754
52769
  if (this.IsShowLeftText) coordinate.Message[0]=strPrice;
52755
52770
 
52756
- if (this.YClose)
52771
+ if (this.YClose && this.YClose!=0)
52757
52772
  {
52758
52773
  var per=(price/this.YClose-1)*100;
52759
52774
  if (per>0) coordinate.TextColor=g_JSChartResource.UpTextColor;
@@ -52837,7 +52852,7 @@ function FrameSplitMinutePriceY()
52837
52852
  var strPrice=price.toFixed(defaultfloatPrecision); //价格刻度字符串
52838
52853
  if (this.IsShowLeftText) coordinate.Message[0]=strPrice
52839
52854
 
52840
- if (IFrameSplitOperator.IsNumber(this.YClose))
52855
+ if (IFrameSplitOperator.IsNumber(this.YClose) && this.YClose!=0)
52841
52856
  {
52842
52857
  var per=(price/this.YClose-1)*100;
52843
52858
  if (per>0) coordinate.TextColor=g_JSChartResource.UpTextColor;
@@ -126264,6 +126279,7 @@ function JSReportChart(divElement)
126264
126279
  {
126265
126280
  this.DivElement=divElement;
126266
126281
  this.JSChartContainer; //表格控件
126282
+ this.ResizeListener; //大小变动监听
126267
126283
 
126268
126284
  //h5 canvas
126269
126285
  this.CanvasElement=document.createElement("canvas");
@@ -126390,6 +126406,16 @@ function JSReportChart(divElement)
126390
126406
  this.JSChartContainer=chart;
126391
126407
  this.DivElement.JSChart=this; //div中保存一份
126392
126408
 
126409
+ //注册事件
126410
+ if (option.EventCallback)
126411
+ {
126412
+ for(var i=0;i<option.EventCallback.length;++i)
126413
+ {
126414
+ var item=option.EventCallback[i];
126415
+ chart.AddEventCallback(item);
126416
+ }
126417
+ }
126418
+
126393
126419
  if (option.EnableResize==true) this.CreateResizeListener();
126394
126420
 
126395
126421
  if (option.EnablePopMenuV2===true) chart.InitalPopMenu();
@@ -136753,6 +136779,7 @@ function JSKeyboardChart(divElement)
136753
136779
  {
136754
136780
  this.DivElement=divElement;
136755
136781
  this.JSChartContainer; //表格控件
136782
+ this.ResizeListener; //大小变动监听
136756
136783
 
136757
136784
  //h5 canvas
136758
136785
  this.CanvasElement=document.createElement("canvas");
@@ -136770,9 +136797,18 @@ function JSKeyboardChart(divElement)
136770
136797
  this.OnSize=function()
136771
136798
  {
136772
136799
  //画布大小通过div获取
136773
- var height=parseInt(this.DivElement.style.height.replace("px",""));
136800
+ var height=this.DivElement.offsetHeight;
136801
+ var width=this.DivElement.offsetWidth;
136802
+ if (this.DivElement.style.height && this.DivElement.style.width)
136803
+ {
136804
+ if (this.DivElement.style.height.includes("px"))
136805
+ height=parseInt(this.DivElement.style.height.replace("px",""));
136806
+ if (this.DivElement.style.width.includes("px"))
136807
+ width=parseInt(this.DivElement.style.width.replace("px",""));
136808
+ }
136809
+
136774
136810
  this.CanvasElement.height=height;
136775
- this.CanvasElement.width=parseInt(this.DivElement.style.width.replace("px",""));
136811
+ this.CanvasElement.width=width;
136776
136812
  this.CanvasElement.style.width=this.CanvasElement.width+'px';
136777
136813
  this.CanvasElement.style.height=this.CanvasElement.height+'px';
136778
136814
 
@@ -136799,6 +136835,18 @@ function JSKeyboardChart(divElement)
136799
136835
  this.JSChartContainer=chart;
136800
136836
  this.DivElement.JSChart=this; //div中保存一份
136801
136837
 
136838
+ //注册事件
136839
+ if (option.EventCallback)
136840
+ {
136841
+ for(var i=0;i<option.EventCallback.length;++i)
136842
+ {
136843
+ var item=option.EventCallback[i];
136844
+ chart.AddEventCallback(item);
136845
+ }
136846
+ }
136847
+
136848
+ if (option.EnableResize==true) this.CreateResizeListener();
136849
+
136802
136850
  chart.Draw();
136803
136851
  }
136804
136852
 
@@ -136843,6 +136891,18 @@ function JSKeyboardChart(divElement)
136843
136891
  chart.Frame.ChartBorder.Bottom*=pixelTatio;
136844
136892
  }
136845
136893
 
136894
+ this.CreateResizeListener=function()
136895
+ {
136896
+ this.ResizeListener = new ResizeObserver((entries)=>{ this.OnDivResize(entries); });
136897
+ this.ResizeListener.observe(this.DivElement);
136898
+ }
136899
+
136900
+ this.OnDivResize=function(entries)
136901
+ {
136902
+ JSConsole.Chart.Log("[JSKeyboardChart::OnDivResize] entries=", entries);
136903
+ this.OnSize();
136904
+ }
136905
+
136846
136906
  /////////////////////////////////////////////////////////////////////////////
136847
136907
  //对外接口
136848
136908
  this.SetColumn=function(aryColumn, option)
@@ -141538,6 +141598,274 @@ JSPopMinuteChart.GetMinuteOption=function()
141538
141598
 
141539
141599
 
141540
141600
 
141601
+ /*
141602
+ Copyright (c) 2018 jones
141603
+
141604
+ http://www.apache.org/licenses/LICENSE-2.0
141605
+
141606
+ 开源项目 https://github.com/jones2000/HQChart
141607
+
141608
+ jones_2000@163.com
141609
+
141610
+ 内置弹出键盘精灵
141611
+ */
141612
+
141613
+ function JSPopKeyboard()
141614
+ {
141615
+ this.DivDialog=null;
141616
+ this.DragTitle=null;
141617
+ this.InputDOM=null;
141618
+ this.Title="HQChart 键盘精灵"
141619
+ this.ID=Guid();
141620
+
141621
+ this.Keyboard=
141622
+ {
141623
+ Option:JSPopKeyboard.GetOption(),
141624
+ JSChart:null,
141625
+ }
141626
+
141627
+ this.Inital=function()
141628
+ {
141629
+ window.addEventListener('mousedown', (e)=>{ this.OnWindowMouseDown(e)});
141630
+ }
141631
+
141632
+ this.OnWindowMouseDown=function(e)
141633
+ {
141634
+ if (!this.DivDialog) return;
141635
+
141636
+ console.log("[JSPopKeyboard::OnWindowMouseDown] e=", e);
141637
+
141638
+ if (!this.DivDialog.contains(e.target))
141639
+ {
141640
+ this.Hide();
141641
+ }
141642
+ }
141643
+
141644
+ this.Create=function()
141645
+ {
141646
+ var divDom=document.createElement('div');
141647
+ divDom.className='jchart_pop_keyboard_dailog';
141648
+ divDom.id=this.ID;
141649
+
141650
+ var divTitle=document.createElement("div");
141651
+ divTitle.className='jschart_keyboard_Title_Div';
141652
+ divTitle.innerText=this.Title;
141653
+ divTitle.onmousedown=(e)=>{ this.OnMouseDownTitle(e); }
141654
+ divDom.appendChild(divTitle);
141655
+
141656
+ var divInput=document.createElement("div");
141657
+ divInput.className='jschart_keyboard_Input_Div';
141658
+ divDom.appendChild(divInput);
141659
+
141660
+ var input=document.createElement("input");
141661
+ input.className="jschart_keyboard_input";
141662
+ input.addEventListener("keydown", (event)=>{ this.OnKeydown(event); });
141663
+ input.addEventListener("keyup", (event)=>{ this.OnKeyup(event); });
141664
+
141665
+ divInput.appendChild(input);
141666
+
141667
+ var divChart=document.createElement("div");
141668
+ divChart.className="jschart_keyboard_Chart_Div";
141669
+ divDom.appendChild(divChart);
141670
+
141671
+ this.DivDialog=divDom;
141672
+ this.InputDOM=input;
141673
+
141674
+ var chart=JSKeyboardChart.Init(divChart);
141675
+ this.Keyboard.JSChart=chart;
141676
+
141677
+ this.Keyboard.Option.OnCreatedCallback=(chart)=>{ this.OnCreateHQChart(chart); }
141678
+ chart.SetOption(this.Keyboard.Option); //设置K线配置
141679
+
141680
+ chart.AddEventCallback(
141681
+ {
141682
+ event:JSCHART_EVENT_ID.ON_KEYBOARD_MOUSEUP,
141683
+ callback:(event, data, chart)=>{ this.OnChartMouseUp(event, data, chart);}
141684
+ }
141685
+ )
141686
+
141687
+ document.body.appendChild(divDom);
141688
+ }
141689
+
141690
+ this.OnCreateHQChart=function(chart)
141691
+ {
141692
+
141693
+ }
141694
+
141695
+ this.OnKeydown=function(event)
141696
+ {
141697
+ var aryKey=new Set([
141698
+ 40,
141699
+ 38,
141700
+ 13,
141701
+ 33,
141702
+ 34
141703
+ ]);
141704
+
141705
+ if (aryKey.has(event.keyCode))
141706
+ {
141707
+ this.Keyboard.JSChart.OnKeyDown(event);
141708
+ }
141709
+
141710
+ if (event.keyCode==27)
141711
+ {
141712
+ this.Hide();
141713
+ }
141714
+ }
141715
+
141716
+ this.OnKeyup=function(event)
141717
+ {
141718
+ var code=event.keyCode;
141719
+ if ((code>=48 && code<=57) || (code>=65 && code<=90) || (code>=97 && code<=122) || code==8)
141720
+ {
141721
+ var strText=this.InputDOM.value;
141722
+ strText=strText.toUpperCase();
141723
+ if (strText.length==0)
141724
+ {
141725
+ this.Hide();
141726
+ }
141727
+ else
141728
+ {
141729
+ this.Keyboard.JSChart.Search(strText);
141730
+ }
141731
+ }
141732
+ }
141733
+
141734
+
141735
+ this.OnMouseDownTitle=function(e)
141736
+ {
141737
+ if (!this.DivDialog) return;
141738
+
141739
+ var dragData={ X:e.clientX, Y:e.clientY };
141740
+ dragData.YOffset=e.clientX - this.DivDialog.offsetLeft;
141741
+ dragData.XOffset=e.clientY - this.DivDialog.offsetTop;
141742
+ this.DragTitle=dragData;
141743
+
141744
+ document.onmousemove=(e)=>{ this.DocOnMouseMoveTitle(e); }
141745
+ document.onmouseup=(e)=>{ this.DocOnMouseUpTitle(e); }
141746
+ }
141747
+
141748
+ this.DocOnMouseMoveTitle=function(e)
141749
+ {
141750
+ if (!this.DragTitle) return;
141751
+
141752
+ var left = e.clientX - this.DragTitle.YOffset;
141753
+ var top = e.clientY - this.DragTitle.XOffset;
141754
+
141755
+ var right=left+this.DivDialog.offsetWidth;
141756
+ var bottom=top+ this.DivDialog.offsetHeight;
141757
+
141758
+ if ((right+5)>=window.innerWidth) left=window.innerWidth-this.DivDialog.offsetWidth-5;
141759
+ if ((bottom+5)>=window.innerHeight) top=window.innerHeight-this.DivDialog.offsetHeight-5;
141760
+
141761
+ this.DivDialog.style.left = left + 'px';
141762
+ this.DivDialog.style.top = top + 'px';
141763
+
141764
+ if(e.preventDefault) e.preventDefault();
141765
+ }
141766
+
141767
+ this.DocOnMouseUpTitle=function(e)
141768
+ {
141769
+ this.DragTitle=null;
141770
+ this.onmousemove = null;
141771
+ this.onmouseup = null;
141772
+ }
141773
+
141774
+ this.SetSymbolData=function(data)
141775
+ {
141776
+ if (!this.Keyboard.JSChart) return false;
141777
+ this.Keyboard.JSChart.SetSymbolData(data);
141778
+ }
141779
+
141780
+ this.Show=function()
141781
+ {
141782
+ if (!this.DivDialog) return;
141783
+
141784
+ //显示在右下方
141785
+ var height=this.DivDialog.offsetHeight;
141786
+ var width=this.DivDialog.offsetWidth;
141787
+ var xRight=window.innerWidth-5;
141788
+ var ybottom=window.innerHeight-5;
141789
+ var x=xRight-width;
141790
+ var y=ybottom-height;
141791
+
141792
+ this.DivDialog.style.visibility='visible';
141793
+ this.DivDialog.style.top = y + "px";
141794
+ this.DivDialog.style.left = x + "px";
141795
+ }
141796
+
141797
+ this.Hide=function()
141798
+ {
141799
+ if (!this.DivDialog) return;
141800
+
141801
+ this.DivDialog.style.visibility='hidden';
141802
+ this.InputDOM.value="";
141803
+ this.Keyboard.JSChart.ClearSearch();
141804
+ }
141805
+
141806
+ this.IsShow=function()
141807
+ {
141808
+ if (!this.DivDialog) return false;
141809
+ return this.DivDialog.style.visibility==='visible';
141810
+ }
141811
+
141812
+ this.OnGlobalKeydown=function(event)
141813
+ {
141814
+ if (!this.DivDialog) return;
141815
+
141816
+ var code=event.keyCode;
141817
+ if (!this.IsShow() && (code>=48 && code<=57) || (code>=65 && code<=90) || (code>=97 && code<=122))
141818
+ {
141819
+ this.Show();
141820
+ this.InputDOM.focus();
141821
+ }
141822
+ else if (code==27 && this.IsShow())
141823
+ {
141824
+ this.Hide();
141825
+ }
141826
+ }
141827
+
141828
+ this.OnGlobalMouseDown=function(event)
141829
+ {
141830
+ if (!this.DivDialog) return;
141831
+
141832
+ if (this.DivDialog.style.display=='none') return;
141833
+
141834
+ if (!this.DivDialog.contains(event.target))
141835
+ {
141836
+ this.Hide();
141837
+ }
141838
+ }
141839
+
141840
+ this.OnChartMouseUp=function(event, data, chart)
141841
+ {
141842
+ this.InputDOM.focus();
141843
+ }
141844
+ }
141845
+
141846
+ JSPopKeyboard.GetOption=function()
141847
+ {
141848
+ var option=
141849
+ {
141850
+ Type:'键盘精灵', //创建图形类型
141851
+
141852
+ Border: //边框
141853
+ {
141854
+ Left:1, //左边间距
141855
+ Right:1, //右边间距
141856
+ Bottom:1, //底部间距
141857
+ Top:1 //顶部间距
141858
+ },
141859
+
141860
+ BorderLine:0,
141861
+ EnableResize:true
141862
+ };
141863
+
141864
+ return option;
141865
+ }
141866
+
141867
+
141868
+
141541
141869
  ///////////////////////////////////////////////////////////////////////////////////
141542
141870
  // 工作线程计算指标示例
141543
141871
  //
@@ -141659,7 +141987,7 @@ function HQChartScriptWorker()
141659
141987
 
141660
141988
 
141661
141989
 
141662
- var HQCHART_VERSION="1.1.13659";
141990
+ var HQCHART_VERSION="1.1.13671";
141663
141991
 
141664
141992
  function PrintHQChartVersion()
141665
141993
  {
@@ -141777,6 +142105,7 @@ export default {
141777
142105
  //键盘精灵
141778
142106
  JSKeyboardChart:JSKeyboardChart,
141779
142107
  KEYBOARD_COLUMN_ID:KEYBOARD_COLUMN_ID,
142108
+ JSPopKeyboard:JSPopKeyboard,
141780
142109
 
141781
142110
  //X轴滚动条
141782
142111
  JSScrollBarChart:JSScrollBarChart,