Salome HOME
V2008a - invoking cmake from configure and remaining plugins
[modules/paravis.git] / src / Plugins / View / CMakeLists.txt
1
2 # create a plugin with a custom view that shows up in ParaView's multi-view
3 # manager.  this plugin also contains a custom display panel
4
5 # moc the Qt based .h files
6 QT4_WRAP_CPP(MOC_SRCS MyView.h MyDisplay.h MyViewActiveOptions.h MyViewOptions.h)
7
8 # invoke macro to create sources for our custom view and display panel
9 ADD_PARAVIEW_VIEW_MODULE(
10                          # returns the interfaces defined (pass in
11                          # GUI_INTERFACES parameter)
12                          IFACES  
13                          # returns a list of source files for this interface
14                          IFACE_SRCS 
15                          # give the view type 
16                          # With MyView.h implementing a
17                          # pqGenericViewModule and MyView being the XML name
18                          # for the view on the server side
19                          VIEW_TYPE MyView 
20                          # the XML group of the view in the server manager xml
21                          VIEW_XML_GROUP views
22                          # the XML name of the display for this view
23                          DISPLAY_XML MyDisplay 
24                          # the name of the display panel for this display
25                          # With MyDisplay.h implementing pqDisplayPanel
26                          DISPLAY_PANEL MyDisplay)
27
28
29 ADD_PARAVIEW_VIEW_OPTIONS(OPTIONS_IFACE OPTIONS_IFACE_SRCS
30                           VIEW_TYPE MyView ACTIVE_VIEW_OPTIONS MyViewActiveOptions)
31
32 # create a GUI side plugin with the GUI side code
33 ADD_PARAVIEW_PLUGIN(GUISampleView "1.0" GUI_INTERFACES ${IFACES} ${OPTIONS_IFACE}
34                     GUI_SOURCES MyView.cxx MyDisplay.cxx MyViewActiveOptions.cxx MyViewOptions.cxx
35                     ${MOC_SRCS} ${IFACE_SRCS} ${OPTIONS_IFACE_SRCS})
36
37 # create a server side plugin with the server side code
38 ADD_PARAVIEW_PLUGIN(SMSampleView "1.0" SERVER_MANAGER_XML MyViewSM.xml)
39
40 # one could combine the two plugins into one if desired
41
42 INSTALL(
43         TARGETS GUISampleView SMSampleView 
44         DESTINATION .
45 )