- /* Figure out height of DirCtrl, which is what is left over by
- * the textctrl and the buttons. Manually, because I can't seem
- * to get the constraints stuff to do this */
- int w,h,h2;
-
- GetClientSize(&w, &h);
- m_input->GetSize(&w,&h2); h -= h2;
- m_ok->GetSize(&w, &h2); h -= h2;
- //m_check->GetSize(&w, &h2); h -= h2;
- h -= 30;
-
- wxLayoutConstraints *c = new wxLayoutConstraints;
- c->left.SameAs (this, wxLeft,5);
- c->right.SameAs (this, wxRight,5);
- c->height.Absolute (h);
- c->top.SameAs (this, wxTop,5);
- m_dir->SetConstraints(c);
-
- c = new wxLayoutConstraints;
- c->left.SameAs (this, wxLeft,5);
- c->right.SameAs (this, wxRight,5);
- c->height.AsIs ();
- c->top.Below (m_dir,5);
- m_input->SetConstraints(c);
-
- /* c = new wxLayoutConstraints;
- c->left.SameAs (this, wxLeft,5);
- c->right.SameAs (this, wxRight,5);
- c->height.AsIs ();
- c->top.Below (m_input,5);
- m_check->SetConstraints(c); */
-
- c = new wxLayoutConstraints;
- c->width.SameAs (m_cancel, wxWidth);
- c->height.AsIs ();
- c->top.Below (m_input,10);
- c->centreX.PercentOf (this, wxWidth, 20);
- m_ok->SetConstraints(c);
-
- c = new wxLayoutConstraints;
- c->width.SameAs (m_cancel, wxWidth);
- c->height.AsIs ();
- c->top.Below (m_input,10);
- c->bottom.SameAs (this, wxBottom, 5);
- c->centreX.PercentOf (this, wxWidth, 50);
- m_new->SetConstraints(c);
-
- c = new wxLayoutConstraints;
- c->width.AsIs ();
- c->height.AsIs ();
- c->top.Below (m_input,10);
- c->centreX.PercentOf (this, wxWidth, 80);
- m_cancel->SetConstraints(c);
-
- Layout();