X-Git-Url: http://git.kpe.io/?p=ctsim.git;a=blobdiff_plain;f=src%2Fviews.cpp;h=3aca5d4d1ff979ef68a63cb11c6974e2aeaa4292;hp=b7934f1901c9cc4320ae02e155561515a2e324a4;hb=b68175983375191c7f302a140c8cab8151a3d628;hpb=a36e4b039279f96f7698a27f49ec1f99e18306a9 diff --git a/src/views.cpp b/src/views.cpp index b7934f1..3aca5d4 100644 --- a/src/views.cpp +++ b/src/views.cpp @@ -1,7 +1,7 @@ /***************************************************************************** ** FILE IDENTIFICATION ** -** Name: view.cpp +** Name: views.cpp ** Purpose: View & Canvas routines for CTSim program ** Programmer: Kevin Rosenberg ** Date Started: July 2000 @@ -9,7 +9,7 @@ ** This is part of the CTSim program ** Copyright (c) 1983-2001 Kevin Rosenberg ** -** $Id: views.cpp,v 1.148 2002/04/30 03:37:12 kevin Exp $ +** $Id: views.cpp,v 1.150 2002/05/01 15:17:36 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 @@ -1027,17 +1027,17 @@ ImageFileView::OnCreate (wxDocument *doc, long WXUNUSED(flags) ) m_bMaxSpecified = false; m_dAutoScaleFactor = 1.; - int width, height; - m_pFrame->GetClientSize (&width, &height); + // int width, height; + // m_pFrame->GetClientSize (&width, &height); m_pFrame->SetTitle("ImageFileView"); m_pCanvas = CreateCanvas (m_pFrame); - int x, y; // X requires a forced resize - m_pFrame->GetSize(&x, &y); - m_pFrame->SetSize(-1, -1, x, y); + // int x, y; // X requires a forced resize + // m_pFrame->GetSize(&x, &y); + // m_pFrame->SetSize(-1, -1, x, y); m_pFrame->SetFocus(); m_pFrame->Show(true); - Activate(true); + // Activate(true); return true; } @@ -1106,7 +1106,7 @@ ImageFileView::OnUpdate (wxView *WXUNUSED(sender), wxObject *WXUNUSED(hint) ) int xSize = nx; int ySize = ny; ySize = clamp (ySize, 0, 800); - m_pFrame->SetClientSize (xSize, ySize); + // m_pFrame->SetClientSize (xSize, ySize); // KMR m_pCanvas->SetScrollbars(20, 20, nx/20, ny/20); m_pCanvas->SetBackgroundColour(*wxWHITE); } @@ -2957,13 +2957,14 @@ ProjectionFileView::doReconstructFBP (const Projections& rProj, bool bRebinToPar pImageFile->labelAdd (rProj.getLabel()); pImageFile->labelAdd (os.str().c_str(), timerRecon.timerEnd()); - if (ImageFileView* rasterView = pReconDoc->getView()) { - rasterView->getFrame()->Show(true); - rasterView->getFrame()->SetFocus(); - rasterView->OnUpdate (rasterView, NULL); - } + // if (ImageFileView* rasterView = pReconDoc->getView()) { + // rasterView->getFrame()->Show(true); + // rasterView->getFrame()->SetFocus(); + // rasterView->OnUpdate (rasterView, NULL); + // } // causes loss of frame in wxGTK - //pReconDoc->UpdateAllViews (this); + pReconDoc->GetFirstView()->GetFrame()->Show(true); + pReconDoc->UpdateAllViews (); // pReconDoc->Activate(); } @@ -3047,7 +3048,8 @@ ProjectionFileView::CreateChildFrame(wxDocument *doc, wxView *view) wxMenu *reconstruct_menu = new wxMenu; reconstruct_menu->Append (PJMENU_RECONSTRUCT_FBP, "&Filtered Backprojection...\tCtrl-R", "Reconstruct image using filtered backprojection"); reconstruct_menu->Append (PJMENU_RECONSTRUCT_FBP_REBIN, "Filtered &Backprojection (Rebin to Parallel)...\tCtrl-B", "Reconstruct image using filtered backprojection"); - reconstruct_menu->Append (PJMENU_RECONSTRUCT_FOURIER, "&Fourier...\tCtrl-E", "Reconstruct image using inverse Fourier"); + // still buggy + // reconstruct_menu->Append (PJMENU_RECONSTRUCT_FOURIER, "&Fourier...\tCtrl-E", "Reconstruct image using inverse Fourier"); wxMenu *help_menu = new wxMenu; help_menu->Append(MAINMENU_HELP_CONTENTS, "&Contents\tF1");