Ignore:
Timestamp:
Mar 28, 2008, 5:43:34 PM (17 years ago)
Author:
イグトランス (egtra)
Message:

インクルードガードとその他不要な前処理定義などの削除

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Include/basic/prompt.sbp

    r411 r497  
    88Namespace Prompt
    99Namespace Detail
    10    
     10
    1111Function _PromptSys_GetTextExtentPoint32(hdc As HDC, psz As PCSTR, cb As Long, ByRef Size As SIZE) As Long
    1212    _PromptSys_GetTextExtentPoint32 = GetTextExtentPoint32A(hdc, psz, cb, Size)
     
    4747Type _PromptSys_LineInformation
    4848    Length As Long
    49     Text As *StrChar
     49    Text As *Char
    5050    CharInfo As *_PromptSys_CharacterInformation
    5151End Type
     
    5353Dim _PromptSys_hFont As HFONT
    5454Dim _PromptSys_FontSize As SIZE
    55 Dim _PromptSys_InputStr[255] As StrChar
     55Dim _PromptSys_InputStr[255] As Char
    5656Dim _PromptSys_InputLen = -1 As Long
    5757Dim _PromptSys_KeyChar As Byte
     
    9797        Next
    9898        _PromptSys_TextLine[100].Length = 0
    99         _PromptSys_TextLine[100].Text = _System_calloc(SizeOf (StrChar) * 255)
     99        _PromptSys_TextLine[100].Text = _System_calloc(SizeOf (Char) * 255)
    100100        _PromptSys_TextLine[100].CharInfo = _System_calloc(SizeOf (_PromptSys_CharacterInformation) * 255)
    101101        _PromptSys_CurPos.y--
     
    136136                End If
    137137                With _PromptSys_FontSize
    138                     _PromptSys_TextOut(hDC, currentLineCharInfo[i2].StartPos, i * .cy, VarPtr(_PromptSys_TextLine[i].Text[i2]) As *StrChar, tempLen)
     138                    _PromptSys_TextOut(hDC, currentLineCharInfo[i2].StartPos, i * .cy, VarPtr(_PromptSys_TextLine[i].Text[i2]) As *Char, tempLen)
    139139                End With
    140140                i2 += tempLen
     
    191191                        EndIf
    192192                        Dim p = buf.StrPtr
    193                         _PromptSys_GetTextExtentPoint32(hdc, VarPtr(p[i2]) As *StrChar, charLen, sz)
     193                        _PromptSys_GetTextExtentPoint32(hdc, VarPtr(p[i2]) As *Char, charLen, sz)
    194194                        currentLineCharInfo[.x + 1].StartPos = currentLineCharInfo[.x].StartPos + sz.cx
    195195                    End If
     
    421421        End If
    422422        Dim tempStr = Nothing As String
    423         Dim str As *StrChar
    424 #ifdef __STRING_IS_NOT_UNICODE
    425         Dim size = _PromptWnd_GetCompositionStringA(himc, str)
    426         tempStr = New String(str, size As Long)
    427 #else
     423        Dim str As *Char
     424#ifdef UNICODE
    428425        Dim osver = System.Environment.OSVersion
    429426        With osver
    430             ' GetCompositionStringW is not implimented in Windows 95 
     427            ' GetCompositionStringW is not implimented in Windows 95
    431428            If .Version.Major = 4 And .Version.Minor = 0 And .Platform = System.PlatformID.Win32Windows Then
    432429                Dim strA As PCSTR
     
    438435            End If
    439436        End With
     437#else
     438        Dim size = _PromptWnd_GetCompositionStringA(himc, str)
     439        tempStr = New String(str, size As Long)
    440440#endif
    441441        ImmReleaseContext(hwnd, himc)
     
    460460        With _PromptSys_TextLine[i]
    461461            .Length = 0
    462             .Text = _System_calloc(SizeOf (StrChar) * 255)
     462            .Text = _System_calloc(SizeOf (Char) * 255)
    463463            .CharInfo = _System_calloc(SizeOf (_PromptSys_CharacterInformation) * 255)
    464464        End With
     
    543543        For i = 0 To 100
    544544            With _PromptSys_TextLine[i]
    545                 .Text[0] = 0 '_System_FillChar(_PromptSys_TextLine[i].Text, -1 As StrChar, 0)
     545                .Text[0] = 0 '_System_FillChar(_PromptSys_TextLine[i].Text, -1 As Char, 0)
    546546                .Length = 0
    547547            End With
     
    589589
    590590    'Set value to variable
    591     Const comma = &h2c As StrChar 'Asc(",")
     591    Const comma = &h2c As Char 'Asc(",")
    592592    Dim broken = ActiveBasic.Strings.Detail.Split(New String(_PromptSys_InputStr), comma)
    593593    Dim i As Long
     
    617617    Dim i = _PromptSys_TextLine[y].Length
    618618    If i < x Then
    619         ActiveBasic.Strings.ChrFill(VarPtr(_PromptSys_TextLine[y].Text[i]), x - i, &h20 As StrChar) 'Asc(" ")
     619        ActiveBasic.Strings.ChrFill(VarPtr(_PromptSys_TextLine[y].Text[i]), x - i, &h20 As Char) 'Asc(" ")
    620620        Dim i2 As Long
    621621        For i2 = i To ELM(x)
Note: See TracChangeset for help on using the changeset viewer.