B4A Library PasscodeView

Discussion in 'Additional libraries, classes and official updates' started by DonManfred, Apr 30, 2017.

  1. DonManfred

    DonManfred Expert Licensed User

    This is a wrap for this github project.

    demo.gif

    demo1.png demo2.png

    PasscodeView
    Author:
    DonManfred (wrapper)
    Version: 1
    • PasscodeView
      Events:
      • onFail ( As )
      • onSuccess (number As String)
      Fields:
      • ba As BA
      Methods:
      • 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)
      • clearInput
      • initListener
      • runOkAnimation
      • runTipTextAnimation
      • runWrongAnimation
      Properties:
      • Background As Drawable
      • Color As Int [write only]
      • CorrectInputTip As String
      • CorrectStatusColor As Int
      • Enabled As Boolean
      • FirstInputTip As String
      • Height As Int
      • Left As Int
      • LocalPasscode As String
      • NormalStatusColor As Int
      • NumberTextColor As Int
      • Padding()() As Int
      • Parent As Object [read only]
      • PasscodeLength As Int
      • PasscodeType As Int
      • SecondInputTip As String
      • Tag As Object
      • Top As Int
      • Visible As Boolean
      • Width As Int
      • WrongInputTip As String
      • WrongLengthTip As String
      • WrongStatusColor As Int


    Important:
    - V1.00 is for the old Android Support Libraries.
    - V1.01 and up is based on AndroidX.
     

    Attached Files:

    Last edited: Sep 7, 2019
  2. Peter Simpson

    Peter Simpson Expert Licensed User

    Excellent Manfred...
     
    DonManfred likes this.
  3. freedom2000

    freedom2000 Well-Known Member Licensed User

    very good !
     
  4. itgirl

    itgirl Active Member Licensed User

    Very nice looking and neat , thanks
     
    DonManfred likes this.
  5. Rantor777

    Rantor777 Member Licensed User

    This is Perfect, More master Manfred!
     
  6. Alexander Stolte

    Alexander Stolte Well-Known Member Licensed User

    Good lib., but i cannot check the input value before he is checking right? Because, i get the pin from my Server with a AES Protection and i want to check if the input is equal to this from the server. Is that planned in the future to implement that so i can check the input from the user?, it would definitely save me a lot of work and would be willing to donate.

    Greetings

    PD: I deleted my last comment because I thought I had found a solution sorry :rolleyes:
     
  7. Multiverse app

    Multiverse app Active Member Licensed User

    Running the example gives me the error:

    Code:
    Copying updated assets files (2)
    *** 
    Service (starter) Create ***
    ** 
    Service (starter) Start **
    ** 
    Activity (main) Create, isFirst = true **
    Error occurred on line: 
    34 (Main)
    java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
        at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayout(LayoutBuilder.java:
    170)
        at anywheresoftware.b4a.objects.ActivityWrapper.LoadLayout(ActivityWrapper.java:
    209)
        at b4a.example.main._activity_create(main.java:
    385)
        at java.lang.reflect.Method.invoke(Native Method)
        at anywheresoftware.b4a.shell.Shell.runMethod(
    Shell.java:732)
        at anywheresoftware.b4a.shell.Shell.raiseEventImpl(
    Shell.java:351)
        at anywheresoftware.b4a.shell.Shell.raiseEvent(
    Shell.java:255)
        at java.lang.reflect.Method.invoke(Native Method)
        at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:
    144)
        at b4a.example.main.afterFirstLayout(main.java:
    104)
        at b4a.example.main.access$
    000(main.java:17)
        at b4a.example.main$WaitForLayout.run(main.java:
    82)
        at android.os.Handler.handleCallback(Handler.java:
    873)
        at android.os.Handler.dispatchMessage(Handler.java:
    99)
        at android.os.Looper.loop(Looper.java:
    193)
        at android.app.ActivityThread.main(ActivityThread.java:
    6669)
        at java.lang.reflect.Method.invoke(Native Method)
        at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:
    493)
        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:
    858)
    Caused by: java.lang.reflect.InvocationTargetException
        at java.lang.reflect.Method.invoke(Native Method)
        at anywheresoftware.b4a.objects.CustomViewWrapper.AfterDesignerScript(CustomViewWrapper.java:
    64)
        at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayout(LayoutBuilder.java:
    162)
        ... 
    18 more
    Caused by: android.view.InflateException: Binary XML 
    file line #65: Binary XML file line #65: Error inflating class android.support.v4.widget.Space
    Caused by: android.view.InflateException: Binary XML 
    file line #65: Error inflating class android.support.v4.widget.Space
    Caused by: java.lang.ClassNotFoundException: Didn
    't find class "android.support.v4.widget.Space" on path: DexPathList[[zip file "/system/framework/org.apache.http.legacy.boot.jar", zip file "/data/app/b4a.example-mxQLYwSA1gyZ7sKRJEg6lQ==/base.apk"],nativeLibraryDirectories=[/data/app/b4a.example-mxQLYwSA1gyZ7sKRJEg6lQ==/lib/x86_64, /system/lib64]]
        at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:134)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:
    379)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:
    312)
        at android.view.LayoutInflater.createView(LayoutInflater.java:
    606)
        at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:
    790)
        at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:
    730)
        at android.view.LayoutInflater.rInflate(LayoutInflater.java:
    863)
        at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:
    824)
        at android.view.LayoutInflater.inflate(LayoutInflater.java:
    515)
        at android.view.LayoutInflater.inflate(LayoutInflater.java:
    423)
        at android.view.LayoutInflater.inflate(LayoutInflater.java:
    374)
        at android.view.View.inflate(
    View.java:24354)
        at com.hanks.passcodeview.PasscodeView.<init>(PasscodeView.java:
    64)
        at com.hanks.passcodeview.PasscodeView.<init>(PasscodeView.java:
    58)
        at de.donmanfred.PasscodeViewwrapper._initialize(PasscodeViewwrapper.java:
    98)
        at java.lang.reflect.Method.invoke(Native Method)
        at anywheresoftware.b4a.objects.CustomViewWrapper.AfterDesignerScript(CustomViewWrapper.java:
    64)
        at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayout(LayoutBuilder.java:
    162)
        at anywheresoftware.b4a.objects.ActivityWrapper.LoadLayout(ActivityWrapper.java:
    209)
        at b4a.example.main._activity_create(main.java:
    385)
        at java.lang.reflect.Method.invoke(Native Method)
        at anywheresoftware.b4a.shell.Shell.runMethod(
    Shell.java:732)
        at anywheresoftware.b4a.shell.Shell.raiseEventImpl(
    Shell.java:351)
        at anywheresoftware.b4a.shell.Shell.raiseEvent(
    Shell.java:255)
        at java.lang.reflect.Method.invoke(Native Method)
        at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:
    144)
        at b4a.example.main.afterFirstLayout(main.java:
    104)
        at b4a.example.main.access$
    000(main.java:17)
        at b4a.example.main$WaitForLayout.run(main.java:
    82)
        at android.os.Handler.h
    Message longer than 
    Log limit (4000). Message was truncated.
    ** 
    Activity (main) Resume **
     
  8. DonManfred

    DonManfred Expert Licensed User

    You should never post to existing threads; you know that

    Please create a new thread in the questionsforum for any issue you have
     
    Peter Simpson likes this.
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice