mirror of
				https://github.com/SoftFever/OrcaSlicer.git
				synced 2025-11-02 20:51:23 -07:00 
			
		
		
		
	Fix scene not being centered
This commit is contained in:
		
							parent
							
								
									929e467df9
								
							
						
					
					
						commit
						a36c7c76cc
					
				
					 1 changed files with 3 additions and 3 deletions
				
			
		| 
						 | 
				
			
			@ -446,13 +446,13 @@ void MyFrame::activate_canvas_display()
 | 
			
		|||
    m_canvas->Bind(wxEVT_PAINT, [this](wxPaintEvent &) {
 | 
			
		||||
        // This is required even though dc is not used otherwise.
 | 
			
		||||
        wxPaintDC dc(this);
 | 
			
		||||
        const wxSize csize = GetClientSize();
 | 
			
		||||
        const wxSize csize = m_canvas->GetClientSize();
 | 
			
		||||
        m_canvas->get_display()->set_screen_size(csize.x, csize.y);
 | 
			
		||||
        m_canvas->get_display()->repaint();
 | 
			
		||||
    });
 | 
			
		||||
    
 | 
			
		||||
    m_canvas->Bind(wxEVT_SIZE, [this](wxSizeEvent &) {            
 | 
			
		||||
        const wxSize csize = GetClientSize();
 | 
			
		||||
    m_canvas->Bind(wxEVT_SIZE, [this](wxSizeEvent &) {
 | 
			
		||||
        const wxSize csize = m_canvas->GetClientSize();
 | 
			
		||||
        m_canvas->get_display()->set_screen_size(csize.x, csize.y);
 | 
			
		||||
        m_canvas->get_display()->repaint();
 | 
			
		||||
    });
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue