[vtkusers] problem with VTK example!

subin supersub at ccea.zju.edu.cn
Mon Sep 8 12:52:48 EDT 2003


hi all,
    I have a problem in changing example source code  "Examples\GUI\Win32\SampleMFC"
and "Examples\GUI\Win32\vtkMFC\vtkMDI".
    I want to add some code in VTK example to answer message WM_RBUTTONDOWN in these two programs. the code is add to the program is as:
 LRESULT CXXView::WindowProc(UINT message, WPARAM wParam, LPARAM lParam) 
{
 // TODO: Add your specialized code here and/or call the base class
 switch (message)   
  {
     case WM_RBUTTONDOWN: 
  {
   CWnd msgwnd;                            //add_begin
   msgwnd.MessageBox("Rbutton");           //add_end
  }
....
  break;
 }
 
 return vtkMFCRenderView::WindowProc(message, wParam, lParam);
}

    But two examples has different characteristics.
    In  program "Examples\GUI\Win32\SampleMFC ", it can show a message box when i press right button whthin the ClientRect of the view; but in program "Examples\GUI\Win32\vtkMFC\vtkMDI", it show nothing.

    who can tell me why???

----------------------------
good luck !
      subin ^_^


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20030909/8ecb0b59/attachment.htm>


More information about the vtkusers mailing list