]> git.saurik.com Git - wxWidgets.git/blobdiff - src/unix/utilsunx.cpp
build fix
[wxWidgets.git] / src / unix / utilsunx.cpp
index 54354d378dcfe5956af701a9f0e4757c94cbf08d..dcf05dfca47d63992a74accd2e1f27b7d3a8eba2 100644 (file)
@@ -1,5 +1,5 @@
 /////////////////////////////////////////////////////////////////////////////
-// Name:        unix/utilsunx.cpp
+// Name:        src/unix/utilsunx.cpp
 // Purpose:     generic Unix implementation of many wx functions
 // Author:      Vadim Zeitlin
 // Id:          $Id$
 // for compilers that support precompilation, includes "wx.h".
 #include "wx/wxprec.h"
 
-#include "wx/defs.h"
-#include "wx/string.h"
+#include "wx/utils.h"
+
+#ifndef WX_PRECOMP
+    #include "wx/string.h"
+    #include "wx/intl.h"
+    #include "wx/log.h"
+    #include "wx/app.h"
+#endif
 
-#include "wx/intl.h"
-#include "wx/log.h"
-#include "wx/app.h"
 #include "wx/apptrait.h"
 
-#include "wx/utils.h"
 #include "wx/process.h"
 #include "wx/thread.h"
 
@@ -280,7 +282,7 @@ long wxExecute( const wxString& command, int flags, wxProcess *process )
     // split the command line in arguments
     do
     {
-        argument=wxT("");
+        argument = wxEmptyString;
         quotechar = wxT('\0');
 
         // eat leading whitespace:
@@ -401,18 +403,6 @@ bool wxShutdown(wxShutdownFlags wFlags)
     return system(wxString::Format(_T("init %c"), level).mb_str()) == 0;
 }
 
-wxPowerType wxGetPowerType()
-{
-    // TODO
-    return wxPOWER_UNKNOWN;
-}
-
-wxBatteryState wxGetBatteryState()
-{
-    // TODO
-    return wxBATTERY_UNKNOWN_STATE;
-}
-
 // ----------------------------------------------------------------------------
 // wxStream classes to support IO redirection in wxExecute
 // ----------------------------------------------------------------------------
@@ -884,7 +874,7 @@ wxString wxGetOsDescription()
         return wxString::FromAscii( buf );
     }
     wxFAIL_MSG( _T("uname failed") );
-    return _T("");
+    return wxEmptyString;
 }
 
 #endif // !__WXMAC__
@@ -927,7 +917,7 @@ wxMemorySize wxGetFreeMemory()
     return -1;
 }
 
-bool wxGetDiskSpace(const wxString& path, wxLongLong *pTotal, wxLongLong *pFree)
+bool wxGetDiskSpace(const wxString& path, wxDiskspaceSize_t *pTotal, wxDiskspaceSize_t *pFree)
 {
 #if defined(HAVE_STATFS) || defined(HAVE_STATVFS)
     // the case to "char *" is needed for AIX 4.3
@@ -942,19 +932,19 @@ bool wxGetDiskSpace(const wxString& path, wxLongLong *pTotal, wxLongLong *pFree)
     // under Solaris we also have to use f_frsize field instead of f_bsize
     // which is in general a multiple of f_frsize
 #ifdef HAVE_STATVFS
-    wxLongLong blockSize = fs.f_frsize;
+    wxDiskspaceSize_t blockSize = fs.f_frsize;
 #else // HAVE_STATFS
-    wxLongLong blockSize = fs.f_bsize;
+    wxDiskspaceSize_t blockSize = fs.f_bsize;
 #endif // HAVE_STATVFS/HAVE_STATFS
 
     if ( pTotal )
     {
-        *pTotal = wxLongLong(fs.f_blocks) * blockSize;
+        *pTotal = wxDiskspaceSize_t(fs.f_blocks) * blockSize;
     }
 
     if ( pFree )
     {
-        *pFree = wxLongLong(fs.f_bavail) * blockSize;
+        *pFree = wxDiskspaceSize_t(fs.f_bavail) * blockSize;
     }
 
     return true;