issue #358: rename ole32-error -> check-ole32-error
parent
7c77597b09
commit
3dd30d2f49
|
@ -21,8 +21,8 @@ IN: io.files.temp.windows
|
|||
0
|
||||
MAX_PATH 1 + WCHAR <c-array>
|
||||
[ SHGetFolderPath ] keep
|
||||
swap ole32-error
|
||||
alien>native-string ;
|
||||
swap check-ole32-error
|
||||
utf16n alien>native-string ;
|
||||
|
||||
PRIVATE>
|
||||
|
||||
|
|
|
@ -86,7 +86,7 @@ FUNCTION: void ReleaseStgMedium ( LPSTGMEDIUM pmedium ) ;
|
|||
|
||||
: com-query-interface ( interface iid -- interface' )
|
||||
{ void* }
|
||||
[ IUnknown::QueryInterface ole32-error ]
|
||||
[ IUnknown::QueryInterface check-ole32-error ]
|
||||
with-out-parameters ;
|
||||
|
||||
: com-add-ref ( interface -- interface )
|
||||
|
|
|
@ -122,11 +122,11 @@ TUPLE: ole32-error code message ;
|
|||
: <ole32-error> ( code -- error )
|
||||
dup n>win32-error-string \ ole32-error boa ;
|
||||
|
||||
: ole32-error ( hresult -- )
|
||||
: check-ole32-error ( hresult -- )
|
||||
dup succeeded? [ drop ] [ <ole32-error> throw ] if ;
|
||||
|
||||
: ole-initialize ( -- )
|
||||
f OleInitialize ole32-error ;
|
||||
f OleInitialize check-ole32-error ;
|
||||
|
||||
: guid= ( a b -- ? )
|
||||
[ 16 memory>byte-array ] bi@ = ;
|
||||
|
|
|
@ -20,12 +20,12 @@ TUPLE: script-string < disposable font string metrics ssa size image ;
|
|||
swap ! icp
|
||||
FALSE ! fTrailing
|
||||
] if
|
||||
{ int } [ ScriptStringCPtoX ole32-error ] with-out-parameters ;
|
||||
{ int } [ ScriptStringCPtoX check-ole32-error ] with-out-parameters ;
|
||||
|
||||
: x>line-offset ( x script-string -- n trailing )
|
||||
ssa>> ! ssa
|
||||
swap ! iX
|
||||
{ int int } [ ScriptStringXtoCP ole32-error ] with-out-parameters ;
|
||||
{ int int } [ ScriptStringXtoCP check-ole32-error ] with-out-parameters ;
|
||||
|
||||
<PRIVATE
|
||||
|
||||
|
@ -44,7 +44,7 @@ TUPLE: script-string < disposable font string metrics ssa size image ;
|
|||
f ! pbInClass
|
||||
f void* <ref> ! pssa
|
||||
[ ScriptStringAnalyse ] keep
|
||||
[ ole32-error ] [ |ScriptStringFree void* deref ] bi* ;
|
||||
[ check-ole32-error ] [ |ScriptStringFree void* deref ] bi* ;
|
||||
|
||||
: set-dc-colors ( dc font -- )
|
||||
[ background>> color>RGB SetBkColor drop ]
|
||||
|
@ -65,7 +65,7 @@ TUPLE: script-string < disposable font string metrics ssa size image ;
|
|||
! iMinSel
|
||||
! iMaxSel
|
||||
FALSE ! fDisabled
|
||||
ScriptStringOut ole32-error ;
|
||||
ScriptStringOut check-ole32-error ;
|
||||
|
||||
: draw-script-string ( dc script-string -- )
|
||||
[ font>> set-dc-colors ] keep (draw-script-string) ;
|
||||
|
@ -103,7 +103,7 @@ TUPLE: script-string < disposable font string metrics ssa size image ;
|
|||
PRIVATE>
|
||||
|
||||
M: script-string dispose*
|
||||
ssa>> void* <ref> ScriptStringFree ole32-error ;
|
||||
ssa>> void* <ref> ScriptStringFree check-ole32-error ;
|
||||
|
||||
SYMBOL: cached-script-strings
|
||||
|
||||
|
|
Loading…
Reference in New Issue