| 663 | void CEditorView::OnUpdateViewWireframemine(CCmdUI *pCmdUI) { pCmdUI->SetCheck(D3EditState.wirescr_visible); } |
| 664 | |
| 665 | void CEditorView::OnViewWireframemine() { |
| 666 | RECT wire_rect; |
| 667 | |
| 668 | D3EditState.wirescr_visible = !D3EditState.wirescr_visible; |
| 669 | |
| 670 | if (!D3EditState.wirescr_visible) { |
| 671 | if (D3EditState.tile_views) { |
| 672 | DeactivateView(); |
| 673 | ActivateView(); |
| 674 | } else if (theApp.wireframe_view) |
| 675 | m_grwndWireframe.DestroyWindow(); |
| 676 | } else { |
| 677 | if (D3EditState.tile_views) { // for tiling, reinit the views |
| 678 | DeactivateView(); |
| 679 | ActivateView(); |
| 680 | } else { |
| 681 | SetRect(&wire_rect, D3EditState.wirescr_x, D3EditState.wirescr_y, D3EditState.wirescr_x + D3EditState.wirescr_w, |
| 682 | D3EditState.wirescr_y + D3EditState.wirescr_h); |
| 683 | m_grwndWireframe.Create(wire_rect, TRUE, this); |
| 684 | } |
| 685 | } |
| 686 | } |
| 687 | |
| 688 | // We do this so that we can tell if the texture or wireframe views were closed by the user |
| 689 | // |
nothing calls this directly
no test coverage detected