X-Git-Url: http://git.kpe.io/?p=ctsim.git;a=blobdiff_plain;f=src%2Fdialogs.cpp;h=87542a9e64e6f8208f90e77b388210e12dac7614;hp=ce808b4c92cb467f3a22e5b77a90fb79681b57a0;hb=484b9ac2ebf8f88dbe36bdc1d3a9c1b6a2b242eb;hpb=07fbc7c8c9cf0e9de956284d6057a825c81ae0ce diff --git a/src/dialogs.cpp b/src/dialogs.cpp index ce808b4..87542a9 100644 --- a/src/dialogs.cpp +++ b/src/dialogs.cpp @@ -9,7 +9,7 @@ ** This is part of the CTSim program ** Copyright (C) 1983-2000 Kevin Rosenberg ** -** $Id: dialogs.cpp,v 1.13 2000/09/04 09:06:46 kevin Exp $ +** $Id: dialogs.cpp,v 1.14 2000/12/16 03:29:02 kevin Exp $ ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License (version 2) as @@ -59,13 +59,14 @@ StringValueAndTitleListBox::StringValueAndTitleListBox (wxDialog* pParent, int nChoices, const char* aszTitle[], const char* aszValue[]) : wxListBox () { - wxString asTitle[nChoices]; + wxString* psTitle = new wxString [nChoices]; for (int i = 0; i < nChoices; i++) - asTitle[i] = aszTitle[i]; + psTitle[i] = aszTitle[i]; - Create (pParent, -1, wxDefaultPosition, wxSize(200,-1), nChoices, asTitle, wxLB_SINGLE | wxLB_NEEDED_SB); + Create (pParent, -1, wxDefaultPosition, wxSize(200,-1), nChoices, psTitle, wxLB_SINGLE | wxLB_NEEDED_SB); - m_ppszValues = aszValue; + m_ppszValues = aszValue; + delete [] psTitle; }; const char* @@ -76,7 +77,7 @@ StringValueAndTitleListBox::getSelectionStringValue (void) const -DialogGetPhantom::DialogGetPhantom (wxFrame* pParent, int iDefaultPhantom = Phantom::PHM_HERMAN) +DialogGetPhantom::DialogGetPhantom (wxFrame* pParent, int iDefaultPhantom) : wxDialog (pParent, -1, "Select Phantom", wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxCAPTION) { wxBoxSizer* pTopSizer = new wxBoxSizer (wxVERTICAL); @@ -112,7 +113,7 @@ DialogGetPhantom::getPhantom(void) } -DialogGetImageMinMax::DialogGetImageMinMax (wxFrame* pParent, const ImageFile& rImagefile, double dDefaultMin = 0., double dDefaultMax = 0.) +DialogGetImageMinMax::DialogGetImageMinMax (wxFrame* pParent, const ImageFile& rImagefile, double dDefaultMin, double dDefaultMax) : wxDialog (pParent, -1, "Set Image Display Minimum & Maximum", wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxCAPTION) { wxBoxSizer* pTopSizer = new wxBoxSizer (wxVERTICAL); @@ -188,7 +189,7 @@ DialogGetImageMinMax::getMaximum (void) // DialogGetRasterParameters ///////////////////////////////////////////////////////////////////// -DialogGetRasterParameters::DialogGetRasterParameters (wxFrame* pParent, int iDefaultXSize = 0, int iDefaultYSize = 0, int iDefaultNSamples = 1) +DialogGetRasterParameters::DialogGetRasterParameters (wxFrame* pParent, int iDefaultXSize, int iDefaultYSize, int iDefaultNSamples) : wxDialog (pParent, -1, "Set Rasterization Parameters", wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxCAPTION) { wxBoxSizer* pTopSizer = new wxBoxSizer (wxVERTICAL);