- Timestamp:
- Aug 21, 2008, 11:04:42 AM (16 years ago)
- Location:
- trunk/ab5.0/ablib/src
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/ab5.0/ablib/src/Classes/ActiveBasic/Windows/Windows.ab
r599 r603 47 47 End Namespace 48 48 49 Function HResultToString(hr As HRESULT) As String 50 Dim pszMsg As PCSTR 51 FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER Or FORMAT_MESSAGE_FROM_SYSTEM Or FORMAT_MESSAGE_IGNORE_INSERTS, 52 0, hr, LANG_USER_DEFAULT, VarPtr(pszMsg) As PTSTR, 0, 0) 53 If pszMsg <> 0 Then 54 HResultToString = New String(pszMsg) 55 LocalFree(pszMsg) 56 End If 57 End Function 49 58 50 59 /*! … … 68 77 */ 69 78 Sub WindowsException(hr As HRESULT) 70 Exception( hresultToString(hr))79 Exception(HResultToString(hr)) 71 80 HResult = hr 72 81 End Sub … … 98 107 End Sub 99 108 Private 100 Static Function hresultToString(hr As HRESULT) As String101 Dim pszMsg As PCSTR102 FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER Or FORMAT_MESSAGE_FROM_SYSTEM Or FORMAT_MESSAGE_IGNORE_INSERTS,103 0, hr, LANG_USER_DEFAULT, VarPtr(pszMsg) As PTSTR, 0, 0)104 If pszMsg <> 0 Then105 hresultToString = New String(pszMsg)106 LocalFree(pszMsg)107 End If108 End Function109 109 End Class 110 110 -
trunk/ab5.0/ablib/src/Classes/System/Environment.ab
r586 r603 69 69 Static Function OSVersion() As OperatingSystem 70 70 Dim vi As OSVERSIONINFO 71 vi.dwOSVersionInfoSize = Len(vi) 71 72 GetVersionEx(vi) 72 73 OSVersion = New OperatingSystem(vi) -
trunk/ab5.0/ablib/src/Classes/System/Math.ab
r589 r603 315 315 End If 316 316 End Function 317 317 /* 318 318 Static Function Sign(value As Double) As Long 319 319 If value = 0 Then … … 325 325 End If 326 326 End Function 327 /* 327 328 328 Static Function Sign(value As SByte) As Long 329 329 If value = 0 Then -
trunk/ab5.0/ablib/src/WinNT.ab
r599 r603 1177 1177 'ACCESS TYPES 1178 1178 1179 'Const DELETE = (&h00010000)1179 Const DELETE = (&h00010000) 1180 1180 Const READ_CONTROL = (&h00020000) 1181 1181 Const WRITE_DAC = (&h00040000) -
trunk/ab5.0/ablib/src/basic.sbp
r497 r603 132 132 InitializeCriticalSection(_System_CriticalSection) 133 133 134 _System_hProcessHeap=HeapCreate( HEAP_GENERATE_EXCEPTIONS,0,0)134 _System_hProcessHeap=HeapCreate(0,0,0) 135 135 136 136 ' GC管理オブジェクトを初期化
Note:
See TracChangeset
for help on using the changeset viewer.