home *** CD-ROM | disk | FTP | other *** search
- VERSION 5.00
- Object = "{00100003-B1BA-11CE-ABC6-F5B2E79D9E3F}#1.0#0"; "ltocx10n.ocx"
- Begin VB.Form FullScreenFrm
- BackColor = &H00000000&
- BorderStyle = 0 'None
- ClientHeight = 4065
- ClientLeft = 2550
- ClientTop = 2535
- ClientWidth = 4380
- ControlBox = 0 'False
- KeyPreview = -1 'True
- LinkTopic = "Form2"
- MaxButton = 0 'False
- MinButton = 0 'False
- PaletteMode = 1 'UseZOrder
- ScaleHeight = 4065
- ScaleWidth = 4380
- ShowInTaskbar = 0 'False
- Begin VB.Timer Timer1
- Enabled = 0 'False
- Left = 480
- Top = 2160
- End
- Begin LEADLib.LEAD Lead1
- Height = 1815
- Left = 240
- TabIndex = 0
- Top = 240
- Width = 2295
- _Version = 65536
- _ExtentX = 4048
- _ExtentY = 3201
- _StockProps = 229
- BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
- Name = "MS Sans Serif"
- Size = 8.25
- Charset = 0
- Weight = 400
- Underline = 0 'False
- Italic = 0 'False
- Strikethrough = 0 'False
- EndProperty
- ScaleHeight = 121
- ScaleWidth = 153
- DataField = ""
- BitmapDataPath = ""
- AnnDataPath = ""
- PanWinTitle = "PanWindow"
- CLeadCtrl = 0
- End
- Attribute VB_Name = "FullScreenFrm"
- Attribute VB_GlobalNameSpace = False
- Attribute VB_Creatable = False
- Attribute VB_PredeclaredId = True
- Attribute VB_Exposed = False
- Option Explicit
- Dim gMultiPass As Boolean
- Dim gQuit As Boolean
- Dim gFirstText As Boolean
- Dim gFirstShape As Boolean
- Dim gDelay As Long
- Private Declare Sub Sleep Lib "kernel32" (ByVal dwMilliseconds As Long)
- Private Sub ShowImage()
- Dim nRet As Long
- Lead1.AutoRepaint = False
- 'load the next image from the list
- If Form1.ImageNameList.ListIndex = Form1.ImageNameList.ListCount - 1 Then
- Form1.ImageNameList.ListIndex = 0
- Else
- Form1.ImageNameList.ListIndex = Form1.ImageNameList.ListIndex + 1
- End If
- Lead1.EnableProgressEvent = False
- nRet = Lead1.Load(Form1.ImageNameList.List(Form1.ImageNameList.ListIndex), 0, 0, 1)
- Lead1.EnableProgressEvent = True
- gQuit = False
- 'is a transition set?
- If Form1.gnTransEffect = EFX_EFFECT_NONE Then
- Lead1.TransitionStyle = EFX_TRANSITION_NONE
- Lead1.TransitionEffect = EFX_EFFECT_NONE
- Else
- 'set the paint effect for the transition
- Lead1.TransitionEffect = Form1.gnTransEffect
- Lead1.PaintMaxPasses = 1
- Lead1.PaintPass = 1
-
- 'set the effect delay for the transition
- Lead1.EffectDelay = Form1.gnTransDelay
- 'set the grain size for the transition
- Lead1.EffectGrain = Form1.gnTransGrain
- 'set the wand size for the transition
- Lead1.WandSize = Form1.gnTransWandWidth
- 'set the wand color for the transition
- Lead1.WandColor = Form1.gclrTransWandColor
- 'Transparency for the transition
- Lead1.UseTransparentColor = Form1.gbTransTransparent
- Lead1.TransparentColor = Form1.gclrTransTransparentColor
- 'set the transition style, Pattern or Gradient
- If (Form1.gnTransition < EFX_GRADIENT_LINE_CLASS) Then
- Lead1.TransitionStyle = EFX_TRANSITION_PATTERN
- Else
- Lead1.TransitionStyle = EFX_TRANSITION_GRADIENT
- End If
- If Lead1.TransitionStyle = EFX_TRANSITION_PATTERN Then 'pattern transition
- Lead1.PatternStyle = Form1.gnPattern
- Else 'gradient transition
- Lead1.GradientStyle = Form1.gnGradient
- Lead1.PatternStyle = EFX_PATTERN_TRANSPARENT
- End If
- 'set the colors
- Lead1.PatternForeColor = Form1.LEADDlg1.ForeColor
- Lead1.PatternBackColor = Form1.LEADDlg1.BackColor
- Lead1.GradientStartColor = Form1.LEADDlg1.StartColor
- Lead1.GradientEndColor = Form1.LEADDlg1.EndColor
- End If
-
- 'set the gradient steps for the transition if one
- Lead1.GradientSteps = Form1.LEADDlg1.GradientSteps
- 'set the effect for the main bitmap
- Lead1.PaintEffect = Form1.gnMainEffect
- 'the effect delay for the main bitmap is set in
- 'the PaintNotification event
- 'the effect grain size for the main bitmap is set in
- 'the PaintNotification event
- 'the wand size for the main bitmap is set in
- 'the PaintNotification event
- 'transparency for the main bitmap is set in
- 'the PaintNotification event
- 'is a label enabled?
- If (Form1.EfxLabelOption(0).Value = True) Or (Form1.EfxLabelOption(1).Value = True) Then 'no label
- 'paint the image
- If (Form1.EfxLabelOption(1).Value = True) Then
- Lead1.PaintMaxPasses = Form1.EfxMaxPass.ListIndex + 2
- Lead1.PaintEffect = Form1.GetMultiEffect(0)
- Lead1.PaintPass = 1
- gMultiPass = True
- Lead1.AutoRepaint = True
- Else
- Lead1.PaintMaxPasses = 1
- Lead1.PaintPass = 1
- Lead1.AutoRepaint = True
- End If
- ElseIf (Form1.EfxLabelOption(2).Value = True) Then 'text label
- 'setup the text
- Lead1.DrawFontColor = Form1.LEADDlg1.TextColor
-
- 'text location
- Lead1.TextTop = Lead1.ScaleHeight * 0.1
- Lead1.TextLeft = Lead1.ScaleWidth * 0.1
- Lead1.TextWidth = Lead1.ScaleWidth * 0.8
- Lead1.TextHeight = Lead1.ScaleHeight * 0.8
- 'text alignment and angle
- Lead1.TextAlign = Form1.LEADDlg1.TextAlign
- Lead1.TextAngle = Form1.LEADDlg1.Angle
- 'text hilite color and style
- Lead1.TextHiliteColor = Form1.LEADDlg1.TextHiliteColor
- Lead1.TextStyle = Form1.LEADDlg1.TextStyle
- 'text dropshadow
- Lead1.ShadowColor = Form1.LEADDlg1.ShadowColor
- Lead1.ShadowXDepth = Form1.LEADDlg1.ShadowXDepth
- Lead1.ShadowYDepth = Form1.LEADDlg1.ShadowYDepth
- 'paint the image
- Lead1.PaintEffect = Form1.gnMainEffect
- Lead1.PaintPass = 1
- Lead1.PaintMaxPasses = 1
-
- Lead1.AutoRepaint = True
-
- 'draw the text
- If (Form1.LEADDlg1.TextUseForegroundImage = True) Then
- 'setup the image for the foreground of the text
- Form1.Lead2.Bitmap = Form1.LEADDlg1.TextForegroundBitmap
- Lead1.DrawText Form1.LEADDlg1.SampleText, Form1.Lead2.Bitmap
- Else
- Lead1.DrawText Form1.LEADDlg1.SampleText, 0
- End If
- Else 'shape label
- Lead1.ShadowColor = Form1.LEADDlg1.ShadowColor
- Lead1.ShadowXDepth = Form1.LEADDlg1.ShadowXDepth
- Lead1.ShadowYDepth = Form1.LEADDlg1.ShadowYDepth
-
- 'setup the shape
- Lead1.ShapeBackgroundStyle = Form1.LEADDlg1.ShapeBackStyle
- Lead1.PatternStyle = Form1.LEADDlg1.ShapeFillStyle
-
- 'set the colors
- Lead1.PatternForeColor = Form1.LEADDlg1.ForeColor
- Lead1.PatternBackColor = Form1.LEADDlg1.BackColor
- Lead1.GradientStartColor = Form1.LEADDlg1.StartColor
- Lead1.GradientEndColor = Form1.LEADDlg1.EndColor
- 'shape borders
- Lead1.ShapeBorderStyle = Form1.LEADDlg1.ShapeBorderStyle
- Lead1.ShapeInnerBandStyle = Form1.LEADDlg1.ShapeInnerStyle
- Lead1.ShapeOuterBandStyle = Form1.LEADDlg1.ShapeOuterStyle
- Lead1.ShapeBorderColor = Form1.LEADDlg1.ShapeBorderColor
- Lead1.ShapeInnerBandHiliteColor = Form1.LEADDlg1.ShapeInnerHiliteColor
- Lead1.ShapeOuterBandHiliteColor = Form1.LEADDlg1.ShapeOuterHiliteColor
- Lead1.ShapeInnerBandShadowColor = Form1.LEADDlg1.ShapeInnerShadowColor
- Lead1.ShapeOuterBandShadowColor = Form1.LEADDlg1.ShapeOuterShadowColor
- Lead1.ShapeBorderThickness = Form1.LEADDlg1.ShapeBorderWidth
- Lead1.ShapeInnerBandThickness = Form1.LEADDlg1.ShapeInnerWidth
- Lead1.ShapeOuterBandThickness = Form1.LEADDlg1.ShapeOuterWidth
-
- 'setup the shape location
- Lead1.ShapeTop = Lead1.ScaleHeight * 0.1
- Lead1.ShapeLeft = Lead1.ScaleWidth * 0.1
- Lead1.ShapeWidth = Lead1.ScaleWidth * 0.8
- Lead1.ShapeHeight = Lead1.ScaleHeight * 0.8
-
- 'paint the image
- Lead1.PaintEffect = Form1.gnMainEffect
- Lead1.PaintPass = 1
- Lead1.PaintMaxPasses = 1
- Lead1.AutoRepaint = True
-
- 'draw the shape
- If ((Lead1.ShapeBackgroundStyle = EFX_BACKSTYLE_TILED_IMAGE) Or _
- (Lead1.ShapeBackgroundStyle = EFX_BACKSTYLE_TRANSLUCENT_TILED_IMAGE)) Then
- 'setup the background image
- Form1.Lead2.Bitmap = Form1.LEADDlg1.ShapeBackgroundBitmap
- Lead1.BackgroundImageTop = 0
- Lead1.BackgroundImageLeft = 0
- Lead1.BackgroundImageWidth = Form1.Lead2.BitmapWidth
- Lead1.BackgroundImageHeight = Form1.Lead2.BitmapHeight
- Lead1.DrawShape Form1.LEADDlg1.Shape, Form1.Lead2.Bitmap
- Else
- 'draw the shape
- Lead1.DrawShape Form1.LEADDlg1.Shape, 0
- End If
- End If
- Lead1.AutoRepaint = True
- End Sub
- Private Sub Form_KeyPress(KeyAscii As Integer)
- Lead1.BackErase = False
- If KeyAscii = vbKeyEscape Then
- gQuit = True
- End If
- End Sub
- Private Sub Form_Load()
- Dim fOK As Integer
- Dim nValue As Integer
- Dim fChecked As Integer
- gDelay = 0
- gFirstText = True
- gFirstShape = True
- Load GetValueFrm
- GetValueInitTheForm "Slide Delay", "Milliseconds:", 5000, 0, CInt(gDelay), 10, 1, False
- GetValueFrm.Show 1
- GetValueGetUserSelections fOK, nValue, fChecked
- Unload GetValueFrm
- If fOK Then
- gDelay = nValue
- End If
- Top = 0
- Left = 0
- Width = Screen.Width
- Height = Screen.Height
- Lead1.Top = 0
- Lead1.Left = 0
- Lead1.Width = Width
- Lead1.Height = Height
- Lead1.PaintSizeMode = PAINTSIZEMODE_FIT 'SIDES
- Lead1.Font.Name = Form1.Lead1.Font.Name
- Lead1.Font.Size = Form1.Lead1.Font.Size
- Lead1.Font.Bold = Form1.Lead1.Font.Bold
- Lead1.Font.Italic = Form1.Lead1.Font.Italic
- Lead1.Font.Charset = Form1.Lead1.Font.Charset
- Lead1.Font.Strikethrough = Form1.Lead1.Font.Strikethrough
- Lead1.Font.Underline = Form1.Lead1.Font.Underline
- Lead1.Font.Weight = Form1.Lead1.Font.Weight
- gMultiPass = False
- gQuit = False
- Timer1.Interval = 300
- Timer1.Enabled = True
- End Sub
- Private Sub Lead1_PaintNotification(ByVal uPass As Integer, ByVal uType As Integer)
- Lead1.EnableProgressEvent = True
- If (gMultiPass = True) Then
- If ((uType = EFX_NOTIFY_IMAGE) And (uPass >= 0) And (uPass < Lead1.PaintMaxPasses)) Then
- Lead1.PaintEffect = Form1.GetMultiEffect(uPass + 1)
- End If
- End If
- If ((uType = EFX_NOTIFY_IMAGE) And (uPass = 0)) Then
- 'set the effect delay for the main bitmap
- Lead1.EffectDelay = Form1.gnMainDelay
- 'set the grain size for the main bitmap
- Lead1.EffectGrain = Form1.gnMainGrain
- 'set the wand size for the main bitmap
- Lead1.WandSize = Form1.gnMainWandWidth
- 'set the wand color for the main bitmap
- Lead1.WandColor = Form1.gclrMainWandColor
- 'Transparency for the main bitmap?
- Lead1.UseTransparentColor = Form1.gbMainTransparent
- Lead1.TransparentColor = Form1.gclrMainTransparentColor
- End If
- If ((uType = EFX_NOTIFY_TRANSITION) And (uPass = Lead1.PaintMaxPasses)) Then
- 'set the colors
- Lead1.PatternForeColor = Form1.LEADDlg1.ForeColor
- Lead1.PatternBackColor = Form1.LEADDlg1.BackColor
- Lead1.GradientStartColor = Form1.LEADDlg1.StartColor
- Lead1.GradientEndColor = Form1.LEADDlg1.EndColor
- End If
- End Sub
- Private Sub Lead1_ProgressStatus(ByVal iPercent As Integer)
- DoEvents
- If gQuit = True Then
- Lead1.EnableProgressEvent = False
- Lead1.PaintEffect = EFX_EFFECT_NONE
- Lead1.TransitionEffect = EFX_EFFECT_NONE
- Lead1.PaintMaxPasses = 1
- End If
- End Sub
- Private Sub Timer1_Timer()
- Timer1.Interval = 0
- Dim x As Long
- For x = 0 To Form1.ImageNameList.ListCount - 1
- Lead1.AutoRepaint = False
- Lead1.BackErase = False
- Lead1.AutoScroll = False
- Lead1.ScaleMode = 3
- Lead1.EnableProgressEvent = False
- Lead1.Load Form1.ImageNameList.List(x), 0, 0, 1
- Lead1.EnableProgressEvent = True
- ShowImage
- If gQuit = True Then GoTo OUT
- Call Sleep(gDelay)
- Next x
- Hide
- End Sub
-