Hi Everyone,
Can you tell me what additional coding I need to add to this to change the wallpaper to the file "img_0293.jpg" referenced in the coding?
Thanks.
Can you tell me what additional coding I need to add to this to change the wallpaper to the file "img_0293.jpg" referenced in the coding?
Thanks.
B4X:
#Region Project Attributes
#ApplicationLabel: My App Label Goes Here
#VersionCode: 1
#VersionName:
'SupportedOrientations possible values: unspecified, landscape or portrait.
#SupportedOrientations: unspecified
#CanInstallToExternalStorage: False
#End Region
#Region Activity Attributes
#FullScreen: False
#IncludeTitle: True
#End Region
Sub Process_Globals
End Sub
Sub Globals
End Sub
Sub Activity_Create(FirstTime As Boolean)
Dim b As Bitmap
Activity.LoadLayout("main")
b = LoadBitmap(File.DirAssets, "img_0293.jpg")
b = CreateScaledBitmap(b, 100, 100, True)
End Sub
Sub Activity_Resume
End Sub
Sub Activity_Pause (UserClosed As Boolean)
End Sub
Sub CreateScaledBitmap(Original As Bitmap, Width As Int, Height As Int, Filter As Boolean) As Bitmap
Dim r As Reflector
Dim b As Bitmap
b = r.RunStaticMethod("android.graphics.Bitmap", "createScaledBitmap", _
Array As Object(Original, Width, Height, Filter), _
Array As String("android.graphics.Bitmap", "java.lang.int", "java.lang.int", "java.lang.boolean"))
Return b
End Sub