It is a wrap for this Github project. Posting the following:
1. B4A library files
2. B4A project
3. The Java code - change it which ever way you want
Note the files in the B4A project's /Object/res/values folder (Property set to READ ONLY)
Sample Code:
Library:
PaperShredder
Author: Github: ldoublem (https://github.com/ldoublem/PaperShredder), Wrapped by: Johan Schoeman
Version: 1
1. B4A library files
2. B4A project
3. The Java code - change it which ever way you want
Note the files in the B4A project's /Object/res/values folder (Property set to READ ONLY)
Sample Code:
B4X:
#Region Project Attributes
#ApplicationLabel: PaperShredder
#VersionCode: 1
#VersionName:
'SupportedOrientations possible values: unspecified, landscape or portrait.
#SupportedOrientations: portrait
#CanInstallToExternalStorage: False
#End Region
#Region Activity Attributes
#FullScreen: False
#IncludeTitle: True
#End Region
Sub Process_Globals
'These global variables will be declared once when the application starts.
'These variables can be accessed from all modules.
'https://github.com/ldoublem/PaperShredder
End Sub
Sub Globals
'These global variables will be redeclared each time the activity is created.
'These variables can only be accessed from this module.
Private ps1 As PaperShredder
End Sub
Sub Activity_Create(FirstTime As Boolean)
'Do not forget to load the layout file created with the visual designer. For example:
Activity.LoadLayout("main")
' ps1.ShrededType = ps1.SHRED_TYPE_SLIP
' ps1.ShredderBgColor = Colors.Magenta
' ps1.PaperColor = Colors.yellow
' ps1.SherderProgress = True
' ps1.TextShadow = False
' ps1.ShredderTextColor = Colors.Black
' ps1.ShredderTitle = "SHREDDING YOUR DATA...."
ps1.ShrededType = ps1.SHRED_TYPE_PIECE
ps1.ShredderBgColor = Colors.DarkGray
ps1.PaperColor = Colors.White
ps1.SherderProgress = True
ps1.TextShadow = False
ps1.ShredderTextColor = Colors.white
ps1.PaperEnterColor = Colors.Yellow
ps1.ShredderTitle = "Deleting unused files...."
End Sub
Sub Activity_Resume
ps1.startAnim(2000)
End Sub
Sub Activity_Pause (UserClosed As Boolean)
ps1.stopAnim
End Sub
Library:
PaperShredder
Author: Github: ldoublem (https://github.com/ldoublem/PaperShredder), Wrapped by: Johan Schoeman
Version: 1
- PaperShredder
Fields:- SHRED_TYPE_PIECE As Int
- SHRED_TYPE_SLIP As Int
- ba As BA
- BringToFront
- DesignerCreateView (base As PanelWrapper, lw As LabelWrapper, props As Map)
- Initialize (EventName As String)
- Invalidate
- Invalidate2 (arg0 As Rect)
- Invalidate3 (arg0 As Int, arg1 As Int, arg2 As Int, arg3 As Int)
- IsInitialized As Boolean
- RemoveView
- RequestFocus As Boolean
- SendToBack
- SetBackgroundImage (arg0 As Bitmap)
- SetColorAnimated (arg0 As Int, arg1 As Int, arg2 As Int)
- SetLayout (arg0 As Int, arg1 As Int, arg2 As Int, arg3 As Int)
- SetLayoutAnimated (arg0 As Int, arg1 As Int, arg2 As Int, arg3 As Int, arg4 As Int)
- SetVisibleAnimated (arg0 As Int, arg1 As Boolean)
- startAnim (duration As Int)
- stopAnim
- Background As Drawable
- Color As Int [write only]
- Enabled As Boolean
- Height As Int
- Left As Int
- PaperColor As Int [write only]
- PaperEnterColor As Int [write only]
- Parent As Object [read only]
- SherderProgress As Boolean [write only]
- ShredderBgColor As Int [write only]
- ShredderTextColor As Int [write only]
- ShredderTitle As String [write only]
- ShrededType As Int [write only]
- Tag As Object
- TextShadow As Boolean [write only]
- Top As Int
- Visible As Boolean
- Width As Int