切换Controller中的不同UIView且不会覆盖前头一个UI
切换Controller中的不同UIView且不会覆盖前面一个UI
第一次进来的时候:
1⃣️ m_imageViewGraphs = [[UIImageView alloc]initWithImage:[self minuteLinesView]];
[self.view addSubview:m_imageViewGraphs];
2⃣️ m_axisUnit=[[AxisUnitPriceView alloc]initWithFrame:CGRectMake(2, 390, 20, 250) :m_difference :m_beginPrice];
3⃣️m_showBar=[[ShowBar alloc]initWithFrame:CGRectMake(15, 28, 70, 2)];
[self addSubview:m_showBar];
之后的切换:
1⃣️ m_imageViewGraphs.image = [self minuteLinesView];
2⃣️ m_axisUnit.firstLabel.text = [NSString stringWithFormat:@"%.2f",m_difference+m_beginPrice];
3⃣️m_showBar.frame=CGRectMake(15+barPoint.x/3+3, 28, 70, 2);
第一次进来的时候:
1⃣️ m_imageViewGraphs = [[UIImageView alloc]initWithImage:[self minuteLinesView]];
[self.view addSubview:m_imageViewGraphs];
2⃣️ m_axisUnit=[[AxisUnitPriceView alloc]initWithFrame:CGRectMake(2, 390, 20, 250) :m_difference :m_beginPrice];
3⃣️m_showBar=[[ShowBar alloc]initWithFrame:CGRectMake(15, 28, 70, 2)];
[self addSubview:m_showBar];
之后的切换:
1⃣️ m_imageViewGraphs.image = [self minuteLinesView];
2⃣️ m_axisUnit.firstLabel.text = [NSString stringWithFormat:@"%.2f",m_difference+m_beginPrice];
3⃣️m_showBar.frame=CGRectMake(15+barPoint.x/3+3, 28, 70, 2);