X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/cc2c11e21856e1ef646141010db007a1d217e523..f5766910b6731eb03e82371416e9778203396ce7:/src/palmos/utils.cpp diff --git a/src/palmos/utils.cpp b/src/palmos/utils.cpp index 02d4de0324..81db337f9b 100644 --- a/src/palmos/utils.cpp +++ b/src/palmos/utils.cpp @@ -1,11 +1,11 @@ ///////////////////////////////////////////////////////////////////////////// -// Name: palmos/utils.cpp +// Name: src/palmos/utils.cpp // Purpose: Various utilities -// Author: William Osborne -// Modified by: +// Author: William Osborne - minimal working wxPalmOS port +// Modified by: Wlodzimierz ABX Skiba - real functionality // Created: 10/13/04 -// RCS-ID: $Id: -// Copyright: (c) William Osborne +// RCS-ID: $Id$ +// Copyright: (c) William Osborne, Wlodzimierz Skiba // Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// @@ -29,16 +29,18 @@ #include "wx/app.h" #include "wx/intl.h" #include "wx/log.h" + #include "wx/timer.h" #endif //WX_PRECOMP #include "wx/apptrait.h" #include "wx/dynload.h" #include "wx/confbase.h" -#include "wx/timer.h" +#include "wx/power.h" #include #include #include +#include // ============================================================================ // implementation @@ -106,12 +108,7 @@ wxChar *wxGetUserHome(const wxString& WXUNUSED(user)) return NULL; } -bool wxDirExists(const wxString& dir) -{ - return false; -} - -bool wxGetDiskSpace(const wxString& path, wxLongLong *pTotal, wxLongLong *pFree) +bool wxGetDiskSpace(const wxString& path, wxDiskspaceSize_t *pTotal, wxDiskspaceSize_t *pFree) { return false; } @@ -151,6 +148,21 @@ bool wxShutdown(wxShutdownFlags wFlags) return false; } +// ---------------------------------------------------------------------------- +// power management +// ---------------------------------------------------------------------------- + +wxPowerType wxGetPowerType() +{ + return wxPOWER_BATTERY; +} + +wxBatteryState wxGetBatteryState() +{ + // TODO + return wxBATTERY_UNKNOWN_STATE; +} + // ---------------------------------------------------------------------------- // misc // ---------------------------------------------------------------------------- @@ -185,6 +197,11 @@ void wxBell() SndPlaySystemSound(sndWarning); } +bool wxIsPlatform64Bit() +{ + return false; +} + wxString wxGetOsDescription() { wxString strOS = _T("PalmOS"); @@ -193,6 +210,7 @@ wxString wxGetOsDescription() if(version) { wxString str = wxString::FromAscii(version); + MemPtrFree(version); if(!str.empty()) { strOS << _(" ") << str; @@ -202,11 +220,11 @@ wxString wxGetOsDescription() return strOS; } -wxToolkitInfo& wxAppTraits::GetToolkitInfo() +wxOperatingSystemId wxGetOsVersion(int *verMaj, int *verMin) { - static wxToolkitInfo info; - info.name = _T("wxBase"); - return info; + // TODO + + return wxOS_UNKNOWN; } // ---------------------------------------------------------------------------- @@ -261,4 +279,3 @@ extern long wxCharsetToCodepage(const wxChar *name) } #endif // wxUSE_FONTMAP/!wxUSE_FONTMAP -