Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

GUI/Client/vtkPVInputMenu.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   ParaView
00004   Module:    $RCSfile: vtkPVInputMenu.h,v $
00005 
00006   Copyright (c) Kitware, Inc.
00007   All rights reserved.
00008   See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
00009 
00010      This software is distributed WITHOUT ANY WARRANTY; without even
00011      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00012      PURPOSE.  See the above copyright notice for more information.
00013 
00014 =========================================================================*/
00022 #ifndef __vtkPVInputMenu_h
00023 #define __vtkPVInputMenu_h
00024 
00025 #include "vtkPVWidget.h"
00026 
00027 class vtkDataSet;
00028 class vtkKWLabel;
00029 class vtkKWMenuButton;
00030 class vtkPVData;
00031 class vtkPVInputProperty;
00032 class vtkPVSourceCollection;
00033 class vtkSMInputProperty;
00034 
00035 class VTK_EXPORT vtkPVInputMenu : public vtkPVWidget
00036 {
00037 public:
00038   static vtkPVInputMenu* New();
00039   vtkTypeRevisionMacro(vtkPVInputMenu, vtkPVWidget);
00040   void PrintSelf(ostream& os, vtkIndent indent);
00041   
00043   virtual void Create(vtkKWApplication *app);
00044 
00046 
00048   void SetLabel (const char* label);
00049   const char* GetLabel();
00051 
00052   //BTX
00054 
00058   void SetSources(vtkPVSourceCollection *sources);
00059   vtkPVSourceCollection *GetSources();
00060   //ETX
00062 
00065   virtual void Select();
00066   
00067   int GetNumberOfSources();
00068   vtkPVSource* GetSource(int i);
00069   
00071 
00073   vtkSetStringMacro(InputName);
00075   
00080   virtual void ModifiedCallback();
00081 
00083 
00085   void SetCurrentValue(vtkPVSource *pvs);
00086   vtkPVSource* GetCurrentValue() { return this->CurrentValue;}
00087   vtkPVSource* GetLastAcceptedValue();
00089   
00091   void MenuEntryCallback(vtkPVSource *pvs);
00092 
00094   virtual void SaveInBatchScript(ofstream *file);
00095 
00096 //BTX
00098 
00101   vtkPVInputMenu* ClonePrototype(vtkPVSource* pvSource,
00102                                  vtkArrayMap<vtkPVWidget*, vtkPVWidget*>* map);
00104 //ETX
00105 
00106   //BTX
00108 
00110   virtual void Accept();
00111   //ETX
00113 
00115   virtual void Initialize();
00116 
00118   virtual void ResetInternal();
00119 
00121   virtual void Trace(ofstream *file);
00122 
00129   virtual void UpdateEnableState();
00130  
00135   virtual void Update();
00136 
00137 protected:
00138   vtkPVInputMenu();
00139   ~vtkPVInputMenu();
00140 
00141   int InitializeWithCurrent;
00142 
00143   char* InputName;
00144   
00145   vtkPVSource *CurrentValue;
00146   vtkPVSourceCollection *Sources;
00147   
00148   vtkKWLabel *Label;
00149   vtkKWMenuButton *Menu;
00150 
00152   void DeleteAllEntries();
00153 
00157   int AddEntry(vtkPVSource *pvs);
00158 
00161   int CheckForLoop(vtkPVSource *pvs);
00162 
00165   int GetPVInputIndex();
00166 
00168   vtkSMInputProperty* GetInputProperty();
00169 
00172   void AddSources(vtkPVSourceCollection *sources);
00173 
00174   vtkPVInputMenu(const vtkPVInputMenu&); // Not implemented
00175   void operator=(const vtkPVInputMenu&); // Not implemented
00176 
00177 //BTX
00178   virtual void CopyProperties(vtkPVWidget* clone, vtkPVSource* pvSource,
00179                               vtkArrayMap<vtkPVWidget*, vtkPVWidget*>* map);
00180 //ETX
00181   
00182   int ReadXMLAttributes(vtkPVXMLElement* element,
00183                         vtkPVXMLPackageParser* parser);
00184 };
00185 
00186 #endif

Generated on Tue May 30 12:31:39 2006 for ParaView by doxygen 1.3.5