Mar 12, 2015 Replies: 46 SlideSwitch Version: 1.02 SlideSwitch Events: close (swview as Object As , token as Object As ) onClick (swview as Object As ) open (swview as Object As , token as Object As ) Fields: ba As BA Methods: AddToParent (Parent As ViewGroup, left As Int, top As Int, width As Int, height As Int) 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) Properties: Background As Drawable Color As Int [write only] Set the Color for the SlideSwitch Enabled As Boolean Height As Int Left As Int Rounded As Boolean [write only] Set this to true if you want to get an rounded SlideSwitch Default is false State As Boolean The State of the the SlideSwitch If true the Switch is open false if Switch is closed Tag As Object Token As Object Top As Int Visible As Boolean Width As Int Attachments libSlideSwitch1.0.0.zip libSlideSwitch1.0.0.zip 8.9 KB · Views: 969 SlideSwitchEx.zip SlideSwitchEx.zip 64.6 KB · Views: 1,105 libSlideSwitch1.0.1.zip libSlideSwitch1.0.1.zip 9.4 KB · Views: 925 libSlideSwitch1.0.2.zip libSlideSwitch1.0.2.zip 10.4 KB · Views: 1,111 Last edited: Apr 30, 2015 Click to expand...
SlideSwitch Version: 1.02 SlideSwitch Events: close (swview as Object As , token as Object As ) onClick (swview as Object As ) open (swview as Object As , token as Object As ) Fields: ba As BA Methods: AddToParent (Parent As ViewGroup, left As Int, top As Int, width As Int, height As Int) 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) Properties: Background As Drawable Color As Int [write only] Set the Color for the SlideSwitch Enabled As Boolean Height As Int Left As Int Rounded As Boolean [write only] Set this to true if you want to get an rounded SlideSwitch Default is false State As Boolean The State of the the SlideSwitch If true the Switch is open false if Switch is closed Tag As Object Token As Object Top As Int Visible As Boolean Width As Int
migrec Member Licensed User Longtime User Mar 12, 2015 #2 You are pumping out libraries right now, trying to break some record? Erels perhaps?
NJDude Expert Licensed User Longtime User Mar 12, 2015 #3 Very nice, however, would it be possible to make those arguments a little but more descriptive? Code: Copy SetColorAnimated(arg0 As Int, arg1 As Int, arg2 As Int) arg0...arg1, gives no idea of what to do there.
Very nice, however, would it be possible to make those arguments a little but more descriptive? Code: Copy SetColorAnimated(arg0 As Int, arg1 As Int, arg2 As Int) arg0...arg1, gives no idea of what to do there.
DonManfred Expert Licensed User Longtime User Mar 13, 2015 #4 NJDude said: Very nice, however, would it be possible to make those arguments a little but more descriptive? Click to expand... must have a look at this. The mentioned method is added automatically (AbsViewWrapper<SlideSwitch>) and it is taken from the View
NJDude said: Very nice, however, would it be possible to make those arguments a little but more descriptive? Click to expand... must have a look at this. The mentioned method is added automatically (AbsViewWrapper<SlideSwitch>) and it is taken from the View
I Inman Well-Known Member Licensed User Longtime User Mar 14, 2015 #5 Great job. Don't forget to mention this library in the Updates thread.
DonManfred Expert Licensed User Longtime User Mar 14, 2015 #6 Inman said: Don't forget to mention this library in the Updates thread. Click to expand... What? I did not do a post there? Oups, sorry ;-) Will do that today when i update this lib here. Want to see first how much work it is to realize @NJDude wish for better method parameter names...
Inman said: Don't forget to mention this library in the Updates thread. Click to expand... What? I did not do a post there? Oups, sorry ;-) Will do that today when i update this lib here. Want to see first how much work it is to realize @NJDude wish for better method parameter names...
D daemon Active Member Licensed User Longtime User Mar 17, 2015 #7 Good one! A feature request: Please add another class SlideToAction that behaves like 'slide to unlock'. Basically, it is always in closed position and raises an even when the slider is moved to beyond 90%. Another feature request: Possibility to add text on slider. Thanks!
Good one! A feature request: Please add another class SlideToAction that behaves like 'slide to unlock'. Basically, it is always in closed position and raises an even when the slider is moved to beyond 90%. Another feature request: Possibility to add text on slider. Thanks!
ArminKH Well-Known Member Apr 28, 2015 #8 Hi thank u 4 for sharing this usefull lib but when i use this lib and ahviewpager lib together then when i want to use slide switch (swipe my hand from left side to right or right to left) then my page (created by using ahviewpager changed and my slide switch not worked properly if is possible please test this or let me to know if is there any way to disable slide switch (slide animation) thank u again
Hi thank u 4 for sharing this usefull lib but when i use this lib and ahviewpager lib together then when i want to use slide switch (swipe my hand from left side to right or right to left) then my page (created by using ahviewpager changed and my slide switch not worked properly if is possible please test this or let me to know if is there any way to disable slide switch (slide animation) thank u again
DonManfred Expert Licensed User Longtime User Apr 28, 2015 #9 daemon said: Another feature request: Possibility to add text on slider. Click to expand... I did not wrote the library. I just wrote a wrapper to use it in B4A. I dont know how to change such things. Find a java library which has exact the features needed and post the link to it. Maybe i´ll do a wrapper for it.
daemon said: Another feature request: Possibility to add text on slider. Click to expand... I did not wrote the library. I just wrote a wrapper to use it in B4A. I dont know how to change such things. Find a java library which has exact the features needed and post the link to it. Maybe i´ll do a wrapper for it.
DonManfred Expert Licensed User Longtime User Apr 28, 2015 #10 arminkh said: if is possible please test this or let me to know if is there any way to disable slide switch (slide animation) Click to expand... I dont have this lib. And i dont have any example which uses this and my lib. But intuitive i would say that is is not a good idea to have a swipe pager and the slideswitch on the same layout. Sounds not logically for me. Create a small project which shows the problem. Maybe i can see anything
arminkh said: if is possible please test this or let me to know if is there any way to disable slide switch (slide animation) Click to expand... I dont have this lib. And i dont have any example which uses this and my lib. But intuitive i would say that is is not a good idea to have a swipe pager and the slideswitch on the same layout. Sounds not logically for me. Create a small project which shows the problem. Maybe i can see anything
ArminKH Well-Known Member Apr 28, 2015 #11 DonManfred said: I dont have this lib. And i dont have any example which uses this and my lib. But intuitive i would say that is is not a good idea to have a swipe pager and the slideswitch on the same layout. Sounds not logically for me. Create a small project which shows the problem. Maybe i can see anything Click to expand... OK I will create a small project to show the problem tonight But now i can say:two touch event(AhviewPager' touch and slide switch's touch)works together for example when i touch and swipe slide switch to change state then at the same time my page(created by ahviewpager)changed because by using that we can change page's by touch and 2 touch event works together Thank u i'll attach small project tonight Last edited: Apr 28, 2015
DonManfred said: I dont have this lib. And i dont have any example which uses this and my lib. But intuitive i would say that is is not a good idea to have a swipe pager and the slideswitch on the same layout. Sounds not logically for me. Create a small project which shows the problem. Maybe i can see anything Click to expand... OK I will create a small project to show the problem tonight But now i can say:two touch event(AhviewPager' touch and slide switch's touch)works together for example when i touch and swipe slide switch to change state then at the same time my page(created by ahviewpager)changed because by using that we can change page's by touch and 2 touch event works together Thank u i'll attach small project tonight
ArminKH Well-Known Member Apr 28, 2015 #12 @DonManfred this is a small project to show the problem if is possible atleast please take an option 4 disable animation during state changed or disable touch and changing state just work by using click event Attachments T.zip T.zip 12.9 KB · Views: 779
@DonManfred this is a small project to show the problem if is possible atleast please take an option 4 disable animation during state changed or disable touch and changing state just work by using click event
walterf25 Expert Licensed User Longtime User Apr 28, 2015 #13 NJDude said: Very nice, however, would it be possible to make those arguments a little but more descriptive? Code: Copy SetColorAnimated(arg0 As Int, arg1 As Int, arg2 As Int) arg0...arg1, gives no idea of what to do there. Click to expand... +1
NJDude said: Very nice, however, would it be possible to make those arguments a little but more descriptive? Code: Copy SetColorAnimated(arg0 As Int, arg1 As Int, arg2 As Int) arg0...arg1, gives no idea of what to do there. Click to expand... +1
thedesolatesoul Expert Licensed User Longtime User Apr 29, 2015 #14 walterf25 said: +1 Click to expand... It cannot be done. The Javadocs is not inherited from the parent class. SetColorAnimated is a method in ViewWrapper not in the slideswitch.
walterf25 said: +1 Click to expand... It cannot be done. The Javadocs is not inherited from the parent class. SetColorAnimated is a method in ViewWrapper not in the slideswitch.
DonManfred Expert Licensed User Longtime User Apr 29, 2015 #15 thedesolatesoul said: ViewWrapper not in the slideswitch. Click to expand... Maybe we should create wa wish. As far as i know viewwrapper is a b4a class. Maybe erel need to extend this class!?
thedesolatesoul said: ViewWrapper not in the slideswitch. Click to expand... Maybe we should create wa wish. As far as i know viewwrapper is a b4a class. Maybe erel need to extend this class!?
thedesolatesoul Expert Licensed User Longtime User Apr 29, 2015 #16 I think the only way is to have the ViewWrapper and all parent class source files in the project rather than just the jar files for reference. I'm not sure if that is a good thing or not.
I think the only way is to have the ViewWrapper and all parent class source files in the project rather than just the jar files for reference. I'm not sure if that is a good thing or not.
walterf25 Expert Licensed User Longtime User Apr 29, 2015 #19 thedesolatesoul said: It cannot be done. The Javadocs is not inherited from the parent class. SetColorAnimated is a method in ViewWrapper not in the slideswitch. Click to expand... That is why it is better to create your own function that can be exposed to B4A that way you can create the documentation and then just pass the viewwraper method inside that function. Example: Code: Copy */Sets the RGB color */<code> */dim whatever as slideswitch */whatever.Initialize */whatever.ColorAnimated(200, 50, 76) */</code> public void ColorAnimated(BA ba, int R, int G, int B){ SetColorAnimated(R, G, B) }
thedesolatesoul said: It cannot be done. The Javadocs is not inherited from the parent class. SetColorAnimated is a method in ViewWrapper not in the slideswitch. Click to expand... That is why it is better to create your own function that can be exposed to B4A that way you can create the documentation and then just pass the viewwraper method inside that function. Example: Code: Copy */Sets the RGB color */<code> */dim whatever as slideswitch */whatever.Initialize */whatever.ColorAnimated(200, 50, 76) */</code> public void ColorAnimated(BA ba, int R, int G, int B){ SetColorAnimated(R, G, B) }
thedesolatesoul Expert Licensed User Longtime User Apr 29, 2015 #20 walterf25 said: That is why it is better to create your own function that can be exposed to B4A that way you can create the documentation and then just pass the viewwraper method inside that function. Example: Code: Copy */Sets the RGB color */<code> */dim whatever as slideswitch */whatever.Initialize */whatever.SetColorAnimated(200, 50, 76) */</code> public void SetColorAnimated(BA ba, int R, int G, int B){ SetColorAnimated(R, G, B) } Click to expand... I'm simply not willing to do so much donkey work. Be my guest, take all my libraries and write the code for every method in ViewWrapper or other.
walterf25 said: That is why it is better to create your own function that can be exposed to B4A that way you can create the documentation and then just pass the viewwraper method inside that function. Example: Code: Copy */Sets the RGB color */<code> */dim whatever as slideswitch */whatever.Initialize */whatever.SetColorAnimated(200, 50, 76) */</code> public void SetColorAnimated(BA ba, int R, int G, int B){ SetColorAnimated(R, G, B) } Click to expand... I'm simply not willing to do so much donkey work. Be my guest, take all my libraries and write the code for every method in ViewWrapper or other.