|
From: <ple...@us...> - 2003-11-17 11:44:02
|
Update of /cvsroot/swebs/swebswebserver/winui/ccTranslator
In directory sc8-pr-cvs1:/tmp/cvs-serv12370/swebswebserver/winui/ccTranslator
Added Files:
basMain.bas cText.cls ccTranslator.csi ccTranslator.dll
ccTranslator.exp ccTranslator.lib ccTranslator.lvw
ccTranslator.vbp ccTranslator.vbw
Log Message:
Ok, now this is a big update, I went ahead with the core/ui split I talked about a while back, this isn't done yet so dont try to use it, just commiting 'just in case'
--- NEW FILE: basMain.bas ---
Attribute VB_Name = "basMain"
'CSEH: WinUI - Custom
'***************************************************************************
'
' SWEBS/WinUI
'
' Copyright (c) 2003 Adam Caudill.
'
' This program is free software; you can redistribute it and/or modify
' it under the terms of the GNU General Public License as published by
' the Free Software Foundation; either version 2 of the License, or
' (at your option) any later version.
'
' This program is distributed in the hope that it will be useful,
' but WITHOUT ANY WARRANTY; without even the implied warranty of
' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
' GNU General Public License for more details.
'
' You should have received a copy of the GNU General Public License
' along with this program; if not, write to the Free Software
' Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
'***************************************************************************
Option Explicit
Public Util As cUtil
Public strLang As String
Public Sub Main()
Set Util = New cUtil
End Sub
--- NEW FILE: cText.cls ---
VERSION 1.0 CLASS
BEGIN
MultiUse = -1 'True
Persistable = 0 'NotPersistable
DataBindingBehavior = 0 'vbNone
DataSourceBehavior = 0 'vbNone
MTSTransactionMode = 0 'NotAnMTSObject
END
Attribute VB_Name = "cTranslate"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = True
Attribute VB_PredeclaredId = False
Attribute VB_Exposed = True
'CSEH: WinUI - Custom
'***************************************************************************
'
' SWEBS/WinUI
'
' Copyright (c) 2003 Adam Caudill.
'
' This program is free software; you can redistribute it and/or modify
' it under the terms of the GNU General Public License as published by
' the Free Software Foundation; either version 2 of the License, or
' (at your option) any later version.
'
' This program is distributed in the hope that it will be useful,
' but WITHOUT ANY WARRANTY; without even the implied warranty of
' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
' GNU General Public License for more details.
'
' You should have received a copy of the GNU General Public License
' along with this program; if not, write to the Free Software
' Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
'***************************************************************************
Option Explicit
Public Function GetText(strString As String) As String
Dim strResult As String
If strString <> "Lang-Maintainer" Then
strResult = Util.GetTaggedData(strLang, "lang base=" & Chr$(34) & strString & Chr$(34), "lang")
Else
strResult = Util.GetTaggedData(strLang, strString)
End If
strResult = Util.CUnescape(strResult)
If strResult <> "" Then
GetText = strResult
Else
GetText = Util.CUnescape(strString)
End If
End Function
Public Sub LoadLang(strLangID As String, strLangFile As String)
Dim strLangTemp As String
If Dir$(strLangFile) <> "" Then
strLangTemp = Space$(FileLen(strLangFile))
Open strLangFile For Binary As 1
Get #1, 1, strLangTemp
Close 1
strLang = Util.GetTaggedData(strLangTemp, "lang-code id=" & Chr$(34) & strLangID & Chr$(34), "lang-code")
strLang = Trim$(strLang)
strLang = Replace(strLang, vbCrLf, "")
strLang = Replace(strLang, Chr$(9), "")
End If
End Sub
--- NEW FILE: ccTranslator.csi ---
[History]
B0=ccTranslator/basMain/Main
B1=ccTranslator/basMain
B2=ccTranslator/cTranslate/GetText
B3=ccTranslator/cTranslate
B4=ccTranslator/cTranslate/LoadLang
--- NEW FILE: ccTranslator.dll ---
(This appears to be a binary file; contents omitted.)
--- NEW FILE: ccTranslator.exp ---
(This appears to be a binary file; contents omitted.)
--- NEW FILE: ccTranslator.lib ---
(This appears to be a binary file; contents omitted.)
--- NEW FILE: ccTranslator.lvw ---
(This appears to be a binary file; contents omitted.)
--- NEW FILE: ccTranslator.vbp ---
Type=OleDll
Reference=*\G{00020430-0000-0000-C000-000000000046}#2.0#0#C:\WINDOWS\System32\stdole2.tlb#OLE Automation
Reference=*\G{0C5C47CC-E5CB-4896-A020-0350E9EF2D64}#5.0#0#..\ccUtil\ccUtil.dll#
Class=cTranslate; cText.cls
Module=basMain; basMain.bas
Startup="Sub Main"
HelpFile=""
ExeName32="ccTranslator.dll"
Command32=""
Name="ccTranslator"
HelpContextID="0"
CompatibleMode="2"
CompatibleEXE32="ccTranslator.dll"
VersionCompatible32="1"
MajorVer=1
MinorVer=0
RevisionVer=0
AutoIncrementVer=0
ServerSupportFiles=0
VersionCompanyName="Imspire.com"
CompilationType=0
OptimizationType=0
FavorPentiumPro(tm)=0
CodeViewDebugInfo=0
NoAliasing=0
BoundsCheck=0
OverflowCheck=0
FlPointCheck=0
FDIVCheck=0
UnroundedFP=0
StartMode=1
Unattended=0
Retained=0
ThreadPerObject=0
MaxNumberOfThreads=1
ThreadingModel=1
DebugStartupOption=0
[MS Transaction Server]
AutoRefresh=1
--- NEW FILE: ccTranslator.vbw ---
cTranslate = 0, 0, 0, 0, C
basMain = 0, 0, 0, 0, C
|