B4A Library SwitchButton

MarcoRome

Expert
Licensed User
Longtime User
This is the content of the Resourcefolder.
There are just drawables. No other xml...
This Resource folder is right. In Resource that you have in example are present also folder value and color into Resource. This is conflict.
Now work
 

peacemaker

Expert
Licensed User
Longtime User
But ... it's impossible to get the current state of the switch ? If to use several switches - how to save the user selection ?

UPD: OK, a common extra map of values can be updated by events...
 
Last edited:

DonManfred

Expert
Licensed User
Longtime User
But ... it's impossible to get the current state of the switch ? If to use several switches - how to save the user selection ?

As i lost my source a few months ago i do not have the source so i cant answer this.
BUT i did a fast new wrap for it.

Try the version attached please
 

Attachments

  • SwitchButtonV2.0.zip
    32.6 KB · Views: 288
  • SwitchButtonEx.zip
    26.4 KB · Views: 326
Last edited:

peacemaker

Expert
Licensed User
Longtime User
Try the version v.2.00 attached please

setThumbSize, performClick were removed why ?
"Checked" is with getter now, but no use to test, as above are removed ((
 

peacemaker

Expert
Licensed User
Longtime User
v.2.1:
java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
Caused by: java.lang.NoSuchFieldError: No static field colorAccent of type I in class Lcom/kyleduo/switchbutton/R$attr; or its superclasses (declaration of 'com.kyleduo.switchbutton.R$attr' appears in base.apk)
 

peacemaker

Expert
Licensed User
Longtime User
Yes, seems AppCompat helped... THanks !
It needs to understand what this is...
 

Matteo Giorgini

Member
Licensed User
Hi DonManfred!
I would like to use your library on my project (v. 2.10).
I downloaded the sample, but on my project I don't use AppCompat. This is a problem because without this reference my APP crashes at start.
Can I use SwitchButton "without" AppCompat? How do I do?

Thanks in advance to replay.

Matteo
 
Cookies are required to use this site. You must accept them to continue using the site. Learn more…