hqchart 1.1.14564 → 1.1.14591
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.
- package/lib/umychart.vue.js +260 -94
- package/package.json +1 -1
- package/src/jscommon/umychart.DialogSearchIndex.js +156 -9
- package/src/jscommon/umychart.NetworkFilterTest.js +82 -1
- package/src/jscommon/umychart.PopMinuteChart.js +5 -2
- package/src/jscommon/umychart.complier.js +25 -7
- package/src/jscommon/umychart.index.data.js +178 -7
- package/src/jscommon/umychart.js +537 -16
- package/src/jscommon/umychart.testdata.js +82 -1
- package/src/jscommon/umychart.uniapp.h5/umychart.uniapp.h5.js +741 -31
- package/src/jscommon/umychart.version.js +1 -1
- package/src/jscommon/umychart.vue/umychart.NetworkFilterTest.vue.js +82 -1
- package/src/jscommon/umychart.vue/umychart.vue.js +902 -42
|
@@ -111,7 +111,7 @@ function JSIndexScript()
|
|
|
111
111
|
['VRSI',this.VRSI],['HSCOL',this.HSCOL],['DBQRV',this.DBQRV],['DBLB',this.DBLB],
|
|
112
112
|
['ACD',this.ACD],['EXPMA',this.EXPMA],['EXPMA_S',this.EXPMA_S],['HMA',this.HMA],
|
|
113
113
|
['LMA',this.LMA],['VMA',this.VMA],['AMV',this.AMV],['BBIBOLL',this.BBIBOLL],
|
|
114
|
-
['ALLIGAT',this.ALLIGAT],['ZX',this.ZX],['XS',this.XS],['XS2',this.XS2],
|
|
114
|
+
['ALLIGAT',this.ALLIGAT],["GMMA",this.GMMA],['ZX',this.ZX],['XS',this.XS],['XS2',this.XS2],
|
|
115
115
|
['SG-XDT',this.SG_XDT],['SG-SMX',this.SG_SMX],['SG-LB',this.SG_LB],['SG-PF',this.SG_PF],
|
|
116
116
|
['RAD',this.RAD],['SHT',this.SHT],['ZLJC',this.ZLJC],['ZLMM',this.ZLMM],['SLZT',this.SLZT],
|
|
117
117
|
['ADVOL',this.ADVOL],['CYC',this.CYC],['CYS',this.CYS],['CYQKL',this.CYQKL],
|
|
@@ -123,7 +123,8 @@ function JSIndexScript()
|
|
|
123
123
|
['神奇九转', this.NineTurns],
|
|
124
124
|
['EMA', this.EMA3], ['EMA4', this.EMA4], ['EMA5', this.EMA5],['EMA6', this.EMA6],
|
|
125
125
|
["ICHIMOKU",this.ICHIMOKU],["CDP-STD", this.CDP_STD],["TBP-STD",this.TBP_STD],
|
|
126
|
-
["ADX", this.ADX],
|
|
126
|
+
["ADX", this.ADX],["SMACD", this.SMACD],["ACCER",this.ACCER],["AMO-TDX", this.AMO_TDX],
|
|
127
|
+
["WSBVOL",this.WSBVOL], ["CCYD",this.CCYD], ["CCL",this.CCL],["ABI", this.ABI],
|
|
127
128
|
|
|
128
129
|
["持仓量", this.VOL_POSITION], //成交量+持仓量
|
|
129
130
|
|
|
@@ -143,11 +144,11 @@ function JSIndexScript()
|
|
|
143
144
|
|
|
144
145
|
["两融余额", this.Margin2],["两融余额2", this.Margin3],
|
|
145
146
|
|
|
146
|
-
|
|
147
|
-
['
|
|
148
|
-
['
|
|
149
|
-
['
|
|
150
|
-
['
|
|
147
|
+
//特色指标
|
|
148
|
+
['特色指标-操盘BS点',this.FXG_BSPoint],
|
|
149
|
+
['特色指标-涨停多空线',this.FXG_INDEX],
|
|
150
|
+
['特色指标-涨停吸筹区',this.FXG_INDEX2],
|
|
151
|
+
['特色指标-量能黄金点',this.FXG_INDEX3],
|
|
151
152
|
|
|
152
153
|
//五彩K线(函数COLOR_开头)
|
|
153
154
|
['五彩K线-十字星',this.COLOR_KSTAR1],['五彩K线-早晨之星',this.COLOR_KSTAR2],['五彩K线-黄昏之星',this.COLOR_KSTAR3],['五彩K线-长十字',this.COLOR_SHI1],
|
|
@@ -708,6 +709,28 @@ MAVOL2:MA(VOLUME,M2);'
|
|
|
708
709
|
return data;
|
|
709
710
|
}
|
|
710
711
|
|
|
712
|
+
|
|
713
|
+
JSIndexScript.prototype.AMO_TDX=function()
|
|
714
|
+
{
|
|
715
|
+
let data=
|
|
716
|
+
{
|
|
717
|
+
Name:'AMO-TDX', Description:'成交金额(虚拟)', IsMainIndex:false,FloatPrecision:0,
|
|
718
|
+
Args:[ { Name:'M1', Value:5}, { Name:'M2', Value:10} ],
|
|
719
|
+
Script: //脚本
|
|
720
|
+
'TOTAL:=IF(PERIOD=1,5,IF(PERIOD=2,15,IF(PERIOD=3,30,IF(PERIOD=4,60,IF(PERIOD=5,TOTALFZNUM,1)))));\n\
|
|
721
|
+
MTIME:=MOD(FROMOPEN,TOTAL);\n\
|
|
722
|
+
CTIME:=IF(MTIME<0.5,TOTAL,MTIME);\n\
|
|
723
|
+
VAMO:=IF((CURRBARSCOUNT=1 AND DYNAINFO(8)>1),AMOUNT/10000.0*TOTAL/CTIME,DRAWNULL);\n\
|
|
724
|
+
STICKLINE((CURRBARSCOUNT=1 AND DYNAINFO(8)>1),VAMO,0,-1,-1),COLOR00C0C0;\n\
|
|
725
|
+
AMOW:AMOUNT/10000.0,VOLSTICK;\n\
|
|
726
|
+
AMO1:MA(AMOW,M1);\n\
|
|
727
|
+
AMO2:MA(AMOW,M2);'
|
|
728
|
+
|
|
729
|
+
};
|
|
730
|
+
|
|
731
|
+
return data;
|
|
732
|
+
}
|
|
733
|
+
|
|
711
734
|
JSIndexScript.prototype.RSI=function()
|
|
712
735
|
{
|
|
713
736
|
let data=
|
|
@@ -1445,6 +1468,40 @@ MACD:DIF-DEA,COLORSTICK;'
|
|
|
1445
1468
|
return data;
|
|
1446
1469
|
}
|
|
1447
1470
|
|
|
1471
|
+
JSIndexScript.prototype.SMACD = function ()
|
|
1472
|
+
{
|
|
1473
|
+
let data =
|
|
1474
|
+
{
|
|
1475
|
+
Name: 'SMACD', Description: '单线平滑异同平均线', IsMainIndex: false,
|
|
1476
|
+
Args: [{ Name: 'SHORT', Value: 12 },{ Name: 'LONG', Value: 26 },{ Name: 'MID', Value: 9 }],
|
|
1477
|
+
Script: //脚本
|
|
1478
|
+
'DIF:=EMA(CLOSE,SHORT)-EMA(CLOSE,LONG);\n\
|
|
1479
|
+
DEA:EMA(DIF,MID);\n\
|
|
1480
|
+
MACD:DIF,COLORSTICK;'
|
|
1481
|
+
|
|
1482
|
+
};
|
|
1483
|
+
|
|
1484
|
+
return data;
|
|
1485
|
+
}
|
|
1486
|
+
|
|
1487
|
+
|
|
1488
|
+
JSIndexScript.prototype.ACCER = function ()
|
|
1489
|
+
{
|
|
1490
|
+
let data =
|
|
1491
|
+
{
|
|
1492
|
+
Name: 'ACCER', Description: '幅度涨速', IsMainIndex: false,
|
|
1493
|
+
Args: [{ Name: 'N', Value: 8 }],
|
|
1494
|
+
Script: //脚本
|
|
1495
|
+
'ACCER:SLOPE(CLOSE,N)/CLOSE;'
|
|
1496
|
+
|
|
1497
|
+
};
|
|
1498
|
+
|
|
1499
|
+
return data;
|
|
1500
|
+
}
|
|
1501
|
+
|
|
1502
|
+
|
|
1503
|
+
|
|
1504
|
+
|
|
1448
1505
|
JSIndexScript.prototype.QACD = function ()
|
|
1449
1506
|
{
|
|
1450
1507
|
let data =
|
|
@@ -1869,6 +1926,32 @@ JSIndexScript.prototype.ALLIGAT = function ()
|
|
|
1869
1926
|
return data;
|
|
1870
1927
|
}
|
|
1871
1928
|
|
|
1929
|
+
|
|
1930
|
+
JSIndexScript.prototype.GMMA = function ()
|
|
1931
|
+
{
|
|
1932
|
+
let data =
|
|
1933
|
+
{
|
|
1934
|
+
Name: 'GMMA', Description: '顾比均线', IsMainIndex: true,
|
|
1935
|
+
Args: [],
|
|
1936
|
+
Script: //脚本
|
|
1937
|
+
'MA3:EMA(CLOSE,3),COLORC08080;\n\
|
|
1938
|
+
MA5:EMA(CLOSE,5),COLORC08080;\n\
|
|
1939
|
+
MA8:EMA(CLOSE,8),COLORC08080;\n\
|
|
1940
|
+
MA10:EMA(CLOSE,10),COLORC08080;\n\
|
|
1941
|
+
MA12:EMA(CLOSE,12),COLORC08080;\n\
|
|
1942
|
+
MA15:EMA(CLOSE,15),COLORC08080;\n\
|
|
1943
|
+
MA30:EMA(CLOSE,30),COLOR0080FF;\n\
|
|
1944
|
+
MA35:EMA(CLOSE,35),COLOR0080FF;\n\
|
|
1945
|
+
MA40:EMA(CLOSE,40),COLOR0080FF;\n\
|
|
1946
|
+
MA45:EMA(CLOSE,45),COLOR0080FF;\n\
|
|
1947
|
+
MA50:EMA(CLOSE,50),COLOR0080FF;\n\
|
|
1948
|
+
MA60:EMA(CLOSE,60),COLOR0080FF;'
|
|
1949
|
+
|
|
1950
|
+
};
|
|
1951
|
+
|
|
1952
|
+
return data;
|
|
1953
|
+
}
|
|
1954
|
+
|
|
1872
1955
|
JSIndexScript.prototype.ZX = function ()
|
|
1873
1956
|
{
|
|
1874
1957
|
let data =
|
|
@@ -3905,6 +3988,94 @@ B:=REF(LLV(CLOSE,N),1);
|
|
|
3905
3988
|
}
|
|
3906
3989
|
|
|
3907
3990
|
|
|
3991
|
+
JSIndexScript.prototype.WSBVOL = function()
|
|
3992
|
+
{
|
|
3993
|
+
let data =
|
|
3994
|
+
{
|
|
3995
|
+
Name: 'WSBVOL', Description: '维斯波成交量', IsMainIndex: false,
|
|
3996
|
+
Script: //脚本
|
|
3997
|
+
`UPTJ1:=CLOSE>REF(CLOSE,1);
|
|
3998
|
+
UPTJ2:=(CLOSE==REF(CLOSE,1) && REF(CLOSE,1)>REF(CLOSE,2));
|
|
3999
|
+
UPTJ3:=MAX(OPEN,CLOSE)<REF(C,BARSLAST(CLOSE>REF(CLOSE,1))) AND MIN(OPEN,CLOSE)>REF(O,BARSLAST(CLOSE>REF(CLOSE,1)));
|
|
4000
|
+
UPTJ4:=NOT (H<REF(H,1) AND L<REF(L,1));
|
|
4001
|
+
UP:=(UPTJ1 || UPTJ2 || UPTJ3) AND UPTJ4;
|
|
4002
|
+
DOWN:=NOT(UP);
|
|
4003
|
+
M1:=BARSLASTCOUNT(UP);
|
|
4004
|
+
N1:=BARSLASTCOUNT(DOWN);
|
|
4005
|
+
CZB:=IF(M1=1 OR N1=1,2*INTPART(VOL*100/10000),INTPART(VOL*100/10000));
|
|
4006
|
+
SZ:=IF(M1>0,SUM(CZB,M1),-1*SUM(CZB,N1));
|
|
4007
|
+
GY:=IF(N1>0,SUM(CZB,N1),0);
|
|
4008
|
+
XQ:=IF(M1>0,SUM(CZB,M1),0);
|
|
4009
|
+
NOTEXT1:STICKLINE(M1>0,0,XQ,1,0),COLORRED;
|
|
4010
|
+
NOTEXT2:STICKLINE(N1>0,0,GY,1,0),COLORGREEN;
|
|
4011
|
+
WSB:SZ,NODRAW;`
|
|
4012
|
+
};
|
|
4013
|
+
|
|
4014
|
+
return data;
|
|
4015
|
+
}
|
|
4016
|
+
|
|
4017
|
+
|
|
4018
|
+
JSIndexScript.prototype.CCL = function()
|
|
4019
|
+
{
|
|
4020
|
+
let data =
|
|
4021
|
+
{
|
|
4022
|
+
Name: 'CCL', Description: '持仓量(适用于期货)', IsMainIndex: false,
|
|
4023
|
+
Script: //脚本
|
|
4024
|
+
`持仓量:VOLINSTK;
|
|
4025
|
+
成交:VOL,COLORLIRED;
|
|
4026
|
+
仓差:VOLINSTK-REF(VOLINSTK,1),NODRAW;
|
|
4027
|
+
STICKLINE(仓差>0 AND C>REF(C,1),0,仓差,2,3),COLORRED;
|
|
4028
|
+
STICKLINE(仓差>0 AND C<REF(C,1),0,仓差,2,3),COLORCYAN;
|
|
4029
|
+
STICKLINE(仓差>0 AND C=REF(C,1),0,仓差,2,3),COLORGRAY;
|
|
4030
|
+
STICKLINE(仓差<0 AND C>REF(C,1),0,仓差,2,3),COLORRED;
|
|
4031
|
+
STICKLINE(仓差<0 AND C<REF(C,1),0,仓差,2,3),COLORCYAN;
|
|
4032
|
+
STICKLINE(仓差<0 AND C=REF(C,1),0,仓差,2,3),COLORGRAY;`
|
|
4033
|
+
};
|
|
4034
|
+
|
|
4035
|
+
return data;
|
|
4036
|
+
}
|
|
4037
|
+
|
|
4038
|
+
JSIndexScript.prototype.CCYD = function()
|
|
4039
|
+
{
|
|
4040
|
+
let data =
|
|
4041
|
+
{
|
|
4042
|
+
Name: 'CCYD', Description: '持仓异动(适用于期货)', IsMainIndex: false,
|
|
4043
|
+
Script: //脚本
|
|
4044
|
+
`CCYD:=VOLINSTK-REF(VOLINSTK,1);
|
|
4045
|
+
SPYD:=C-REF(C,1);
|
|
4046
|
+
多头增仓:IF(SPYD>=0 AND CCYD>=0,ABS(CCYD),DRAWNULL),COLOR3232FF,NODRAW;
|
|
4047
|
+
空头减仓:IF(SPYD>0 AND CCYD<0,ABS(CCYD),DRAWNULL),COLOR3232FF,NODRAW;
|
|
4048
|
+
空头增仓:IF(SPYD<0 AND CCYD>=0,ABS(CCYD),DRAWNULL),COLORFFFF54,NODRAW;
|
|
4049
|
+
多头减仓:IF(SPYD<0 AND CCYD<0,ABS(CCYD),DRAWNULL),COLORFFFF54,NODRAW;
|
|
4050
|
+
STICKLINE(SPYD>=0 AND CCYD>=0,0,CCYD,3,1),COLOR3232FF;
|
|
4051
|
+
STICKLINE(SPYD>0 AND CCYD<0,CCYD,0,3,1),COLOR3232FF;
|
|
4052
|
+
STICKLINE(SPYD<0 AND CCYD>=0,CCYD,0,3,0),COLORFFFF54;
|
|
4053
|
+
STICKLINE(SPYD<0 AND CCYD<0,CCYD,0,3,0),COLORFFFF54;`
|
|
4054
|
+
};
|
|
4055
|
+
|
|
4056
|
+
return data;
|
|
4057
|
+
}
|
|
4058
|
+
|
|
4059
|
+
JSIndexScript.prototype.ABI = function()
|
|
4060
|
+
{
|
|
4061
|
+
let data =
|
|
4062
|
+
{
|
|
4063
|
+
Name: 'ABI', Description: '绝对广量指标', IsMainIndex: false,
|
|
4064
|
+
Args: [{ Name: 'N', Value: 10 }],
|
|
4065
|
+
Condition:
|
|
4066
|
+
{
|
|
4067
|
+
Period:[CONDITION_PERIOD.KLINE_DAY_ID, CONDITION_PERIOD.KLINE_WEEK_ID, CONDITION_PERIOD.KLINE_TWOWEEK_ID,
|
|
4068
|
+
CONDITION_PERIOD.KLINE_MONTH_ID, CONDITION_PERIOD.KLINE_QUARTER_ID ,CONDITION_PERIOD.KLINE_YEAR_ID ],
|
|
4069
|
+
Include:["000001.SH", "000003.SH", "000016.SH", "000300.SH", "000905.SH", "399001.SZ", " 399005.SZ", "399006.SZ"]
|
|
4070
|
+
},
|
|
4071
|
+
Script: //脚本
|
|
4072
|
+
`ABI:100*ABS(ADVANCE-DECLINE)/(ADVANCE+DECLINE);
|
|
4073
|
+
MAABI:EMA(ABI,M);`
|
|
4074
|
+
};
|
|
4075
|
+
|
|
4076
|
+
return data;
|
|
4077
|
+
}
|
|
4078
|
+
|
|
3908
4079
|
|
|
3909
4080
|
|
|
3910
4081
|
|
|
@@ -4214,6 +4385,7 @@ function JSChart(divElement, bOffscreen, bCacheCanvas)
|
|
|
4214
4385
|
if (IFrameSplitOperator.IsBool(option.EnableZoomIndexWindow)) chart.EnableZoomIndexWindow=option.EnableZoomIndexWindow;
|
|
4215
4386
|
if (IFrameSplitOperator.IsBool(option.IsDrawPictureXY)) chart.IsDrawPictureXY=option.IsDrawPictureXY;
|
|
4216
4387
|
if (IFrameSplitOperator.IsNumber(option.CtrlMoveStep)) chart.CtrlMoveStep=option.CtrlMoveStep;
|
|
4388
|
+
if (IFrameSplitOperator.IsNumber(option.ShiftMoveStep)) chart.ShiftMoveStep=option.ShiftMoveStep;
|
|
4217
4389
|
if (IFrameSplitOperator.IsBool(option.EnableIndexChartDrag)) chart.EnableIndexChartDrag=option.EnableIndexChartDrag;
|
|
4218
4390
|
if (IFrameSplitOperator.IsBool(option.EnableVerifyRecvData)) chart.EnableVerifyRecvData=option.EnableVerifyRecvData;
|
|
4219
4391
|
|
|
@@ -4365,6 +4537,12 @@ function JSChart(divElement, bOffscreen, bCacheCanvas)
|
|
|
4365
4537
|
if (IFrameSplitOperator.IsNumber(item.ZIndex)) zindex=item.ZIndex;
|
|
4366
4538
|
if (item.Enable) this.CreateExtraCanvasElement(JSChart.RectDragCanvasKey, { ZIndex:zindex }); //创建独立的区间选择画布
|
|
4367
4539
|
}
|
|
4540
|
+
|
|
4541
|
+
if (option.DragKLine)
|
|
4542
|
+
{
|
|
4543
|
+
var item=option.DragKLine;
|
|
4544
|
+
if (IFrameSplitOperator.IsBool(item.EnableShfit)) chart.KLineDragConfig.EnableShfit=item.EnableShfit;
|
|
4545
|
+
}
|
|
4368
4546
|
}
|
|
4369
4547
|
|
|
4370
4548
|
//创建子窗口
|
|
@@ -4416,6 +4594,7 @@ function JSChart(divElement, bOffscreen, bCacheCanvas)
|
|
|
4416
4594
|
if (IFrameSplitOperator.IsNumber(item.PriceFormatType)) chart.ChartCorssCursor.StringFormatY.PriceFormatType=item.PriceFormatType;
|
|
4417
4595
|
if (IFrameSplitOperator.IsNumber(item.DataFormatType)) chart.ChartCorssCursor.StringFormatY.DataFormatType=item.DataFormatType;
|
|
4418
4596
|
if (IFrameSplitOperator.IsBool(item.EnableKeyboard)) chart.ChartCorssCursor.EnableKeyboard=item.EnableKeyboard;
|
|
4597
|
+
if (IFrameSplitOperator.IsBool(item.EnableDBClick)) chart.ChartCorssCursor.EnableDBClick=item.EnableDBClick;
|
|
4419
4598
|
|
|
4420
4599
|
if (IFrameSplitOperator.IsBool(item.IsShowCorssPoint)) chart.ChartCorssCursor.CorssPointConfig.Enable=item.IsShowCorssPoint;
|
|
4421
4600
|
|
|
@@ -4921,6 +5100,7 @@ function JSChart(divElement, bOffscreen, bCacheCanvas)
|
|
|
4921
5100
|
if (IFrameSplitOperator.IsNumber(item.HPenType)) chart.ChartCorssCursor.HPenType=item.HPenType;
|
|
4922
5101
|
if (IFrameSplitOperator.IsNumber(item.VPenType)) chart.ChartCorssCursor.VPenType=item.VPenType;
|
|
4923
5102
|
if (IFrameSplitOperator.IsBool(item.EnableKeyboard)) chart.ChartCorssCursor.EnableKeyboard=item.EnableKeyboard;
|
|
5103
|
+
if (IFrameSplitOperator.IsBool(item.EnableDBClick)) chart.ChartCorssCursor.EnableDBClick=item.EnableDBClick;
|
|
4924
5104
|
if (IFrameSplitOperator.IsBool(item.IsShowCorssPoint)) chart.ChartCorssCursor.CorssPointConfig.Enable=item.IsShowCorssPoint;
|
|
4925
5105
|
if (IFrameSplitOperator.IsNumber(item.VLineType)) chart.ChartCorssCursor.VLineType=item.VLineType;
|
|
4926
5106
|
}
|
|
@@ -6424,9 +6604,6 @@ JSChart.GetfloatPrecision=function(symbol)
|
|
|
6424
6604
|
return GetfloatPrecision(symbol);
|
|
6425
6605
|
}
|
|
6426
6606
|
|
|
6427
|
-
|
|
6428
|
-
|
|
6429
|
-
|
|
6430
6607
|
var JSCHART_EVENT_ID=
|
|
6431
6608
|
{
|
|
6432
6609
|
//RECV_KLINE_MATCH:1, //接收到形态匹配
|
|
@@ -6822,10 +6999,14 @@ var JSCHART_MENU_ID=
|
|
|
6822
6999
|
CMD_CORSS_ON_VAILD_TIME_ID:50, //超出当前时间的,X轴调整到当前最后的时间(分时图)
|
|
6823
7000
|
CMD_CORSS_ON_KLINE_ID:51, //十字光标只能画在K线上
|
|
6824
7001
|
CMD_CORSS_POINT_ID:52, //十字光标圆点
|
|
7002
|
+
|
|
6825
7003
|
|
|
6826
7004
|
CMD_RBUTTON_SELECT_RECT_ID:53, //右键区间选择
|
|
6827
7005
|
CMD_LBUTTON_SELECT_RECT_ID:54, //左键区间选择
|
|
6828
|
-
CMD_ENABLE_XDRAG_BOTTOM_ID:55,
|
|
7006
|
+
CMD_ENABLE_XDRAG_BOTTOM_ID:55, //X轴拖动缩放
|
|
7007
|
+
|
|
7008
|
+
CMD_FULLSCREEN_SUMMARY_ID:56, //当前屏区间统计
|
|
7009
|
+
CMD_CORSS_DBCLICK_ID:57, //双击显示隐藏十字光标
|
|
6829
7010
|
|
|
6830
7011
|
|
|
6831
7012
|
|
|
@@ -6980,6 +7161,7 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
6980
7161
|
this.ZoomStepPixel=5; //放大缩小手势需要的最小像素
|
|
6981
7162
|
this.TouchMoveMinAngle=70; //左右移动最小角度
|
|
6982
7163
|
this.EnableAnimation=false; //是否开启动画
|
|
7164
|
+
this.ShiftUpDownStepPixel=1*GetDevicePixelRatio(); //Shift+(up/down) 移动十字光标
|
|
6983
7165
|
|
|
6984
7166
|
//tooltip提示信息
|
|
6985
7167
|
this.Tooltip=document.createElement("div");
|
|
@@ -7080,7 +7262,10 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
7080
7262
|
|
|
7081
7263
|
this.RestoreFocusTimer=null; //恢复焦点定时器
|
|
7082
7264
|
this.PreventRightMenu={ Timer:null, Enable:false, Delay:2000 }; //阻止右键菜单
|
|
7083
|
-
|
|
7265
|
+
|
|
7266
|
+
//SecondKeyID 1=shiftKey 2=ctrlKey 3=altKey
|
|
7267
|
+
this.AryHotKey=[]; //热键 { KeyID:87, SecondKeyID:1, CMD:JSCHART_MENU_ID.CMD_FULLSCREEN_SUMMARY_ID, Args:null, Description:"Alt+W 全屏区间统计" },
|
|
7268
|
+
|
|
7084
7269
|
this.RestoreFocus=function(delay)
|
|
7085
7270
|
{
|
|
7086
7271
|
var value=1000;
|
|
@@ -8115,6 +8300,17 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
8115
8300
|
document.oncontextmenu=(e)=> { this.DocContextMenu(e); }
|
|
8116
8301
|
}
|
|
8117
8302
|
|
|
8303
|
+
|
|
8304
|
+
this.IsShfitDragKLine=function(e)
|
|
8305
|
+
{
|
|
8306
|
+
if (this.DragMode!=1) return false;
|
|
8307
|
+
if (!this.KLineDragConfig) return false;
|
|
8308
|
+
if (!this.KLineDragConfig.EnableShfit) return false;
|
|
8309
|
+
if (!e.shiftKey) return false;
|
|
8310
|
+
|
|
8311
|
+
return true;
|
|
8312
|
+
}
|
|
8313
|
+
|
|
8118
8314
|
this.DocOnMouseMove=function(e)
|
|
8119
8315
|
{
|
|
8120
8316
|
//加载数据中,禁用鼠标事件
|
|
@@ -8130,6 +8326,7 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
8130
8326
|
var moveSetpY=Math.abs(drag.LastMove.Y-e.clientY);
|
|
8131
8327
|
var isDragSelectRect=(this.RectSelectDrag && this.RectSelectDrag.Index>=0);
|
|
8132
8328
|
var isDragSubSelectRect=(this.RectSelectDrag && this.RectSelectDrag.Type==4);
|
|
8329
|
+
var bShfitDragKLine=this.IsShfitDragKLine(e); //shift+鼠标移动K线
|
|
8133
8330
|
if (drag.CurrentMove)
|
|
8134
8331
|
{
|
|
8135
8332
|
drag.CurrentMove.X=e.clientX;
|
|
@@ -8237,7 +8434,7 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
8237
8434
|
{
|
|
8238
8435
|
this.OnDragXCoordinateZoom(drag, {X:moveSetp, Y:moveSetpY}, e);
|
|
8239
8436
|
}
|
|
8240
|
-
else if ((bLButtonSelectRect || bRButtonSelectRect) && !isDragSelectRect && !isDragSubSelectRect) //左右键区间选择
|
|
8437
|
+
else if ((bLButtonSelectRect || bRButtonSelectRect) && !isDragSelectRect && !isDragSubSelectRect && !bShfitDragKLine) //左右键区间选择
|
|
8241
8438
|
{
|
|
8242
8439
|
var yMoveSetp=Math.abs(drag.LastMove.Y-e.clientY);
|
|
8243
8440
|
|
|
@@ -8349,6 +8546,9 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
8349
8546
|
var isLeft=true;
|
|
8350
8547
|
if (drag.LastMove.X<e.clientX) isLeft=false;//右移数据
|
|
8351
8548
|
|
|
8549
|
+
//按住shift才能移动K线
|
|
8550
|
+
if (this.KLineDragConfig && this.KLineDragConfig.EnableShfit && !e.shiftKey) return;
|
|
8551
|
+
|
|
8352
8552
|
var cursorStatus="pointer";
|
|
8353
8553
|
var oneStepWidth=this.GetMoveOneStepWidth();
|
|
8354
8554
|
if (moveSetp<oneStepWidth)
|
|
@@ -8446,6 +8646,7 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
8446
8646
|
var isDragSelectRect=(this.RectSelectDrag && this.RectSelectDrag.Index>=0);
|
|
8447
8647
|
var isDragSubSelectRect=(this.RectSelectDrag && this.RectSelectDrag.Type==4);
|
|
8448
8648
|
var bClearDrawPicture=true;
|
|
8649
|
+
var bShfitDragKLine=this.IsShfitDragKLine(e);
|
|
8449
8650
|
if (this.CurrentChartDrawPicture)
|
|
8450
8651
|
{
|
|
8451
8652
|
var drawPicture=this.CurrentChartDrawPicture;
|
|
@@ -8488,7 +8689,7 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
8488
8689
|
{
|
|
8489
8690
|
if (this.OnMinuteSelectRectMouseUp) this.OnMinuteSelectRectMouseUp(e); //分时图区间选择
|
|
8490
8691
|
}
|
|
8491
|
-
else if (bLButtonSelectRect || bRButtonSelectRect) //K线图区间选择
|
|
8692
|
+
else if ((bLButtonSelectRect || bRButtonSelectRect) && !bShfitDragKLine) //K线图区间选择
|
|
8492
8693
|
{
|
|
8493
8694
|
var drag=this.MouseDrag;
|
|
8494
8695
|
drag.LastMove.X=e.clientX;
|
|
@@ -9777,6 +9978,8 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
9777
9978
|
item.Draw();
|
|
9778
9979
|
}
|
|
9779
9980
|
|
|
9981
|
+
this.DrawExtendChartPaint(IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_5);
|
|
9982
|
+
|
|
9780
9983
|
if (this.Frame.DrawOveraly)
|
|
9781
9984
|
this.Frame.DrawOveraly(true); //画叠加指标
|
|
9782
9985
|
|
|
@@ -9800,9 +10003,14 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
9800
10003
|
item.Draw();
|
|
9801
10004
|
}
|
|
9802
10005
|
|
|
10006
|
+
this.DrawExtendChartPaint(IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_8);
|
|
10007
|
+
|
|
9803
10008
|
if (this.Frame.DrawOveraly)
|
|
9804
10009
|
this.Frame.DrawOveraly(false); //画叠加指标
|
|
9805
10010
|
|
|
10011
|
+
this.DrawExtendChartPaint(IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_10);
|
|
10012
|
+
|
|
10013
|
+
/*
|
|
9806
10014
|
//固定扩展图形
|
|
9807
10015
|
for(var i=0;i<this.ExtendChartPaint.length;++i)
|
|
9808
10016
|
{
|
|
@@ -9811,6 +10019,7 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
9811
10019
|
if (item.DrawAfterPicture) continue;
|
|
9812
10020
|
if (!item.IsDynamic && item.IsAnimation==false) item.Draw();
|
|
9813
10021
|
}
|
|
10022
|
+
*/
|
|
9814
10023
|
|
|
9815
10024
|
if (this.Frame.DrawInsideHorizontal) this.Frame.DrawInsideHorizontal();
|
|
9816
10025
|
this.KLineIncreaseCustomHorizontal();
|
|
@@ -9839,6 +10048,10 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
9839
10048
|
|
|
9840
10049
|
var moveonPoint=null;
|
|
9841
10050
|
if (this.LastMouseStatus && this.LastMouseStatus.MoveOnPoint) moveonPoint=this.LastMouseStatus.MoveOnPoint;
|
|
10051
|
+
|
|
10052
|
+
this.DrawExtendChartPaint(IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_20, { MoveonPoint:moveonPoint} );
|
|
10053
|
+
|
|
10054
|
+
/*
|
|
9842
10055
|
for(var i=0;i<this.ExtendChartPaint.length;++i) //动态扩展图形
|
|
9843
10056
|
{
|
|
9844
10057
|
var item=this.ExtendChartPaint[i];
|
|
@@ -9850,6 +10063,7 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
9850
10063
|
if (item.DrawToolbar) item.DrawToolbar(moveonPoint);
|
|
9851
10064
|
}
|
|
9852
10065
|
}
|
|
10066
|
+
*/
|
|
9853
10067
|
|
|
9854
10068
|
for(var i=0;i<this.ChartDrawPicture.length;++i)
|
|
9855
10069
|
{
|
|
@@ -9939,6 +10153,8 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
9939
10153
|
item.Draw(moveonPoint, this.LastMouseStatus);
|
|
9940
10154
|
}
|
|
9941
10155
|
|
|
10156
|
+
this.DrawExtendChartPaint(IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_25);
|
|
10157
|
+
/*
|
|
9942
10158
|
for(var i=0;i<this.ExtendChartPaint.length;++i) //动态扩展图形
|
|
9943
10159
|
{
|
|
9944
10160
|
var item=this.ExtendChartPaint[i];
|
|
@@ -9946,7 +10162,11 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
9946
10162
|
if (item.DrawAfterPicture) continue;
|
|
9947
10163
|
if (item.IsDynamic && item.DrawAfterTitle===true && item.IsAnimation==false) item.Draw();
|
|
9948
10164
|
}
|
|
10165
|
+
*/
|
|
10166
|
+
|
|
10167
|
+
if (this.EnableAnimation) this.DrawExtendChartPaint(IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_30);
|
|
9949
10168
|
|
|
10169
|
+
/*
|
|
9950
10170
|
if (this.EnableAnimation)
|
|
9951
10171
|
{
|
|
9952
10172
|
for(var i=0;i<this.ExtendChartPaint.length;++i) //动画
|
|
@@ -9955,6 +10175,7 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
9955
10175
|
if (item.IsAnimation===true) item.Draw();
|
|
9956
10176
|
}
|
|
9957
10177
|
}
|
|
10178
|
+
*/
|
|
9958
10179
|
|
|
9959
10180
|
for(var i=0;i<this.ChartDrawPicture.length;++i)
|
|
9960
10181
|
{
|
|
@@ -9973,12 +10194,15 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
9973
10194
|
this.CurrentChartDrawPicture.Draw();
|
|
9974
10195
|
}
|
|
9975
10196
|
|
|
10197
|
+
this.DrawExtendChartPaint(IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_50);
|
|
10198
|
+
/*
|
|
9976
10199
|
for(var i=0;i<this.ExtendChartPaint.length;++i) //画图工具绘制完成以后 动态扩展图形
|
|
9977
10200
|
{
|
|
9978
10201
|
var item=this.ExtendChartPaint[i];
|
|
9979
10202
|
if (item.DrawAfterPicture)
|
|
9980
10203
|
item.Draw();
|
|
9981
10204
|
}
|
|
10205
|
+
*/
|
|
9982
10206
|
|
|
9983
10207
|
this.OffscreenToShowCanvas();
|
|
9984
10208
|
|
|
@@ -10007,6 +10231,45 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
10007
10231
|
++this.TouchDrawCount;
|
|
10008
10232
|
}
|
|
10009
10233
|
|
|
10234
|
+
this.DrawExtendChartPaint=function(level, option)
|
|
10235
|
+
{
|
|
10236
|
+
if (!IFrameSplitOperator.IsNonEmptyArray(this.ExtendChartPaint)) return;
|
|
10237
|
+
|
|
10238
|
+
//扩展图形
|
|
10239
|
+
for(var i=0;i<this.ExtendChartPaint.length;++i)
|
|
10240
|
+
{
|
|
10241
|
+
var item=this.ExtendChartPaint[i];
|
|
10242
|
+
if (item.IsCallbackDraw) continue;
|
|
10243
|
+
|
|
10244
|
+
var value=item.GetPriority(); //绘图优先级
|
|
10245
|
+
if (value!=level) continue;
|
|
10246
|
+
|
|
10247
|
+
if (level==IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_20)
|
|
10248
|
+
{
|
|
10249
|
+
item.Draw();
|
|
10250
|
+
if (item.DrawToolbar && option) item.DrawToolbar(option.MoveonPoint, option.LastMouseStatus);
|
|
10251
|
+
}
|
|
10252
|
+
else if (level==IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_25 && option)
|
|
10253
|
+
{
|
|
10254
|
+
if (item.ClassName=='KLineTooltipPaint' && option)
|
|
10255
|
+
{
|
|
10256
|
+
if (option.Tooltip==false) continue;
|
|
10257
|
+
if (option.Point) item.LatestPoint=option.Point;
|
|
10258
|
+
}
|
|
10259
|
+
else if (item.ClassName=="MinuteTooltipPaint" && option)
|
|
10260
|
+
{
|
|
10261
|
+
if (option.Point) item.LatestPoint=option.Point;
|
|
10262
|
+
}
|
|
10263
|
+
|
|
10264
|
+
item.Draw(option.MoveonPoint, option.LastMouseStatus);
|
|
10265
|
+
}
|
|
10266
|
+
else
|
|
10267
|
+
{
|
|
10268
|
+
item.Draw();
|
|
10269
|
+
}
|
|
10270
|
+
}
|
|
10271
|
+
}
|
|
10272
|
+
|
|
10010
10273
|
this.PtInButton=function(x, y)
|
|
10011
10274
|
{
|
|
10012
10275
|
var button=this.Frame.PtInButtons(x,y);
|
|
@@ -10319,6 +10582,10 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
10319
10582
|
|
|
10320
10583
|
var moveonPoint=null;
|
|
10321
10584
|
if (this.LastMouseStatus && this.LastMouseStatus.MoveOnPoint) moveonPoint=this.LastMouseStatus.MoveOnPoint;
|
|
10585
|
+
|
|
10586
|
+
this.DrawExtendChartPaint(IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_20, { MoveonPoint:moveonPoint, LastMouseStatus:this.LastMouseStatus } );
|
|
10587
|
+
|
|
10588
|
+
/*
|
|
10322
10589
|
for(var i=0;i<this.ExtendChartPaint.length;++i) //动态扩展图形
|
|
10323
10590
|
{
|
|
10324
10591
|
var item=this.ExtendChartPaint[i];
|
|
@@ -10330,6 +10597,7 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
10330
10597
|
if (item.DrawToolbar) item.DrawToolbar(moveonPoint, this.LastMouseStatus);
|
|
10331
10598
|
}
|
|
10332
10599
|
}
|
|
10600
|
+
*/
|
|
10333
10601
|
|
|
10334
10602
|
for(var i=0;i<this.ChartDrawPicture.length;++i)
|
|
10335
10603
|
{
|
|
@@ -10428,6 +10696,15 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
10428
10696
|
item.Draw(moveonPoint, this.LastMouseStatus);
|
|
10429
10697
|
}
|
|
10430
10698
|
|
|
10699
|
+
|
|
10700
|
+
var exChartOption={ MoveonPoint:moveonPoint, LastMouseStatus:this.LastMouseStatus };
|
|
10701
|
+
if (option)
|
|
10702
|
+
{
|
|
10703
|
+
exChartOption.Tooltip=option.Tooltip;
|
|
10704
|
+
exChartOption.Point=option.Point;
|
|
10705
|
+
}
|
|
10706
|
+
this.DrawExtendChartPaint(IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_25,exChartOption);
|
|
10707
|
+
/*
|
|
10431
10708
|
for(var i=0;i<this.ExtendChartPaint.length;++i) //动态扩展图形 在动态标题以后画
|
|
10432
10709
|
{
|
|
10433
10710
|
var item=this.ExtendChartPaint[i];
|
|
@@ -10445,7 +10722,10 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
10445
10722
|
|
|
10446
10723
|
if (item.IsDynamic && item.DrawAfterTitle===true) item.Draw(moveonPoint, this.LastMouseStatus);
|
|
10447
10724
|
}
|
|
10725
|
+
*/
|
|
10448
10726
|
|
|
10727
|
+
if (this.EnableAnimation) this.DrawExtendChartPaint(IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_30);
|
|
10728
|
+
/*
|
|
10449
10729
|
if (this.EnableAnimation)
|
|
10450
10730
|
{
|
|
10451
10731
|
for(var i=0;i<this.ExtendChartPaint.length;++i) //动画
|
|
@@ -10454,6 +10734,7 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
10454
10734
|
if (item.IsAnimation===true) item.Draw();
|
|
10455
10735
|
}
|
|
10456
10736
|
}
|
|
10737
|
+
*/
|
|
10457
10738
|
|
|
10458
10739
|
for(var i=0;i<this.ChartDrawPicture.length;++i)
|
|
10459
10740
|
{
|
|
@@ -10475,12 +10756,15 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
10475
10756
|
this.CurrentChartDrawPicture.Draw();
|
|
10476
10757
|
}
|
|
10477
10758
|
|
|
10759
|
+
this.DrawExtendChartPaint(IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_50);
|
|
10760
|
+
/*
|
|
10478
10761
|
for(var i=0;i<this.ExtendChartPaint.length;++i) //动态扩展图形
|
|
10479
10762
|
{
|
|
10480
10763
|
var item=this.ExtendChartPaint[i];
|
|
10481
10764
|
if (item.DrawAfterPicture)
|
|
10482
10765
|
item.Draw();
|
|
10483
10766
|
}
|
|
10767
|
+
*/
|
|
10484
10768
|
|
|
10485
10769
|
if (this.LastMouseStatus.MouseOnToolbar) //工具栏按钮提示信息
|
|
10486
10770
|
{
|
|
@@ -10907,6 +11191,40 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
10907
11191
|
this.UIElement.style.cursor=obj.Cursor;
|
|
10908
11192
|
}
|
|
10909
11193
|
|
|
11194
|
+
this.OnHotKeyDown=function(keyID, e) //热键触发
|
|
11195
|
+
{
|
|
11196
|
+
var item=this.FindHotKey(keyID,e);
|
|
11197
|
+
if (!item) return false;
|
|
11198
|
+
|
|
11199
|
+
this.ExecuteMenuCommand(item.CMD, item.Args);
|
|
11200
|
+
return true;
|
|
11201
|
+
}
|
|
11202
|
+
|
|
11203
|
+
this.FindHotKey=function(keyID, e)
|
|
11204
|
+
{
|
|
11205
|
+
if (!IFrameSplitOperator.IsNonEmptyArray(this.AryHotKey)) return null;
|
|
11206
|
+
|
|
11207
|
+
for(var i=0;i<this.AryHotKey.length;++i)
|
|
11208
|
+
{
|
|
11209
|
+
var item=this.AryHotKey[i];
|
|
11210
|
+
if (keyID==item.KeyID)
|
|
11211
|
+
{
|
|
11212
|
+
//SecondKeyID 1=shiftKey 2=ctrlKey 3=altKey
|
|
11213
|
+
if ((item.SecondKeyID==1 && e.shiftKey) || (item.SecondKeyID==2 && e.ctrlKey) || (item.SecondKeyID==3 && e.altKey))
|
|
11214
|
+
return item;
|
|
11215
|
+
}
|
|
11216
|
+
}
|
|
11217
|
+
|
|
11218
|
+
return null;
|
|
11219
|
+
}
|
|
11220
|
+
|
|
11221
|
+
this.IsHotKey=function(keyID, e)
|
|
11222
|
+
{
|
|
11223
|
+
var item=this.FindHotKey(keyID,e);
|
|
11224
|
+
if (!item) return false;
|
|
11225
|
+
return true;
|
|
11226
|
+
}
|
|
11227
|
+
|
|
10910
11228
|
this.OnKeyDown=function(e)
|
|
10911
11229
|
{
|
|
10912
11230
|
if (this.ChartSplashPaint && this.ChartSplashPaint.IsEnableSplash == true) return;
|
|
@@ -10923,22 +11241,35 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
10923
11241
|
}
|
|
10924
11242
|
|
|
10925
11243
|
var draw=false;
|
|
10926
|
-
if (this.
|
|
11244
|
+
if (keyID==27 && this.PopMinuteChart && this.PopMinuteChart.IsShow())
|
|
11245
|
+
{
|
|
11246
|
+
this.PopMinuteChart.Close();
|
|
11247
|
+
draw=true;
|
|
11248
|
+
}
|
|
11249
|
+
else if (this.ChartCorssCursor && this.ChartCorssCursor.OnKeyDown) //十字光标 隐藏显示
|
|
10927
11250
|
{
|
|
10928
11251
|
var sendData={ e:e, KeyID:keyID, Draw:false, PreventDefault:false };
|
|
10929
11252
|
this.ChartCorssCursor.OnKeyDown(sendData);
|
|
10930
11253
|
draw=sendData.Draw;
|
|
10931
11254
|
}
|
|
10932
11255
|
|
|
11256
|
+
if (this.OnHotKeyDown(keyID, e))
|
|
11257
|
+
{
|
|
11258
|
+
//不让滚动条滚动
|
|
11259
|
+
if(e.preventDefault) e.preventDefault();
|
|
11260
|
+
else e.returnValue = false;
|
|
11261
|
+
return;
|
|
11262
|
+
}
|
|
11263
|
+
|
|
10933
11264
|
switch(keyID)
|
|
10934
11265
|
{
|
|
10935
11266
|
case 37: //left
|
|
10936
|
-
if (e.ctrlKey && this.OnCustomKeyDown)
|
|
11267
|
+
if ((e.ctrlKey||e.shiftKey) && this.OnCustomKeyDown)
|
|
10937
11268
|
{
|
|
10938
11269
|
if (this.OnCustomKeyDown(keyID, e))
|
|
10939
11270
|
break;
|
|
10940
11271
|
}
|
|
10941
|
-
|
|
11272
|
+
|
|
10942
11273
|
if (this.CursorIndex<=0.99999)
|
|
10943
11274
|
{
|
|
10944
11275
|
if (!this.DataMoveLeft())
|
|
@@ -10963,7 +11294,7 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
10963
11294
|
}
|
|
10964
11295
|
break;
|
|
10965
11296
|
case 39: //right
|
|
10966
|
-
if (e.ctrlKey && this.OnCustomKeyDown)
|
|
11297
|
+
if ((e.ctrlKey|| e.shiftKey) && this.OnCustomKeyDown)
|
|
10967
11298
|
{
|
|
10968
11299
|
if (this.OnCustomKeyDown(keyID, e))
|
|
10969
11300
|
break;
|
|
@@ -10999,8 +11330,14 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
10999
11330
|
}
|
|
11000
11331
|
break;
|
|
11001
11332
|
case 38: //up
|
|
11333
|
+
if ((e.ctrlKey||e.shiftKey) && this.OnCustomKeyDown)
|
|
11334
|
+
{
|
|
11335
|
+
if (this.OnCustomKeyDown(keyID, e))
|
|
11336
|
+
break;
|
|
11337
|
+
}
|
|
11002
11338
|
if (this.EnableZoomUpDown && this.EnableZoomUpDown.Keyboard===false) break;
|
|
11003
11339
|
var cursorIndex={ ZoomType:this.ZoomType, IsLockRight:this.IsZoomLockRight };
|
|
11340
|
+
if (e.ctrlKey) cursorIndex.ZoomType=1; //ctrl 十字中心缩放
|
|
11004
11341
|
cursorIndex.Index=parseInt(Math.abs(this.CursorIndex-0.5).toFixed(0));
|
|
11005
11342
|
if (!this.Frame.ZoomUp(cursorIndex)) break;
|
|
11006
11343
|
this.CursorIndex=cursorIndex.Index;
|
|
@@ -11013,8 +11350,14 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
11013
11350
|
this.OnKLinePageChange("keydown");
|
|
11014
11351
|
break;
|
|
11015
11352
|
case 40: //down
|
|
11353
|
+
if ((e.ctrlKey||e.shiftKey) && this.OnCustomKeyDown)
|
|
11354
|
+
{
|
|
11355
|
+
if (this.OnCustomKeyDown(keyID, e))
|
|
11356
|
+
break;
|
|
11357
|
+
}
|
|
11016
11358
|
if (this.EnableZoomUpDown && this.EnableZoomUpDown.Keyboard===false) break;
|
|
11017
11359
|
var cursorIndex={ ZoomType:this.ZoomType ,IsLockRight:this.IsZoomLockRight };
|
|
11360
|
+
if (e.ctrlKey) cursorIndex.ZoomType=1; //ctrl 十字中心缩放
|
|
11018
11361
|
cursorIndex.Index=parseInt(Math.abs(this.CursorIndex-0.5).toFixed(0));
|
|
11019
11362
|
if (!this.Frame.ZoomDown(cursorIndex, { ZoomDownloadDataCallback:(requestData)=>{ this.ZoomDownloadData(requestData) } })) break;
|
|
11020
11363
|
|
|
@@ -11067,6 +11410,9 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
11067
11410
|
this.CurrentChartDrawPicture=null;
|
|
11068
11411
|
}
|
|
11069
11412
|
break;
|
|
11413
|
+
case 13: //回车
|
|
11414
|
+
if (this.OnCustomKeyDown) this.OnCustomKeyDown(keyID, e);
|
|
11415
|
+
break;
|
|
11070
11416
|
default:
|
|
11071
11417
|
return;
|
|
11072
11418
|
}
|
|
@@ -11080,7 +11426,7 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
11080
11426
|
|
|
11081
11427
|
this.OnDoubleClick=function(x,y,e)
|
|
11082
11428
|
{
|
|
11083
|
-
|
|
11429
|
+
|
|
11084
11430
|
}
|
|
11085
11431
|
|
|
11086
11432
|
this.ZoomIndexWindow=function(frameID, option) //最大化/最小化指标窗口
|
|
@@ -13025,6 +13371,43 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
13025
13371
|
return width;
|
|
13026
13372
|
}
|
|
13027
13373
|
|
|
13374
|
+
this.GetChartPaintByClassName=function(name)
|
|
13375
|
+
{
|
|
13376
|
+
var aryData=[];
|
|
13377
|
+
for(var i=0;i<this.ChartPaint.length;++i)
|
|
13378
|
+
{
|
|
13379
|
+
var item=this.ChartPaint[i];
|
|
13380
|
+
if (item.ClassName==name)
|
|
13381
|
+
{
|
|
13382
|
+
var frameID=null;
|
|
13383
|
+
if (item.ChartFrame) frameID=item.ChartFrame.Identify;
|
|
13384
|
+
aryData.push({ IsOverlay:false, Chart:item, FrameID:frameID });
|
|
13385
|
+
}
|
|
13386
|
+
}
|
|
13387
|
+
|
|
13388
|
+
for(var i=0;i<this.Frame.SubFrame.length;++i)
|
|
13389
|
+
{
|
|
13390
|
+
var subItem=this.Frame.SubFrame[i];
|
|
13391
|
+
if (!subItem) continue;
|
|
13392
|
+
if (!IFrameSplitOperator.IsNonEmptyArray(subItem.OverlayIndex)) continue;
|
|
13393
|
+
|
|
13394
|
+
for(var j=0;j<subItem.OverlayIndex.length;++j)
|
|
13395
|
+
{
|
|
13396
|
+
var item=subItem.OverlayIndex[j];
|
|
13397
|
+
for(var k=0;k<item.ChartPaint.length;++k)
|
|
13398
|
+
{
|
|
13399
|
+
var chartItem=item.ChartPaint[k];
|
|
13400
|
+
if (chartItem.ClassName==name)
|
|
13401
|
+
{
|
|
13402
|
+
aryData.push({ IsOverlay:true, Chart:chartItem, FrameID:subItem.Frame.Identify, SubFrameID:j });
|
|
13403
|
+
}
|
|
13404
|
+
}
|
|
13405
|
+
}
|
|
13406
|
+
}
|
|
13407
|
+
|
|
13408
|
+
return aryData;
|
|
13409
|
+
}
|
|
13410
|
+
|
|
13028
13411
|
//删除扩展画法
|
|
13029
13412
|
this.DeleteExtendChart=function(data)
|
|
13030
13413
|
{
|
|
@@ -14399,6 +14782,9 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
14399
14782
|
case JSCHART_MENU_ID.CMD_CORSS_POINT_ID:
|
|
14400
14783
|
if (IFrameSplitOperator.IsBool(srcParam) && this.ChartCorssCursor) this.ChartCorssCursor.CorssPointConfig.Enable=srcParam;
|
|
14401
14784
|
break;
|
|
14785
|
+
case JSCHART_MENU_ID.CMD_CORSS_DBCLICK_ID:
|
|
14786
|
+
if (IFrameSplitOperator.IsBool(srcParam) && this.ChartCorssCursor) this.ChartCorssCursor.EnableDBClick=srcParam;
|
|
14787
|
+
break;
|
|
14402
14788
|
case JSCHART_MENU_ID.CMD_RBUTTON_SELECT_RECT_ID:
|
|
14403
14789
|
if (IFrameSplitOperator.IsBool(srcParam) && this.ChartDragSelectRect) this.ChartDragSelectRect.EnableRButton=srcParam;
|
|
14404
14790
|
break;
|
|
@@ -14408,6 +14794,9 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
14408
14794
|
case JSCHART_MENU_ID.CMD_ENABLE_XDRAG_BOTTOM_ID:
|
|
14409
14795
|
if (IFrameSplitOperator.IsBool(srcParam)) this.EnableXDrag.Bottom=srcParam;
|
|
14410
14796
|
break;
|
|
14797
|
+
case JSCHART_MENU_ID.CMD_FULLSCREEN_SUMMARY_ID:
|
|
14798
|
+
this.FullScreenSummary();
|
|
14799
|
+
break;
|
|
14411
14800
|
}
|
|
14412
14801
|
}
|
|
14413
14802
|
|
|
@@ -14964,6 +15353,63 @@ function JSChartContainer(uielement, OffscreenElement, cacheElement)
|
|
|
14964
15353
|
this.Draw();
|
|
14965
15354
|
}
|
|
14966
15355
|
}
|
|
15356
|
+
|
|
15357
|
+
this.MoveCorssCursorUp=function(step)
|
|
15358
|
+
{
|
|
15359
|
+
if (!IFrameSplitOperator.IsNumber(this.LastPoint.Y)) return;
|
|
15360
|
+
var border=this.Frame.ChartBorder.GetBorder();
|
|
15361
|
+
var top=border.TopEx;
|
|
15362
|
+
if (this.LastPoint.Y-step<=top) return;
|
|
15363
|
+
|
|
15364
|
+
this.LastPoint.Y-=step;
|
|
15365
|
+
this.DrawDynamicInfo();
|
|
15366
|
+
}
|
|
15367
|
+
|
|
15368
|
+
this.MoveCorssCursorDown=function(step)
|
|
15369
|
+
{
|
|
15370
|
+
if (!IFrameSplitOperator.IsNumber(this.LastPoint.Y)) return;
|
|
15371
|
+
var border=this.Frame.ChartBorder.GetBorder();
|
|
15372
|
+
var border=this.Frame.ChartBorder.GetBorder();
|
|
15373
|
+
var bottom=border.BottomEx;
|
|
15374
|
+
if (this.LastPoint.Y+step>=bottom) return;
|
|
15375
|
+
|
|
15376
|
+
this.LastPoint.Y+=step;
|
|
15377
|
+
this.DrawDynamicInfo();
|
|
15378
|
+
}
|
|
15379
|
+
|
|
15380
|
+
//整屏区间统计
|
|
15381
|
+
this.FullScreenSummary=function()
|
|
15382
|
+
{
|
|
15383
|
+
var kData=this.GetKData();
|
|
15384
|
+
if (!kData || !IFrameSplitOperator.IsNonEmptyArray(kData.Data)) return false;
|
|
15385
|
+
|
|
15386
|
+
var paint=this.GetRectSelectPaint();
|
|
15387
|
+
if (!paint) return false;
|
|
15388
|
+
|
|
15389
|
+
var xPointcount=0;
|
|
15390
|
+
if (this.Frame.XPointCount) xPointcount=this.Frame.XPointCount;
|
|
15391
|
+
else xPointcount=this.Frame.SubFrame[0].Frame.XPointCount;
|
|
15392
|
+
if (!IFrameSplitOperator.IsPlusNumber(xPointcount)) return false;
|
|
15393
|
+
|
|
15394
|
+
var startIndex=kData.DataOffset;
|
|
15395
|
+
var endIndex=startIndex+xPointcount;
|
|
15396
|
+
this.UpdateSelectRect(startIndex, endIndex);
|
|
15397
|
+
|
|
15398
|
+
var selectData=paint.GetSelectRectData();
|
|
15399
|
+
var border=this.Frame.SubFrame[0].Frame.GetBorder();
|
|
15400
|
+
|
|
15401
|
+
var data=
|
|
15402
|
+
{
|
|
15403
|
+
X:border.ChartWidth/2, Y:border.ChartHeight/2,
|
|
15404
|
+
SelectData:selectData, //区间选择的数据
|
|
15405
|
+
RectSelectPaint:paint //区间选择背景
|
|
15406
|
+
}
|
|
15407
|
+
|
|
15408
|
+
var e={ data:data };
|
|
15409
|
+
if (this.DialogSelectRect) this.DrawSelectRectDialog(e);
|
|
15410
|
+
|
|
15411
|
+
return true;
|
|
15412
|
+
}
|
|
14967
15413
|
}
|
|
14968
15414
|
|
|
14969
15415
|
function GetDevicePixelRatio()
|
|
@@ -46611,7 +47057,7 @@ function ChartMultiSVGIconV2()
|
|
|
46611
47057
|
if (IFrameSplitOperator.IsString(item.Value)) value=this.GetKValue(kItem,item.Value);
|
|
46612
47058
|
if (!IFrameSplitOperator.IsNumber(value)) continue;
|
|
46613
47059
|
|
|
46614
|
-
var y=this.ChartFrame.GetYFromData(
|
|
47060
|
+
var y=this.ChartFrame.GetYFromData(value,false);
|
|
46615
47061
|
|
|
46616
47062
|
if (item.Image)
|
|
46617
47063
|
{
|
|
@@ -49021,12 +49467,34 @@ function IExtendChartPainting()
|
|
|
49021
49467
|
this.IsCallbackDraw=false; //在回调函数里绘制, 不在Draw()中绘制
|
|
49022
49468
|
this.ID=Guid();
|
|
49023
49469
|
|
|
49470
|
+
this.DrawPriority=null; //绘图优先级
|
|
49471
|
+
|
|
49024
49472
|
//上下左右间距
|
|
49025
49473
|
this.Left=5;
|
|
49026
49474
|
this.Right=5;
|
|
49027
49475
|
this.Top=5;
|
|
49028
49476
|
this.Bottom=5;
|
|
49029
49477
|
|
|
49478
|
+
|
|
49479
|
+
this.GetPriority=function()
|
|
49480
|
+
{
|
|
49481
|
+
if (IFrameSplitOperator.IsNumber(this.DrawPriority)) return this.DrawPriority; //新版本
|
|
49482
|
+
|
|
49483
|
+
//老版本转换
|
|
49484
|
+
|
|
49485
|
+
if (!this.IsDynamic && !this.DrawAfterPicture) return IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_10;
|
|
49486
|
+
|
|
49487
|
+
if (this.DrawAfterTitle===false && this.IsAnimation==false) return IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_20;
|
|
49488
|
+
|
|
49489
|
+
if (this.DrawAfterTitle===true) return IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_25;
|
|
49490
|
+
|
|
49491
|
+
if (this.IsAnimation===true) return IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_35;
|
|
49492
|
+
|
|
49493
|
+
if (this.DrawAfterPicture===true) IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_50;
|
|
49494
|
+
|
|
49495
|
+
return IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_50
|
|
49496
|
+
}
|
|
49497
|
+
|
|
49030
49498
|
this.Draw=function()
|
|
49031
49499
|
{
|
|
49032
49500
|
|
|
@@ -49063,6 +49531,23 @@ function IExtendChartPainting()
|
|
|
49063
49531
|
}
|
|
49064
49532
|
}
|
|
49065
49533
|
|
|
49534
|
+
//绘图优先级
|
|
49535
|
+
IExtendChartPainting.DRAW_PRIORITY_ID=
|
|
49536
|
+
{
|
|
49537
|
+
LEVEL_1:1,
|
|
49538
|
+
LEVEL_5:5, // 叠加指数图形前面 指标图形 IsDrawFirst=true
|
|
49539
|
+
LEVEL_8:8, // 叠加指数图形前面 指标图形 IsDrawFirst=false
|
|
49540
|
+
LEVEL_10:10, // IsDynamic=false
|
|
49541
|
+
|
|
49542
|
+
LEVEL_20:20, // IsDynamic=true
|
|
49543
|
+
|
|
49544
|
+
LEVEL_25:25, // DrawAfterTitle=true 标题栏绘制完成以后
|
|
49545
|
+
|
|
49546
|
+
LEVEL_35:35, // IsAnimation=true
|
|
49547
|
+
|
|
49548
|
+
LEVEL_50:50, // DrawAfterPicture=true; 是否在画图工具以后绘制
|
|
49549
|
+
}
|
|
49550
|
+
|
|
49066
49551
|
//K线Tooltip, 显示在左边或右边
|
|
49067
49552
|
function KLineTooltipPaint()
|
|
49068
49553
|
{
|
|
@@ -49082,6 +49567,7 @@ function KLineTooltipPaint()
|
|
|
49082
49567
|
this.AmountColor=g_JSChartResource.TooltipPaint.AmountColor; //成交金额
|
|
49083
49568
|
this.LatestPoint; //手势位置
|
|
49084
49569
|
this.ShowPosition=0; //显示位置 0=左 1=右
|
|
49570
|
+
this.DrawPriority=IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_25;
|
|
49085
49571
|
|
|
49086
49572
|
this.Left=1*GetDevicePixelRatio();
|
|
49087
49573
|
this.Top=5*GetDevicePixelRatio();
|
|
@@ -49825,6 +50311,7 @@ function MinuteLeftTooltipPaint()
|
|
|
49825
50311
|
this.IsDynamic=true;
|
|
49826
50312
|
this.IsEraseBG=true;
|
|
49827
50313
|
this.DrawAfterTitle=true;
|
|
50314
|
+
this.DrawPriority=IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_25;
|
|
49828
50315
|
this.ClassName='MinuteLeftTooltipPaint';
|
|
49829
50316
|
this.BorderColor=g_JSChartResource.PCTooltipPaint.BorderColor; //边框颜色
|
|
49830
50317
|
this.BGColor=g_JSChartResource.PCTooltipPaint.BGColor; //背景色
|
|
@@ -50235,6 +50722,7 @@ function StockChip()
|
|
|
50235
50722
|
this.PixelRatio=GetDevicePixelRatio();
|
|
50236
50723
|
this.ShowType=0; //0=所有筹码 1=周期前 2=周期内
|
|
50237
50724
|
this.IsDynamic=true;
|
|
50725
|
+
this.DrawPriority=IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_20;
|
|
50238
50726
|
this.ClientRect={};
|
|
50239
50727
|
this.Font=g_JSChartResource.StockChip.Font;
|
|
50240
50728
|
this.InfoColor=g_JSChartResource.StockChip.InfoColor;
|
|
@@ -53914,6 +54402,7 @@ function FrameButtomToolbarPaint()
|
|
|
53914
54402
|
this.FrameGuid=null;
|
|
53915
54403
|
this.IsDynamic=true;
|
|
53916
54404
|
this.DrawAfterTitle=true;
|
|
54405
|
+
this.DrawPriority=IExtendChartPainting.DRAW_PRIORITY_ID.LEVEL_25;
|
|
53917
54406
|
|
|
53918
54407
|
this.AryButton=[]; // { Title:, ID:, Data:数据, TooltipText:提示信息 }
|
|
53919
54408
|
this.SelectedID=null; // 选中按钮ID
|
|
@@ -58059,6 +58548,7 @@ function ChartCorssCursor()
|
|
|
58059
58548
|
this.CallAcutionXOperator;
|
|
58060
58549
|
|
|
58061
58550
|
this.EnableKeyboard=false; //是否支持键盘隐藏显示
|
|
58551
|
+
this.EnableDBClick=false; //是否允许双击显示|隐藏十字光标
|
|
58062
58552
|
this.OnChangeStatusCallback; //状态切换以后回调
|
|
58063
58553
|
|
|
58064
58554
|
|
|
@@ -59287,6 +59777,27 @@ function ChartCorssCursor()
|
|
|
59287
59777
|
}
|
|
59288
59778
|
}
|
|
59289
59779
|
|
|
59780
|
+
this.OnDBClick=function(data)
|
|
59781
|
+
{
|
|
59782
|
+
if (!this.EnableDBClick) return;
|
|
59783
|
+
if (!IFrameSplitOperator.IsNonEmptyArray(this.Frame.SubFrame)) return;
|
|
59784
|
+
|
|
59785
|
+
//在主图框架内
|
|
59786
|
+
var frame=this.Frame.SubFrame[0].Frame;
|
|
59787
|
+
if (!frame) return;
|
|
59788
|
+
|
|
59789
|
+
var border=frame.GetBorder();
|
|
59790
|
+
var rtClient={ Left:border.Left, Top:border.Top, Bottom:border.Bottom, Right:border.Right };
|
|
59791
|
+
var x=data.X, y=data.Y;
|
|
59792
|
+
if (x>=rtClient.Left && x<=rtClient.Right && y>=rtClient.Top && y<=rtClient.Bottom)
|
|
59793
|
+
{
|
|
59794
|
+
this.IsShowCorss=!this.IsShowCorss
|
|
59795
|
+
data.Draw=true;
|
|
59796
|
+
|
|
59797
|
+
if (this.OnChangeStatusCallback) this.OnChangeStatusCallback({ Type:1, IsShowCorss:this.IsShowCorss }, this);
|
|
59798
|
+
}
|
|
59799
|
+
}
|
|
59800
|
+
|
|
59290
59801
|
|
|
59291
59802
|
this.DrawCorssPoint=function(x,y)
|
|
59292
59803
|
{
|
|
@@ -80046,7 +80557,8 @@ function KLineChartContainer(uielement,OffscreenElement, cacheElement)
|
|
|
80046
80557
|
this.ChartDrawStorageCache=null; //首次需要创建的画图工具数据
|
|
80047
80558
|
this.RightSpaceCount=0; //右侧空白个数
|
|
80048
80559
|
this.SourceDataLimit=new Map(); //每个周期缓存数据最大个数 key=周期 value=最大个数
|
|
80049
|
-
this.CtrlMoveStep=5; //Ctrl+(Left/Right) 移动数据个数
|
|
80560
|
+
this.CtrlMoveStep=5; //Ctrl+(Left/Right) 移动数据个数
|
|
80561
|
+
this.ShiftMoveStep=1; //Shift+(Left/Right) 移动K线
|
|
80050
80562
|
|
|
80051
80563
|
this.CustomShow=null; //首先显示的K线的起始日期 { Date:日期, Time:时间, PageSize:, Callback:, Position:0=left 1=center }
|
|
80052
80564
|
this.ZoomType=0; //缩放模式 0=最右边固定缩放, 1=十字光标两边缩放
|
|
@@ -80100,6 +80612,15 @@ function KLineChartContainer(uielement,OffscreenElement, cacheElement)
|
|
|
80100
80612
|
this.ScrollBar=null; //横向滚动条
|
|
80101
80613
|
this.IsAutoSyncDataOffset=true; //增量更新时,是否移动当前屏数据
|
|
80102
80614
|
|
|
80615
|
+
//热键
|
|
80616
|
+
this.AryHotKey=
|
|
80617
|
+
[
|
|
80618
|
+
//SecondKeyID 1=shiftKey 2=ctrlKey 3=altKey
|
|
80619
|
+
{ KeyID:87, SecondKeyID:3, CMD:JSCHART_MENU_ID.CMD_FULLSCREEN_SUMMARY_ID, Args:null, Description:"Alt+W 全屏区间统计" },
|
|
80620
|
+
]
|
|
80621
|
+
|
|
80622
|
+
this.KLineDragConfig={ EnableShfit:false }; //是否启动Shift+鼠标拖动K线
|
|
80623
|
+
|
|
80103
80624
|
this.GetKLineCalulate=function()
|
|
80104
80625
|
{
|
|
80105
80626
|
var kLineDrawType=this.GetKLineDrawType();
|
|
@@ -81137,7 +81658,9 @@ function KLineChartContainer(uielement,OffscreenElement, cacheElement)
|
|
|
81137
81658
|
this.PopMinuteChart.Show({ Date:date, Symbol:symbol, Data:data.Tooltip.Data, Chart:data.Tooltip.ChartPaint }, x/pixelRatio,y/pixelRatio);
|
|
81138
81659
|
}
|
|
81139
81660
|
|
|
81140
|
-
|
|
81661
|
+
//Alt+W 区间统计
|
|
81662
|
+
//Alt+数字 切换多个窗口
|
|
81663
|
+
//Ctrl+I
|
|
81141
81664
|
this.OnCustomKeyDown=function(keyID, e) //自定义键盘事件
|
|
81142
81665
|
{
|
|
81143
81666
|
if (keyID==37 && e.ctrlKey) //Ctrl+Left
|
|
@@ -81150,12 +81673,93 @@ function KLineChartContainer(uielement,OffscreenElement, cacheElement)
|
|
|
81150
81673
|
this.MoveCorssCursorRight(this.CtrlMoveStep);
|
|
81151
81674
|
return true;
|
|
81152
81675
|
}
|
|
81676
|
+
else if (keyID==37 && e.shiftKey) //shift+Left 移动K线
|
|
81677
|
+
{
|
|
81678
|
+
this.MoveKLineLeft(this.ShiftMoveStep);
|
|
81679
|
+
return true;
|
|
81680
|
+
}
|
|
81681
|
+
else if (keyID==39 && e.shiftKey) //shift+Right 移动K线
|
|
81682
|
+
{
|
|
81683
|
+
this.MoveKLineRight(this.ShiftMoveStep);
|
|
81684
|
+
return true;
|
|
81685
|
+
}
|
|
81686
|
+
else if (keyID==38 && e.shiftKey) //shift+up 上移十字光标
|
|
81687
|
+
{
|
|
81688
|
+
this.MoveCorssCursorUp(this.ShiftUpDownStepPixel);
|
|
81689
|
+
return true;
|
|
81690
|
+
}
|
|
81691
|
+
else if (keyID==40 && e.shiftKey) //shift+down 下移十字光标
|
|
81692
|
+
{
|
|
81693
|
+
this.MoveCorssCursorDown(this.ShiftUpDownStepPixel);
|
|
81694
|
+
return true;
|
|
81695
|
+
}
|
|
81696
|
+
else if (keyID==13) //回车显示分时图
|
|
81697
|
+
{
|
|
81698
|
+
this.OnEnterKeyDown();
|
|
81699
|
+
}
|
|
81153
81700
|
else
|
|
81154
81701
|
{
|
|
81155
81702
|
return false;
|
|
81156
81703
|
}
|
|
81157
81704
|
}
|
|
81158
81705
|
|
|
81706
|
+
this.MoveKLineLeft=function(value)
|
|
81707
|
+
{
|
|
81708
|
+
return this.MoveKLine(-value);
|
|
81709
|
+
}
|
|
81710
|
+
|
|
81711
|
+
this.MoveKLineRight=function(value)
|
|
81712
|
+
{
|
|
81713
|
+
return this.MoveKLine(value);
|
|
81714
|
+
}
|
|
81715
|
+
|
|
81716
|
+
this.MoveKLine=function(step)
|
|
81717
|
+
{
|
|
81718
|
+
if (step==0) return;
|
|
81719
|
+
|
|
81720
|
+
var oneStepWidth=this.GetMoveOneStepWidth();
|
|
81721
|
+
var moveSetp=step*oneStepWidth;
|
|
81722
|
+
var bLeft=true;
|
|
81723
|
+
if (step<0)
|
|
81724
|
+
{
|
|
81725
|
+
moveSetp=Math.abs(step)*oneStepWidth;
|
|
81726
|
+
bLeft=false;
|
|
81727
|
+
}
|
|
81728
|
+
|
|
81729
|
+
if(!this.DataMove(moveSetp,bLeft)) return;
|
|
81730
|
+
|
|
81731
|
+
this.UpdataDataoffset();
|
|
81732
|
+
this.RepairCursorIndex();
|
|
81733
|
+
this.UpdatePointByCursorIndex(); //推拽数据的时候不需要把鼠标位置更新到K线上
|
|
81734
|
+
this.UpdateFrameMaxMin();
|
|
81735
|
+
this.ResetFrameXYSplit();
|
|
81736
|
+
this.Draw();
|
|
81737
|
+
this.ShowTooltipByKeyDown();
|
|
81738
|
+
this.OnKLinePageChange("datamove");
|
|
81739
|
+
}
|
|
81740
|
+
|
|
81741
|
+
//修复 当前数据索引大于数据个数的请求
|
|
81742
|
+
this.RepairCursorIndex=function()
|
|
81743
|
+
{
|
|
81744
|
+
var kData=this.GetKData();
|
|
81745
|
+
if (!kData) return;
|
|
81746
|
+
|
|
81747
|
+
var xPointcount=0;
|
|
81748
|
+
if (this.Frame.XPointCount) xPointcount=this.Frame.XPointCount;
|
|
81749
|
+
else xPointcount=this.Frame.SubFrame[0].Frame.XPointCount;
|
|
81750
|
+
if (!IFrameSplitOperator.IsPlusNumber(xPointcount)) return;
|
|
81751
|
+
|
|
81752
|
+
if (this.CursorIndex<0) this.CursorIndex=0;
|
|
81753
|
+
|
|
81754
|
+
var index=this.CursorIndex;
|
|
81755
|
+
index=parseInt(index.toFixed(0));
|
|
81756
|
+
|
|
81757
|
+
if (index+kData.DataOffset>=kData.Data.length)
|
|
81758
|
+
{
|
|
81759
|
+
this.CursorIndex=kData.Data.length-1-kData.DataOffset;
|
|
81760
|
+
}
|
|
81761
|
+
}
|
|
81762
|
+
|
|
81159
81763
|
this.MoveCorssCursorLeft=function(step)
|
|
81160
81764
|
{
|
|
81161
81765
|
var data=null;
|
|
@@ -81232,6 +81836,30 @@ function KLineChartContainer(uielement,OffscreenElement, cacheElement)
|
|
|
81232
81836
|
this.ShowTooltipByKeyDown();
|
|
81233
81837
|
}
|
|
81234
81838
|
|
|
81839
|
+
this.OnEnterKeyDown=function()
|
|
81840
|
+
{
|
|
81841
|
+
if (!this.PopMinuteChart) return false;
|
|
81842
|
+
if (!ChartData.IsDayPeriod(this.Period,true)) return false; //只支持日K
|
|
81843
|
+
if (!this.ChartCorssCursor || !this.ChartCorssCursor.IsShowCorss || this.ChartCorssCursor.ClientPos<0) return false;
|
|
81844
|
+
var index=this.ChartCorssCursor.CursorIndex;
|
|
81845
|
+
index=parseInt(index.toFixed(0));
|
|
81846
|
+
var kData=this.GetKData();
|
|
81847
|
+
if (!kData || !IFrameSplitOperator.IsNonEmptyArray(kData.Data)) return false;
|
|
81848
|
+
var dataIndex=kData.DataOffset+index;
|
|
81849
|
+
if (dataIndex<0 || dataIndex>=kData.Data.length) return false;
|
|
81850
|
+
|
|
81851
|
+
var kItem = kData.Data[dataIndex];
|
|
81852
|
+
if (!kItem) return false;
|
|
81853
|
+
|
|
81854
|
+
var frame=this.Frame.SubFrame[0].Frame;
|
|
81855
|
+
var x=frame.GetXFromIndex(index);
|
|
81856
|
+
var y=frame.GetYFromData(kItem.Close);
|
|
81857
|
+
|
|
81858
|
+
var data={ Chart:this, Tooltip:{ ChartPaint:this.ChartPaint[0], Data:kItem } };
|
|
81859
|
+
|
|
81860
|
+
this.ShowMinuteChartDialog(data, x, y);
|
|
81861
|
+
}
|
|
81862
|
+
|
|
81235
81863
|
//获取K线图实例
|
|
81236
81864
|
this.GetKLineChart=function()
|
|
81237
81865
|
{
|
|
@@ -85989,12 +86617,14 @@ function KLineChartContainer(uielement,OffscreenElement, cacheElement)
|
|
|
85989
86617
|
var bCorssDrawKLine=false;
|
|
85990
86618
|
var bCorssDrawVaildTime=false;
|
|
85991
86619
|
var bCorssDrawPoint=false;
|
|
86620
|
+
var bCorssBCClick=false;
|
|
85992
86621
|
if (this.ChartCorssCursor)
|
|
85993
86622
|
{
|
|
85994
86623
|
bShowCorss=this.ChartCorssCursor.IsShowCorss;
|
|
85995
86624
|
bCorssDrawKLine=this.ChartCorssCursor.IsOnlyDrawKLine && this.ChartCorssCursor.IsShowClose;
|
|
85996
86625
|
bCorssDrawVaildTime=this.ChartCorssCursor.IsFixXLastTime;
|
|
85997
86626
|
bCorssDrawPoint=this.ChartCorssCursor.CorssPointConfig.Enable;
|
|
86627
|
+
bCorssBCClick=this.ChartCorssCursor.EnableDBClick;
|
|
85998
86628
|
}
|
|
85999
86629
|
|
|
86000
86630
|
var bPopMinuteChart=false;
|
|
@@ -86180,6 +86810,7 @@ function KLineChartContainer(uielement,OffscreenElement, cacheElement)
|
|
|
86180
86810
|
{ Name:"显示在K线上", Data:{ ID:JSCHART_MENU_ID.CMD_CORSS_ON_KLINE_ID, Args:[!bCorssDrawKLine]}, Checked:bCorssDrawKLine },
|
|
86181
86811
|
{ Name:"画在有效X轴上",Data:{ ID:JSCHART_MENU_ID.CMD_CORSS_ON_VAILD_TIME_ID, Args:[!bCorssDrawVaildTime]}, Checked:bCorssDrawVaildTime },
|
|
86182
86812
|
{ Name:"画圆点",Data:{ ID:JSCHART_MENU_ID.CMD_CORSS_POINT_ID, Args:[!bCorssDrawPoint]}, Checked:bCorssDrawPoint },
|
|
86813
|
+
{ Name:"双击显示/隐藏", Data:{ ID:JSCHART_MENU_ID.CMD_CORSS_DBCLICK_ID, Args:[!bCorssBCClick]}, Checked:bCorssBCClick },
|
|
86183
86814
|
]
|
|
86184
86815
|
},
|
|
86185
86816
|
{
|
|
@@ -86653,6 +87284,14 @@ function KLineChartContainer(uielement,OffscreenElement, cacheElement)
|
|
|
86653
87284
|
|
|
86654
87285
|
this.OnDoubleClick=function(x,y,e)
|
|
86655
87286
|
{
|
|
87287
|
+
var bDraw=false;
|
|
87288
|
+
if (this.ChartCorssCursor)
|
|
87289
|
+
{
|
|
87290
|
+
var data={ e:e, X:x, Y:y, Draw:false };
|
|
87291
|
+
this.ChartCorssCursor.OnDBClick(data);
|
|
87292
|
+
bDraw=data.Draw
|
|
87293
|
+
}
|
|
87294
|
+
|
|
86656
87295
|
if (this.EnableYDrag && (this.EnableYDrag.Left || this.EnableYDrag.Right) && this.Frame && this.Frame.PtInFrameY)
|
|
86657
87296
|
{
|
|
86658
87297
|
var pixelTatio = GetDevicePixelRatio();
|
|
@@ -86689,6 +87328,8 @@ function KLineChartContainer(uielement,OffscreenElement, cacheElement)
|
|
|
86689
87328
|
}
|
|
86690
87329
|
}
|
|
86691
87330
|
|
|
87331
|
+
if (bDraw) this.Draw();
|
|
87332
|
+
|
|
86692
87333
|
var tooltip=new TooltipData();
|
|
86693
87334
|
if (!this.PtInChartPaintTooltip(x,y,tooltip))
|
|
86694
87335
|
{
|
|
@@ -88475,6 +89116,13 @@ function MinuteChartContainer(uielement,offscreenElement,cacheElement)
|
|
|
88475
89116
|
this.BaselineType=0; //基准线类型 0=最新昨收盘 1=多日前昨收盘
|
|
88476
89117
|
this.EnableNightDayBG=false; //是否启动夜盘背景色
|
|
88477
89118
|
|
|
89119
|
+
//热键
|
|
89120
|
+
this.AryHotKey=
|
|
89121
|
+
[
|
|
89122
|
+
//SecondKeyID 1=shiftKey 2=ctrlKey 3=altKey
|
|
89123
|
+
{ KeyID:87, SecondKeyID:3, CMD:JSCHART_MENU_ID.CMD_FULLSCREEN_SUMMARY_ID, Args:null, Description:"Alt+W 全屏区间统计" },
|
|
89124
|
+
]
|
|
89125
|
+
|
|
88478
89126
|
//集合竞价设置 obj={ Left:true/false, Right:true/false, MultiDay:{Left:, Right:} }
|
|
88479
89127
|
this.SetCallCationDataBorder=function(obj)
|
|
88480
89128
|
{
|
|
@@ -89979,6 +90627,14 @@ function MinuteChartContainer(uielement,offscreenElement,cacheElement)
|
|
|
89979
90627
|
draw=sendData.Draw;
|
|
89980
90628
|
}
|
|
89981
90629
|
|
|
90630
|
+
if (this.OnHotKeyDown(keyID, e))
|
|
90631
|
+
{
|
|
90632
|
+
//不让滚动条滚动
|
|
90633
|
+
if(e.preventDefault) e.preventDefault();
|
|
90634
|
+
else e.returnValue = false;
|
|
90635
|
+
return;
|
|
90636
|
+
}
|
|
90637
|
+
|
|
89982
90638
|
switch(keyID)
|
|
89983
90639
|
{
|
|
89984
90640
|
case 37: //left
|
|
@@ -90092,6 +90748,11 @@ function MinuteChartContainer(uielement,offscreenElement,cacheElement)
|
|
|
90092
90748
|
this.CurrentChartDrawPicture=null;
|
|
90093
90749
|
}
|
|
90094
90750
|
break;
|
|
90751
|
+
case 38:
|
|
90752
|
+
case 40:
|
|
90753
|
+
if ((e.ctrlKey||e.shiftKey) && this.OnCustomKeyDown)
|
|
90754
|
+
this.OnCustomKeyDown(keyID, e)
|
|
90755
|
+
break;
|
|
90095
90756
|
default:
|
|
90096
90757
|
return;
|
|
90097
90758
|
}
|
|
@@ -90103,6 +90764,24 @@ function MinuteChartContainer(uielement,offscreenElement,cacheElement)
|
|
|
90103
90764
|
else e.returnValue = false;
|
|
90104
90765
|
}
|
|
90105
90766
|
|
|
90767
|
+
this.OnCustomKeyDown=function(keyID, e) //自定义键盘事件
|
|
90768
|
+
{
|
|
90769
|
+
if (keyID==38 && e.shiftKey) //shift+up 上移十字光标
|
|
90770
|
+
{
|
|
90771
|
+
this.MoveCorssCursorUp(this.ShiftUpDownStepPixel);
|
|
90772
|
+
return true;
|
|
90773
|
+
}
|
|
90774
|
+
else if (keyID==40 && e.shiftKey) //shift+down 下移十字光标
|
|
90775
|
+
{
|
|
90776
|
+
this.MoveCorssCursorDown(this.ShiftUpDownStepPixel);
|
|
90777
|
+
return true;
|
|
90778
|
+
}
|
|
90779
|
+
else
|
|
90780
|
+
{
|
|
90781
|
+
return false;
|
|
90782
|
+
}
|
|
90783
|
+
}
|
|
90784
|
+
|
|
90106
90785
|
/*
|
|
90107
90786
|
this.OnMarkRectSelect=function(e)
|
|
90108
90787
|
{
|
|
@@ -90212,12 +90891,14 @@ function MinuteChartContainer(uielement,offscreenElement,cacheElement)
|
|
|
90212
90891
|
var bCorssDrawCloseLine=false; //十字光标只能画在走势图价格线上
|
|
90213
90892
|
var bCorssDrawVaildTime=false;
|
|
90214
90893
|
var bCorssDrawPoint=false;
|
|
90894
|
+
var bCorssBCClick=false;
|
|
90215
90895
|
if (this.ChartCorssCursor)
|
|
90216
90896
|
{
|
|
90217
90897
|
bShowCorss=this.ChartCorssCursor.IsShowCorss;
|
|
90218
90898
|
bCorssDrawCloseLine=this.ChartCorssCursor.IsOnlyDrawMinute;
|
|
90219
90899
|
bCorssDrawVaildTime=this.ChartCorssCursor.IsFixXLastTime;
|
|
90220
90900
|
bCorssDrawPoint=this.ChartCorssCursor.CorssPointConfig.Enable;
|
|
90901
|
+
bCorssBCClick=this.ChartCorssCursor.EnableDBClick;
|
|
90221
90902
|
}
|
|
90222
90903
|
|
|
90223
90904
|
var bRButtonSelectRect=false,bLButtonSelectRect=false;
|
|
@@ -90314,6 +90995,7 @@ function MinuteChartContainer(uielement,offscreenElement,cacheElement)
|
|
|
90314
90995
|
{ Name:"画在价格线上", Data:{ ID:JSCHART_MENU_ID.CMD_CORSS_ON_CLOSE_LINE_ID, Args:[!bCorssDrawCloseLine]}, Checked:bCorssDrawCloseLine },
|
|
90315
90996
|
{ Name:"画在有效X轴上",Data:{ ID:JSCHART_MENU_ID.CMD_CORSS_ON_VAILD_TIME_ID, Args:[!bCorssDrawVaildTime]}, Checked:bCorssDrawVaildTime },
|
|
90316
90997
|
{ Name:"画圆点",Data:{ ID:JSCHART_MENU_ID.CMD_CORSS_POINT_ID, Args:[!bCorssDrawPoint]}, Checked:bCorssDrawPoint },
|
|
90998
|
+
{ Name:"双击显示/隐藏", Data:{ ID:JSCHART_MENU_ID.CMD_CORSS_DBCLICK_ID, Args:[!bCorssBCClick]}, Checked:bCorssBCClick },
|
|
90317
90999
|
]
|
|
90318
91000
|
},
|
|
90319
91001
|
|
|
@@ -90454,6 +91136,14 @@ function MinuteChartContainer(uielement,offscreenElement,cacheElement)
|
|
|
90454
91136
|
{
|
|
90455
91137
|
JSConsole.Chart.Log("[MinuteChartContainer::OnDoubleClick]", e);
|
|
90456
91138
|
|
|
91139
|
+
var bDraw=false;
|
|
91140
|
+
if (this.ChartCorssCursor)
|
|
91141
|
+
{
|
|
91142
|
+
var data={ e:e, X:x, Y:y, Draw:false };
|
|
91143
|
+
this.ChartCorssCursor.OnDBClick(data);
|
|
91144
|
+
bDraw=data.Draw
|
|
91145
|
+
}
|
|
91146
|
+
|
|
90457
91147
|
if (this.EnableYDrag && (this.EnableYDrag.Left || this.EnableYDrag.Right) && this.Frame && this.Frame.PtInFrameY)
|
|
90458
91148
|
{
|
|
90459
91149
|
var pixelTatio = GetDevicePixelRatio();
|
|
@@ -90491,10 +91181,12 @@ function MinuteChartContainer(uielement,offscreenElement,cacheElement)
|
|
|
90491
91181
|
if (this.ZoomIndexWindow(frameId, {X:x, Y:y}))
|
|
90492
91182
|
{
|
|
90493
91183
|
this.Frame.SetSizeChage(true);
|
|
90494
|
-
|
|
91184
|
+
bDraw=true;
|
|
90495
91185
|
}
|
|
90496
91186
|
}
|
|
90497
91187
|
}
|
|
91188
|
+
|
|
91189
|
+
if (bDraw) this.Draw();
|
|
90498
91190
|
}
|
|
90499
91191
|
|
|
90500
91192
|
this.GetDataItem=function(pointInfo)
|
|
@@ -104150,7 +104842,7 @@ function Node(ErrorHandler)
|
|
|
104150
104842
|
//CAPITAL流通股本(手), EXCHANGE 换手率, TOTALCAPITAL 总股本(手)
|
|
104151
104843
|
let setVariantName=new Set(
|
|
104152
104844
|
[
|
|
104153
|
-
"CAPITAL","TOTALCAPITAL","EXCHANGE",
|
|
104845
|
+
"CAPITAL","TOTALCAPITAL","EXCHANGE","HSL",
|
|
104154
104846
|
"HYBLOCK","DYBLOCK","GNBLOCK","FGBLOCK","ZSBLOCK","ZHBLOCK","ZDBLOCK","HYZSCODE",
|
|
104155
104847
|
"GNBLOCKNUM","FGBLOCKNUM","ZSBLOCKNUM","ZHBLOCKNUM","ZDBLOCKNUM",
|
|
104156
104848
|
"HYSYL","HYSJL","FROMOPEN",
|
|
@@ -117694,7 +118386,7 @@ function JSSymbolData(ast,option,jsExecute)
|
|
|
117694
118386
|
{
|
|
117695
118387
|
var dataType=0;
|
|
117696
118388
|
if (IFrameSplitOperator.IsNumber(recvData.DataType)) dataType=recvData.DataType;
|
|
117697
|
-
self.RecvStockValue(recvData.Data,jobItem,key,dataType);
|
|
118389
|
+
self.RecvStockValue(recvData.Data,jobItem,key,dataType,recvData);
|
|
117698
118390
|
}
|
|
117699
118391
|
|
|
117700
118392
|
self.Execute.RunNextJob();
|
|
@@ -117709,7 +118401,7 @@ function JSSymbolData(ast,option,jsExecute)
|
|
|
117709
118401
|
};
|
|
117710
118402
|
|
|
117711
118403
|
var apiDownload;
|
|
117712
|
-
if (jobItem.VariantName=="CAPITAL" || jobItem.VariantName=="TOTALCAPITAL" || jobItem.VariantName=="EXCHANGE")
|
|
118404
|
+
if (jobItem.VariantName=="CAPITAL" || jobItem.VariantName=="TOTALCAPITAL" || jobItem.VariantName=="EXCHANGE" || jobItem.VariantName=="HSL")
|
|
117713
118405
|
{
|
|
117714
118406
|
var callback=function(recvData, jobItem, key)
|
|
117715
118407
|
{
|
|
@@ -117904,7 +118596,7 @@ function JSSymbolData(ast,option,jsExecute)
|
|
|
117904
118596
|
}
|
|
117905
118597
|
}
|
|
117906
118598
|
|
|
117907
|
-
this.RecvStockValue=function(recvData,jobItem,key,dataType)
|
|
118599
|
+
this.RecvStockValue=function(recvData,jobItem,key,dataType, srcData)
|
|
117908
118600
|
{
|
|
117909
118601
|
if (!recvData)
|
|
117910
118602
|
{
|
|
@@ -117935,8 +118627,9 @@ function JSSymbolData(ast,option,jsExecute)
|
|
|
117935
118627
|
var bindData=new ChartData();
|
|
117936
118628
|
bindData.Data=aryFittingData;
|
|
117937
118629
|
var result=bindData.GetValue();
|
|
118630
|
+
var bVersion2=srcData && srcData.Ver==2; //2.0 版本
|
|
117938
118631
|
|
|
117939
|
-
if (key=="EXCHANGE") //计算换手率=成交量/流通股本*100
|
|
118632
|
+
if (!bVersion2 && (key=="EXCHANGE" || key=="HSL")) //计算换手率=成交量/流通股本*100
|
|
117940
118633
|
{
|
|
117941
118634
|
for(var i in result)
|
|
117942
118635
|
{
|
|
@@ -119956,7 +120649,7 @@ function JSExecute(ast,option)
|
|
|
119956
120649
|
|
|
119957
120650
|
['CAPITAL',null], //流通股本(手)
|
|
119958
120651
|
["TOTALCAPITAL",null], //TOTALCAPITAL 当前总股本 手
|
|
119959
|
-
['EXCHANGE',null], //换手率
|
|
120652
|
+
['EXCHANGE',null], ["HSL",null], //换手率
|
|
119960
120653
|
['SETCODE', null], //市场类型
|
|
119961
120654
|
['CODE',null], //品种代码
|
|
119962
120655
|
['STKNAME',null], //品种名称
|
|
@@ -120206,6 +120899,7 @@ function JSExecute(ast,option)
|
|
|
120206
120899
|
case "TOTALCAPITAL":
|
|
120207
120900
|
case 'CAPITAL':
|
|
120208
120901
|
case 'EXCHANGE':
|
|
120902
|
+
case "HSL":
|
|
120209
120903
|
|
|
120210
120904
|
case "HYBLOCK":
|
|
120211
120905
|
case "DYBLOCK":
|
|
@@ -121873,7 +122567,7 @@ function JSExplainer(ast,option)
|
|
|
121873
122567
|
['BARSTATUS',"数据位置状态"], //BARSTATUS返回数据位置信息,1表示第一根K线,2表示最后一个数据,0表示中间位置.
|
|
121874
122568
|
|
|
121875
122569
|
['CAPITAL',"当前流通股本(手)"], ["TOTALCAPITAL","当前总股本(手)"],
|
|
121876
|
-
['EXCHANGE',"换手率"],
|
|
122570
|
+
['EXCHANGE',"换手率"], ['HSL',"换手线"],
|
|
121877
122571
|
['SETCODE', "市场类型"], //市场类型
|
|
121878
122572
|
['CODE',"品种代码"], //品种代码
|
|
121879
122573
|
['STKNAME',"品种名称"], //品种名称
|
|
@@ -128813,6 +129507,19 @@ function APIScriptIndex(name,script,args,option, isOverlay)
|
|
|
128813
129507
|
|
|
128814
129508
|
result.push(outVarItem);
|
|
128815
129509
|
}
|
|
129510
|
+
else if (draw.DrawType=="DRAWTEXT_LINE")
|
|
129511
|
+
{
|
|
129512
|
+
drawItem.Name=draw.Name;
|
|
129513
|
+
drawItem.Type=draw.Type;
|
|
129514
|
+
|
|
129515
|
+
drawItem.DrawType=draw.DrawType;
|
|
129516
|
+
drawItem.DrawData=draw.DrawData; //{ Price:, Text:{ Title:text, Color:textcolor }, Line:{ Type:linetype, Color:linecolor } };
|
|
129517
|
+
|
|
129518
|
+
outVarItem.Draw=drawItem;
|
|
129519
|
+
if (draw.Font) outVarItem.Font=draw.Font;
|
|
129520
|
+
|
|
129521
|
+
result.push(outVarItem);
|
|
129522
|
+
}
|
|
128816
129523
|
else
|
|
128817
129524
|
{
|
|
128818
129525
|
var find=g_ScriptIndexChartFactory.Get(draw.DrawType); //外部挂接
|
|
@@ -129118,6 +129825,7 @@ function DownloadFinanceData(obj)
|
|
|
129118
129825
|
case 1: //FINANCE(1) 总股本(随时间可能有变化) 股
|
|
129119
129826
|
case 7: //FINANCE(7) 流通股本(随时间可能有变化) 股
|
|
129120
129827
|
case "EXCHANGE": //换手率
|
|
129828
|
+
case "HSL"://换手率
|
|
129121
129829
|
this.DownloadHistoryData(id);
|
|
129122
129830
|
break;
|
|
129123
129831
|
case 3:
|
|
@@ -129244,6 +129952,7 @@ function DownloadFinanceData(obj)
|
|
|
129244
129952
|
return ["capital.total", "capital.date"];
|
|
129245
129953
|
case 7:
|
|
129246
129954
|
return ["capital.a", "capital.date"];
|
|
129955
|
+
case "HSL":
|
|
129247
129956
|
case "EXCHANGE":
|
|
129248
129957
|
return ["capital.a", "capital.date"];
|
|
129249
129958
|
|
|
@@ -129377,6 +130086,7 @@ function DownloadFinanceData(obj)
|
|
|
129377
130086
|
if (!item.capital) return null;
|
|
129378
130087
|
return { Date:date, Value:item.capital.total };
|
|
129379
130088
|
case 7:
|
|
130089
|
+
case "HSL": //换手率
|
|
129380
130090
|
case "EXCHANGE": //换手率 历史流通股本
|
|
129381
130091
|
if (!item.capital) return null;
|
|
129382
130092
|
return { Date:date, Value:item.capital.a };
|
|
@@ -144946,7 +145656,7 @@ function ScrollBarBGChart()
|
|
|
144946
145656
|
|
|
144947
145657
|
|
|
144948
145658
|
|
|
144949
|
-
var HQCHART_VERSION="1.1.
|
|
145659
|
+
var HQCHART_VERSION="1.1.14590";
|
|
144950
145660
|
|
|
144951
145661
|
function PrintHQChartVersion()
|
|
144952
145662
|
{
|