| | |
| | | return _sharp_type; |
| | | } |
| | | } |
| | | bool _isxml = false; |
| | | public bool Isxml |
| | | { |
| | | get { return _isxml; } |
| | | set { _isxml = value; } |
| | | } |
| | | private void InitialOutflowStyle() |
| | | { |
| | | if (_parasControlCenter == null) |
| | |
| | | tabPage1.Controls.Add(_parasControlArcCenter); |
| | | return; |
| | | } |
| | | if (_sharp_type == eOutflowShapeStyle.渚ч潰鍑哄彛_鏇茬嚎杩炴帴) |
| | | if (_sharp_type == eOutflowShapeStyle.渚ч潰鍑哄彛) |
| | | { |
| | | metroTile鍑哄彛鍥剧墖.BackgroundImage = GlobalResource.BuildImage("Central-exit.png", 878, 238); |
| | | _parasControlArcSide.SetA_state(true); |
| | |
| | | _parasControlCenter.SetA_state(false); |
| | | tabPage1.Controls.Add(_parasControlCenter); |
| | | return; |
| | | case DPumpHydr.WinFrmUI.Volute.ViewModel.eOutflowShapeStyle.渚ч潰鍑哄彛_鏇茬嚎杩炴帴: |
| | | case DPumpHydr.WinFrmUI.Volute.ViewModel.eOutflowShapeStyle.渚ч潰鍑哄彛: |
| | | metroTile鍑哄彛鍥剧墖.BackgroundImage = GlobalResource.BuildImage("Side-exit-curve.png", 878, 238); |
| | | _parasControlCurve.SetA_state(true); |
| | | tabPage1.Controls.Add(_parasControlCurve); |
| | |
| | | if(outflowParas != null) |
| | | { |
| | | _sharp_type = outflowParas.ShapeStyle; |
| | | _link_type = outflowParas.LinkStyle; |
| | | } |
| | | // |
| | | InitialCtrlDefaultParas(hdrBaseInfo, geomBaseInfo, sectionBundleInfo, outflowParas); |
| | | |
| | | |
| | | if(_link_type == eOutflowLinkStyle.鏇茬嚎) |
| | | { |
| | | checkBox鍦嗗姬杩炴帴.Checked = false; |
| | | } |
| | | else |
| | | { |
| | | checkBox鍦嗗姬杩炴帴.Checked = true; |
| | | } |
| | | |
| | | if (_sharp_type == eOutflowShapeStyle.鏈煡) |
| | | { |
| | |
| | | } |
| | | else |
| | | { |
| | | comboBoxType.SelectedIndex = (int)_sharp_type; |
| | | if (_isxml) |
| | | { |
| | | InitialOutflowStyle(); |
| | | _isxml = false; |
| | | |
| | | } |
| | | InitialOutflowStyle(); |
| | | |
| | | RefreshModel(); |
| | | RefreshModel(); |
| | | } |
| | | |
| | | return 1; |
| | |
| | | double outer_dia = 4.5 * Math.Pow(hdrBaseInfo.Q / 3600 / hdrBaseInfo.n, 1 / 3.0) * 1000; |
| | | //渚ч潰鏇茬嚎 |
| | | OutflowParas outflowParas渚ч潰鏇茬嚎 = null; |
| | | if(outflowParas != null && outflowParas.ShapeStyle == eOutflowShapeStyle.渚ч潰鍑哄彛_鏇茬嚎杩炴帴) |
| | | if(outflowParas != null && outflowParas.ShapeStyle == eOutflowShapeStyle.渚ч潰鍑哄彛) |
| | | { |
| | | outflowParas渚ч潰鏇茬嚎 = outflowParas; |
| | | } |
| | |
| | | |
| | | //鍦嗗姬渚ч潰 |
| | | OutflowParas outflowParas鍦嗗姬渚ч潰 = null; |
| | | if (outflowParas != null && outflowParas.ShapeStyle == eOutflowShapeStyle.渚ч潰鍑哄彛_鏇茬嚎杩炴帴 && outflowParas.LinkStyle == eOutflowLinkStyle.鐩寸嚎鍦嗗姬) |
| | | if (outflowParas != null && outflowParas.ShapeStyle == eOutflowShapeStyle.渚ч潰鍑哄彛 && outflowParas.LinkStyle == eOutflowLinkStyle.鐩寸嚎鍦嗗姬) |
| | | { |
| | | outflowParas鍦嗗姬渚ч潰 = outflowParas; |
| | | } |
| | |
| | | return null; |
| | | _outflowParas = _parasControlArcCenter.GetBindingData(out error); |
| | | } |
| | | if (_sharp_type == eOutflowShapeStyle.渚ч潰鍑哄彛_鏇茬嚎杩炴帴) |
| | | if (_sharp_type == eOutflowShapeStyle.渚ч潰鍑哄彛) |
| | | { |
| | | if (_parasControlArcSide == null) |
| | | return null; |
| | |
| | | return null; |
| | | _outflowParas = _parasControlCenter.GetBindingData(out error); |
| | | break; |
| | | case DPumpHydr.WinFrmUI.Volute.ViewModel.eOutflowShapeStyle.渚ч潰鍑哄彛_鏇茬嚎杩炴帴: |
| | | case DPumpHydr.WinFrmUI.Volute.ViewModel.eOutflowShapeStyle.渚ч潰鍑哄彛: |
| | | _outflowParas = _parasControlCurve.GetBindingData(out error); |
| | | break; |
| | | case DPumpHydr.WinFrmUI.Volute.ViewModel.eOutflowShapeStyle.渚ч潰鍑哄彛_鐩寸嚎杩炴帴: |
| | |
| | | { |
| | | paras2.Offset = (int)((_geomBaseInfo.D3 + _sectionBundleInfo.H[8]) / 2 + 0.5); |
| | | } |
| | | else if (paras3.ShapeStyle == eOutflowShapeStyle.渚ч潰鍑哄彛_鏇茬嚎杩炴帴) |
| | | else if (paras3.ShapeStyle == eOutflowShapeStyle.渚ч潰鍑哄彛) |
| | | { |
| | | paras3.Offset = (int)(((_geomBaseInfo.D3 / 2 + _sectionBundleInfo.H[8]) * 1.6 / 3 / 5) + 1) * 5; |
| | | } |
| | |
| | | { |
| | | comboBoxType.SelectedIndex = 0; |
| | | } |
| | | else if (_sharp_type == DPumpHydr.WinFrmUI.Volute.ViewModel.eOutflowShapeStyle.渚ч潰鍑哄彛_鏇茬嚎杩炴帴) |
| | | else if (_sharp_type == DPumpHydr.WinFrmUI.Volute.ViewModel.eOutflowShapeStyle.渚ч潰鍑哄彛) |
| | | { |
| | | comboBoxType.SelectedIndex = 1; |
| | | } |
| | |
| | | private void RefreshModel() |
| | | { |
| | | string error; |
| | | if(OnRefreshShape3D == null) |
| | | { |
| | | return; |
| | | } |
| | | var resp = OnRefreshShape3D(GetBindingData(out error)); |
| | | if (resp != null) |
| | | { |
| | |
| | | { |
| | | _parasControlArcCenter.SetBindingData(resp); |
| | | } |
| | | else if (_sharp_type == eOutflowShapeStyle.渚ч潰鍑哄彛_鏇茬嚎杩炴帴) |
| | | else if (_sharp_type == eOutflowShapeStyle.渚ч潰鍑哄彛) |
| | | { |
| | | _parasControlArcSide.SetBindingData(resp); |
| | | } |
| | |
| | | { |
| | | _parasControlLine.SetBindingData(resp); |
| | | } |
| | | else if (_sharp_type == eOutflowShapeStyle.渚ч潰鍑哄彛_鏇茬嚎杩炴帴) |
| | | else if (_sharp_type == eOutflowShapeStyle.渚ч潰鍑哄彛) |
| | | { |
| | | _parasControlCurve.SetBindingData(resp); |
| | | } |
| | |
| | | } |
| | | else if (comboBoxType.SelectedIndex == 1) |
| | | { |
| | | _sharp_type = DPumpHydr.WinFrmUI.Volute.ViewModel.eOutflowShapeStyle.渚ч潰鍑哄彛_鏇茬嚎杩炴帴; |
| | | checkBox鍦嗗姬杩炴帴.Enabled = false; |
| | | checkBox鍦嗗姬杩炴帴.Visible = false; |
| | | _sharp_type = DPumpHydr.WinFrmUI.Volute.ViewModel.eOutflowShapeStyle.渚ч潰鍑哄彛; |
| | | checkBox鍦嗗姬杩炴帴.Enabled = true; |
| | | checkBox鍦嗗姬杩炴帴.Visible = true; |
| | | _link_type = DPumpHydr.WinFrmUI.Volute.ViewModel.eOutflowLinkStyle.鏇茬嚎; |
| | | if (checkBox鍦嗗姬杩炴帴.Checked) |
| | | { |
| | |
| | | { |
| | | _link_type = DPumpHydr.WinFrmUI.Volute.ViewModel.eOutflowLinkStyle.鏇茬嚎; |
| | | } |
| | | } |
| | | } |
| | | else if (comboBoxType.SelectedIndex == 2) |
| | | { |
| | | _sharp_type = DPumpHydr.WinFrmUI.Volute.ViewModel.eOutflowShapeStyle.渚ч潰鍑哄彛_鐩寸嚎杩炴帴; |
| | |
| | | checkBox鍦嗗姬杩炴帴.Visible = false; |
| | | _link_type = DPumpHydr.WinFrmUI.Volute.ViewModel.eOutflowLinkStyle.鏇茬嚎; |
| | | } |
| | | |
| | | if (_isxml) |
| | | { |
| | | InitialOutflowStyle(); |
| | | return; |
| | | } |
| | | InitialOutflowStyle(); |
| | | |
| | | RefreshModel(); |
| | | RefreshModel(); |
| | | } |
| | | |
| | | private void btnNextStep_Click(object sender, EventArgs e) |
| | |
| | | { |
| | | _link_type = DPumpHydr.WinFrmUI.Volute.ViewModel.eOutflowLinkStyle.鐩寸嚎鍦嗗姬; |
| | | } |
| | | if (_isxml) |
| | | { |
| | | InitialOutflowStyle(); |
| | | return; |
| | | } |
| | | |
| | | InitialOutflowStyle(); |
| | | |