Changeset 303


Ignore:
Timestamp:
Aug 24, 2007, 11:14:46 AM (15 years ago)
Author:
イグトランス (egtra)
Message:

フルコンパイルでのミスあぶり出し。註:修正は全て@300や@301以前に行われた。

Location:
trunk/Include
Files:
2 added
1 deleted
30 edited

Legend:

Unmodified
Added
Removed
  • trunk/Include/Classes/ActiveBasic/Windows/CriticalSection.ab

    r297 r303  
    77
    88Namespace Detail
    9     Const InterlockedExchangeAnyPointer(p, x) = InterlockedExchangePointer(VarPtr(p) As VoidPtr, x)
     9    Const InterlockedExchangeAnyPointer(p, x) = InterlockedExchangePointer(ByVal VarPtr(p) As *VoidPtr, x)
    1010End Namespace
    1111
     
    5353
    5454    /*Override*/ Sub Dispose()
    55         Dim pcs = Detail.InterlockedExchangeAnyPointer(pcs, 0)
    56         If pcs <> 0 Then
    57             LeaveCriticalSection(ByVal pcs)
     55'       Dim p = ActiveBasic.Windows.Detail.InterlockedExchangeAnyPointer(pcs, 0)
     56        Dim p = InterlockedExchangePointer(pcs As VoidPtr, 0) As *CRITICAL_SECTION
     57        If p <> 0 Then
     58            LeaveCriticalSection(ByVal p)
    5859        End If
    5960    End Sub
  • trunk/Include/Classes/ActiveBasic/Windows/WindowHandle.sbp

    r302 r303  
    1 ' Windows/WindowHandle.sbp
    2 
    3 #ifndef __WINDOWS_WINDOWHANDLE_SBP__
    4 #define __WINDOWS_WINDOWHANDLE_SBP__
     1'Classes/ActiveBasic/Windows/WindowHandle.sbp
    52
    63#ifdef _WIN64
     
    1613#endif
    1714Declare Function _System_GetParent Lib "user32" Alias "GetParent" (hWnd As HWND) As HWND
    18 Declare Function _System_SetParent Lib "user32" Alias "SetParent" (hWnd As HWND) As HWND
     15Declare Function _System_SetParent Lib "user32" Alias "SetParent" (hWnd As HWND, hwndParent As HWND) As HWND
    1916Declare Function _System_GetMenu Lib "user32" Alias "GetMenu" (hWnd As HWND) As HMENU
    20 Declare Function _System_SetMenu Lib "user32" Alias "SetMenu" (hWnd As HWND) As HMENU
     17Declare Function _System_SetMenu Lib "user32" Alias "SetMenu" (hWnd As HWND, hmenu As HMENU) As HMENU
    2118Declare Function _System_InvalidateRect Lib "user32" Alias "InvalidateRect" (hWnd As HWND, ByRef Rect As RECT, bErase As BOOL) As BOOL
    2219Declare Function _System_InvalidateRgn Lib "user32" Alias "InvalidateRgn" (hWnd As HWND, hRgn As HRGN, bErase As BOOL) As BOOL
     
    3330Declare Function _System_GetWindowRect Lib "user32" Alias "DrawMenuBar" (hWnd As HWND, ByRef Rect As RECT) As BOOL
    3431Declare Function _System_IsWindow Lib "user32" Alias "IsWindow" (hWnd As HWND) As BOOL
    35 Declare Function _System_Isiconic Lib "user32" Alias "Isiconic" (hWnd As HWND) As BOOL
     32Declare Function _System_IsIconic Lib "user32" Alias "IsIconic" (hWnd As HWND) As BOOL
    3633Declare Function _System_GetClientRect Lib "user32" Alias "GetClientRect" (hWnd As HWND, ByRef Rect As RECT) As BOOL
    3734Declare Function _System_GetProp Lib "user32" Alias _FuncName_GetProp (hWnd As HWND, pString As PCTSTR) As HANDLE
     
    4138Declare Function _System_SetScrollInfo Lib "user32" Alias "SetScrollInfo" (hWnd As HWND, fnBar As Long, ByRef lpsi As SCROLLINFO, bRedraw As Long) As BOOL
    4239Declare Function _System_GetSystemMenu Lib "user32" Alias "GetSystemMenu" (hWnd As HWND, bRevert As BOOL) As HMENU
    43 Declare Function _System_GetDC Lib "gdi32" Alias "GetDC" (hwnd As HWND) As HDC
    44 Declare Function _System_ReleaseDC Lib "gdi32" Alias "ReleaseDC" (hwnd As HWND, hdc As HDC) As BOOL
     40Declare Function _System_GetDC Lib "user32" Alias "GetDC" (hwnd As HWND) As HDC
     41Declare Function _System_GetDCEx Lib "user32" Alias "GetDCEx" (hwnd As HWND, hrgnClip As HRGN, flags As DWord) As HDC
     42Declare Function _System_GetWindowDC Lib "user32" Alias "GetWindowDC" (hwnd As HWND) As HDC
     43Declare Function _System_ReleaseDC Lib "user32" Alias "ReleaseDC" (hwnd As HWND, hdc As HDC) As BOOL
     44Declare Function _System_SendMessage Lib "user32" Alias _FuncName_SendMessage (hwnd As HWND, msg As DWord, wp As WPARAM, lp As LPARAM) As LRESULT
     45Declare Function _System_PostMessage Lib "user32" Alias _FuncName_PostMessage (hwnd As HWND, msg As DWord, wp As WPARAM, lp As LPARAM) As LRESULT
     46Declare Function _System_SendDlgItemMessage Lib "user32" Alias _FuncName_SendDlgItemMessage (hwnd As HWND, id As DWord, msg As DWord, wp As WPARAM, lp As LPARAM) As LRESULT
     47Declare Function _System_GetWindowThreadProcessId Lib "user32" Alias "GetWindowThreadProcessId" (hwnd As HWND, pdwProcessId As *DWord) As DWord
     48
     49Namespace ActiveBasic
     50Namespace Windows
    4551
    4652Class WindowHandle
     
    5561    End Sub
    5662
    57     Sub WindowHandle(wnd As WindowHandle)
    58         hwnd = wnd.hwnd
    59     End Sub
    60 
    61     Sub Operator =(hwndNew As HWND)
    62         hwnd = hwndNew
    63     End Sub
    64 
    6563    Const Function HWnd() As HWND
    6664        Return hwnd
     
    7876        Return _System_BeginPaint(hwnd, ps)
    7977    End Function
    80 
     78/*
    8179    Const Function ChildFromPoint(x As Long, y As Long) As WindowHandle
    8280        Return New WindowHandle(ChildWindowFromPoint(hwnd, x, y))
     
    8684        Return New WindowHandle(ChildWindowFromPointEx(hwnd, x, y, flags))
    8785    End Function
    88 
     86*/
    8987    Const Function ClientToScreen(ByRef pt As POINTAPI) As Boolean
    9088        Return _System_ClientToScreen(hwnd, pt) As Boolean
     
    10199
    102100    Function CreateCaret(hbmp As HBITMAP, width As Long, height As Long) As Boolean
    103         Return _System_CreateCaret(hwnd, hbmp, width, hegiht) As Boolean
     101        Return _System_CreateCaret(hwnd, hbmp, width, height) As Boolean
    104102    End Function
    105103
     
    111109        Return _System_DrawMenuBar(hwnd) As Boolean
    112110    End Function
    113 
     111/*
    114112    Function EnableScrollBar(SBFlags As DWord, arrows As DWord) As Boolean
    115113        Return EnableScrollBar(hwnd, SBFlags, arrows) As Boolean
    116114    End Function
    117 
     115*/
    118116    Function Enable(enable As Boolean) As Boolean
    119117        Return EnableWindow(hwnd, enable) As Boolean
     
    137135
    138136    Const Function GetClassName(className As PTSTR, maxCount As Long) As Long
    139         Return _System_GetClassName(className, maxCount)
     137        Return _System_GetClassName(hwnd, className, maxCount)
    140138    End Function
    141139
     
    143141        Return _System_GetClientRect(hwnd, rc) As Boolean
    144142    End Function
    145 
     143/*
    146144    Const Function GetContextHelpId() As DWord
    147145        Return GetWindowContextHelpId(hwnd)
    148146    End Function
    149 
     147*/
    150148    Function GetDC() As HDC
    151149        Return _System_GetDC(hwnd)
     
    153151
    154152    Function GetDCEx(hrgnClip As HRGN, flags As DWord) As HDC
    155         Return GetDCEx(hwnd, hrgnClip, flags)
    156     End Function
    157 
     153        Return _System_GetDCEx(hwnd, hrgnClip, flags)
     154    End Function
     155/*
    158156    Const Function GetDlgCtrlID() As Long
    159157        Return GetDlgCtrlID(hwnd)
     
    167165        Return GetDlgItemText(hwnd, idDlgItem, ps, maxCount)
    168166    End Function
    169 
     167*/
    170168    Const Function GetMenu() As HMENU
    171169        Return _System_GetMenu(hwnd)
    172170    End Function
    173 
     171/*
    174172    Const Function GetParent() As WindowHandle
    175173        Return New WindowHandle(_System_GetParent(hwnd))
    176174    End Function
    177 
     175*/
    178176    Const Function GetProp(str As String) As HANDLE
    179177        Return _System_GetProp(hwnd, ToTCStr(str))
     
    191189        Return _System_GetScrollInfo(hwnd, fnBar, si) As Boolean
    192190    End Function
    193 
     191/*
    194192    Const Function GetSystemMenu(revert As Boolean) As HMENU
    195193        Return GetSystemMenu(hwnd, revert)
     
    207205        Return GetWindow(hwnd, cmd)
    208206    End Function
    209 
     207*/
    210208    Function GetWindowDC() As HDC
    211         Return GetWindowDC(hwnd)
     209        Return _System_GetWindowDC(hwnd)
    212210    End Function
    213211
     
    215213        Return _System_GetWindowLongPtr(hwnd, index)
    216214    End Function
    217 
     215/*
    218216    Const Function GetWindowPlasement(ByRef wndpl As WINDOWPLACEMENT) As Boolean
    219217        Return GetWindowPlasement(hwnd, wndpl) As Boolean
    220218    End Function
    221 
     219*/
    222220    Const Function GetWindowRect(ByRef rc As RECT) As Boolean
    223         Return _System_GetWindowRect(rc) As Boolean
     221        Return _System_GetWindowRect(hwnd, rc) As Boolean
    224222    End Function
    225223
    226224    Const Function GetText(ps As PTSTR, maxCount As Long) As Boolean
    227         Return GetWindowText(ps, maxCount) As Boolean
     225        Return GetWindowText(hwnd, ps, maxCount) As Boolean
    228226    End Function
    229227
     
    233231
    234232    Const Function GetWindowThreadId() As DWord
    235         Return GetWindowProcessThreadId(hwnd, 0)
    236     End Function
    237 
    238     Const Function GetWindowProcessThreadId(ByRef processId As DWord) As DWord
    239         Return GetWindowProcessThreadId(hwnd, VarPtr(processId))
     233        Return _System_GetWindowThreadProcessId(hwnd, 0)
     234    End Function
     235
     236    Const Function GetWindowThreadProcessId(ByRef processId As DWord) As DWord
     237        Return _System_GetWindowThreadProcessId(hwnd, VarPtr(processId))
    240238    End Function
    241239
     
    267265        Return _System_InvalidateRect(hwnd, ByVal 0, TRUE) As Boolean
    268266    End Function
    269 
     267/*
    270268    Const Function IsChild(hwnd As HWND) As Boolean
    271269        Return IsChild(This.hwnd, hwnd) As Boolean
     
    275273        Return IsDialogMessage(hwnd, msg) As Boolean
    276274    End Function
    277 
     275*/
    278276    Const Function IsIconic() As Boolean
    279277        Return _System_IsIconic(hwnd) As Boolean
     
    295293        Return IsWindowVisible(hwnd) As Boolean
    296294    End Function
    297 
     295/*
    298296    Const Function IsZoomed() As Boolean
    299297        Return IsZoomed(hwnd) As Boolean
     
    303301        Return KillTimer(idEvent) As Boolean
    304302    End Function
    305 
     303*/
    306304    Function LockUpdate() As Boolean
    307305        Return LockWindowUpdate(hwnd) As Boolean
    308306    End Function
    309 
     307/*
    310308    Function MapPoints(hwndTo As HWND, pPoints As *POINTAPI, cPoints As DWord) As Long
    311309        Return MapWindowPoints(hwnd, hwndTo, pPoints, cPoints)
     
    327325        Return MessageBox(hwnd, text, 0, MB_OK)
    328326    End Function
    329 
     327*/
    330328    Function Move(x As Long, y As Long, width As Long, height As Long, repaint As Boolean) As Boolean
    331329        Return MoveWindow(hwnd, x, y, width, height, repaint) As Boolean
     
    336334    End Function
    337335
    338     Function Move(ByRef rc As RECT, repeaint As Boolean) As Boolean
     336    Function Move(ByRef rc As RECT, repaint As Boolean) As Boolean
    339337        With rc
    340338            Return MoveWindow(hwnd, .left, .top, .right - .left, .bottom - .top, repaint) As Boolean
     
    347345        End With
    348346    End Function
    349 
     347/*
    350348    Function OpenClipboard() As Boolean
    351349        Return OpenClipboard(hwnd) As Boolean
     
    355353        Return OpenIcon(hwnd) As Boolean
    356354    End Function
    357 
     355*/
    358356    Function PostMessage(msg As DWord, wp As WPARAM, lp As LPARAM) As Boolean
    359         Return PostMessage(hwnd, msg, wp, lp) As Boolean
     357        Return _System_PostMessage(hwnd, msg, wp, lp) As Boolean
    360358    End Function
    361359
    362360    Function PostMessage(msg As DWord) As Boolean
    363         Return PostMessage(hwnd, msg, 0, 0) As Boolean
    364     End Function
    365 
     361        Return _System_PostMessage(hwnd, msg, 0, 0) As Boolean
     362    End Function
     363/*
    366364    Function RedrawWindow(ByRef rcUpdate As RECT, hrgnUpdate As HRGN, flags As DWord) As Boolean
    367365        Return RedrawWindow(hwnd, rcUpdatre, hrgnUpdate, flags) As Boolean
    368366    End Function
    369 
     367*/
    370368    Function ReleaseDC(hdc As HDC) As Boolean
    371369        Return _System_ReleaseDC(hwnd, hdc) As Boolean
    372370    End Function
    373 
     371/*
    374372    Function RemoveProp(str As String) As HANDLE
    375373        Return RemoveProp(hwnd, ToTCStr(str))
     
    383381        Return RemoveProp(hwnd, atom As ULONG_PTR As PCTSTR)
    384382    End Function
    385 
     383*/
    386384    Const Function ScreenToClient(ByRef pt As POINTAPI) As Boolean
    387385        Return _System_ScreenToClient(hwnd, pt) As Boolean
     
    398396
    399397    Function SendDlgItemMessage(idDlgItem As Long, msg As DWord, wp As WPARAM, lp As LPARAM) As LRESULT
    400         Return SendDlgItemMessage(hwnd, idDlgItem, wp, lp)
     398        Return _System_SendDlgItemMessage(hwnd, idDlgItem, msg, wp, lp)
    401399    End Function
    402400
    403401    Function SendDlgItemMessage(idDlgItem As Long, msg As DWord) As LRESULT
    404         Return SendDlgItemMessage(hwnd, idDlgItem, 0, 0)
     402        Return _System_SendDlgItemMessage(hwnd, idDlgItem, msg, 0, 0)
    405403    End Function
    406404
    407405    Function SendMessage(msg As DWord, wp As WPARAM, lp As LPARAM) As LRESULT
    408         Return SendMessage(hwnd, msg, wp, lp)
     406        Return _System_SendMessage(hwnd, msg, wp, lp)
    409407    End Function
    410408
    411409    Function SendMessage(msg As DWord) As LRESULT
    412         Return SendMessage(hwnd, msg, 0, 0)
    413     End Function
    414 
     410        Return _System_SendMessage(hwnd, msg, 0, 0)
     411    End Function
     412/*
    415413    Function SetActiveWindow() As WindowHandle
    416414        Return New WindowHandle(SetActiveWindow(hwnd))
     
    424422        Return New WindowHandle(SetCapture(hwnd))
    425423    End Function
    426 
     424*/
    427425    Function SetClassLongPtr(index As Long, newLong As LONG_PTR) As LONG_PTR
    428426        Return _System_SetClassLongPtr(hwnd, index, newLong)
    429427    End Function
    430 
     428/*
    431429    Function SetFocus() As WindowHandle
    432430        Return New WindowHandle(SetFocus(hwnd))
    433431    End Function
    434 
     432*/
    435433    Function SetForeground() As Boolean
    436434        Return SetForegroundWindow(hwnd) As Boolean
     
    454452
    455453    Function SetProp(atom As ATOM, hData As HANDLE) As Boolean
    456         Return SetProp((atom As ULONG_PTR) As PCTSTR, hData) As Boolean
     454        Return This.SetProp((atom As ULONG_PTR) As PCTSTR, hData) As Boolean
    457455    End Function
    458456
     
    464462        Return _System_SetScrollInfo(hwnd, fnBar, si, TRUE) As Boolean
    465463    End Function
    466 
     464/*
    467465    Function SetTimer(idEvent As ULONG_PTR, elapse As DWord, timerFunc As TIMERPROC) As ULONG_PTR
    468466        Return SetTmer(hwnd, idEvent, elapse, timerFunc)
     
    470468
    471469    Function SetTimer(idEvent As ULONG_PTR, elapse As DWord) As ULONG_PTR
    472         Return SetTmer(hwnd, idEvent, elapse, 0)
     470        Return This.SetTmer(hwnd, idEvent, elapse, 0)
    473471    End Function
    474472
     
    476474        Return SetContextHelpId(hwnd, contextHelpId) As Boolean
    477475    End Function
    478 
     476*/
    479477    Function SetWindowLongPtr(index As Long, newLong As LONG_PTR) As LONG_PTR
    480478        Return _System_SetWindowLongPtr(hwnd, index, newLong)
    481479    End Function
    482 
     480/*
    483481    Function SetWindowPlacement(ByRef wndpl As WINDOWPLACEMENT) As Boolean
    484482        Return SetWindowPlacement(hwnd, wndpl) As Boolean
    485483    End Function
    486 
     484*/
    487485    Function SetPos(hwndInsertAfter As HWND, x As Long, y As Long, cx As Long, cy As Long, flags As DWord) As Boolean
    488486        Return SetWindowPos(hwnd, hwndInsertAfter, x, y, cx, cy, flags) As Boolean
     
    514512        Return _System_ShowCaret(hwnd) As Boolean
    515513    End Function
    516 
     514/*
    517515    Function ShowScrollBar(bar As DWord, show As Boolean) As Boolean
    518516        Return ShowScrollBar(hwnd, bar, show) As Boolean
     
    522520        Return ShowScrollBar(hwnd, bar, TRUE) As Boolean
    523521    End Function
    524 
     522*/
    525523    Function Show(cmdShow As DWord) As Boolean
    526524        Return ShowWindow(hwnd, cmdShow) As Boolean
     
    556554        Return _System_GetWindowLongPtr(hwnd, GWL_STYLE) As DWord
    557555    End Function
    558 
     556#ifdef _UNDEF
    559557    Const Function GetWndProc() As WNDPROC
    560         Return _System_GetWindowLongPtr(hwnd, GWLP_HINSTANCE) As WNDPROC
    561     End Function
    562 
     558        Return _System_GetWindowLongPtr(hwnd, GWLP_WNDPROC) As WNDPROC
     559    End Function
     560#endif
    563561    Const Function GetInstance() As HINSTANCE
    564562        Return _System_GetWindowLongPtr(hwnd, GWLP_HINSTANCE) As HINSTANCE
     
    576574        Return _System_SetWindowLongPtr(hwnd, GWL_STYLE, style) As DWord
    577575    End Function
    578 
     576#ifdef _UNDEF
    579577    Function SetWndProc(wndProc As WNDPROC) As WNDPROC
    580         Return _System_SetWindowLongPtR(hwnd, GWLP_WNDPROC, wndProc As WNDPROC) As WNDPROC
    581     End Function
    582 
     578        Return _System_SetWindowLongPtr(hwnd, GWLP_WNDPROC, wndProc As WNDPROC) As WNDPROC
     579    End Function
     580#endif
    583581    Function SetUserData(value As LONG_PTR) As LONG_PTR
    584         Return _System_SetWindowLongPtr(value As LONG_PTR)
     582        Return _System_SetWindowLongPtr(hwnd, GWLP_USERDATA, value As LONG_PTR)
    585583    End Function
    586584
     
    592590        Return rc
    593591    End Function
    594 
     592#ifdef _UNDEF
    595593    Sub ClientRect(ByRef rc As RECT)
    596594        Dim hasMenu As BOOL
    597         If IsChild() = False And IsMenu() <> False Then
     595        If IsChild() = False And GetMenu() <> 0 Then
    598596            hasMenu = TRUE
    599597        Else
     
    601599        End If
    602600        AdjustWindowRectEx(rc, GetStyle(), hasMenu, GetExStyle())
    603         MoveWindow(rc) ' WindowRect = rc
    604     End Sub
    605 
     601        This.Move(rc) ' WindowRect = rc
     602    End Sub
     603#endif
    606604    Const Function WindowRect() As RECT
    607605        Dim rc As RECT
     
    611609
    612610    Sub WindowRect(ByRef rc As RECT)
    613         MoveWindow(rc)
    614     End Sub
    615 
     611        This.Move(rc)
     612    End Sub
     613#ifdef _UNDEF
    616614    Const Function ContextHelpID() As DWord
    617615        Return GetContextHelpId(hwnd)
     
    634632        Return w
    635633    End Function
    636 
     634#endif
    637635    Const Function ExStyle() As DWord
    638636        Return _System_GetWindowLongPtr(hwnd, GWL_EXSTYLE) As DWord
     
    640638
    641639    Sub ExStyle(newExStyle As DWord)
    642         _System_SetWindowLongPtr(hwnd, GWLP_EXSTYLE, newExStyle)
     640        _System_SetWindowLongPtr(hwnd, GWL_EXSTYLE, newExStyle)
    643641    End Sub
    644642
     
    648646
    649647    Sub Style(newStyle As DWord)
    650         _System_SetWindowLongPtr(hwnd, GWLP_STYLE, newStyle)
     648        _System_SetWindowLongPtr(hwnd, GWL_STYLE, newStyle)
    651649    End Sub
    652650
     
    660658
    661659    Const Function Font() As HFONT
    662         Return SendMessage(hwnd, WM_GETFONT, 0, 0) As HFONT
     660        Return _System_SendMessage(hwnd, WM_GETFONT, 0, 0) As HFONT
    663661    End Function
    664662
    665663    Sub Font(hfntNew As HFONT)
    666         SendMessage(hwnd, WM_SETFONT, hfntNew As WPARAM, TRUE)
     664        _System_SendMessage(hwnd, WM_SETFONT, hfntNew As WPARAM, TRUE)
    667665    End Sub
    668666
     
    680678
    681679    Const Function Minimized() As Boolean
    682         Return IsIconic(hwnd) As Boolean
     680        Return _System_IsIconic(hwnd) As Boolean
    683681    End Function
    684682
     
    705703    End Sub
    706704
    707     Const Function ProcessID() As DWord
    708         GetWindowProcessThreadId(ProcessID)
    709     End Function
    710 
    711     Const Function ThreadID() As DWord
    712         Return GetWindowProcessThreadId(ByVal 0)
     705    Const Function ProcessId() As DWord
     706        GetWindowThreadProcessId(ProcessId)
     707    End Function
     708
     709    Const Function ThreadId() As DWord
     710        Return GetWindowThreadProcessId(ByVal 0)
    713711    End Function
    714712
     
    759757        Return GetWindowTextLength(hwnd)
    760758    End Function
    761 
     759#ifdef _UNDEF
    762760    Const Function UserData() As LONG_PTR
    763761        Return _System_GetWindowLongPtr(hwnd, GWLP_USERDATA)
     
    767765        _System_SetWindowLongPtr(hwnd, GWLP_USERDATA, newValue)
    768766    End Sub
    769 
     767#endif
    770768    Const Function Visible() As Boolean
    771         Return IsVisible(hwnd) As Boolean
     769        Return IsWindowVisible(hwnd) As Boolean
    772770    End Function
    773771
     
    779777        EndIf
    780778    End Sub
    781 
     779#ifdef _UNDEF
    782780    Const Function WindowPlacement() As WINDOWPLACEMENT
    783781        WindowPlacement.length = Len(WindowPlacement)
     
    796794        _System_SetWindowLongPtr(hwnd, GWLP_WNDPROC, newWndProc As LONG_PTR)
    797795    End Sub
    798 
     796#endif
    799797Protected
    800798    Sub SetHWnd(hwndNew As HWND)
     
    803801End Class
    804802
    805 #endif '__WINDOWS_WINDOWHANDLE_SBP__
     803End Namespace 'Widnows
     804End Namespace 'ActiveBasic
  • trunk/Include/Classes/ActiveBasic/Windows/Windows.ab

    r269 r303  
    2727    Return GetFolderPath(0, folder)
    2828End Function
     29/*
     30Function MessageBox(hw As HWND, s As PCSTR, t As PCSTR, b As DWord) As DWord
     31    Return MessageBoxA(hw, s, t, b)
     32End Function
     33
     34Function MessageBox(hw As HWND, s As PCWSTR, t As PCWSTR, b As DWord) As DWord
     35    Return MessageBoxW(hw, s, t, b)
     36End Function
     37*/
     38
     39Namespace Detail
     40Function _System_MessageBox(hw As HWND, s As PCSTR, t As PCSTR, b As DWord) As DWord
     41    Return MessageBoxA(hw, s, t, b)
     42End Function
     43
     44Function _System_MessageBox(hw As HWND, s As PCWSTR, t As PCWSTR, b As DWord) As DWord
     45    Return MessageBoxW(hw, s, t, b)
     46End Function
     47End Namespace
    2948
    3049End Namespace 'Widnows
  • trunk/Include/Classes/System/Drawing/Color.ab

    r282 r303  
    6969            Exit Sub ' パレットインデックス指定は無効
    7070        Else
    71             argb = Color_MakeARGB(255, GetRValue(rgb), GetGValue(rgb), GetBValue(rgb))
     71            argb = MakeARGB(255, GetRValue(rgb) As Byte, GetGValue(rgb) As Byte, GetBValue(rgb) As Byte)
    7272        End If
    7373    End Sub
     
    8282
    8383    Static Function FromArgb(argb As ARGB) As Color
    84         Dim c As Color(argb)
    85         Rteurn c
     84        Return New Color(argb)
    8685    End Function
    8786
    8887    Static Function FromArgb(a As Byte, base As Color) As Color
    89         Dim c As Color(a, base.R, base.G, base.B)
    90         Return c
     88        Return New Color(a, base.R, base.G, base.B)
    9189    End Function
    9290
    9391    Static Function FromArgb(r As Byte, g As Byte, b As Byte) As Color
    94         Dim c As Color(r, g, b)
    95         Return c
     92        Return New Color(r, g, b)
    9693    End Function
    9794
    9895    Static Function FromArgb(a As Byte, r As Byte, g As Byte, b As Byte) As Color
    99         Dim c As Color(a, r, g, b)
    100         Return c
     96        Return New Color(a, r, g, b)
    10197    End Function
    10298
     
    119115        d = max - min
    120116        If g = max Then
    121             Return (b - r) As Double / d * 60 + 120
     117            Return ((b - r) As Double / d * 60.0 + 120.0) As Single
    122118        ElseIf b = max Then
    123             Return (r - g) As Double / d * 60 + 240
     119            Return ((r - g) As Double / d * 60 + 240) As Single
    124120        ElseIf g < b Then
    125             Return (g - b) As Double / d * 60 + 360
     121            Return ((g - b) As Double / d * 60 + 360) As Single
    126122        Else
    127             Return (g - b) As Double / d * 60
     123            Return ((g - b) As Double / d * 60) As Single
    128124        EndIf
    129125    End Function
    130126
    131127    Function GetSaturation() As Single
    132         Dim max As Long, min As Long
    133128        Dim r = R
    134129        Dim g = G
    135130        Dim b = B
    136         max = System.Math.Max(System.Math.Max(r, g), b)
    137         min = System.Math.Min(System.Math.Min(r, g), b)
     131        Dim max = System.Math.Max(System.Math.Max(r, g), b) As Long
     132        Dim min = System.Math.Min(System.Math.Min(r, g), b) As Long
    138133        Return (max - min) / max
    139134    End Function
    140135
    141136    Function GetBrightness() As Single
    142         Dim max As Long
    143137        Dim r = R
    144138        Dim g = G
    145139        Dim b = B
    146         max = System.Math.Max(System.Math.Max(r, g), b)
     140        Dim max = System.Math.Max(System.Math.Max(r, g), b)
    147141        Return max * (1 / 255)
    148142    End Function
  • trunk/Include/Classes/System/Drawing/Point.ab

    r223 r303  
    7575
    7676    Static Function Add(pt1 As Point, pt2 As Point) As Point
    77         Dim ret As Point(pt1.x + pt2.x, pt1.y + pt2.y)
    78         Return ret
     77        Return New Point(pt1.x + pt2.x, pt1.y + pt2.y)
    7978    End Function
    8079
    8180    Static Function Add(pt As Point, sz As Size) As Point
    82         Dim ret As Point(pt.x + sz.Width, pt.y + sz.Height)
    83         Return ret
     81        Return New Point(pt.x + sz.Width, pt.y + sz.Height)
    8482    End Function
    8583
    8684    Function Offset(pt As Point) As Point
    87         Dim ret As Point(x + pt.x, y + pt.y)
    88         Return ret
     85        Return New Point(x + pt.x, y + pt.y)
    8986    End Function
    9087
     
    9592
    9693    Static Function Substract(pt1 As Point, pt2 As Point) As Point
    97         Dim ret As Point(pt1.x - pt2.x, pt1.y - pt2.y)
    98         Return ret
     94        Return New Point(pt1.x - pt2.x, pt1.y - pt2.y)
    9995    End Function
    10096
    10197    Static Function Substract(pt As Point, sz As Size) As Point
    102         Dim ret As Point(pt.x - sz.Width, pt.y - sz.Height)
    103         Return ret
     98        Return New Point(pt.x - sz.Width, pt.y - sz.Height)
    10499    End Function
    105100
     
    113108
    114109    Static Function Ceiling(ptf As PointF) As Point
    115         Dim pt As Size(Math.Ceiling(ptf.width), Math.Ceiling(ptf.height))
    116         Return pt
     110        Return New Point(System.Math.Ceiling(ptf.X) As Long, System.Math.Ceiling(ptf.Y) As Long)
    117111    End Function
    118112
    119113    Static Function Round(ptf As PointF) As Point
    120         Dim pt As Point(Math.Round(ptf.width), Math.Round(ptf.height))
    121         Return pt
     114        Return New Point(System.Math.Round(ptf.X) As Long, System.Math.Round(ptf.Y) As Long)
    122115    End Function
    123116
    124117    Static Function Truncate(ptf As PointF) As Point
    125         Dim pt As Point(Math.Truncate(ptf.width), Math.Truncate(ptf.height))
    126         Return pt
     118        Return New Point(System.Math.Truncate(ptf.X) As Long, System.Math.Truncate(ptf.Y) As Long)
    127119    End Function
    128120
    129121    Function Operator () As PointF
    130         Return Return PointF(X, Y)
     122        Return New PointF(X, Y)
    131123    End Function
    132124
  • trunk/Include/Classes/System/Drawing/PointF.ab

    r212 r303  
    4848        Return x = 0 And y = 0
    4949    End Function
    50 /*
    51     Sub Operator = (ByRef pt As PointF)
    52         x = pt.x
    53         y = pt.y
    54     End Sub
    55 */
     50
    5651    Function Operator + (pt As PointF) As PointF
    5752        Return Add(This, pt)
  • trunk/Include/Classes/System/Drawing/Rectangle.ab

    r223 r303  
    110110    End Function
    111111
    112     Function Operator == (rc As Rectangle)
     112    Function Operator == (rc As Rectangle) As Boolean
    113113        Return Equals(rc)
    114114    End Function
    115115
    116     Function Operator <> (rc As Rectangle)
    117         Return Not Equals(rc)
     116    Function Operator <> (rc As Rectangle) As Boolean
     117        Return (Not Equals(rc))
    118118    End Function
    119119
     
    147147
    148148    Sub Inflate(dx As Long, dy As Long)
    149         X -= dx
    150         Y -= dy
    151         Width += dx + dx
    152         Height += dy + dy
     149        x -= dx
     150        y -= dy
     151        width += dx + dx
     152        height += dy + dy
    153153    End Sub
    154154
     
    158158
    159159    Static Function Inflate(rc As Rectangle, x As Long, y As Long) As Rectangle
    160         Inflate = New Rectangle(rc)
     160        Inflate = New Rectangle(rc.X, rc.Y, rc.Width, rc.Height)
    161161        Inflate.Inflate(x, y)
    162162    End Function
    163163
    164164    Sub Intersect(rect As Rectangle)
    165         This = Rectangle.Intersect(This, rect)
     165        Dim r = Rectangle.Intersect(This, rect)
     166        x = r.x
     167        y = r.y
     168        width = r.width
     169        height = r.height
    166170    End Sub
    167171
    168172    Static Function Intersect(a As Rectangle, ByRef b As Rectangle) As Rectangle
    169173        Dim right As Long, bottom As Long, left As Long, top As Long
    170         right = Math.Min(a.Right, b.Right)
    171         bottom = Math.Min(a.Bottom, b.Bottom)
    172         left = Math.Min(a.Left, b.Left)
    173         top = Math.Min(a.Top, b.Top)
     174        right = System.Math.Min(a.Right, b.Right)
     175        bottom = System.Math.Min(a.Bottom, b.Bottom)
     176        left = System.Math.Min(a.Left, b.Left)
     177        top = System.Math.Min(a.Top, b.Top)
    174178        Return Rectangle.FromLTRB(left, top, right, bottom)
    175179    End Function
     
    184188    Static Function Union(a As Rectangle, b As Rectangle) As Rectangle
    185189        Dim right As Long, bottom As Long, left As Long, top As Long
    186         right = Math.Max(a.Right(), b.Right())
    187         bottom = Math.Max(a.Bottom(), b.Bottom())
    188         left = Math.Max(a.Left(), b.Left())
    189         top = Math.Max(a.Top(), b.Top())
     190        right = System.Math.Max(a.Right(), b.Right())
     191        bottom = System.Math.Max(a.Bottom(), b.Bottom())
     192        left = System.Math.Max(a.Left(), b.Left())
     193        top = System.Math.Max(a.Top(), b.Top())
    190194        Return FromLTRB(left, top, right, bottom)
    191195    End Function
     
    196200
    197201    Sub Offset(dx As Long, dy As Long)
    198         X += dx
    199         Y += dy
     202        x += dx
     203        y += dy
    200204    End Sub
    201205
    202206    Static Function Ceiling(rcf As RectangleF) As Rectangle
    203207        Dim r As Rectangle(
    204             Math.Ceiling(rcf.X),
    205             Math.Ceiling(rcf.Y),
    206             Math.Ceiling(rcf.Width),
    207             Math.Ceiling(rcf.Height))
     208            System.Math.Ceiling(rcf.X) As Long,
     209            System.Math.Ceiling(rcf.Y) As Long,
     210            System.Math.Ceiling(rcf.Width) As Long,
     211            System.Math.Ceiling(rcf.Height) As Long)
    208212        Return r
    209213    End Function
     
    211215    Static Function Round(rcf As RectangleF) As Rectangle
    212216        Dim r As Rectangle(
    213             Math.Round(rcf.X),
    214             Math.Round(rcf.Y),
    215             Math.Round(rcf.Width),
    216             Math.Round(rcf.Height))
     217            System.Math.Round(rcf.X) As Long,
     218            System.Math.Round(rcf.Y) As Long,
     219            System.Math.Round(rcf.Width) As Long,
     220            System.Math.Round(rcf.Height) As Long)
    217221        Return r
    218222    End Function
     
    220224    Static Function Truncate(rcf As RectangleF) As Rectangle
    221225        Dim r As Rectangle(
    222             Math.Truncate(rcf.X),
    223             Math.Truncate(rcf.Y),
    224             Math.Truncate(rcf.Width),
    225             Math.Truncate(rcf.Height))
     226            System.Math.Truncate(rcf.X) As Long,
     227            System.Math.Truncate(rcf.Y) As Long,
     228            System.Math.Truncate(rcf.Width) As Long,
     229            System.Math.Truncate(rcf.Height) As Long)
    226230        Return r
    227231    End Function
  • trunk/Include/Classes/System/Drawing/RectangleF.ab

    r212 r303  
    106106
    107107    Function IsEmpty() As Boolean
    108         If Width <= 0 Or Height <= 0 Then
    109             IsEmpty = _System_TRUE
    110         Else
    111             IsEmpty = _System_FALSE
    112         End If
    113     End Function
    114 /*
    115     Function Operator =(ByRef rc As RectangleF)
    116         With rc
    117             x = .x
    118             y = .y
    119             width = .width
    120             height = .height
    121         End With
    122     End Function
    123 */
    124     Function Operator ==(rc As RectangleF)
     108        Return Width <= 0 Or Height <= 0
     109    End Function
     110
     111    Function Operator ==(rc As RectangleF) As Boolean
    125112        Return Equals(rc)
    126113    End Function
    127114
    128     Function Operator <>(rc As RectangleF)
     115    Function Operator <>(rc As RectangleF) As Boolean
    129116        Return Not Equals(rc)
    130117    End Function
    131118
    132119    Function Equals(rc As RectangleF) As Boolean
    133         If X = rc.X And Y = rc.Y And Width = rc.Width And Height = rc.Height Then
    134             Return True
    135         Else
    136             Return False
    137         End If
     120        Equals = (X = rc.X And Y = rc.Y And Width = rc.Width And Height = rc.Height)
    138121    End Function
    139122
     
    147130
    148131    Function Contains(x As Single, y As Single) As Boolean
    149         If x >= X And x < X + Width And y >= Y And y < Y + Height Then
    150             Contains = _System_TRUE
    151         Else
    152             Contains = _System_FALSE
    153         End If
     132        Contains = (x >= X And x < X + Width And y >= Y And y < Y + Height)
    154133    End Function
    155134
     
    159138
    160139    Function Contains(rc As RectangleF) As Boolean
    161         If X <= rc.X And rc.Right <= Right And Y <= rc.Y And rc.Bottom <= Bottom Then
    162             Return True
    163         Else
    164             Return False
    165         End If
     140        Contains = (X <= rc.X And rc.Right <= Right And Y <= rc.Y And rc.Bottom <= Bottom)
    166141    End Function
    167142
    168143    Sub Inflate(dx As Single, dy As Single)
    169         X -= dx
    170         Y -= dy
    171         Width += dx + dx
    172         Height += dy + dy
     144        x -= dx
     145        y -= dy
     146        width += dx + dx
     147        height += dy + dy
    173148    End Sub
    174149
     
    178153
    179154    Static Function Inflate(rc As RectangleF, x As Single, y As Single) As RectangleF
    180         Inflate = New Rectangle(rc)
     155        Inflate = New RectangleF(rc.X, rc.Y, rc.Width, rc.Height)
    181156        Inflate.Inflate(x, y)
    182157    End Function
    183158
    184159    Sub Intersect(rect As RectangleF)
    185         This = RectangleF.Intersect(This, rect)
     160        Dim r = RectangleF.Intersect(This, rect)
     161        x = r.x
     162        y = r.y
     163        width = r.width
     164        height = r.height
    186165    End Sub
    187166   
    188167    Static Function Intersect(a As RectangleF, b As RectangleF) As RectangleF
    189168        Dim right As Single, bottom As Single, left As Single, top As Single
    190         right = Math.Min(a.Right, b.Right)
    191         bottom = Math.Min(a.Bottom, b.Bottom)
    192         left = Math.Min(a.Left, b.Left)
    193         top = Math.Min(a.Top, b.Top)
     169        right = System.Math.Min(a.Right, b.Right)
     170        bottom = System.Math.Min(a.Bottom, b.Bottom)
     171        left = System.Math.Min(a.Left, b.Left)
     172        top = System.Math.Min(a.Top, b.Top)
    194173        Return FromLTRB(left, top, right, bottom)
    195174    End Function
     
    200179            Right > rc.Left And _
    201180            Bottom > rc.Top Then
    202             IntersectsWith = _System_TRUE
     181            IntersectsWith = True
    203182        Else
    204             IntersectsWith = _System_FALSE
     183            IntersectsWith = False
    205184        End If
    206185    End Function
     
    208187    Static Function Union(a As RectangleF, b As RectangleF) As RectangleF
    209188        Dim right As Single, bottom As Single, left As Single, top As Single
    210         right = Math.Max(a.Right(), b.Right())
    211         bottom = Math.Max(a.Bottom(), b.Bottom())
    212         left = Math.Max(a.Left(), b.Left())
    213         top = Math.Max(a.Top(), b.Top())
     189        right = System.Math.Max(a.Right(), b.Right())
     190        bottom = System.Math.Max(a.Bottom(), b.Bottom())
     191        left = System.Math.Max(a.Left(), b.Left())
     192        top = System.Math.Max(a.Top(), b.Top())
    214193        Return FromLTRB(left, top, right, bottom)
    215194    End Function
     
    220199
    221200    Sub Offset(dx As Single, dy As Single)
    222         X += dx
    223         Y += dy
     201        x += dx
     202        y += dy
    224203    End Sub
    225204
  • trunk/Include/Classes/System/Drawing/Size.ab

    r223 r303  
    7070    Function Equals(sz As Size) As Boolean
    7171        If width = sz.width And height = sz.height Then
    72             Equals = _System_TRUE
     72            Equals = True
    7373        Else
    74             Equals = _System_FALSE
     74            Equals = False
    7575        End If
    7676    End Function
     
    9393
    9494    Static Function Ceiling(szf As SizeF) As Size
    95         Dim sz As Size(Math.Ceiling(szf.width), Math.Ceiling(szf.height))
     95        Dim sz As Size(System.Math.Ceiling(szf.Width) As Long, System.Math.Ceiling(szf.Height) As Long)
    9696        Return sz
    9797    End Function
    9898
    9999    Static Function Round(szf As SizeF) As Size
    100         Dim sz As Size(Math.Round(szf.width), Math.Round(szf.height))
     100        Dim sz As Size(System.Math.Round(szf.Width) As Long, System.Math.Round(szf.Height) As Long)
    101101        Return sz
    102102    End Function
    103103
    104104    Static Function Truncate(szf As SizeF) As Size
    105         Dim sz As Size(Math.Truncate(szf.width), Math.Truncate(szf.height))
     105        Dim sz As Size(System.Math.Truncate(szf.Width) As Long, System.Math.Truncate(szf.Height) As Long)
    106106        Return sz
    107107    End Function
  • trunk/Include/Classes/System/Drawing/SizeF.ab

    r223 r303  
    6868
    6969    Override Function GetHashCode() As Long
    70         Return VarPtr(GetDWord(width)) Xor _System_BSwap(VarPtr(GetDWord(height)))
     70        Return GetDWord(VarPtr(width)) Xor _System_BSwap(GetDWord(VarPtr(height)))
    7171    End Function
    7272
     
    7575    End Function
    7676
    77     Function Add(sz As Size) As Size
     77    Function Add(sz As SizeF) As SizeF
    7878        Return This + sz
    7979    End Function
  • trunk/Include/Classes/System/Media/SystemSound.ab

    r116 r303  
    1515Public
    1616    Sub Play()
    17         PlaySound(SoundID,GetModuleHandle(NULL),SND_ALIAS_ID)
     17        PlaySound(SoundID As LPCTSTR, GetModuleHandle(NULL), SND_ALIAS_ID)
    1818    End Sub
    1919
  • trunk/Include/Classes/System/Threading/Thread.ab

    r249 r303  
    281281        For i=0 To ELM(ThreadNum)
    282282
    283             If currentThread.Equals( ByVal ppobj_Thread[i] ) Then
     283            If currentThread.Equals( ppobj_Thread[i] As Object ) Then
    284284                Continue
    285285            End If
     
    298298        For i=0 To ELM(ThreadNum)
    299299
    300             If currentThread.Equals( ByVal ppobj_Thread[i] ) Then
     300            If currentThread.Equals( ppobj_Thread[i] As Object ) Then
    301301                Continue
    302302            End If
  • trunk/Include/Classes/System/Windows/Forms/Control.ab

    r285 r303  
    44#define __SYSTEM_WINDOWS_FORMS_CONTROL_AB__
    55
    6 #require <windows/WindowHandle.sbp>
    76#require <Classes/System/Windows/Forms/misc.ab>
    87#require <Classes/System/Windows/Forms/CreateParams.ab>
     
    1716#require <Classes/System/Drawing/Rectangle.ab>
    1817#require <Classes/System/Runtime/InteropServices/GCHandle.ab>
     18#require <Classes/ActiveBasic/Windows/WindowHandle.sbp>
    1919#require <Classes/ActiveBasic/Strings/Strings.ab>
    2020
     
    4444
    4545    Override Function CompletedSynchronously() As Boolean
    46         Return FALSE
     46        Return False
    4747    End Function
    4848
     
    7474
    7575Class Control
     76
    7677'   Inherits IWin32Window
    7778Public
     
    8081    Function AllowDrop() As Boolean
    8182    End Function
     83
     84    'Anchor
     85    'AutoScrollOffset
     86    'AutoSize
     87    'BackColor下
     88    'BackgroundImage
     89    'BackgroundImageLayout
     90    '-BindingContext
     91    'Bottom 下
     92    'Bounds 下
     93    'CanFocus
     94    'CanSelect
     95    'Capture
     96    '-CausesValidation
     97    'CheckForIllegalCrossThreadCalls
    8298
    8399    /*Override*/ Function Handle() As HWND
     
    201217        Return b.Top + b.Height
    202218    End Function
    203 
     219/*
    204220    Const Function PointToScreen(p As Point) As Point
    205221        PointToScreen = New Point
    206         ret.X = p.X
    207         ret.Y = p.Y
    208         wnd.ClientToScreen(ByVal VarPtr(PointToScreen) As *POINTAPI)
     222        PointToScreen.X = p.X
     223        PointToScreen.Y = p.Y
     224        wnd.ClientToScreen(ByVal ObjPtr(PointToScreen) As *POINTAPI)
    209225    End Function
    210226
    211227    Const Function PointToClient(p As Point) As Point
    212228        PointToScreen = New Point
    213         ret.X = p.X
    214         ret.Y = p.Y
    215         wnd.ScreenToClient(ByVal VarPtr(PointToScreen) As *POINTAPI)
    216     End Function
    217 
     229        PointToClient.X = p.X
     230        PointToClient.Y = p.Y
     231        wnd.ScreenToClient(ByVal ObjPtr(PointToClient) As *POINTAPI)
     232    End Function
     233*/
    218234    Const Function RectangleToScreen(r As Rectangle) As Rectangle
    219235        Dim rc = r.ToRECT
     
    223239
    224240    Const Function RectangleToClient(r As Rectangle) As Rectangle
    225         Dim rc As RECT
    226         rc = r.ToRECT()
     241        Dim rc = r.ToRECT()
    227242        wnd.ScreenToClient(rc)
    228243        Return New Rectangle(rc)
     
    230245
    231246    Const Function InvokeRequired() As Boolean
    232         Return wnd.ThreadID <> GetCurrentThreadId()
     247        Return wnd.ThreadId <> GetCurrentThreadId()
    233248    End Function
    234249
     
    239254    Virtual Sub BackColor(c As Color)
    240255        c = bkColor
    241         Dim e As EventArgs
    242         OnBackColorChanged(e)
     256        OnBackColorChanged(New EventArgs)
    243257    End Sub
    244258
     
    248262
    249263    Const Function IsHandleCreated() As Boolean
    250         Return wnd.HWnd <> 0
     264        Return wnd.HWnd <> 0 Or IsWindow(wnd.HWnd) <> FALSE
    251265    End Function
    252266
     
    259273
    260274    Sub Control()
     275        Debug
    261276        Dim sz = DefaultSize()
    262277        Control("", 100, 100, sz.Width, sz.Height)
     
    279294
    280295    Sub Control(parent As Control, text As String, left As Long, top As Long, width As Long, height As Long)
    281         This.parent = VarPtr(parent)
     296        This.parent = parent
    282297        Control(text, left, top, width, height)
    283298    End Sub
     
    296311    '---------------------------------------------------------------------------
    297312    ' Public Methods
    298 
     313/*
    299314    ' 同期関数呼出、Controlが作成されたスレッドで関数を実行する。
    300315    ' 関数は同期的に呼び出されるので、関数が終わるまでInvokeは制御を戻さない。
     
    317332        Dim gch = System.Runtime.InteropServices.GCHandle.Alloc(asyncInvokeData)
    318333        wnd.PostMessage(WM_CONTROL_BEGININVOKE, 0, System.Runtime.InteropServices.GCHandle.ToIntPtr(gch))
    319         Return pAsyncResult
     334        Return asyncResult
    320335    End Function
    321336
     
    327342        Return arInvoke.Result
    328343    End Function
    329 
     344*/
    330345    ' 与えられたウィンドウハンドルがControl(若しくはその派生クラス)の
    331346    ' インスタンスに対応するものであった場合、
     
    360375
    361376    Sub Show()
     377        Debug
    362378        wnd.Show(SW_SHOW)
    363379    End Sub
     
    396412    Virtual Sub CreateHandle()
    397413        Dim createParams = CreateParams()
    398         Dim gch = GCHandle.Alloc(This)
    399         TlsSetValue(tlsIndex, GCHandle.ToIntPtr(gch) As VoidPtr)
     414        Dim gch = System.Runtime.InteropServices.GCHandle.Alloc(This)
     415        TlsSetValue(tlsIndex, System.Runtime.InteropServices.GCHandle.ToIntPtr(gch) As VoidPtr)
    400416        With createParams
    401417            Dim hwndParent = 0 As HWND
     
    516532Private
    517533    ' Member variables
    518     wnd As WindowHandle
     534    wnd As ActiveBasic.Windows.WindowHandle
    519535    text As String
    520536    parent As Control
     
    590606                ExitThread(-1)
    591607            End If
    592             rThis.wnd = New WindowHandle(hwnd)
     608            rThis.wnd = New ActiveBasic.Windows.WindowHandle(hwnd)
    593609            SetWindowLongPtr(hwnd, GWLP_THIS, gchValue)
    594610        End If
  • trunk/Include/Classes/System/Windows/Forms/Message.ab

    r282 r303  
    5555        Return hwnd = x.hwnd And _
    5656            msg = x.msg And _
    57             wp = .wp And _
    58             lp = .lp And _
    59             lr = .lr
     57            wp = x.wp And _
     58            lp = x.lp And _
     59            lr = x.lr
    6060    End Function
    6161
  • trunk/Include/Classes/System/Windows/Forms/index.ab

    r223 r303  
    99#require <Classes/System/Windows/Forms/CreateParams.ab>
    1010#require <Classes/System/Windows/Forms/PaintEventArgs.ab>
     11#require <Classes/System/Windows/Forms/MessageBox.ab>
    1112
    1213#endif '__SYSTEM_WINDOWS_FORMS_INDEX_AB__
  • trunk/Include/Classes/System/Windows/Forms/misc.ab

    r282 r303  
    1 ' Classes/System/Windows/Forms/misc.ab
     1'Classes/System/Windows/Forms/misc.ab
    22
    33#ifndef __SYSTEM_WINDOWS_FORMS_MISC_AB__
     
    197197End Enum
    198198
     199Enum DialogResult
     200    None = 0
     201    OK = IDOK
     202    Abort = IDABORT
     203    Cancel = IDCANCEL
     204    Retry = IDRETRY
     205    Ignore = IDIGNORE
     206    Yes = IDYES
     207    No = IDNO
     208End Enum
     209
    199210End Namespace 'Forms
    200211End Namespace 'Widnows
  • trunk/Include/OAIdl.ab

    r300 r303  
    77
    88'#ifndef COM_NO_WINDOWS_H
    9 #include <windows.sbp>
    10 #include <ole2.ab>
     9#require <windows.sbp>
     10#require <ole2.ab>
    1111'#endif /*COM_NO_WINDOWS_H*/
    1212
    13 #include <objidl.sbp>
     13#require <objidl.sbp>
    1414
    1515#ifndef __IOleAutomationTypes_INTERFACE_DEFINED__
    1616#define __IOleAutomationTypes_INTERFACE_DEFINED__
    17 
    18 TypeDef SCODE = Long
    1917
    2018/* interface IOleAutomationTypes */
     
    694692Const Enum VARKIND
    695693    VAR_PERINSTANCE = 0
    696     VAR_STATIC = VAR_PERINSTANCE + 1
    697     VAR_CONST = VAR_STATIC + 1
    698     VAR_DISPATCH = VAR_CONST + 1
     694    VAR_STATIC = 1
     695    VAR_CONST = 2
     696    VAR_DISPATCH = 3
    699697End Enum
    700698
     
    893891    Function DeleteFuncDesc(
    894892        /* [in] */ index As DWord) As HRESULT
    895 
    896893    Function DeleteFuncDescByMemId(
    897894        /* [in] */ memid As *MEMBERID,
    898895        /* [in] */ invKind As *INVOKEKIND) As HRESULT
    899 
    900896    Function DeleteVarDesc(
    901897        /* [in] */ index As DWord) As HRESULT
    902 
    903898    Function DeleteVarDescByMemId(
    904899        /* [in] */ memid As *MEMBERID) As HRESULT
    905 
    906900    Function DeleteImplType(
    907901        /* [in] */ index As DWord) As HRESULT
    908 
    909902    Function SetCustData(
    910903        /* [in] */ ByRef guid As GUID,
    911904        /* [in] */ ByRef VarVal As VARIANT) As HRESULT
    912 
    913905    Function SetFuncCustData(
    914906        /* [in] */ index As DWord,
    915907        /* [in] */ ByRef guid As GUID,
    916908        /* [in] */ ByRef VarVal As VARIANT) As HRESULT
    917 
    918909    Function SetParamCustData(
    919910        /* [in] */ indexFunc As DWord,
     
    921912        /* [in] */ ByRef guid As GUID,
    922913        /* [in] */ ByRef VarVal As VARIANT) As HRESULT
    923 
    924914    Function SetVarCustData(
    925915        /* [in] */ index As DWord,
    926916        /* [in] */ ByRef guid As GUID,
    927917        /* [in] */ ByRef VarVal As VARIANT) As HRESULT
    928 
    929918    Function SetImplTypeCustData(
    930919        /* [in] */ index As DWord,
    931920        /* [in] */ ByRef guid As GUID,
    932921        /* [in] */ ByRef VarVal As VARIANT) As HRESULT
    933 
    934922    Function SetHelpStringContext(
    935923        /* [in] */ dwHelpStringContext As DWord) As HRESULT
    936 
    937924    Function SetFuncHelpStringContext(
    938925        /* [in] */ index As DWord,
    939926        /* [in] */ dwHelpStringContext As DWord) As HRESULT
    940 
    941927    Function SetVarHelpStringContext(
    942928        /* [in] */ index As DWord,
    943929        /* [in] */ dwHelpStringContext As DWord) As HRESULT
    944 
    945930    Function Invalidate() As HRESULT
    946 
    947931    Function SetName(
    948932        /* [in] */ szName As LPOLESTR) As HRESULT
     
    959943
    960944TypeDef LPCREATETYPELIB = /* [unique] */ *ICreateTypeLib
    961 
    962945
    963946Dim IID_ICreateTypeLib = [&h00020406, &h0000, &h0000, [&hC0, &h00, &h00, &h00, &h00, &h00, &h00, &h46]] As IID
     
    968951        /* [in] */ szName As LPOLESTR,
    969952        /* [in] */ tkind As *TYPEKIND,
    970         /* [out] */ ByRef pCTInfo As *ICreateTypeInfo) As HRESULT
    971 
     953        /* [out] */ ByRef CTInfo As ICreateTypeInfo) As HRESULT
    972954    Function SetName(
    973955        /* [in] */ szName As LPOLESTR) As HRESULT
    974 
    975956    Function SetVersion(
    976957        /* [in] */ wMajorVerNum As Word,
    977958        /* [in] */ wMinorVerNum As Word) As HRESULT
    978 
    979959    Function SetGuid(
    980960        /* [in] */ ByRef guid As GUID) As HRESULT
    981 
    982961    Function SetDocString(
    983962        /* [in] */ szDoc As LPOLESTR) As HRESULT
    984 
    985963    Function SetHelpFileName(
    986964        /* [in] */ szHelpFileName As LPOLESTR) As HRESULT
    987 
    988965    Function SetHelpContext(
    989966        /* [in] */ dwHelpContext As DWord) As HRESULT
    990 
    991967    Function SetLcid(
    992968        /* [in] */ lcid As LCID) As HRESULT
    993 
    994969    Function SetLibFlags(
    995970        /* [in] */ uLibFlags As DWord) As HRESULT
    996 
    997971    Function SaveAllChanges() As HRESULT
    998972End Interface
    999 
    1000973
    1001974#endif  /* __ICreateTypeLib_INTERFACE_DEFINED__ */
     
    1017990    Function DeleteTypeInfo(
    1018991        /* [in] */ szName As LPOLESTR) As HRESULT
    1019 
    1020992    Function SetCustData(
    1021993        /* [in] */ ByRef guid As GUID,
    1022994        /* [in] */ ByRef VarVal As VARIANT) As HRESULT
    1023 
    1024995    Function SetHelpStringContext(
    1025996        /* [in] */ dwHelpStringContext As DWord) As HRESULT
    1026 
    1027997    Function SetHelpStringDll(
    1028998        /* [in] */ szFileName As LPOLESTR) As HRESULT
    1029 
    1030999End Interface
    10311000
     
    11821151    Function /* [local] */ GetTypeAttr(
    11831152        /* [out] */ ByRef pTypeAttr As *TYPEATTR) As HRESULT
    1184 
    11851153    Function GetTypeComp(
    1186         /* [out] */ ByRef pTComp As *ITypeComp) As HRESULT
    1187 
     1154        /* [out] */ ByRef TComp As ITypeComp) As HRESULT
    11881155    Function /* [local] */ GetFuncDesc(
    11891156        /* [in] */ index As DWord,
    11901157        /* [out] */ ByRef pFuncDesc As *FUNCDESC) As HRESULT
    1191 
    11921158    Function /* [local] */ GetVarDesc(
    11931159        /* [in] */ index As DWord,
    11941160        /* [out] */ ByRef pVarDesc As *VARDESC) As HRESULT
    1195 
    11961161    Function /* [local] */ GetNames(
    11971162        /* [in] */ memid As MEMBERID,
     
    11991164        /* [in] */ cMaxNames As DWord,
    12001165        /* [out] */ ByRef cNames As DWord) As HRESULT
    1201 
    12021166    Function GetRefTypeOfImplType(
    12031167        /* [in] */ index As DWord,
    12041168        /* [out] */ ByRef RefType As HREFTYPE) As HRESULT
    1205 
    12061169    Function GetImplTypeFlags(
    12071170        /* [in] */ index As DWord,
    12081171        /* [out] */ ByRef ImplTypeFlags As Long) As HRESULT
    1209 
    12101172    Function /* [local] */ GetIDsOfNames(
    12111173        /* [size_is][in] */ rgszNames As *LPOLESTR,
    12121174        /* [in] */ cNames As DWord,
    12131175        /* [size_is][out] */ pMemId As *MEMBERID) As HRESULT
    1214 
    12151176    Function /* [local] */ Invoke(
    12161177        /* [in] */ pvInstance As VoidPtr,
     
    12211182        /* [out] */ ByRef ExcepInfo As EXCEPINFO,
    12221183        /* [out] */ ByRef uArgErr As DWord) As HRESULT
    1223 
    12241184    Function /* [local] */ GetDocumentation(
    12251185        /* [in] */ memid As MEMBERID,
     
    12281188        /* [out] */ ByRef dwHelpContext As DWord,
    12291189        /* [out] */ ByRef BstrHelpFile As BSTR) As HRESULT
    1230 
    12311190    Function /* [local] */ GetDllEntry(
    12321191        /* [in] */ memid As MEMBERID,
     
    12351194        /* [out] */ ByRef BstrName As BSTR,
    12361195        /* [out] */ ByRef wOrdinal As Word) As HRESULT
    1237 
    12381196    Function GetRefTypeInfo(
    12391197        /* [in] */ hRefType As HREFTYPE,
    1240         /* [out] */ ByRef pTInfo As *ITypeInfo) As HRESULT
    1241 
     1198        /* [out] */ ByRef TInfo As ITypeInfo) As HRESULT
    12421199    Function /* [local] */ AddressOfMember(
    12431200        /* [in] */ memid As MEMBERID,
    12441201        /* [in] */ invKind As INVOKEKIND,
    12451202        /* [out] */ ByRef pv As VoidPtr) As HRESULT
    1246 
    12471203    Function /* [local] */ CreateInstance(
    1248         /* [in] */ pUnkOuter As *IUnknown,
     1204        /* [in] */ pUnkOuter As IUnknown,
    12491205        /* [in] */ ByRef riid As IID,
    12501206        /* [iid_is][out] */ ByRef pvObj As Any) As HRESULT
    1251 
    12521207    Function GetMops(
    12531208        /* [in] */ memid As MEMBERID,
    12541209        /* [out] */ ByRef BstrMops As BSTR) As HRESULT
    1255 
    12561210    Function /* [local] */ GetContainingTypeLib(
    1257         /* [out] */ ByRef pTLib As *ITypeLib,
     1211        /* [out] */ ByRef TLib As ITypeLib,
    12581212        /* [out] */ ByRef Index As DWord) As HRESULT
    1259 
    12601213    Sub /* [local] */ ReleaseTypeAttr(
    12611214        /* [in] */ pTypeAttr As *TYPEATTR)
    1262 
    12631215    Sub /* [local] */ ReleaseFuncDesc(
    12641216        /* [in] */ pFuncDesc As *FUNCDESC)
    1265 
    12661217    Sub /* [local] */ ReleaseVarDesc(
    12671218        /* [in] */ pVarDesc As *VARDESC)
     
    16451596        /* [out] */ ByRef cbSize As DWord) As HRESULT
    16461597    Function GetTypeInfo(
    1647         /* [out] */ ByRef pTypeInfo As *ITypeInfo) As HRESULT
     1598        /* [out] */ ByRef TypeInfo As ITypeInfo) As HRESULT
    16481599    Function GetField(
    16491600        /* [in] */ pvData As VoidPtr,
     
    16561607        /* [out] */ ByRef pvDataCArray As VoidPtr) As HRESULT
    16571608    Function PutField(
    1658         /* [in] */ wFlags As DWord,
     1609        /* [in] */ wFlags As DWord,
    16591610        /* [out][in] */ pvData As VoidPtr,
    16601611        /* [in] */ szFieldName As LPCOLESTR,
    16611612        /* [in] */ ByRef varField As VARIANT) As HRESULT
    16621613    Function PutFieldNoCopy(
    1663         /* [in] */ wFlags As DWord,
     1614        /* [in] */ wFlags As DWord,
    16641615        /* [out][in] */ pvData As VoidPtr,
    16651616        /* [in] */ szFieldName As LPCOLESTR,
     
    17181669        /* [in] */ pszPropName As LPCOLESTR,
    17191670        /* [out][in] */ ByRef Var As VARIANT,
    1720         /* [in] */ pErrorLog As *IErrorLog) As HRESULT
     1671        /* [in] */ ErrorLog As IErrorLog) As HRESULT
    17211672
    17221673    Function Write(
  • trunk/Include/OleAuto.ab

    r300 r303  
    2222*/
    2323
    24 #include <oaidl.ab>
     24#require <oaidl.ab>
    2525'Dummy
    2626
  • trunk/Include/api_window.sbp

    r300 r303  
    10711071Const MB_RIGHT =                  &H00080000
    10721072Const MB_RTLREADING =             &H00100000
     1073Const MB_SERVICE_NOTIFICATION =   &H00200000
    10731074#ifdef UNICODE
    10741075Declare Function MessageBox Lib "user32" Alias "MessageBoxW" (hwnd As HWND, pText As PCWSTR, pCaption As PCWSTR, uType As DWord) As Long
  • trunk/Include/basic.sbp

    r300 r303  
    11'basic.sbp
    2 
    3 #_core
    42
    53' Unicodeが不安定な間の暫定対応
     
    97#ifndef _INC_BASIC
    108#define _INC_BASIC
    11 
    129
    1310Sub _System_InitDllGlobalVariables()    'dummy
     
    5451TypeDef Int16 = Integer
    5552TypeDef Int8 = SByte
    56 
    57 TypeDef BOOL = Long
    5853
    5954' Boolena型の定数
     
    122117' Specify elements number
    123118'--------------------------
    124 Const ELM(n) = (n - 1)
     119Const ELM(n) = ((n) - 1)
    125120
    126 #include <windows.sbp>
    127 #include <crt.sbp>
    128 #include <objbase.sbp>
     121#require <windows.sbp>
     122#require <crt.sbp>
    129123
    130124
     
    138132Sub _System_StartupProgram()
    139133    'Unsafe
     134
    140135        'この関数はアプリケーションの起動時にシステムからコールバックされます
    141136
     
    150145        ActiveBasic.Core._System_TypeBase.Initialize()
    151146
    152         ' Initialize static variables
     147        'Initialize static variables
    153148        _System_InitStaticLocalVariables()
    154149
     
    168163        ' GC管理オブジェクトを破棄
    169164        _System_pGC->Finish()
    170         _System_free( _System_pGC )
     165'       _System_free( _System_pGC )
    171166
    172167        DeleteCriticalSection(_System_CriticalSection)
     
    178173
    179174
    180 #include <system\interface.ab>
    181 #include <system\built_in.ab>
    182 #include <system\string.sbp>
    183 #include <system\debug.sbp>
    184 #include <system\gc.sbp>
    185 #include <system\enum.sbp>
    186 #include <system\exception.ab>
    187175
    188 #include <Classes\index.ab>
     176#require <system\string.sbp>
     177#require <system\debug.sbp>
     178#require <system\gc.sbp>
     179#require <system\enum.sbp>
     180#require <system\exception.ab>
     181
     182#require <Classes\index.ab>
    189183
    190184
    191 #include <basic\function.sbp>
    192 #include <basic\command.sbp>
     185#require <basic\function.sbp>
     186#require <basic\command.sbp>
    193187
    194188
  • trunk/Include/basic/command.sbp

    r288 r303  
    77#require <windows.sbp>
    88#require <Classes/System/Environment.ab>
     9#require <Classes/ActiveBasic/Windows/Windows.ab>
    910
    1011Const _System_Type_SByte = 1
     
    6566'----------------
    6667
    67 Function _System_MessageBox(hw As HWND, s As PCSTR, t As PCSTR, b As DWord) As DWord
    68     Return MessageBoxA(hw, s, t, b)
    69 End Function
    70 
    71 Function _System_MessageBox(hw As HWND, s As PCWSTR, t As PCWSTR, b As DWord) As DWord
    72     Return MessageBoxW(hw, s, t, b)
    73 End Function
    74 
    7568Macro MSGBOX(hwnd As HWND, str As String)(title As String, boxType As DWord, ByRef retAns As DWord)
     69    Dim ret = ActiveBasic.Windows.Detail._System_MessageBox(hwnd, ToSCStr(str), ToSCStr(title), boxType)
    7670    If VarPtr(retAns) Then
    77         retAns = _System_MessageBox(hwnd, ToSCStr(str), ToSCStr(title), boxType)
    78     Else
    79         _System_MessageBox(hwnd, ToSCStr(str), ToSCStr(title), boxType)
     71        retAns = ret
    8072    End If
    8173End Macro
     
    424416Macro FIELD(FileNumber As Long, FieldSize As Long)
    425417    FileNumber--
    426 
    427418    _System_FieldSize(FileNumber)=FieldSize
    428419End Macro
    429 Macro GET(FileNumber As Long, RecodeNumber As Long, ByRef lpBuffer As String)
     420Macro GET(FileNumber As Long, RecodeNumber As Long, ByRef buffer As String)
    430421    Dim dwAccessByte As DWord
    431422
     
    434425
    435426    SetFilePointer(_System_hFile(FileNumber), SizeOf (StrChar) * RecodeNumber * _System_FieldSize(FileNumber), 0, FILE_BEGIN)
    436     lpBuffer = ZeroString(_System_FieldSize(FileNumber))
    437     ReadFile(_System_hFile(FileNumber), StrPtr(lpBuffer), SizeOf (StrChar) * _System_FieldSize(FileNumber), VarPtr(dwAccessByte),ByVal 0)
    438     If Not dwAccessByte=_System_FieldSize(FileNumber) Then
    439         lpBuffer = Left$(lpBuffer, dwAccessByte)
     427    Dim t = ZeroString(_System_FieldSize(FileNumber))
     428    ReadFile(_System_hFile(FileNumber), StrPtr(t), SizeOf (StrChar) * _System_FieldSize(FileNumber), VarPtr(dwAccessByte), ByVal 0)
     429    If dwAccessByte = _System_FieldSize(FileNumber) Then
     430        buffer = t.ToString
     431    Else
     432        buffer = Left$(t.ToString, dwAccessByte)
    440433    End If
    441434End Macro
    442 Macro PUT(FileNumber As Long, RecodeNumber As Long, ByRef lpBuffer As String)
     435Macro PUT(FileNumber As Long, RecodeNumber As Long, buffer As String)
    443436    Dim dwAccessByte As DWord
    444437
     
    447440
    448441    SetFilePointer(_System_hFile(FileNumber), SizeOf (StrChar) * RecodeNumber*_System_FieldSize(FileNumber), 0, FILE_BEGIN)
    449     WriteFile(_System_hFile(FileNumber), StrPtr(lpBuffer),SizeOf (StrChar) * _System_FieldSize(FileNumber), VarPtr(dwAccessByte), ByVal 0)
     442    WriteFile(_System_hFile(FileNumber), StrPtr(buffer), SizeOf (StrChar) * _System_FieldSize(FileNumber), VarPtr(dwAccessByte), ByVal 0)
    450443End Macro
    451444
  • trunk/Include/basic/function.sbp

    r289 r303  
    10191019End Function
    10201020
     1021Function _System_PtrObj(p As VoidPtr) As Object
     1022    SetPointer(VarPtr(_System_PtrObj), p)
     1023End Function
     1024
    10211025'--------
    10221026' 文字列関数その2
  • trunk/Include/directx9/d3d9.sbp

    r1 r303  
    99Const D3D_SDK_VERSION = 32
    1010
    11 #include <directx9\d3d9types.sbp>
    12 #include <directx9\d3d9caps.sbp>
     11#require <directx9\d3d9types.sbp>
     12#require <directx9\d3d9caps.sbp>
    1313
    1414
     
    2424'--------------------
    2525
    26 Class IDirect3D9
     26Interface IDirect3D9
    2727    Inherits IUnknown
    2828Public
    2929    'IDirect3D9 methods
    30     Abstract Function ShoRegisterSoftwareDevice(pInitializeFunction As VoidPtr) As DWord
    31     Abstract Function GetAdapterCount() As DWord
    32     Abstract Function GetAdapterIdentifier(Adapter As DWord, Flags As DWord, pIdentifier As *D3DADAPTER_IDENTIFIER9) As DWord
    33     Abstract Function GetAdapterModeCount(Adapter As DWord, Format As D3DFORMAT) As DWord
    34     Abstract Function EnumAdapterModes(Adapter As DWord, Format As D3DFORMAT, Mode As DWord, pMode As *D3DDISPLAYMODE) As DWord
    35     Abstract Function GetAdapterDisplayMode(Adapter As DWord, pMode As *D3DDISPLAYMODE) As DWord
    36     Abstract Function CheckDeviceType(Adapter As DWord, DevType As D3DDEVTYPE, AdapterFormat As D3DFORMAT, BackBufferFormat As D3DFORMAT, bWindowed As Long) As DWord
    37     Abstract Function CheckDeviceFormat(Adapter As DWord, DeviceType As D3DDEVTYPE, AdapterFormat As D3DFORMAT, Usage As DWord, RType As D3DRESOURCETYPE, CheckFormat As D3DFORMAT) As DWord
    38     Abstract Function CheckDeviceMultiSampleType(Adapter As DWord, DeviceType As D3DDEVTYPE, SurfaceFormat As D3DFORMAT, Windowed As Long, MultiSampleType As D3DMULTISAMPLE_TYPE, pQualityLevels As DWordPtr) As DWord
    39     Abstract Function CheckDepthStencilMatch(Adapter As DWord, DeviceType As D3DDEVTYPE, AdapterFormat As D3DFORMAT, RenderTargetFormat As D3DFORMAT, DepthStencilFormat As D3DFORMAT) As DWord
    40     Abstract Function CheckDeviceFormatConversion(Adapter As DWord, DeviceType As D3DDEVTYPE, SourceFormat As D3DFORMAT, TargetFormat As D3DFORMAT) As DWord
    41     Abstract Function GetDeviceCaps(Adapter As DWord, DeviceType As D3DDEVTYPE, pCaps As *D3DCAPS9) As DWord
    42     Abstract Function GetAdapterMonitor(Adapter As DWord) As DWord
    43     Abstract Function CreateDevice(Adapter As DWord, DeviceType As D3DDEVTYPE, hFocusWindow As HWND, BehaviorFlags As DWord, pPresentationParameters As *D3DPRESENT_PARAMETERS, ppReturnedDeviceInterface As *LPDIRECT3DDEVICE9) As DWord
    44 End Class
     30    Function ShoRegisterSoftwareDevice(pInitializeFunction As VoidPtr) As DWord
     31    Function GetAdapterCount() As DWord
     32    Function GetAdapterIdentifier(Adapter As DWord, Flags As DWord, pIdentifier As *D3DADAPTER_IDENTIFIER9) As DWord
     33    Function GetAdapterModeCount(Adapter As DWord, Format As D3DFORMAT) As DWord
     34    Function EnumAdapterModes(Adapter As DWord, Format As D3DFORMAT, Mode As DWord, pMode As *D3DDISPLAYMODE) As DWord
     35    Function GetAdapterDisplayMode(Adapter As DWord, pMode As *D3DDISPLAYMODE) As DWord
     36    Function CheckDeviceType(Adapter As DWord, DevType As D3DDEVTYPE, AdapterFormat As D3DFORMAT, BackBufferFormat As D3DFORMAT, bWindowed As Long) As DWord
     37    Function CheckDeviceFormat(Adapter As DWord, DeviceType As D3DDEVTYPE, AdapterFormat As D3DFORMAT, Usage As DWord, RType As D3DRESOURCETYPE, CheckFormat As D3DFORMAT) As DWord
     38    Function CheckDeviceMultiSampleType(Adapter As DWord, DeviceType As D3DDEVTYPE, SurfaceFormat As D3DFORMAT, Windowed As Long, MultiSampleType As D3DMULTISAMPLE_TYPE, pQualityLevels As DWordPtr) As DWord
     39    Function CheckDepthStencilMatch(Adapter As DWord, DeviceType As D3DDEVTYPE, AdapterFormat As D3DFORMAT, RenderTargetFormat As D3DFORMAT, DepthStencilFormat As D3DFORMAT) As DWord
     40    Function CheckDeviceFormatConversion(Adapter As DWord, DeviceType As D3DDEVTYPE, SourceFormat As D3DFORMAT, TargetFormat As D3DFORMAT) As DWord
     41    Function GetDeviceCaps(Adapter As DWord, DeviceType As D3DDEVTYPE, pCaps As *D3DCAPS9) As DWord
     42    Function GetAdapterMonitor(Adapter As DWord) As DWord
     43    Function CreateDevice(Adapter As DWord, DeviceType As D3DDEVTYPE, hFocusWindow As HWND, BehaviorFlags As DWord, pPresentationParameters As *D3DPRESENT_PARAMETERS, ppReturnedDeviceInterface As *LPDIRECT3DDEVICE9) As DWord
     44End Interface
    4545TypeDef LPDIRECT3D9 = *IDirect3D9
    4646
    47 Class IDirect3DDevice9
     47Interface IDirect3DDevice9
    4848    Inherits IUnknown
    4949Public
    5050    'IDirect3DDevice9 methods
    51     Abstract Function TestCooperativeLevel() As DWord
    52     Abstract Function GetAvailableTextureMem() As DWord
    53     Abstract Function EvictManagedResources() As DWord
    54     Abstract Function GetDirect3D(ppD3D9 As *LPDIRECT3D9) As DWord
    55     Abstract Function GetDeviceCaps(pCaps As *D3DCAPS9) As DWord
    56     Abstract Function GetDisplayMode(iSwapChain As DWord, pMode As DWordPtr) As DWord
    57     Abstract Function GetCreationParameters(pParameters As *D3DDEVICE_CREATION_PARAMETERS) As DWord
    58     Abstract Function SetCursorProperties(XHotSpot As DWord, YHotSpot As DWord,pCursorBitmap As *IDirect3DSurface9) As DWord
    59     Abstract Sub SetCursorPosition(X As Long, Y As Long, Flags As DWord)
    60     Abstract Function ShowCursor(bShow As Long) As Long
    61     Abstract Function CreateAdditionalSwapChain(pPresentationParameters As *D3DPRESENT_PARAMETERS, ppSwapChain As **IDirect3DSwapChain9) As DWord
    62     Abstract Function GetSwapChain(iSwapChain As DWord, ppSwapChain As **IDirect3DSwapChain9) As DWord
    63     Abstract Function GetNumberOfSwapChains() As DWord
    64     Abstract Function Reset(pPresentationParameters As *D3DPRESENT_PARAMETERS) As DWord
    65     Abstract Function Present(pSourceRect As *RECT, pDestRect As *RECT, hDestWindowOverride As DWord, pDirtyRegion As *RGNDATA) As DWord
    66     Abstract Function GetBackBuffer(iSwapChain As DWord, iBackBuffer As DWord, bufType As D3DBACKBUFFER_TYPE, ppBackBuffer As **IDirect3DSurface9) As DWord
    67     Abstract Function GetRasterStatus(iSwapChain As DWord, pRasterStatus As *D3DRASTER_STATUS) As DWord
    68     Abstract Function SetDialogBoxMode(bEnableDialogs As Long) As DWord
    69     Abstract Sub SetGammaRamp(iSwapChain As DWord, Flags As DWord, pRamp As *D3DGAMMARAMP)
    70     Abstract Sub GetGammaRamp(iSwapChain As DWord, pRamp As *D3DGAMMARAMP)
    71     Abstract Function CreateTexture(Width As DWord, Height As DWord, Levels As DWord, Usage As DWord, Format As D3DFORMAT, Pool As D3DPOOL, ppTexture As **IDirect3DTexture9, pSharedHandle As DWordPtr) As DWord
    72     Abstract Function CreateVolumeTexture(Width As DWord, Height As DWord, Depth As DWord, Levels As DWord, Usage As DWord, Format As D3DFORMAT, Pool As D3DPOOL, ppVolumeTexture As **IDirect3DVolumeTexture9, pSharedHandle As DWordPtr) As DWord
    73     Abstract Function CreateCubeTexture(EdgeLength As DWord, Levels As DWord, Usage As DWord, Format As D3DFORMAT, Pool As D3DPOOL, ppCubeTexture As **IDirect3DCubeTexture9, pSharedHandle As DWordPtr) As DWord
    74     Abstract Function CreateVertexBuffer(Length As DWord, Usage As DWord, FVF As DWord, Pool As D3DPOOL, ppVertexBuffer As **IDirect3DVertexBuffer9, pSharedHandle As DWordPtr) As DWord
    75     Abstract Function CreateIndexBuffer(Length As DWord, Usage As DWord, Format As D3DFORMAT, Pool As D3DPOOL, ppIndexBuffer As **IDirect3DIndexBuffer9, pSharedHandle As DWordPtr) As DWord
    76     Abstract Function CreateRenderTarget(Width As DWord, Height As DWord, Format As D3DFORMAT, MultiSample As D3DMULTISAMPLE_TYPE, MultisampleQuality As DWord, Lockable As Long, ppSurface As **IDirect3DSurface9, pSharedHandle As DWordPtr) As DWord
    77     Abstract Function CreateDepthStencilSurface(Width As DWord, Height As DWord, Format As D3DFORMAT, MultiSample As D3DMULTISAMPLE_TYPE, MultisampleQuality As DWord, Discard As Long, ppSurface As **IDirect3DSurface9, pSharedHandle As DWordPtr) As DWord
    78     Abstract Function UpdateSurface(pSourceSurface As *IDirect3DSurface9, pSourceRect As *RECT, pDestinationSurface As *IDirect3DSurface9, pDestPoint As *POINTAPI) As DWord
    79     Abstract Function UpdateTexture(pSourceTexture As *IDirect3DBaseTexture9, pDestinationTexture As *IDirect3DBaseTexture9) As DWord
    80     Abstract Function GetRenderTargetData(pRenderTarget As *IDirect3DSurface9, pDestSurface As *IDirect3DSurface9) As DWord
    81     Abstract Function GetFrontBufferData(iSwapChain As DWord, pDestSurface As *IDirect3DSurface9) As DWord
    82     Abstract Function StretchRect(pSourceSurface As *IDirect3DSurface9, pSourceRect As *RECT, pDestSurface As *IDirect3DSurface9, pDestRect As *RECT, Filter As D3DTEXTUREFILTERTYPE) As DWord
    83     Abstract Function ColorFill(pSurface As *IDirect3DSurface9, pRect As *RECT,dwColor As DWord) As DWord
    84     Abstract Function CreateOffscreenPlainSurface(Width As DWord, Height As DWord, Format As D3DFORMAT, Pool As D3DPOOL, ppSurface As **IDirect3DSurface9, pSharedHandle As DWordPtr) As DWord
    85     Abstract Function SetRenderTarget(RenderTargetIndex As DWord, pRenderTarget As *IDirect3DSurface9) As DWord
    86     Abstract Function GetRenderTarget(RenderTargetIndex As DWord, ppRenderTarget As **IDirect3DSurface9) As DWord
    87     Abstract Function SetDepthStencilSurface(pNewZStencil As *IDirect3DSurface9) As DWord
    88     Abstract Function GetDepthStencilSurface(ppZStencilSurface As **IDirect3DSurface9) As DWord
    89     Abstract Function BeginScene() As DWord
    90     Abstract Function EndScene() As DWord
    91     Abstract Function Clear(Count As DWord, pRects As *D3DRECT, Flags As DWord, dwColor As DWord, Z As Single, Stencil As DWord) As DWord
    92     Abstract Function SetTransform(State As D3DTRANSFORMSTATETYPE, pMatrix As *D3DMATRIX) As DWord
    93     Abstract Function GetTransform(State As D3DTRANSFORMSTATETYPE, pMatrix As *D3DMATRIX) As DWord
    94     Abstract Function MultiplyTransform(State As D3DTRANSFORMSTATETYPE, pMatrix As *D3DMATRIX) As DWord
    95     Abstract Function SetViewport(pViewport As *D3DVIEWPORT9) As DWord
    96     Abstract Function GetViewport(pViewport As *D3DVIEWPORT9) As DWord
    97     Abstract Function SetMaterial(pMaterial As *D3DMATERIAL9) As DWord
    98     Abstract Function GetMaterial(pMaterial As *D3DMATERIAL9) As DWord
    99     Abstract Function SetLight(Index As DWord, pLight As *D3DLIGHT9) As DWord
    100     Abstract Function GetLight(Index As DWord, pLight As *D3DLIGHT9) As DWord
    101     Abstract Function LightEnable(Index As DWord, Enable As Long) As DWord
    102     Abstract Function GetLightEnable(Index As DWord, pEnable As DWordPtr) As DWord
    103     Abstract Function SetClipPlane(Index As DWord, pPlane As SinglePtr) As DWord
    104     Abstract Function GetClipPlane(Index As DWord, pPlane As SinglePtr) As DWord
    105     Abstract Function SetRenderState(State As D3DRENDERSTATETYPE, Value As DWord) As DWord
    106     Abstract Function GetRenderState(State As D3DRENDERSTATETYPE, pValue As DWordPtr) As DWord
    107     Abstract Function CreateStateBlock(BlockType As D3DSTATEBLOCKTYPE, ppSB As **IDirect3DStateBlock9) As DWord
    108     Abstract Function BeginStateBlock() As DWord
    109     Abstract Function EndStateBlock(ppSB As **IDirect3DStateBlock9) As DWord
    110     Abstract Function SetClipStatus(pClipStatus As *D3DCLIPSTATUS9) As DWord
    111     Abstract Function GetClipStatus(pClipStatus As *D3DCLIPSTATUS9) As DWord
    112     Abstract Function GetTexture(Stage As DWord, ppTexture As **IDirect3DBaseTexture9) As DWord
    113     Abstract Function SetTexture(Stage As DWord, pTexture As *IDirect3DBaseTexture9) As DWord
    114     Abstract Function GetTextureStageState(Stage As DWord, StateType As D3DTEXTURESTAGESTATETYPE, pValue As DWordPtr) As DWord
    115     Abstract Function SetTextureStageState(Stage As DWord, StateType As D3DTEXTURESTAGESTATETYPE, Value As DWord) As DWord
    116     Abstract Function GetSamplerState(Sampler As DWord, SamplerStateType As D3DSAMPLERSTATETYPE, pValue As DWordPtr) As DWord
    117     Abstract Function SetSamplerState(Sampler As DWord, SamplerStateType As D3DSAMPLERSTATETYPE, Value As DWord) As DWord
    118     Abstract Function ValidateDevice(pNumPasses As DWordPtr) As DWord
    119     Abstract Function SetPaletteEntries(PaletteNumber As DWord, pEntries As *PALETTEENTRY) As DWord
    120     Abstract Function GetPaletteEntries(PaletteNumber As DWord, pEntries As *PALETTEENTRY) As DWord
    121     Abstract Function SetCurrentTexturePalette(PaletteNumber As DWord) As DWord
    122     Abstract Function GetCurrentTexturePalette(pPaletteNumber As DWordPtr) As DWord
    123     Abstract Function SetScissorRect(pRect As *RECT) As DWord
    124     Abstract Function GetScissorRect(pRect As *RECT) As DWord
    125     Abstract Function SetSoftwareVertexProcessing(bSoftware As Long) As DWord
    126     Abstract Function GetSoftwareVertexProcessing() As Long
    127     Abstract Function SetNPatchMode(nSegments As Single) As DWord
    128     Abstract Function GetNPatchMode() As Single
    129     Abstract Function DrawPrimitive(PrimitiveType As D3DPRIMITIVETYPE, StartVertex As DWord, PrimitiveCount As DWord) As DWord
    130     Abstract Function DrawIndexedPrimitive(PrimitiveType As D3DPRIMITIVETYPE, BaseVertexIndex As Long, MinVertexIndex As DWord, NumVertices As DWord, startIndex As DWord, primCount As DWord) As DWord
    131     Abstract Function DrawPrimitiveUP(PrimitiveType As D3DPRIMITIVETYPE, PrimitiveCount As DWord, pVertexStreamZeroData As VoidPtr, VertexStreamZeroStride As DWord) As DWord
    132     Abstract Function DrawIndexedPrimitiveUP(PrimitiveType As D3DPRIMITIVETYPE, MinVertexIndex As DWord, NumVertices As DWord, PrimitiveCount As DWord, pIndexData As VoidPtr, IndexDataFormat As D3DFORMAT, pVertexStreamZeroData As VoidPtr, VertexStreamZeroStride As DWord) As DWord
    133     Abstract Function ProcessVertices(SrcStartIndex As DWord, DestIndex As DWord, VertexCount As DWord, pDestBuffer As *IDirect3DVertexBuffer9, pVertexDecl As *IDirect3DVertexDeclaration9, Flags As DWord) As DWord
    134     Abstract Function CreateVertexDeclaration(pVertexElements As *D3DVERTEXELEMENT9, ppDecl As **IDirect3DVertexDeclaration9) As DWord
    135     Abstract Function SetVertexDeclaration(pDecl As *IDirect3DVertexDeclaration9) As DWord
    136     Abstract Function GetVertexDeclaration(ppDecl As **IDirect3DVertexDeclaration9) As DWord
    137     Abstract Function SetFVF(FVF As DWord) As DWord
    138     Abstract Function GetFVF(pFVF As DWordPtr) As DWord
    139     Abstract Function CreateVertexShader(pFunction As DWordPtr, ppShader As **IDirect3DVertexShader9) As DWord
    140     Abstract Function SetVertexShader(pShader As *IDirect3DVertexShader9) As DWord
    141     Abstract Function GetVertexShader(ppShader As **IDirect3DVertexShader9) As DWord
    142     Abstract Function SetVertexShaderConstantF(StartRegister As DWord, pConstantData As SinglePtr, Vector4fCount As DWord) As DWord
    143     Abstract Function GetVertexShaderConstantF(StartRegister As DWord, pConstantData As SinglePtr, Vector4fCount As DWord) As DWord
    144     Abstract Function SetVertexShaderConstantI(StartRegister As DWord, pConstantData As WordPtr, Vector4iCount As DWord) As DWord
    145     Abstract Function GetVertexShaderConstantI(StartRegister As DWord, pConstantData As WordPtr, Vector4iCount As DWord) As DWord
    146     Abstract Function SetVertexShaderConstantB(StartRegister As DWord, pConstantData As DWordPtr, BoolCount As DWord) As DWord
    147     Abstract Function GetVertexShaderConstantB(StartRegister As DWord, pConstantData As DWordPtr, BoolCount As DWord) As DWord
    148     Abstract Function SetStreamSource(StreamNumber As DWord, pStreamData As *IDirect3DVertexBuffer9, OffsetInBytes As DWord, Stride As DWord) As DWord
    149     Abstract Function GetStreamSource(StreamNumber As DWord, ppStreamData As **IDirect3DVertexBuffer9, pOffsetInBytes As DWordPtr, pStride As DWordPtr) As DWord
    150     Abstract Function SetStreamSourceFreq(StreamNumber As DWord, Setting As DWord) As DWord
    151     Abstract Function GetStreamSourceFreq(StreamNumber As DWord, pSetting As DWordPtr) As DWord
    152     Abstract Function SetIndices(pIndexData As *IDirect3DIndexBuffer9) As DWord
    153     Abstract Function GetIndices(ppIndexData As **IDirect3DIndexBuffer9) As DWord
    154     Abstract Function CreatePixelShader(pFunction As DWordPtr, ppShader As **IDirect3DPixelShader9) As DWord
    155     Abstract Function SetPixelShader(pShader As *IDirect3DPixelShader9) As DWord
    156     Abstract Function GetPixelShader(ppShader As **IDirect3DPixelShader9) As DWord
    157     Abstract Function SetPixelShaderConstantF(StartRegister As DWord, pConstantData As SinglePtr, Vector4fCount As DWord) As DWord
    158     Abstract Function GetPixelShaderConstantF(StartRegister As DWord, pConstantData As SinglePtr, Vector4fCount As DWord) As DWord
    159     Abstract Function SetPixelShaderConstantI(StartRegister As DWord, pConstantData As WordPtr, Vector4iCount As DWord) As DWord
    160     Abstract Function GetPixelShaderConstantI(StartRegister As DWord, pConstantData As WordPtr, Vector4iCount As DWord) As DWord
    161     Abstract Function SetPixelShaderConstantB(StartRegister As DWord, pConstantData As DWordPtr, BoolCount As DWord) As DWord
    162     Abstract Function GetPixelShaderConstantB(StartRegister As DWord, pConstantData As DWordPtr, BoolCount As DWord) As DWord
    163     Abstract Function DrawRectPatch(Handle As DWord, pNumSegs As SinglePtr, pRectPatchInfo As *D3DRECTPATCH_INFO) As DWord
    164     Abstract Function DrawTriPatch(Handle As DWord, pNumSegs As SinglePtr, pTriPatchInfo As *D3DTRIPATCH_INFO) As DWord
    165     Abstract Function DeletePatch(Handle As DWord) As DWord
    166     Abstract Function CreateQuery(QueryType As D3DQUERYTYPE, ppQuery As **IDirect3DQuery9) As DWord
    167 End Class
     51    Function TestCooperativeLevel() As DWord
     52    Function GetAvailableTextureMem() As DWord
     53    Function EvictManagedResources() As DWord
     54    Function GetDirect3D(ppD3D9 As *LPDIRECT3D9) As DWord
     55    Function GetDeviceCaps(pCaps As *D3DCAPS9) As DWord
     56    Function GetDisplayMode(iSwapChain As DWord, pMode As DWordPtr) As DWord
     57    Function GetCreationParameters(pParameters As *D3DDEVICE_CREATION_PARAMETERS) As DWord
     58    Function SetCursorProperties(XHotSpot As DWord, YHotSpot As DWord,pCursorBitmap As *IDirect3DSurface9) As DWord
     59    Sub SetCursorPosition(X As Long, Y As Long, Flags As DWord)
     60    Function ShowCursor(bShow As Long) As Long
     61    Function CreateAdditionalSwapChain(pPresentationParameters As *D3DPRESENT_PARAMETERS, ppSwapChain As **IDirect3DSwapChain9) As DWord
     62    Function GetSwapChain(iSwapChain As DWord, ppSwapChain As **IDirect3DSwapChain9) As DWord
     63    Function GetNumberOfSwapChains() As DWord
     64    Function Reset(pPresentationParameters As *D3DPRESENT_PARAMETERS) As DWord
     65    Function Present(pSourceRect As *RECT, pDestRect As *RECT, hDestWindowOverride As DWord, pDirtyRegion As *RGNDATA) As DWord
     66    Function GetBackBuffer(iSwapChain As DWord, iBackBuffer As DWord, bufType As D3DBACKBUFFER_TYPE, ppBackBuffer As **IDirect3DSurface9) As DWord
     67    Function GetRasterStatus(iSwapChain As DWord, pRasterStatus As *D3DRASTER_STATUS) As DWord
     68    Function SetDialogBoxMode(bEnableDialogs As Long) As DWord
     69    Sub SetGammaRamp(iSwapChain As DWord, Flags As DWord, pRamp As *D3DGAMMARAMP)
     70    Sub GetGammaRamp(iSwapChain As DWord, pRamp As *D3DGAMMARAMP)
     71    Function CreateTexture(Width As DWord, Height As DWord, Levels As DWord, Usage As DWord, Format As D3DFORMAT, Pool As D3DPOOL, ppTexture As **IDirect3DTexture9, pSharedHandle As DWordPtr) As DWord
     72    Function CreateVolumeTexture(Width As DWord, Height As DWord, Depth As DWord, Levels As DWord, Usage As DWord, Format As D3DFORMAT, Pool As D3DPOOL, ppVolumeTexture As **IDirect3DVolumeTexture9, pSharedHandle As DWordPtr) As DWord
     73    Function CreateCubeTexture(EdgeLength As DWord, Levels As DWord, Usage As DWord, Format As D3DFORMAT, Pool As D3DPOOL, ppCubeTexture As **IDirect3DCubeTexture9, pSharedHandle As DWordPtr) As DWord
     74    Function CreateVertexBuffer(Length As DWord, Usage As DWord, FVF As DWord, Pool As D3DPOOL, ppVertexBuffer As **IDirect3DVertexBuffer9, pSharedHandle As DWordPtr) As DWord
     75    Function CreateIndexBuffer(Length As DWord, Usage As DWord, Format As D3DFORMAT, Pool As D3DPOOL, ppIndexBuffer As **IDirect3DIndexBuffer9, pSharedHandle As DWordPtr) As DWord
     76    Function CreateRenderTarget(Width As DWord, Height As DWord, Format As D3DFORMAT, MultiSample As D3DMULTISAMPLE_TYPE, MultisampleQuality As DWord, Lockable As Long, ppSurface As **IDirect3DSurface9, pSharedHandle As DWordPtr) As DWord
     77    Function CreateDepthStencilSurface(Width As DWord, Height As DWord, Format As D3DFORMAT, MultiSample As D3DMULTISAMPLE_TYPE, MultisampleQuality As DWord, Discard As Long, ppSurface As **IDirect3DSurface9, pSharedHandle As DWordPtr) As DWord
     78    Function UpdateSurface(pSourceSurface As *IDirect3DSurface9, pSourceRect As *RECT, pDestinationSurface As *IDirect3DSurface9, pDestPoint As *POINTAPI) As DWord
     79    Function UpdateTexture(pSourceTexture As *IDirect3DBaseTexture9, pDestinationTexture As *IDirect3DBaseTexture9) As DWord
     80    Function GetRenderTargetData(pRenderTarget As *IDirect3DSurface9, pDestSurface As *IDirect3DSurface9) As DWord
     81    Function GetFrontBufferData(iSwapChain As DWord, pDestSurface As *IDirect3DSurface9) As DWord
     82    Function StretchRect(pSourceSurface As *IDirect3DSurface9, pSourceRect As *RECT, pDestSurface As *IDirect3DSurface9, pDestRect As *RECT, Filter As D3DTEXTUREFILTERTYPE) As DWord
     83    Function ColorFill(pSurface As *IDirect3DSurface9, pRect As *RECT,dwColor As DWord) As DWord
     84    Function CreateOffscreenPlainSurface(Width As DWord, Height As DWord, Format As D3DFORMAT, Pool As D3DPOOL, ppSurface As **IDirect3DSurface9, pSharedHandle As DWordPtr) As DWord
     85    Function SetRenderTarget(RenderTargetIndex As DWord, pRenderTarget As *IDirect3DSurface9) As DWord
     86    Function GetRenderTarget(RenderTargetIndex As DWord, ppRenderTarget As **IDirect3DSurface9) As DWord
     87    Function SetDepthStencilSurface(pNewZStencil As *IDirect3DSurface9) As DWord
     88    Function GetDepthStencilSurface(ppZStencilSurface As **IDirect3DSurface9) As DWord
     89    Function BeginScene() As DWord
     90    Function EndScene() As DWord
     91    Function Clear(Count As DWord, pRects As *D3DRECT, Flags As DWord, dwColor As DWord, Z As Single, Stencil As DWord) As DWord
     92    Function SetTransform(State As D3DTRANSFORMSTATETYPE, pMatrix As *D3DMATRIX) As DWord
     93    Function GetTransform(State As D3DTRANSFORMSTATETYPE, pMatrix As *D3DMATRIX) As DWord
     94    Function MultiplyTransform(State As D3DTRANSFORMSTATETYPE, pMatrix As *D3DMATRIX) As DWord
     95    Function SetViewport(pViewport As *D3DVIEWPORT9) As DWord
     96    Function GetViewport(pViewport As *D3DVIEWPORT9) As DWord
     97    Function SetMaterial(pMaterial As *D3DMATERIAL9) As DWord
     98    Function GetMaterial(pMaterial As *D3DMATERIAL9) As DWord
     99    Function SetLight(Index As DWord, pLight As *D3DLIGHT9) As DWord
     100    Function GetLight(Index As DWord, pLight As *D3DLIGHT9) As DWord
     101    Function LightEnable(Index As DWord, Enable As Long) As DWord
     102    Function GetLightEnable(Index As DWord, pEnable As DWordPtr) As DWord
     103    Function SetClipPlane(Index As DWord, pPlane As SinglePtr) As DWord
     104    Function GetClipPlane(Index As DWord, pPlane As SinglePtr) As DWord
     105    Function SetRenderState(State As D3DRENDERSTATETYPE, Value As DWord) As DWord
     106    Function GetRenderState(State As D3DRENDERSTATETYPE, pValue As DWordPtr) As DWord
     107    Function CreateStateBlock(BlockType As D3DSTATEBLOCKTYPE, ppSB As **IDirect3DStateBlock9) As DWord
     108    Function BeginStateBlock() As DWord
     109    Function EndStateBlock(ppSB As **IDirect3DStateBlock9) As DWord
     110    Function SetClipStatus(pClipStatus As *D3DCLIPSTATUS9) As DWord
     111    Function GetClipStatus(pClipStatus As *D3DCLIPSTATUS9) As DWord
     112    Function GetTexture(Stage As DWord, ppTexture As **IDirect3DBaseTexture9) As DWord
     113    Function SetTexture(Stage As DWord, pTexture As *IDirect3DBaseTexture9) As DWord
     114    Function GetTextureStageState(Stage As DWord, StateType As D3DTEXTURESTAGESTATETYPE, pValue As DWordPtr) As DWord
     115    Function SetTextureStageState(Stage As DWord, StateType As D3DTEXTURESTAGESTATETYPE, Value As DWord) As DWord
     116    Function GetSamplerState(Sampler As DWord, SamplerStateType As D3DSAMPLERSTATETYPE, pValue As DWordPtr) As DWord
     117    Function SetSamplerState(Sampler As DWord, SamplerStateType As D3DSAMPLERSTATETYPE, Value As DWord) As DWord
     118    Function ValidateDevice(pNumPasses As DWordPtr) As DWord
     119    Function SetPaletteEntries(PaletteNumber As DWord, pEntries As *PALETTEENTRY) As DWord
     120    Function GetPaletteEntries(PaletteNumber As DWord, pEntries As *PALETTEENTRY) As DWord
     121    Function SetCurrentTexturePalette(PaletteNumber As DWord) As DWord
     122    Function GetCurrentTexturePalette(pPaletteNumber As DWordPtr) As DWord
     123    Function SetScissorRect(pRect As *RECT) As DWord
     124    Function GetScissorRect(pRect As *RECT) As DWord
     125    Function SetSoftwareVertexProcessing(bSoftware As Long) As DWord
     126    Function GetSoftwareVertexProcessing() As Long
     127    Function SetNPatchMode(nSegments As Single) As DWord
     128    Function GetNPatchMode() As Single
     129    Function DrawPrimitive(PrimitiveType As D3DPRIMITIVETYPE, StartVertex As DWord, PrimitiveCount As DWord) As DWord
     130    Function DrawIndexedPrimitive(PrimitiveType As D3DPRIMITIVETYPE, BaseVertexIndex As Long, MinVertexIndex As DWord, NumVertices As DWord, startIndex As DWord, primCount As DWord) As DWord
     131    Function DrawPrimitiveUP(PrimitiveType As D3DPRIMITIVETYPE, PrimitiveCount As DWord, pVertexStreamZeroData As VoidPtr, VertexStreamZeroStride As DWord) As DWord
     132    Function DrawIndexedPrimitiveUP(PrimitiveType As D3DPRIMITIVETYPE, MinVertexIndex As DWord, NumVertices As DWord, PrimitiveCount As DWord, pIndexData As VoidPtr, IndexDataFormat As D3DFORMAT, pVertexStreamZeroData As VoidPtr, VertexStreamZeroStride As DWord) As DWord
     133    Function ProcessVertices(SrcStartIndex As DWord, DestIndex As DWord, VertexCount As DWord, pDestBuffer As *IDirect3DVertexBuffer9, pVertexDecl As *IDirect3DVertexDeclaration9, Flags As DWord) As DWord
     134    Function CreateVertexDeclaration(pVertexElements As *D3DVERTEXELEMENT9, ppDecl As **IDirect3DVertexDeclaration9) As DWord
     135    Function SetVertexDeclaration(pDecl As *IDirect3DVertexDeclaration9) As DWord
     136    Function GetVertexDeclaration(ppDecl As **IDirect3DVertexDeclaration9) As DWord
     137    Function SetFVF(FVF As DWord) As DWord
     138    Function GetFVF(pFVF As DWordPtr) As DWord
     139    Function CreateVertexShader(pFunction As DWordPtr, ppShader As **IDirect3DVertexShader9) As DWord
     140    Function SetVertexShader(pShader As *IDirect3DVertexShader9) As DWord
     141    Function GetVertexShader(ppShader As **IDirect3DVertexShader9) As DWord
     142    Function SetVertexShaderConstantF(StartRegister As DWord, pConstantData As SinglePtr, Vector4fCount As DWord) As DWord
     143    Function GetVertexShaderConstantF(StartRegister As DWord, pConstantData As SinglePtr, Vector4fCount As DWord) As DWord
     144    Function SetVertexShaderConstantI(StartRegister As DWord, pConstantData As WordPtr, Vector4iCount As DWord) As DWord
     145    Function GetVertexShaderConstantI(StartRegister As DWord, pConstantData As WordPtr, Vector4iCount As DWord) As DWord
     146    Function SetVertexShaderConstantB(StartRegister As DWord, pConstantData As DWordPtr, BoolCount As DWord) As DWord
     147    Function GetVertexShaderConstantB(StartRegister As DWord, pConstantData As DWordPtr, BoolCount As DWord) As DWord
     148    Function SetStreamSource(StreamNumber As DWord, pStreamData As *IDirect3DVertexBuffer9, OffsetInBytes As DWord, Stride As DWord) As DWord
     149    Function GetStreamSource(StreamNumber As DWord, ppStreamData As **IDirect3DVertexBuffer9, pOffsetInBytes As DWordPtr, pStride As DWordPtr) As DWord
     150    Function SetStreamSourceFreq(StreamNumber As DWord, Setting As DWord) As DWord
     151    Function GetStreamSourceFreq(StreamNumber As DWord, pSetting As DWordPtr) As DWord
     152    Function SetIndices(pIndexData As *IDirect3DIndexBuffer9) As DWord
     153    Function GetIndices(ppIndexData As **IDirect3DIndexBuffer9) As DWord
     154    Function CreatePixelShader(pFunction As DWordPtr, ppShader As **IDirect3DPixelShader9) As DWord
     155    Function SetPixelShader(pShader As *IDirect3DPixelShader9) As DWord
     156    Function GetPixelShader(ppShader As **IDirect3DPixelShader9) As DWord
     157    Function SetPixelShaderConstantF(StartRegister As DWord, pConstantData As SinglePtr, Vector4fCount As DWord) As DWord
     158    Function GetPixelShaderConstantF(StartRegister As DWord, pConstantData As SinglePtr, Vector4fCount As DWord) As DWord
     159    Function SetPixelShaderConstantI(StartRegister As DWord, pConstantData As WordPtr, Vector4iCount As DWord) As DWord
     160    Function GetPixelShaderConstantI(StartRegister As DWord, pConstantData As WordPtr, Vector4iCount As DWord) As DWord
     161    Function SetPixelShaderConstantB(StartRegister As DWord, pConstantData As DWordPtr, BoolCount As DWord) As DWord
     162    Function GetPixelShaderConstantB(StartRegister As DWord, pConstantData As DWordPtr, BoolCount As DWord) As DWord
     163    Function DrawRectPatch(Handle As DWord, pNumSegs As SinglePtr, pRectPatchInfo As *D3DRECTPATCH_INFO) As DWord
     164    Function DrawTriPatch(Handle As DWord, pNumSegs As SinglePtr, pTriPatchInfo As *D3DTRIPATCH_INFO) As DWord
     165    Function DeletePatch(Handle As DWord) As DWord
     166    Function CreateQuery(QueryType As D3DQUERYTYPE, ppQuery As **IDirect3DQuery9) As DWord
     167End Interface
    168168TypeDef LPDIRECT3DDEVICE9 = *IDirect3DDevice9
    169169
    170 Class IDirect3DStateBlock9
     170Interface IDirect3DStateBlock9
    171171    Inherits IUnknown
    172172Public
    173173    'IDirect3DStateBlock9 methods
    174     Abstract Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
    175     Abstract Function Capture() As DWord
    176     Abstract Function Apply() As DWord
    177 End Class
     174    Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
     175    Function Capture() As DWord
     176    Function Apply() As DWord
     177End Interface
    178178TypeDef LPDIRECT3DSTATEBLOCK9 = *IDirect3DStateBlock9
    179179
    180 Class IDirect3DSwapChain9
     180Interface IDirect3DSwapChain9
    181181    Inherits IUnknown
    182182Public
    183183    'IDirect3DSwapChain9 methods
    184     Abstract Function Present(pSourceRect As *RECT, pDestRect As *RECT, hDestWindowOverride As DWord, pDirtyRegion As *RGNDATA, dwFlags As DWord) As DWord
    185     Abstract Function GetFrontBufferData(pDestSurface As *IDirect3DSurface9) As DWord
    186     Abstract Function GetBackBuffer(iBackBuffer As DWord, bbtype As D3DBACKBUFFER_TYPE, ppBackBuffer As **IDirect3DSurface9) As DWord
    187     Abstract Function GetRasterStatus(pRasterStatus As *D3DRASTER_STATUS) As DWord
    188     Abstract Function GetDisplayMode(pMode As *D3DDISPLAYMODE) As DWord
    189     Abstract Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
    190     Abstract Function GetPresentParameters(pPresentationParameters As *D3DPRESENT_PARAMETERS) As DWord
    191 End Class
     184    Function Present(pSourceRect As *RECT, pDestRect As *RECT, hDestWindowOverride As DWord, pDirtyRegion As *RGNDATA, dwFlags As DWord) As DWord
     185    Function GetFrontBufferData(pDestSurface As *IDirect3DSurface9) As DWord
     186    Function GetBackBuffer(iBackBuffer As DWord, bbtype As D3DBACKBUFFER_TYPE, ppBackBuffer As **IDirect3DSurface9) As DWord
     187    Function GetRasterStatus(pRasterStatus As *D3DRASTER_STATUS) As DWord
     188    Function GetDisplayMode(pMode As *D3DDISPLAYMODE) As DWord
     189    Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
     190    Function GetPresentParameters(pPresentationParameters As *D3DPRESENT_PARAMETERS) As DWord
     191End Interface
    192192TypeDef LPDIRECT3DSWAPCHAIN9 = *IDirect3DSwapChain9
    193193
    194 Class IDirect3DResource9
     194Interface IDirect3DResource9
    195195    Inherits IUnknown
    196196Public
    197197    'IDirect3DResource9 methods
    198     Abstract Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
    199     Abstract Function SetPrivateData(ByRef refguid As GUID, pData As VoidPtr, SizeOfData As DWord, Flags As DWord) As DWord
    200     Abstract Function GetPrivateData(ByRef refguid As GUID, pData As VoidPtr, pSizeOfData As DWordPtr) As DWord
    201     Abstract Function FreePrivateData(ByRef refguid As GUID) As DWord
    202     Abstract Function SetPriority(PriorityNew As DWord) As DWord
    203     Abstract Function GetPriority() As DWord
    204     Abstract Sub PreLoad()
    205     Abstract Function GetType() As D3DRESOURCETYPE
    206 End Class
     198    Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
     199    Function SetPrivateData(ByRef refguid As GUID, pData As VoidPtr, SizeOfData As DWord, Flags As DWord) As DWord
     200    Function GetPrivateData(ByRef refguid As GUID, pData As VoidPtr, pSizeOfData As DWordPtr) As DWord
     201    Function FreePrivateData(ByRef refguid As GUID) As DWord
     202    Function SetPriority(PriorityNew As DWord) As DWord
     203    Function GetPriority() As DWord
     204    Sub PreLoad()
     205    Function GetType() As D3DRESOURCETYPE
     206End Interface
    207207TypeDef LPDIRECT3DRESOURCE9 = *IDirect3DResource9
    208208
    209 Class IDirect3DVertexDeclaration9
     209Interface IDirect3DVertexDeclaration9
    210210    Inherits IUnknown
    211211Public
    212212    'IDirect3DVertexDeclaration9 methods
    213     Abstract Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
    214     Abstract Function GetDeclaration(pElement As *D3DVERTEXELEMENT9, pNumElements As DWordPtr) As DWord
    215 End Class
     213    Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
     214    Function GetDeclaration(pElement As *D3DVERTEXELEMENT9, pNumElements As DWordPtr) As DWord
     215End Interface
    216216TypeDef LPDIRECT3DVERTEXDECLARATION9 = *IDirect3DVertexDeclaration9
    217217
    218 Class IDirect3DVertexShader9
     218Interface IDirect3DVertexShader9
    219219    Inherits IUnknown
    220220Public
    221221    'IDirect3DVertexShader9 methods
    222     Abstract Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
    223     Abstract Function GetFunction(pData As VoidPtr, pSizeOfData As DWordPtr) As DWord
    224 End Class
     222    Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
     223    Function GetFunction(pData As VoidPtr, pSizeOfData As DWordPtr) As DWord
     224End Interface
    225225TypeDef LPDIRECT3DVERTEXSHADER9 = *IDirect3DVertexShader9
    226226
    227 Class IDirect3DPixelShader9
     227Interface IDirect3DPixelShader9
    228228    Inherits IUnknown
    229229Public
    230230    'IDirect3DPixelShader9 methods
    231     Abstract Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
    232     Abstract Function GetFunction(pData As VoidPtr, pSizeOfData As DWordPtr) As DWord
    233 End Class
     231    Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
     232    Function GetFunction(pData As VoidPtr, pSizeOfData As DWordPtr) As DWord
     233End Interface
    234234TypeDef LPDIRECT3DPIXELSHADER9 = *IDirect3DPixelShader9
    235235
    236 Class IDirect3DBaseTexture9
     236Interface IDirect3DBaseTexture9
    237237    Inherits IUnknown
    238238Public
    239239    'IDirect3DResource9 methods
    240     Abstract Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
    241     Abstract Function SetPrivateData(ByRef refguid As GUID, pData As VoidPtr, SizeOfData As DWord, Flags As DWord) As DWord
    242     Abstract Function GetPrivateData(ByRef refguid As GUID, pData As VoidPtr, pSizeOfData As DWordPtr) As DWord
    243     Abstract Function FreePrivateData(ByRef refguid As GUID) As DWord
    244     Abstract Function SetPriority(PriorityNew As DWord) As DWord
    245     Abstract Function GetPriority() As DWord
    246     Abstract Sub PreLoad()
    247     Abstract Function GetType() As D3DRESOURCETYPE
    248     Abstract Function SetLOD(LODNew As DWord) As DWord
    249     Abstract Function GetLOD() As DWord
    250     Abstract Function GetLevelCount() As DWord
    251     Abstract Function SetAutoGenFilterType(FilterType As D3DTEXTUREFILTERTYPE) As DWord
    252     Abstract Function GetAutoGenFilterType() As D3DTEXTUREFILTERTYPE
    253     Abstract Sub GenerateMipSubLevels()
    254 End Class
     240    Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
     241    Function SetPrivateData(ByRef refguid As GUID, pData As VoidPtr, SizeOfData As DWord, Flags As DWord) As DWord
     242    Function GetPrivateData(ByRef refguid As GUID, pData As VoidPtr, pSizeOfData As DWordPtr) As DWord
     243    Function FreePrivateData(ByRef refguid As GUID) As DWord
     244    Function SetPriority(PriorityNew As DWord) As DWord
     245    Function GetPriority() As DWord
     246    Sub PreLoad()
     247    Function GetType() As D3DRESOURCETYPE
     248    Function SetLOD(LODNew As DWord) As DWord
     249    Function GetLOD() As DWord
     250    Function GetLevelCount() As DWord
     251    Function SetAutoGenFilterType(FilterType As D3DTEXTUREFILTERTYPE) As DWord
     252    Function GetAutoGenFilterType() As D3DTEXTUREFILTERTYPE
     253    Sub GenerateMipSubLevels()
     254End Interface
    255255TypeDef LPDIRECT3DBASETEXTURE9 = *IDirect3DBaseTexture9
    256256
    257 Class IDirect3DTexture9
     257Interface IDirect3DTexture9
    258258    Inherits IDirect3DBaseTexture9
    259259Public
    260     Abstract Function GetLevelDesc(Level As DWord, pDesc As *D3DSURFACE_DESC) As DWord
    261     Abstract Function GetSurfaceLevel(Level As DWord, ppSurfaceLevel As **IDirect3DSurface9) As DWord
    262     Abstract Function LockRect(Level As DWord, pLockedRect As *D3DLOCKED_RECT, pRect As *RECT, Flags As DWord) As DWord
    263     Abstract Function UnlockRect(Level As DWord) As DWord
    264     Abstract Function AddDirtyRect(pDirtyRect As *RECT) As DWord
    265 End Class
     260    Function GetLevelDesc(Level As DWord, pDesc As *D3DSURFACE_DESC) As DWord
     261    Function GetSurfaceLevel(Level As DWord, ppSurfaceLevel As **IDirect3DSurface9) As DWord
     262    Function LockRect(Level As DWord, pLockedRect As *D3DLOCKED_RECT, pRect As *RECT, Flags As DWord) As DWord
     263    Function UnlockRect(Level As DWord) As DWord
     264    Function AddDirtyRect(pDirtyRect As *RECT) As DWord
     265End Interface
    266266TypeDef LPDIRECT3DTEXTURE9 = *IDirect3DTexture9
    267267
    268 Class IDirect3DVolumeTexture9
     268Interface IDirect3DVolumeTexture9
    269269    Inherits IDirect3DBaseTexture9
    270270Public
    271     Abstract Function GetLevelDesc(Level As DWord, pDesc As *D3DSURFACE_DESC) As DWord
    272     Abstract Function GetVolumeLevel(Level As DWord, ppVolumeLevel As **IDirect3DVolume9) As DWord
    273     Abstract Function LockBox(Level As DWord, pLockedVolume As *D3DLOCKED_BOX, pBox As *D3DBOX, Flags As DWord) As DWord
    274     Abstract Function UnlockBox(Level As DWord) As DWord
    275     Abstract Function AddDirtyBox(pDirtyBox As *D3DBOX) As DWord
    276 End Class
     271    Function GetLevelDesc(Level As DWord, pDesc As *D3DSURFACE_DESC) As DWord
     272    Function GetVolumeLevel(Level As DWord, ppVolumeLevel As **IDirect3DVolume9) As DWord
     273    Function LockBox(Level As DWord, pLockedVolume As *D3DLOCKED_BOX, pBox As *D3DBOX, Flags As DWord) As DWord
     274    Function UnlockBox(Level As DWord) As DWord
     275    Function AddDirtyBox(pDirtyBox As *D3DBOX) As DWord
     276End Interface
    277277TypeDef LPDIRECT3DVOLUMETEXTURE9 = *IDirect3DVolumeTexture9
    278278
    279 Class IDirect3DCubeTexture9
     279Interface IDirect3DCubeTexture9
    280280    Inherits IDirect3DBaseTexture9
    281 End Class
     281End Interface
    282282TypeDef LPDIRECT3DCUBETEXTURE9 = *IDirect3DCubeTexture9
    283283
    284 Class IDirect3DVertexBuffer9
     284Interface IDirect3DVertexBuffer9
    285285    Inherits IUnknown
    286286Public
    287287    'IDirect3DResource9 methods
    288     Abstract Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
    289     Abstract Function SetPrivateData(ByRef refguid As GUID, pData As VoidPtr, SizeOfData As DWord, Flags As DWord) As DWord
    290     Abstract Function GetPrivateData(ByRef refguid As GUID, pData As VoidPtr, pSizeOfData As DWordPtr) As DWord
    291     Abstract Function FreePrivateData(ByRef refguid As GUID) As DWord
    292     Abstract Function SetPriority(PriorityNew As DWord) As DWord
    293     Abstract Function GetPriority() As DWord
    294     Abstract Sub PreLoad()
    295     Abstract Function GetType() As D3DRESOURCETYPE
    296     Abstract Function Lock(OffsetToLock As DWord, SizeToLock As DWord, ppbData As VoidPtr, Flags As DWord) As DWord
    297     Abstract Function Unlock() As DWord
    298     Abstract Function GetDesc(pDesc As *D3DVERTEXBUFFER_DESC) As DWord
    299 End Class
     288    Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
     289    Function SetPrivateData(ByRef refguid As GUID, pData As VoidPtr, SizeOfData As DWord, Flags As DWord) As DWord
     290    Function GetPrivateData(ByRef refguid As GUID, pData As VoidPtr, pSizeOfData As DWordPtr) As DWord
     291    Function FreePrivateData(ByRef refguid As GUID) As DWord
     292    Function SetPriority(PriorityNew As DWord) As DWord
     293    Function GetPriority() As DWord
     294    Sub PreLoad()
     295    Function GetType() As D3DRESOURCETYPE
     296    Function Lock(OffsetToLock As DWord, SizeToLock As DWord, ppbData As VoidPtr, Flags As DWord) As DWord
     297    Function Unlock() As DWord
     298    Function GetDesc(pDesc As *D3DVERTEXBUFFER_DESC) As DWord
     299End Interface
    300300TypeDef LPDIRECT3DVERTEXBUFFER9 = *IDirect3DVertexBuffer9
    301301
    302 Class IDirect3DIndexBuffer9
     302Interface IDirect3DIndexBuffer9
    303303    Inherits IUnknown
    304304Public
    305305    'IDirect3DResource9 methods
    306     Abstract Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
    307     Abstract Function SetPrivateData(ByRef refguid As GUID, pData As VoidPtr, SizeOfData As DWord, Flags As DWord) As DWord
    308     Abstract Function GetPrivateData(ByRef refguid As GUID, pData As VoidPtr, pSizeOfData As DWordPtr) As DWord
    309     Abstract Function FreePrivateData(ByRef refguid As GUID) As DWord
    310     Abstract Function SetPriority(PriorityNew As DWord) As DWord
    311     Abstract Function GetPriority() As DWord
    312     Abstract Sub PreLoad()
    313     Abstract Function GetType() As D3DRESOURCETYPE
    314     Abstract Function Lock(OffsetToLock As DWord, SizeToLock As DWord, ppbData As VoidPtr, Flags As DWord) As DWord
    315     Abstract Function Unlock() As DWord
    316     Abstract Function GetDesc(pDesc As *D3DINDEXBUFFER_DESC) As DWord
    317 End Class
     306    Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
     307    Function SetPrivateData(ByRef refguid As GUID, pData As VoidPtr, SizeOfData As DWord, Flags As DWord) As DWord
     308    Function GetPrivateData(ByRef refguid As GUID, pData As VoidPtr, pSizeOfData As DWordPtr) As DWord
     309    Function FreePrivateData(ByRef refguid As GUID) As DWord
     310    Function SetPriority(PriorityNew As DWord) As DWord
     311    Function GetPriority() As DWord
     312    Sub PreLoad()
     313    Function GetType() As D3DRESOURCETYPE
     314    Function Lock(OffsetToLock As DWord, SizeToLock As DWord, ppbData As VoidPtr, Flags As DWord) As DWord
     315    Function Unlock() As DWord
     316    Function GetDesc(pDesc As *D3DINDEXBUFFER_DESC) As DWord
     317End Interface
    318318TypeDef LPDIRECT3DINDEXBUFFER9 = *IDirect3DIndexBuffer9
    319319
    320 Class IDirect3DSurface9
     320Interface IDirect3DSurface9
    321321    Inherits IUnknown
    322322Public
    323323    'IDirect3DResource9 methods
    324     Abstract Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
    325     Abstract Function SetPrivateData(ByRef refguid As GUID, pData As VoidPtr, SizeOfData As DWord, Flags As DWord) As DWord
    326     Abstract Function GetPrivateData(ByRef refguid As GUID, pData As VoidPtr, pSizeOfData As DWordPtr) As DWord
    327     Abstract Function FreePrivateData(ByRef refguid As GUID) As DWord
    328     Abstract Function SetPriority(PriorityNew As DWord) As DWord
    329     Abstract Function GetPriority() As DWord
    330     Abstract Sub PreLoad()
    331     Abstract Function GetType() As D3DRESOURCETYPE
    332     Abstract Function GetContainer(ByRef riid As GUID, ppContainer As VoidPtr) As DWord
    333     Abstract Function GetDesc(pDesc As *D3DSURFACE_DESC) As DWord
    334     Abstract Function LockRect(pLockedRect As *D3DLOCKED_RECT, pRect As *RECT, Flags As DWord) As DWord
    335     Abstract Function UnlockRect() As DWord
    336     Abstract Function GetDC(phdc As DWordPtr) As DWord
    337     Abstract Function ReleaseDC(hdc As DWord) As DWord
    338 End Class
     324    Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
     325    Function SetPrivateData(ByRef refguid As GUID, pData As VoidPtr, SizeOfData As DWord, Flags As DWord) As DWord
     326    Function GetPrivateData(ByRef refguid As GUID, pData As VoidPtr, pSizeOfData As DWordPtr) As DWord
     327    Function FreePrivateData(ByRef refguid As GUID) As DWord
     328    Function SetPriority(PriorityNew As DWord) As DWord
     329    Function GetPriority() As DWord
     330    Sub PreLoad()
     331    Function GetType() As D3DRESOURCETYPE
     332    Function GetContainer(ByRef riid As GUID, ppContainer As VoidPtr) As DWord
     333    Function GetDesc(pDesc As *D3DSURFACE_DESC) As DWord
     334    Function LockRect(pLockedRect As *D3DLOCKED_RECT, pRect As *RECT, Flags As DWord) As DWord
     335    Function UnlockRect() As DWord
     336    Function GetDC(phdc As DWordPtr) As DWord
     337    Function ReleaseDC(hdc As DWord) As DWord
     338End Interface
    339339TypeDef LPDIRECT3DSURFACE9 = *IDirect3DSurface9
    340340
    341 Class IDirect3DVolume9
     341Interface IDirect3DVolume9
    342342    Inherits IUnknown
    343343Public
    344344    'IDirect3DVolume9 methods
    345     Abstract Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
    346     Abstract Function SetPrivateData(ByRef refguid As GUID, pData As VoidPtr, SizeOfData As DWord, Flags As DWord) As DWord
    347     Abstract Function GetPrivateData(ByRef refguid As GUID, pData As VoidPtr, pSizeOfData As DWordPtr) As DWord
    348     Abstract Function FreePrivateData(ByRef refguid As GUID) As DWord
    349     Abstract Function GetContainer(ByRef riid As GUID, ppContainer As DWordPtr) As DWord
    350     Abstract Function GetDesc(pDesc As *D3DVOLUME_DESC) As DWord
    351     Abstract Function LockBox(pLockedVolume As *D3DLOCKED_BOX, pBox As *D3DBOX, Flags As DWord) As DWord
    352     Abstract Function UnlockBox() As DWord
    353 End Class
     345    Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
     346    Function SetPrivateData(ByRef refguid As GUID, pData As VoidPtr, SizeOfData As DWord, Flags As DWord) As DWord
     347    Function GetPrivateData(ByRef refguid As GUID, pData As VoidPtr, pSizeOfData As DWordPtr) As DWord
     348    Function FreePrivateData(ByRef refguid As GUID) As DWord
     349    Function GetContainer(ByRef riid As GUID, ppContainer As DWordPtr) As DWord
     350    Function GetDesc(pDesc As *D3DVOLUME_DESC) As DWord
     351    Function LockBox(pLockedVolume As *D3DLOCKED_BOX, pBox As *D3DBOX, Flags As DWord) As DWord
     352    Function UnlockBox() As DWord
     353End Interface
    354354TypeDef LPDIRECT3DVOLUME9 = *IDirect3DVolume9
    355355
    356 Class IDirect3DQuery9
     356Interface IDirect3DQuery9
    357357    Inherits IUnknown
    358358Public
    359359    'IDirect3DQuery9 methods
    360     Abstract Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
    361     Abstract Function GetType() As D3DQUERYTYPE
    362     Abstract Function GetDataSize() As DWord
    363     Abstract Function Issue(dwIssueFlags As DWord) As DWord
    364     Abstract Function GetData(pData As VoidPtr, dwSize As DWord, dwGetDataFlags As DWord) As DWord
    365 End Class
     360    Function GetDevice(ppDevice As *LPDIRECT3DDEVICE9) As DWord
     361    Function GetType() As D3DQUERYTYPE
     362    Function GetDataSize() As DWord
     363    Function Issue(dwIssueFlags As DWord) As DWord
     364    Function GetData(pData As VoidPtr, dwSize As DWord, dwGetDataFlags As DWord) As DWord
     365End Interface
    366366TypeDef LPDIRECT3DQUERY9 = *IDirect3DQuery9
    367367
  • trunk/Include/objbase.sbp

    r300 r303  
    107107Declare Function CoInitialize Lib "ole32" (pvReserved As VoidPtr) As HRESULT
    108108Declare Sub CoUninitialize Lib "ole32" ()
    109 'Declare Sub CoGetMalloc Lib "ole32" (dwMemContext As DWord, ByRef pMalloc As IMalloc) As HRESULT
     109'Declare Sub CoGetMalloc Lib "ole32" (dwMemContext As DWord, ByRef Malloc As IMalloc) As HRESULT
    110110Declare Function CoGetCurrentProcess Lib "ole32" () As DWord
    111 'Declare Function CoRegisterMallocSpy Lib "ole32" (pMallocSpy As *IMallocSpy) As HRESULT
     111'Declare Function CoRegisterMallocSpy Lib "ole32" (ByRef MallocSpy As IMallocSpy) As HRESULT
    112112Declare Function CoRevokeMallocSpy Lib "ole32" () As HRESULT
    113 'Declare Function CoCreateStandardMalloc Lib "ole32" (memctx As DWord, ByRef pMalloc As *IMalloc) As HRESULT
     113'Declare Function CoCreateStandardMalloc Lib "ole32" (memctx As DWord, ByRef Malloc As IMalloc) As HRESULT
    114114
    115115
     
    129129'#if (_WIN32_WINNT >= &h0501)
    130130' 注意:このcokkieは本来ULARGE_INTEGER型
    131 'Declare Function CoRegisterInitializeSpy Lib "ole32" (pSpy As *IInitializeSpy, ByRef uliCokkie As QWord) As HRESULT
     131'Declare Function CoRegisterInitializeSpy Lib "ole32" (Spy As IInitializeSpy, ByRef uliCokkie As QWord) As HRESULT
    132132Declare Function CoRevokeInitializeSpy Lib "ole32" (uliCookie As QWord) As HRESULT
    133133
     
    179179
    180180/* Registering surrogate processes */
    181 'Declare Function CoRegisterSurrogate Lib "ole32" (pSurrogate As *ISurrogate) As HRESULT
     181'Declare Function CoRegisterSurrogate Lib "ole32" (Surrogate As ISurrogate) As HRESULT
    182182
    183183/* marshaling interface pointers */
  • trunk/Include/objidl.sbp

    r300 r303  
    1313/* interface IMarshal */
    1414/* [uuid][object][local] */
    15 
    16 TypeDef LPMARSHAL = /* [unique] */ *IMarshal
    1715
    1816Dim IID_IMarshal = [&h00000003, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
     
    5149End Interface
    5250
    53 ' IMarshal2
     51/* interface IMarshal2 */
     52/* [uuid][object][local] */
     53
     54Dim IID_IMarshal2 = [&h000001Cf, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
     55Interface IMarshal2
     56    Inherits IMarshal
     57End Interface
     58
     59/* interface IMalloc */
     60/* [uuid][object][local] */
    5461
    5562Dim IID_IMalloc = [&h00000002, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
     
    6976End Interface
    7077
    71 ' IMallocSpy
     78/* interface IMallocSpy */
     79/* [uuid][object][local] */
     80
     81Dim IID_IMallocSpy = [&h0000001d, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
     82Interface IMallocSpy
     83    Inherits IUnknown
     84
     85    Function PreAlloc(
     86        /* [in] */ cbRequest As SIZE_T) As HRESULT
     87    Function PostAlloc(
     88        /* [in] */ pActual As VoidPtr) As VoidPtr
     89    Function PreFree(
     90        /* [in] */ pRequest As VoidPtr,
     91        /* [in] */ fSpyed As BOOL) As VoidPtr
     92    Sub PostFree(
     93        /* [in] */ fSpyed As BOOL)
     94    Function PreRealloc(
     95        /* [in] */ pRequest As VoidPtr,
     96        /* [in] */ cbRequestt As SIZE_T,
     97        /* [out] */ ByRef ppNewRequest As VoidPtr,
     98        /* [in] */ fSpyed As BOOL) As HRESULT
     99    Function PostRealloc(
     100        /* [in] */ pActual As VoidPtr,
     101        /* [in] */ fSpyed As BOOL) As VoidPtr
     102    Function PreGetSize(
     103        /* [in] */ pRequest As VoidPtr,
     104        /* [in] */ fSpyed As BOOL) As VoidPtr
     105    Function PostGetSize(
     106        /* [in] */ cbActual As SIZE_T,
     107        /* [in] */ fSpyed As BOOL) As HRESULT
     108    Function PreDidAlloc(
     109    /* [in] */ pRequest As VoidPtr,
     110    /* [in] */ fSpyed As BOOL) As VoidPtr
     111    Function PostDidAlloc(
     112    /* [in] */ pRequest As VoidPtr,
     113    /* [in] */ fSpyed As BOOL,
     114    /* [in] */ fActual As Long) As Long
     115    Sub PreHeapMinimize()
     116    Sub PostHeapMinimize()
     117End Interface
    72118
    73119' IStdMarshalInfo
     
    77123Type MULTI_QI
    78124    pIID As * /*Const*/ IID
    79     pItf As *IUnknown
     125    pItf As IUnknown
    80126    hr As HRESULT
    81127End Type
    82128
    83129Dim IID_IMultiQI = [&h00000020, &h0000, &h0000, [&hC0, &h00, &h00, &h00, &h00, &h00, &h00, &h46]] As IID
    84 
    85130Interface IMultiQI
    86131    Inherits IUnknown
     
    95140' IInternalUnknown
    96141
    97 ' IEnumUnknown
     142/* interface IEnumUnknown */
     143/* [unique][uuid][object] */
     144
     145Dim IID_IEnumUnknown = [&h00000100, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
     146Interface IEnumUnknown
     147    Inherits IUnknown
     148
     149    /* [local] */ Function Next_(
     150        /* [in] */ celt As DWord,
     151        /* [out] */ rgelt As *IUnknown,
     152        /* [out] */ ByRef celtFetched As DWord) As HRESULT
     153    Function Skip(
     154        /* [in] */ celt As DWord) As HRESULT
     155    Function Reset() As HRESULT
     156    Function Clone(
     157        /* [out] */ ByRef enumUnk As IEnumUnknown) As HRESULT
     158End Interface
     159
     160/* interface IBindCtx */
     161/* [unique][uuid][object] */
    98162
    99163Type BIND_OPTS
     
    146210        /* [unique][in] */ punk As IUnknown) As HRESULT
    147211    Function ReleaseBoundObjects() As HRESULT
    148     /* [local] */ Function SetBindOptions(
     212    /* [local] */ Function SetBindOptions(
    149213        /* [in] */ ByRef bindopts As BIND_OPTS) As HRESULT
    150     /* [local] */ Function GetBindOptions(
     214    /* [local] */ Function GetBindOptions(
    151215        /* [out][in] */ ByRef bindopts As BIND_OPTS) As HRESULT
    152216    Function GetRunningObjectTable(
     
    159223        /* [out] */ ByRef unk As IUnknown) As HRESULT
    160224    Function EnumObjectParam(
    161         /* [out] */ ByRef enumstr As IEnumString) As HRESULT
     225        /* [out] */ ByRef enumstr As IEnumString) As HRESULT
    162226    Function RevokeObjectParam(
    163227        /* [in] */ pszKey As LPOLESTR) As HRESULT
    164228End Interface
    165229
    166 ' IEnumMoniker
    167 
     230/* interface IEnumMoniker */
     231/* [unique][uuid][object] */
     232
     233Dim IID_IEnumMoniker = [&h00000102, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
     234Interface IEnumMoniker
     235    Inherits IUnknown
     236    /* [local] */ Function Next_(
     237        /* [in] */ celt As DWord,
     238        /* [length_is][size_is][out] */ rgelt As *IMoniker,
     239        /* [out] */ ByRef celtFetched As DWord) As HRESULT
     240    Function Skip(
     241        /* [in] */ celt As DWord) As HRESULT
     242    Function Reset() As HRESULT
     243    Function Clone(
     244        /* [out] */ enumMon As IEnumMoniker) As HRESULT
     245End Interface
     246
     247/* interface IRunningObjectTable */
     248/* [uuid][object] */
     249
     250Dim IID_IRunningObjectTable = [&h00000010, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
    168251Interface IRunningObjectTable
    169252    Inherits IUnknown
     253
     254    Function Register(
     255        /* [in] */ grfFlags As DWord,
     256        /* [unique][in] */ unkObject As IUnknown,
     257        /* [unique][in] */ mkObjectName As IMoniker,
     258        /* [out] */ ByRef dwRegister As DWord) As HRESULT
     259    Function Revoke(
     260        /* [in] */ dwRegister As DWord) As HRESULT
     261    Function IsRunning(
     262        /* [unique][in] */ mkObjectName As IMoniker) As HRESULT
     263    Function GetObject(
     264        /* [unique][in] */ mkObjectName As IMoniker,
     265        /* [out] */ ByRef unkObject As IUnknown) As HRESULT
     266    Function NoteChangeTime(
     267        /* [in] */ dwRegister As DWord,
     268        /* [in] */ ByRef filetime As FILETIME) As HRESULT
     269    Function GetTimeOfLastChange(
     270        /* [unique][in] */ mkObjectName As IMoniker,
     271        /* [in] */ ByRef filetime As FILETIME) As HRESULT
     272    Function EnumRunning(
     273        /* [out] */ ByRef enumMoniker As IEnumMoniker) As HRESULT
    170274End Interface
    171275
     
    186290    Function Load(
    187291        /* [unique][in] */ Stm As IStream) As HRESULT
    188 
    189292    Function Save(
    190293        /* [unique][in] */ Stm As IStream,
    191294        /* [in] */ fClearDirty As BOOL) As HRESULT
    192 
    193295    Function GetSizeMax(
    194296        /* [out] */ ByRef cbSize As ULARGE_INTEGER) As HRESULT
    195297End Interface
    196298
     299/* interface IMoniker */
     300/* [unique][uuid][object] */
     301
     302Const Enum MKSYS
     303    MKSYS_NONE = 0
     304    MKSYS_GENERICCOMPOSITE = 1
     305    MKSYS_FILEMONIKER = 2
     306    MKSYS_ANTIMONIKER = 3
     307    MKSYS_ITEMMONIKER = 4
     308    MKSYS_POINTERMONIKER = 5
     309    MKSYS_CLASSMONIKER = 7
     310    MKSYS_OBJREFMONIKER = 8
     311    MKSYS_SESSIONMONIKER = 9
     312    MKSYS_LUAMONIKER = 10
     313End Enum
     314
     315/* [v1_enum] */ Const Enum MKREDUCE
     316    MKRREDUCE_ONE = (3 << 16)
     317    MKRREDUCE_TOUSER = (2 << 16)
     318    MKRREDUCE_THROUGHUSER = (1 << 16)
     319    MKRREDUCE_ALL = 0
     320End Enum
     321
     322Dim IID_IMoniker = [&h0000000f, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
    197323Interface IMoniker
    198324    Inherits IPersistStream
    199 End Interface
     325
     326    /* [local] */ Function BindToObject(
     327        /* [unique][in] */ bc As IBindCtx,
     328        /* [unique][in] */ mkToLeft As IMoniker,
     329        /* [in] */ ByRef riidResult As IID,
     330        /* [iid_is][out] */ ByRef Result As Any) As HRESULT
     331    /* [local] */ Function BindToStorage(
     332        /* [unique][in] */ bc As IBindCtx,
     333        /* [unique][in] */ mkToLeft As IMoniker,
     334        /* [in] */ ByRef riid As IID,
     335        /* [iid_is][out] */ ByRef Obj As Any) As HRESULT
     336    Function Reduce(
     337        /* [unique][in] */ bc As IBindCtx,
     338        /* [in] */ dwReduceHowFar As DWord,
     339        /* [unique][out][in] */ ByRef mkToLeft As IMoniker,
     340        /* [out] */ ByRef mkReduced As IMoniker) As HRESULT
     341    Function ComposeWith(
     342        /* [unique][in] */ ByRef mkRight As IMoniker,
     343        /* [in] */ fOnlyIfNotGeneric As BOOL,
     344        /* [out] */ ByRef mkComposite As IMoniker) As HRESULT
     345    Function Enum_(
     346        /* [in] */ fForward As BOOL,
     347        /* [out] */ ByRef enumMoniker As IEnumMoniker) As HRESULT
     348    Function IsEqual(
     349        /* [unique][in] */ mkOtherMoniker As IMoniker) As HRESULT
     350    Function Hash(
     351        /* [out] */ ByRef dwHash As DWord) As HRESULT
     352    Function IsRunning(
     353        /* [unique][in] */ bc As IBindCtx,
     354        /* [unique][in] */ mkToLeft As IMoniker,
     355        /* [unique][in] */ mkNewlyRunning As IMoniker) As HRESULT
     356    Function GetTimeOfLastChange(
     357        /* [unique][in] */ bc As IBindCtx,
     358        /* [unique][in] */ mkToLeft As IMoniker,
     359        /* [out] */ ByRef FileTime As FILETIME) As HRESULT
     360    Function Inverse(
     361        /* [out] */ ByRef mk As IMoniker) As HRESULT
     362    Function CommonPrefixWith(
     363        /* [unique][in] */ mkOther As IMoniker,
     364        /* [out] */ ByRef mkPrefix As IMoniker) As HRESULT
     365    Function RelativePathTo(
     366        /* [unique][in] */ mkOther As IMoniker,
     367        /* [out] */ ByRef mkRelPath As IMoniker) As HRESULT
     368    Function GetDisplayName(
     369        /* [unique][in] */ bc As IBindCtx,
     370        /* [unique][in] */ mkToLeft As IMoniker,
     371        /* [out] */ ByRef pszDisplayName As LPOLESTR) As HRESULT
     372    Function ParseDisplayName(
     373        /* [unique][in] */ bc As IBindCtx,
     374        /* [unique][in] */ mkToLeft As IMoniker,
     375        /* [in] */  pszDisplayName As LPOLESTR,
     376        /* [out] */ ByRef chEaten As DWord,
     377        /* [out] */ ByRef mkOut As IMoniker) As HRESULT
     378    Function IsSystemMoniker(
     379        /* [out] */ ByRef dwMksys As DWord) As HRESULT
     380End Interface
     381
     382/* interface IEnumString */
     383/* [unique][uuid][object] */
    200384
    201385Dim IID_IEnumString = [&h00000101, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
     
    214398End Interface
    215399
     400/* interface ISequentialStream */
     401/* [unique][uuid][object] */
     402
    216403Dim IID_ISequentialStream = [&h0c733a30, &h2a1c, &h11ce, [&had, &he5, &h00, &haa, &h00, &h44, &h77, &h3d]] As IID
    217404Interface ISequentialStream
    218405    Inherits IUnknown
    219406
    220     Function Read(pv As VoidPtr, cb As DWord, ByRef cbRead As DWord) As HRESULT
    221     Function Write(pv As VoidPtr, cb As DWord, ByRef cbWritten As DWord) As HRESULT
    222 End Interface
     407    Function Read(
     408        /* [length_is][size_is][out] */ pv As VoidPtr,
     409        /* [in] */ cb As DWord,
     410        /* [out] */ ByRef cbRead As DWord) As HRESULT
     411    Function Write(
     412        /* [size_is][in] */ pv As VoidPtr,
     413        /* [in] */ cb As DWord,
     414        /* [out] */ ByRef cbWritten As DWord) As HRESULT
     415End Interface
     416
     417/* interface IStream */
     418/* [unique][uuid][object] */
    223419
    224420Type STATSTG
     
    259455    Inherits ISequentialStream
    260456
    261     Function Seek(dlibMove As LARGE_INTEGER, dwOrigin As DWord, plibNewPosition As *ULARGE_INTEGER) As HRESULT
    262     Function SetSize(libNewSize As ULARGE_INTEGER) As HRESULT
    263     Function CopyTo(pstm As *IStream, cb As ULARGE_INTEGER, pcbRead As *ULARGE_INTEGER, pcbWritten As *ULARGE_INTEGER) As HRESULT
    264     Function Commit(grfCommitFlags As DWord) As HRESULT
     457    /* [local] */ Function Seek(
     458        /* [in] */ dlibMove As LARGE_INTEGER,
     459        /* [in] */ dwOrigin As DWord,
     460        /* [out] */ plibNewPosition As *ULARGE_INTEGER) As HRESULT
     461    Function SetSize(
     462        /* [in] */ libNewSize As ULARGE_INTEGER) As HRESULT
     463    /* [local] */ Function CopyTo(
     464        /* [unique][in] */ stm As IStream,
     465        /* [in] */ cb As ULARGE_INTEGER,
     466        /* [out] */ pcbRead As *ULARGE_INTEGER,
     467        /* [out] */ pcbWritten As *ULARGE_INTEGER) As HRESULT
     468    Function Commit(
     469        /* [in] */ grfCommitFlags As DWord) As HRESULT
    265470    Function Revert() As HRESULT
    266     Function LockRegion(libOffset As ULARGE_INTEGER, cb As ULARGE_INTEGER, dwLockType As DWord) As HRESULT
    267     Function UnlockRegion(libOffset As ULARGE_INTEGER, cb As ULARGE_INTEGER, dwLockType As DWord) As HRESULT
    268     Function Stat(pstatstg As *STATSTG, grfStatFlag As DWord) As HRESULT
    269     Function Clone(ByRef stm As IStream) As HRESULT
    270 End Interface
     471    Function LockRegion(
     472        /* [in] */ libOffset As ULARGE_INTEGER,
     473        /* [in] */ cb As ULARGE_INTEGER,
     474        /* [in] */ dwLockType As DWord) As HRESULT
     475    Function UnlockRegion(
     476        /* [in] */ libOffset As ULARGE_INTEGER,
     477        /* [in] */ cb As ULARGE_INTEGER,
     478        /* [in] */ dwLockType As DWord) As HRESULT
     479    Function Stat(
     480        /* [out] */ pstatstg As *STATSTG,
     481        /* [in] */ grfStatFlag As DWord) As HRESULT
     482    Function Clone(
     483        /* [out] */ ByRef stm As IStream) As HRESULT
     484End Interface
     485
    271486TypeDef LPSTREAM = *IStream
    272487
     488/* interface IEnumSTATSTG */
     489/* [unique][uuid][object] */
     490
     491Dim IID_IEnumSTATSTG = [&h0000000d, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
    273492Interface IEnumSTATSTG
    274493    Inherits IUnknown
    275 End Interface
    276 
    277 #ifndef __IStorage_INTERFACE_DEFINED__
    278 #define __IStorage_INTERFACE_DEFINED__
     494
     495    /* [local] */ Function Next_(
     496        /* [in] */ celt As DWord,
     497        /* [length_is][size_is][out] */ rgelt As *STATSTG,
     498        /* [out] */ ByRef celtFetched As DWord) As HRESULT
     499    Function Skip(
     500        /* [in] */ celt As DWord) As HRESULT
     501    Function Reset() As HRESULT
     502    Function Clone(
     503        /* [out] */ ByRef enumStat As IEnumSTATSTG) As HRESULT
     504End Interface
    279505
    280506/* interface IStorage */
     
    294520
    295521Dim IID_IStorage = [&h0000000b, &h0000, &h0000, [&hC0, &h00, &h00, &h00, &h00, &h00, &h00, &h46]] As IID
    296 
    297522Interface IStorage
    298523    Inherits IUnknown
     
    361586End Interface
    362587
    363 #endif  /* __IStorage_INTERFACE_DEFINED__ */
    364 
     588/* interface IPersistFile */
     589/* [unique][uuid][object] */
     590
     591Dim IID_IPersistFile = [&h0000010b, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
    365592Interface IPersistFile
    366593    Inherits IPersist
     
    379606End Interface
    380607
    381 
    382 ' IPersistStrage
    383 
     608/* interface IPersistStorage */
     609/* [unique][uuid][object] */
     610
     611Dim IID_IPersistStorage = [&h0000010a, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
     612Interface IPersistStorage
     613    Inherits IPersist
     614
     615    Function IsDirty() As HRESULT
     616    Function InitNew(
     617        /* [unique][in] */ Stg As IStorage) As HRESULT
     618    Function Load(
     619        /* [unique][in] */ Stg As IStorage) As HRESULT
     620    Function Save(
     621        /* [unique][in] */ StgSave As IStorage,
     622        /* [in] */ fSameAsLoad As BOOL) As HRESULT
     623    Function SaveCompleted(
     624        /* [unique][in] */ StgNew As IStorage) As HRESULT
     625    Function HandsOffStorage() As HRESULT
     626End Interface
     627
     628/* interface ILockBytes */
     629/* [unique][uuid][object] */
     630
     631Dim IID_ILockBytes = [&h0000000a, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
    384632Interface ILockBytes
    385633    Inherits IUnknown
     634
     635    /* [local] */ Function ReadAt(
     636        /* [in] */ ulOffset As ULARGE_INTEGER,
     637        /* [length_is][size_is][out] */ pv As VoidPtr,
     638        /* [in] */ cb As DWord,
     639        /* [out] */ ByRef cbRead As DWord) As HRESULT
     640    /* [local] */ Function WriteAt(
     641        /* [in] */ ulOffset As ULARGE_INTEGER,
     642        /* [size_is][in] */ pv As VoidPtr,
     643        /* [in] */ cb As DWord,
     644        /* [out] */ ByRef cbWritten As DWord) As HRESULT
     645    Function Flush() As HRESULT
     646    Function SetSize(
     647    /* [in] */ cb As ULARGE_INTEGER) As HRESULT
     648    Function LockRegion(
     649        /* [in] */ libOffset As ULARGE_INTEGER,
     650        /* [in] */ cb As ULARGE_INTEGER,
     651        /* [in] */ dwLockType As DWord) As HRESULT
     652    Function UnlockRegion(
     653        /* [in] */ libOffset As ULARGE_INTEGER,
     654        /* [in] */ cb As ULARGE_INTEGER,
     655        /* [in] */ dwLockType As DWord) As HRESULT
     656    Function Stat(
     657        /* [out] */ ByRef statstg As STATSTG,
     658        /* [in] */ grfStatFlag As DWord) As HRESULT
    386659End Interface
    387660
     
    415688End Interface
    416689
    417 ' IRootStorage
     690/* interface IRootStorage */
     691/* [unique][uuid][object] */
     692
     693Dim IID_IRootStorage = [&h00000012, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
     694Interface IRootStorage
     695    Inherits IUnknown
     696
     697    Function SwitchToFile(
     698        /* [in] */ pszFile As LPOLESTR) As HRESULT
     699End Interface
     700
     701/* interface IAdviseSink */
     702/* [unique][async_uuid][uuid][object] */
    418703
    419704Enum /*[transmit_as(long)]*/ TYMED
     
    428713End Enum
    429714
    430 Type STGMEDIUM
     715Type RemSTGMEDIUM
     716    tymed As DWord
     717    dwHandleType As DWord
     718    pData As DWord
     719    pUnkForRelease As DWord
     720    cbData As DWord
     721    data[ELM(1)] As Byte
     722End Type
     723
     724/* [wire_marshal] */ Type STGMEDIUM
    431725    tymed As DWord
    432726    data As VoidPtr
     
    445739End Type
    446740
     741Type GDI_OBJECT
     742'   ObjectType As DWord
     743'   /* [switch_type] */ u As Union
     744'       hBitmap As wireHBITMAP
     745'       hPalette As wireHPALETTE
     746'       hGeneric As wireHGLOBAL
     747'   End Union
     748End Type
     749
     750Type userSTGMEDIUM
     751'   tymed As DWord
     752'   /* [switch_type] */ u As Union
     753'       /* Empty union arm */
     754'       hMetaFilePict As wireHMETAFILEPICT
     755'       hHEnhMetaFile As wireHENHMETAFILE
     756'       hGdiHandle As *GDI_OBJECT
     757'       hGlobal As wireHGLOBAL
     758'       lpszFileName As LPOLESTR
     759'       pstm As *BYTE_BLOB
     760'       pstg As BYTE_BLOB
     761'   End Union
     762'   pUnkForRelease As IUnknown
     763End Type
     764
     765TypeDef wireSTGMEDIUM = /* [unique] */ *userSTGMEDIUM
     766TypeDef ASYNC_STGMEDIUM = /* [unique] */ *userSTGMEDIUM
     767TypeDef wireSTGMEDIUM = /* [wire_marshal] */ STGMEDIUM
     768
     769Type userFLAG_STGMEDIUM
     770'   ContextFlags As Long
     771'   fPassOwnership As Long
     772'   Stgmed As userSTGMEDIUM
     773End Type
     774
     775TypeDef wireFLAG_STGMEDIUM = /* [unique] */ *userFLAG_STGMEDIUM
     776
     777Type /* [wire_marshal] */ FLAG_STGMEDIUM
     778    ContextFlags As Long
     779    fPassOwnership As Long
     780    Stgmed As STGMEDIUM
     781End Type
     782
     783Dim IID_IAdviseSink = [&h0000010f, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
    447784Interface IAdviseSink
    448785    Inherits IUnknown
     786
     787    /* [local] */ Sub OnDataChange(
     788        /* [unique][in] */ ByRef Formatetc As FORMATETC,
     789        /* [unique][in] */ ByRef Stgmed As STGMEDIUM)
     790    /* [local] */ Sub OnViewChange(
     791        /* [in] */ dwAspect As DWord,
     792        /* [in] */ lindex As Long)
     793    /* [local] */ Sub OnRename(
     794        /* [in] */ mk As IMoniker)
     795    /* [local] */ Sub OnSave()
     796    /* [local] */ Sub OnClose()
    449797End Interface
    450798
     
    455803' AsyncIAdviseSink2
    456804
     805Dim IID_IDataObject = [&h0000010e, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
    457806Interface IDataObject
    458807    Inherits IUnknown
     
    524873
    525874Dim IID_IMessageFilter = [&h00000016, &h0000, &h0000, [&hC0, &h00, &h00, &h00, &h00, &h00, &h00, &h46]] As IID
    526 
    527875Interface IMessageFilter
    528876    Inherits IUnknown
     
    533881        /* [in] */ dwTickCount As DWord,
    534882        /* [in] */ lpInterfaceInfo As LPINTERFACEINFO) As DWord
    535 
    536883    Function RetryRejectedCall(
    537884        /* [in] */ htaskCallee As HTASK,
    538885        /* [in] */ dwTickCount As DWord,
    539886        /* [in] */ dwRejectType As DWord) As DWord
    540 
    541887    Function MessagePending(
    542888        /* [in] */ htaskCallee As HTASK,
     
    653999' IInitializeSpy
    6541000
    655 #endif'_INC_OBJIDL
     1001#endif '_INC_OBJIDL
  • trunk/Include/ole2.ab

    r300 r303  
    33
    44' 暫定措置
    5 
    6 Interface IPersistStorage
    7     Inherits IUnknown
    8 End Interface
    9 
    10 Interface IDropTarget
    11     Inherits IUnknown
    12 End Interface
    13 
    14 Interface IDropSource
    15     Inherits IUnknown
    16 End Interface
    17 
    18 Interface IOleInPlaceFrame
    19     Inherits IUnknown
    20 End Interface
    21 
    22 Interface IOleInPlaceActiveObject
    23     Inherits IUnknown
    24 End Interface
    25 
    26 Interface IOleAdviseHolder
    27     Inherits IUnknown
    28 End Interface
    29 
    30 Interface IEnumOLEVERB
    31     Inherits IUnknown
    32 End Interface
    335
    346#require <api_winerror.sbp>
  • trunk/Include/oleidl.ab

    r300 r303  
    11'oleidl.ab
    22
    3 Const Enum OLERENDER
     3#require <objidl.sbp>
     4
     5Dim IID_IOleAdviseHolder = [&h00000111, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
     6Interface IOleAdviseHolder
     7    Inherits IUnknown
     8
     9    Function Advise(
     10        /* [unique][in] */ Advise As IAdviseSink,
     11        /* [out] */ ByRef dwConnection As DWord) As HRESULT
     12    Function Unadvise(
     13        /* [in] */ dwConnection As DWord) As HRESULT
     14    Function EnumAdvise(
     15        /* [out] */ ByRef enumAdvise As IEnumSTATDATA) As HRESULT
     16    Function SendOnRename(
     17        /* [unique][in] */ pmk As IMoniker) As HRESULT
     18    Function SendOnSave() As HRESULT
     19    Function SendOnClose() As HRESULT
     20End Interface
     21
     22'IOleCache
     23'IOleCache2
     24'IOleCacheControl
     25
     26/* interface IParseDisplayName */
     27/* [unique][uuid][object] */
     28
     29Dim IID_IParseDisplayName = [&h0000011a, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
     30
     31Interface IParseDisplayName
     32    Inherits IUnknown
     33
     34    Function ParseDisplayName(
     35        /* [unique][in] */ bc As IBindCtx,
     36        /* [in] */ pszDisplayName As LPOLESTR,
     37        /* [out] */ ByRef chEaten As DWord,
     38        /* [out] */ ByRef mkOut As IMoniker) As HRESULT
     39End Interface
     40
     41/* interface IOleContainer */
     42/* [unique][uuid][object] */
     43
     44Dim IID_IOleContainer = [&h0000011b, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
     45Interface IOleContainer
     46    Inherits IParseDisplayName
     47
     48    Function EnumObjects(
     49        /* [in] */ grfFlags As DWord,
     50        /* [out] */ ByRef enumUnk As IEnumUnknown) As HRESULT
     51    Function LockContainer(
     52        /* [in] */ fLock As BOOL) As HRESULT
     53End Interface
     54
     55Const Enum OLERENDER
    456    OLERENDER_NONE = 0
    557    OLERENDER_DRAW = 1
    658    OLERENDER_FORMAT = 2
    7     OLERENDER_ASIS = 3 
     59    OLERENDER_ASIS = 3
    860End Enum
    961
    1062Dim IID_IOleClientSite = [&h00000118, &h0000, &h0000, [&hC0, &h00, &h00, &h00, &h00, &h00, &h00, &h46]] As IID
    11 Interface IOleClientSite 
     63Interface IOleClientSite
    1264    Inherits IUnknown
    1365
     
    1668        /* [in] */ dwAssign As DWord,
    1769        /* [in] */ dwWhichMoniker As DWord,
    18         /* [out] */ ByRef pmk As *IMoniker) As HRESULT
     70        /* [out] */ ByRef mk As IMoniker) As HRESULT
    1971    Function GetContainer(
    20         /* [out] */ ByRef pContainer As VoidPtr /* *IOleContainer*/) As HRESULT
     72        /* [out] */ ByRef Container As IOleContainer) As HRESULT
    2173    Function ShowObject() As HRESULT
    2274    Function OnShowWindow(
     
    2577End Interface
    2678
     79/* interface IOleObject */
     80/* [unique][uuid][object] */
     81
     82Const Enum  OLEGETMONIKER
     83    OLEGETMONIKER_ONLYIFTHERE = 1
     84    OLEGETMONIKER_FORCEASSIGN = 2
     85    OLEGETMONIKER_UNASSIGN = 3
     86    OLEGETMONIKER_TEMPFORUSER = 4
     87End Enum
     88
     89Const Enum  OLEWHICHMK
     90    OLEWHICHMK_CONTAINER = 1
     91    OLEWHICHMK_OBJREL = 2
     92    OLEWHICHMK_OBJFULL = 3
     93End Enum
     94
     95Const Enum  USERCLASSTYPE
     96    USERCLASSTYPE_FULL = 1
     97    USERCLASSTYPE_SHORT = 2
     98    USERCLASSTYPE_APPNAME = 3
     99End Enum
     100
     101Const Enum  OLEMISC
     102    OLEMISC_RECOMPOSEONRESIZE = &h1
     103    OLEMISC_ONLYICONIC = &h2
     104    OLEMISC_INSERTNOTREPLACE = &h4
     105    OLEMISC_STATIC = &h8
     106    OLEMISC_CANTLINKINSIDE = &h10
     107    OLEMISC_CANLINKBYOLE1 = &h20
     108    OLEMISC_ISLINKOBJECT = &h40
     109    OLEMISC_INSIDEOUT = &h80
     110    OLEMISC_ACTIVATEWHENVISIBLE = &h100
     111    OLEMISC_RENDERINGISDEVICEINDEPENDENT = &h200
     112    OLEMISC_INVISIBLEATRUNTIME = &h400
     113    OLEMISC_ALWAYSRUN = &h800
     114    OLEMISC_ACTSLIKEBUTTON = &h1000
     115    OLEMISC_ACTSLIKELABEL = &h2000
     116    OLEMISC_NOUIACTIVATE = &h4000
     117    OLEMISC_ALIGNABLE = &h8000
     118    OLEMISC_SIMPLEFRAME = &h10000
     119    OLEMISC_SETCLIENTSITEFIRST = &h20000
     120    OLEMISC_IMEMODE = &h40000
     121    OLEMISC_IGNOREACTIVATEWHENVISIBLE = &h80000
     122    OLEMISC_WANTSTOMENUMERGE = &h100000
     123    OLEMISC_SUPPORTSMULTILEVELUNDO = &h200000
     124End Enum
     125
     126Const Enum OLECLOSE
     127    OLECLOSE_SAVEIFDIRTY = 0
     128    OLECLOSE_NOSAVE = 1
     129    OLECLOSE_PROMPTSAVE = 2
     130End Enum
     131
    27132Dim IID_IOleObject = [&h00000112, &h0000, &h0000, [&hC0, &h00, &h00, &h00, &h00, &h00, &h00, &h46]] As IID
    28133Interface IOleObject
     
    30135
    31136    Function SetClientSite(
    32         /* [unique][in] */ pClientSite As IOleClientSite) As HRESULT   
     137        /* [unique][in] */ ClientSite As IOleClientSite) As HRESULT
    33138    Function GetClientSite(
    34         /* [out] */ ByRef pClientSite As *IOleClientSite) As HRESULT
     139        /* [out] */ ByRef ClientSite As IOleClientSite) As HRESULT
    35140    Function SetHostNames(
    36141        /* [in] */ szContainerApp As LPCOLESTR,
    37142        /* [unique][in] */ szContainerObj As LPCOLESTR) As HRESULT
    38143    Function Close(
    39         /* [in] */ dwSaveOption As DWord) As HRESULT   
     144        /* [in] */ dwSaveOption As DWord) As HRESULT
    40145    Function SetMoniker(
    41146        /* [in] */ dwWhichMoniker As DWord,
    42         /* [unique][in] */ pmk As *IMoniker) As HRESULT
     147        /* [unique][in] */ mk As IMoniker) As HRESULT
    43148    Function GetMoniker(
    44149        /* [in] */ dwAssign As DWord,
    45150        /* [in] */ dwWhichMoniker As DWord,
    46         /* [out] */ ByRef pmk As *IMoniker) As HRESULT
     151        /* [out] */ ByRef mk As IMoniker) As HRESULT
    47152    Function InitFromData(
    48         /* [unique][in] */ pDataObject As IDataObject,
     153        /* [unique][in] */ DataObject As IDataObject,
    49154        /* [in] */ fCreation As BOOL,
    50155        /* [in] */ dwReserved As DWord) As HRESULT
    51156    Function GetClipboardData(
    52157        /* [in] */ dwReserved As DWord,
    53         /* [out] */ ByRef pDataObject As *IDataObject) As HRESULT
     158        /* [out] */ ByRef DataObject As IDataObject) As HRESULT
    54159    Function DoVerb(
    55160        /* [in] */ iVerb As Long,
    56161        /* [unique][in] */ lpmsg As *MSG,
    57         /* [unique][in] */ pActiveSite As IOleClientSite,
     162        /* [unique][in] */ ActiveSite As IOleClientSite,
    58163        /* [in] */ lindex As Long,
    59164        /* [in] */ hwndParent As HWND,
    60165        /* [unique][in] */ lprcPosRect As *RECT /*LPCRECT*/) As HRESULT
    61166    Function EnumVerbs(
    62         /* [out] */ ByRef pEnumOleVerb As *IUnknown /*IEnumOLEVERB*/) As HRESULT
     167        /* [out] */ ByRef EnumOleVerb As IUnknown /*IEnumOLEVERB*/) As HRESULT
    63168    Function Update() As HRESULT
    64169    Function IsUpToDate() As HRESULT
     
    75180        /* [out] */ ByRef sizel As SIZEL) As HRESULT
    76181    Function Advise(
    77         /* [unique][in] */ pAdvSink As *IAdviseSink,
     182        /* [unique][in] */ AdvSink As IAdviseSink,
    78183        /* [out] */ ByRef dwConnection As DWord) As HRESULT
    79184    Function Unadvise(
     
    87192        /* [in] */ ByRef Logpal As LOGPALETTE) As HRESULT
    88193End Interface
     194
     195/* interface IOleWindow */
     196/* [unique][uuid][object] */
     197
     198Dim IID_IOleWindow = [&h00000114, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
     199Interface IOleWindow
     200    Inherits IUnknown
     201
     202    /* [input_sync] */ Function GetWindow(
     203        /* [out] */ ByRef hwnd As HWND) As HRESULT
     204    Function ContextSensitiveHelp(
     205        /* [in] */ fEnterMode As BOOL) As HRESULT
     206End Interface
     207
     208'IOleLink
     209'IOleItemContainer
     210'IOleInPlaceUIWindow
     211'IOleInPlaceActiveObject
     212Interface IOleInPlaceActiveObject
     213    Inherits IOleWindow
     214End Interface
     215
     216'IOleInPlaceFrame
     217Interface IOleInPlaceFrame
     218    Inherits IOleWindow
     219End Interface
     220
     221'IOleInPlaceObject
     222'IOleInPlaceSite
     223'IContinue
     224'IViewObject
     225'IViewObject2
     226
     227/* interface IDropSource */
     228/* [uuid][object][local] */
     229
     230Dim IID_IDropSource = [&h00000121, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
     231
     232Interface IDropSource
     233    Inherits IUnknown
     234
     235    Function QueryContinueDrag(
     236        fEscapePressed As DWord,
     237        grfKeyState As DWord) As HRESULT
     238    Function GiveFeedback(
     239        dwEffect As DWord) As HRESULT
     240End Interface
     241
     242/* interface IDropTarget */
     243/* [unique][uuid][object] */
     244
     245Const MK_ALT = &h20
     246
     247Const DROPEFFECT_NONE = 0
     248Const DROPEFFECT_COPY = 1
     249Const DROPEFFECT_MOVE = 2
     250Const DROPEFFECT_LINK = 4
     251Const DROPEFFECT_SCROLL = &h80000000
     252
     253Const DD_DEFSCROLLINSET = 11
     254Const DD_DEFSCROLLDELAY = 50
     255Const DD_DEFSCROLLINTERVAL = 50
     256Const DD_DEFDRAGDELAY = 200
     257Const DD_DEFDRAGMINDIST = 2
     258
     259Dim IID_IDropTarget = [&h00000122, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
     260Interface IDropTarget
     261    Inherits IUnknown
     262
     263    Function DragEnter(
     264        /* [unique][in] */ DataObj As IDataObject,
     265        /* [in] */ grfKeyState As DWord,
     266        /* [in] */ x As Long, y As Long,
     267        /* [out][in] */ ByRef effect As DWord) As HRESULT
     268    Function DragOver(
     269        /* [in] */ grfKeyState As DWord,
     270        /* [in] */ x As Long, y As Long,
     271        /* [out][in] */ ByRef effect As DWord) As HRESULT
     272    Function DragLeave() As HRESULT
     273    Function Drop(
     274        /* [unique][in] */ DataObj As IDataObject,
     275        /* [in] */ grfKeyState As DWord,
     276        /* [in] */ x As Long, y As Long,
     277        /* [out][in] */ ByRef effect As DWord) As HRESULT
     278End Interface
     279
     280/* interface IDropSourceNotify */
     281/* [unique][uuid][object][local] */
     282
     283Dim IID_IDropSourceNotify = [&h0000012B, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
     284Interface IDropSourceNotify
     285    Inherits IUnknown
     286
     287    Function DragEnterTarget(
     288        /* [in] */ hwndTarget As HWND) As HRESULT
     289    Function DragLeaveTarget() As HRESULT
     290End Interface
     291
     292/* interface IEnumOLEVERB */
     293/* [unique][uuid][object] */
     294
     295Type OLEVERB
     296    lVerb As Long
     297    lpszVerbName As LPOLESTR
     298    fuFlags As DWord
     299    grfAttribs As DWord
     300End Type
     301
     302/* [v1_enum] */ Const Enum OLEVERBATTRIB
     303    OLEVERBATTRIB_NEVERDIRTIES = 1
     304    OLEVERBATTRIB_ONCONTAINERMENU = 2
     305End Enum
     306
     307Dim IID_IEnumOLEVERB = [&h00000104, 0, 0, [&hC0, 0, 0, 0, 0, 0, 0, &h46]] As IID
     308Interface IEnumOLEVERB
     309    Inherits IUnknown
     310
     311    /* [local] */ Function Next_(
     312        /* [in] */ celt As DWord,
     313        /* [length_is][size_is][out] */ rgelt As *OLEVERB,
     314        /* [out] */ ByRef celtFetched As DWord) As HRESULT
     315    Function Skip(
     316        /* [in] */ celt As DWord) As HRESULT
     317    Function Reset() As HRESULT
     318    Function Clone(
     319        /* [out] */ ByRef enumOleVerb As IEnumOLEVERB) As HRESULT
     320End Interface
  • trunk/Include/system/string.sbp

    r272 r303  
    55#define _INC_BASIC_STRING
    66
     7#require <Classes/System/String.ab>
     8#require <Classes/System/Text/StringBuilder.ab>
     9
    710Function StrPtr(s As String) As *StrChar
    811    StrPtr = s.StrPtr
    912End Function
    10 
    11 Function ZeroString(length As Long) As String
    12     Return New String(0 As StrChar, length)
     13'StringBuilder版はClasses/System/Text/StringBuilder.abに定義されている
     14
     15Function ZeroString(length As Long) As System.Text.StringBuilder
     16    ZeroString = New System.Text.StringBuilder
     17    ZeroString.Length = length
    1318End Function
    1419
  • trunk/Include/windows.sbp

    r300 r303  
    2020#require <api_system.sbp>
    2121#require <api_window.sbp>
    22 #require <api_commdlg.sbp>
    2322#require <api_gdi.sbp>
    2423#require <api_shell.sbp>
    25 #require <api_reg.sbp>
    2624#require <api_msg.sbp>
    2725#require <api_windowstyles.sbp>
     
    2927#require <api_console.sbp>
    3028#require <winver.ab>
     29#require <api_reg.sbp>
     30
     31#ifndef WIN32_LEAN_AND_MEAN
     32#require <api_mmsys.sbp>
     33#require <ole2.ab>
     34#require <api_commdlg.sbp>
     35#endif
     36
     37#ifdef INC_OLE2
     38#require <ole2.ab>
     39#endif
     40
     41#ifndef NOIME
     42#require <api_imm.sbp>
     43#endif
    3144
    3245#endif '_INC_WINDOWS
  • trunk/Include/wtypes.ab

    r300 r303  
    451451
    452452TypeDef wireBSTR = /* [unique] */ *FLAGGED_WORD_BLOB
    453 TypeDef BSTR = /* [wire_marshal] */ OLECHAR
    454 TypeDef LPBSTR = BSTR
     453TypeDef BSTR = /* [wire_marshal] */ *OLECHAR
     454TypeDef LPBSTR = *BSTR
    455455
    456456TypeDef VARIANT_BOOL = Integer
Note: See TracChangeset for help on using the changeset viewer.