# CMake 2.6:
# technically those packages are not required
# since one can still use the Motif/X11 version and not the gtk one:
- FIND_PACKAGE(PkgConfig)
- pkg_check_modules (GTK2 gtk+-2.0)
+ FIND_PACKAGE(PkgConfig REQUIRED)
+
+## pkg_check_modules (GTK2 gtk+-2.0)
+## pkg_check_modules (GTK322 gtk+-3.0)
+ pkg_check_modules (GTK3 REQUIRED gtk+-3.0)
+
#MESSAGE("${GTK2_INCLUDE_DIRS}")
# Can I require all my user to have the gl lib on linux, even if they do not really need it...
#EED SET(WXGLCANVASLIBS "gl")
optimized msvcprt
)
ELSE(WIN32)
- # GTK2
- INCLUDE_DIRECTORIES(${GTK2_INCLUDE_DIRS})
- LINK_DIRECTORIES(${GTK2_LIBRARY_DIRS})
- LINK_LIBRARIES(${GTK2_LIBRARIES})
+## # GTK2
+## INCLUDE_DIRECTORIES(${GTK2_INCLUDE_DIRS})
+## LINK_DIRECTORIES(${GTK2_LIBRARY_DIRS})
+## LINK_LIBRARIES(${GTK2_LIBRARIES})
+ # GTK3
+ INCLUDE_DIRECTORIES(${GTK3_INCLUDE_DIRS})
+ LINK_DIRECTORIES(${GTK3_LIBRARY_DIRS})
+ LINK_LIBRARIES(${GTK3_LIBRARIES})
# WX
auiManager.SetManagedWindow(this);
+//EED 2017-09-16 Migration wxWidgets 2.8 to 3.0
+#if wxMAJOR_VERSION <= 2
tree_Projects = new wxCDMProjectsTreeCtrl(
this,
ID_TREE_PROJECTS,
wxDefaultPosition,
wxSize(200,400),
- wxTR_HAS_BUTTONS | wxTR_AQUA_BUTTONS
- );
+ wxTR_HAS_BUTTONS | wxTR_AQUA_BUTTONS );
+ this->actualTreeItem.Unset();
+#else
+ tree_Projects = new wxCDMProjectsTreeCtrl(
+ this,
+ ID_TREE_PROJECTS,
+ wxDefaultPosition,
+ wxSize(200,400),
+ wxTR_HAS_BUTTONS );
this->actualTreeItem.Unset();
+#endif
+
panel_Properties = new wxCDMMainDescriptionPanel(
this,
# ------------------------------------------------------------------------ */
crea_DEFINE(DEF1)
-crea_DEFINE_WITH_VAL(DEF2 "This is the value of DEF2")
+#crea_DEFINE_WITH_VAL(DEF2 "This is the value of DEF2")
crea_DEFINE_WITH_VAL(DEF3 10)
ADD_EXECUTABLE(creaSample_preprocessor main)
#include <creaSystem.h>
int main(int argc, char* argv[])
-{
+{
std::cout << "** creaSample_preprocessor : begin of main "<<std::endl;
#if defined (DEF1)
std::cout << "** creaSample_preprocessor : end of main "<<std::endl;
+
}
#endif //VTK_USE_COCOA
#endif //__WXCOCOA__
-#ifdef __WXGTK__
-# include <gdk/gdkx.h> // GDK_WINDOW_XWINDOW is found here in wxWidgets 2.8.0
-# include "gdk/gdkprivate.h"
-#if wxCHECK_VERSION(2, 8, 0)
-#ifdef __WXGTK20__
-#include <wx/gtk/win_gtk.h>
-#else
-#include <wx/gtk1/win_gtk.h>
-#endif
+
+//EED 2017-09-16 Migration wxWidgets 2.8 to 3.0
+#if wxMAJOR_VERSION <= 2
+ #ifdef __WXGTK__
+ #include <gdk/gdkx.h> // GDK_WINDOW_XWINDOW is found here in wxWidgets 2.8.0
+ #include "gdk/gdkprivate.h"
+ #if wxCHECK_VERSION(2, 8, 0)
+ #ifdef __WXGTK20__
+ #include <wx/gtk/win_gtk.h>
+ #else
+ #include <wx/gtk1/win_gtk.h>
+ #endif
+ #else
+ #include <wx/gtk/win_gtk.h>
+ #endif
+ #define GetXWindow(wxwin) (wxwin)->m_wxwindow ? \
+ GDK_WINDOW_XWINDOW(GTK_PIZZA((wxwin)->m_wxwindow)->bin_window) : \
+ GDK_WINDOW_XWINDOW((wxwin)->m_widget->window)
+ #endif
#else
-#include <wx/gtk/win_gtk.h>
-#endif
-#define GetXWindow(wxwin) (wxwin)->m_wxwindow ? \
- GDK_WINDOW_XWINDOW(GTK_PIZZA((wxwin)->m_wxwindow)->bin_window) : \
- GDK_WINDOW_XWINDOW((wxwin)->m_widget->window)
+ #ifdef __WXGTK__
+ #include <gdk/gdkx.h>
+ #include <gtk/gtk.h>
+ #endif
#endif
+
+
#ifdef __WXX11__
#include "wx/x11/privx.h"
#define GetXWindow(wxwin) ((Window)(wxwin)->GetHandle())
// Find and return the actual X-Window.
#if defined(__WXGTK__) || defined(__WXX11__)
- return (long)GetXWindow(this);
+
+ //EED 2017-09-16 Migration wxWidgets 2.8 to 3.0
+ #if wxMAJOR_VERSION <= 2
+ return (long)GetXWindow(this);
+ #else
+ GdkWindow* Win = gtk_widget_get_window( (GtkWidget *) GetHandle() );
+ return (long int)GDK_WINDOW_XDISPLAY(Win);
+ #endif
+
#endif
//#ifdef __WXMOTIF__