Fix window resize on Mac and Windows
This commit is contained in:
parent
dbf89a1a33
commit
a01864b928
3 changed files with 14 additions and 3 deletions
3
Makefile
3
Makefile
|
|
@ -43,7 +43,8 @@ gui: gui.o portlist.o $(OBJS)
|
|||
$(CXX) -s $(CFLAGS) $(LDFLAGS) -o $@ $^ `$(WXCONFIG) --libs all,opengl`
|
||||
|
||||
gui.exe: gui
|
||||
cp gui gui.exe
|
||||
cp gui $@
|
||||
-./cp_windows.sh $@
|
||||
|
||||
gui.app: gui Info.plist
|
||||
mkdir -p $@/Contents/MacOS
|
||||
|
|
|
|||
10
cp_windows.sh
Executable file
10
cp_windows.sh
Executable file
|
|
@ -0,0 +1,10 @@
|
|||
#! /bin/sh
|
||||
|
||||
# copy a file to Windows machine for testing
|
||||
|
||||
ftp xp << EOT
|
||||
pass
|
||||
bin
|
||||
put $1
|
||||
EOT
|
||||
|
||||
4
gui.cpp
4
gui.cpp
|
|
@ -110,7 +110,7 @@ MyFrame::MyFrame(wxWindow *parent, wxWindowID id, const wxString &title,
|
|||
WX_GL_DOUBLEBUFFER,
|
||||
0};
|
||||
m_canvas = new MyCanvas(this, wxID_ANY, gl_attrib);
|
||||
m_canvas->SetMinSize(wxSize(340,340));
|
||||
m_canvas->SetMinSize(wxSize(400,400));
|
||||
|
||||
middlesizer->Add(m_canvas, 1, wxEXPAND | wxALL, 10);
|
||||
topsizer->SetSizeHints(this);
|
||||
|
|
@ -248,7 +248,7 @@ bool MyApp::OnInit()
|
|||
wxPoint pos(100, 100);
|
||||
|
||||
MyFrame *frame = new MyFrame(NULL, -1, wxT("IMU Read"), pos, wxSize(1120,760),
|
||||
wxDEFAULT_FRAME_STYLE & ~(wxMAXIMIZE_BOX | wxRESIZE_BORDER));
|
||||
wxDEFAULT_FRAME_STYLE);
|
||||
frame->Show( true );
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue