MovieBox: Add backward-compatible Path property.

[GB.GUI.BASE]
* BUG: MovieBox: Add backward-compatible Path property.
This commit is contained in:
gambas 2021-01-09 10:38:43 +01:00
parent a0a2d0379c
commit 13c0d23424

View file

@ -18,10 +18,12 @@ Property Border As Integer
Property Stretch As Boolean
Property Mode As Integer
Property Playing As Boolean
Property Path As String
Public Enum Normal, Fill, Cover, Contain, {Repeat}
Static Private $hDefault As Image
Static Private $bDeprecated As Boolean
Private $hObs As Observer
Private $iAlign As Integer = Align.TopLeft
@ -363,3 +365,23 @@ Public Sub Animation_Change()
Me.Refresh
End
Private Function Path_Read() As String
If Not $bDeprecated Then
$bDeprecated = True
Error "gb.gui.base: MovieBox.Path is deprecated. Do not use it anymore."
Endif
End
Private Sub Path_Write(Value As String)
If Not $bDeprecated Then
$bDeprecated = True
Error "gb.gui.base: MovieBox.Path is deprecated. Do not use it anymore."
Endif
Animation_Write(Animation.Load(Value))
End