]> git.saurik.com Git - wxWidgets.git/commitdiff
Only include <unistd.h> under Unix in wxGTK code.
authorVadim Zeitlin <vadim@wxwidgets.org>
Mon, 27 Feb 2012 00:40:16 +0000 (00:40 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Mon, 27 Feb 2012 00:40:16 +0000 (00:40 +0000)
Also remove the inclusions of some Unix-specific headers that were not needed
at all.

Closes #14048.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70704 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

demos/forty/scorefil.cpp
src/gtk/dirdlg.cpp
src/gtk/filedlg.cpp
src/gtk/filepicker.cpp
src/gtk/utilsgtk.cpp

index 96f66d3198d23c6271b4053c7d4de618a3321a27..9d60a32cd686c77fa7fa649e9cc7830ad6668752 100644 (file)
 #include "wx/wx.h"
 #endif
 
-#ifdef __WXGTK__
-#include <unistd.h>
-#include <sys/stat.h>
-#include <fcntl.h>
-#endif
 #include "wx/textfile.h"
 #include "wx/config.h"
 #include "wx/fileconf.h"
index c6655fdaefc256cb2ad3c472a0e536d7a067e632..07cc55c8d17ceca4dd1fba9241db4348d54984c1 100644 (file)
@@ -31,7 +31,9 @@
 
 #include "wx/gtk/private.h"
 
+#ifdef __UNIX__
 #include <unistd.h> // chdir
+#endif
 
 //-----------------------------------------------------------------------------
 // "clicked" for OK-button
index a9359fa3ff092bad20e97cff9828105ce0a56b2c..6ba83203126033ef0587a241c8b73c81c565316a 100644 (file)
@@ -22,7 +22,9 @@
 #include <gtk/gtk.h>
 #include "wx/gtk/private.h"
 
+#ifdef __UNIX__
 #include <unistd.h> // chdir
+#endif
 
 #include "wx/filename.h" // wxFilename
 #include "wx/tokenzr.h" // wxStringTokenizer
index f457717e8af886c147e7f7695991ea0b9a9982f5..b3d16788a39ae22a5921b82c6255d8463251e8a4 100644 (file)
@@ -144,7 +144,9 @@ void wxFileButton::SetInitialDirectory(const wxString& dir)
 
 #if wxUSE_DIRPICKERCTRL && defined(__WXGTK26__)
 
+#ifdef __UNIX__
 #include <unistd.h> // chdir
+#endif
 
 //-----------------------------------------------------------------------------
 // "current-folder-changed"
index abe0d0424c5a47f4646335848defed5b54988096..0d1add821a5f4df361239cfc164b12d5bda2eb89 100644 (file)
@@ -45,8 +45,9 @@
 #include <string.h>
 #include <sys/stat.h>
 #include <sys/types.h>
-#include <sys/wait.h>   // for WNOHANG
+#ifdef __UNIX__
 #include <unistd.h>
+#endif
 
 #if wxUSE_DETECT_SM
     #include <X11/SM/SMlib.h>