aritraroy / patternlockview Goto Github PK
View Code? Open in Web Editor NEWAn easy-to-use, customizable and Material Design ready Pattern Lock view for Android
License: Apache License 2.0
An easy-to-use, customizable and Material Design ready Pattern Lock view for Android
License: Apache License 2.0
if yes, tell me .thx
I'm making a Dialog with this pattern lock view inside of it but I would like to be able to easily adjust the pattern lock view's width and height depending on the containing Dialog's dimensions. Any way to do this? Seems like once the layout_width and layout_height are set in the layout file, they can't be changed anymore.
Thanks
i new to app development . I need to add validation to creating a pattern with minimum 3 or 4 dots make to poper pattern. so let me know where i want to modify the code
the library just refuses to work. I also can't launch the application I downloaded (source code). Nothing helps
Actually on the wrong pattern entered we want to set the color of paths and dots to red.
How can we achieve this functionality?
and also SetPattern use.
Since JCenter is now removed in the latest Android Gradle Plugin, would you mind uploading this library to Maven Central instead?
There is a bug in the PatternLockUtils lib where stringToPattern()
cannot convert every pattern combination.
Number values should not be saved in a string for pattern views with 4x4 dots and higher, because the tenth, eleventh and twelfth dot will be interpreted as "1", "0"
, "1", "1"
, and "1", "2"
, etc.
patternToString()
, patternToMd5()
, patternToSha1()
should include a separator between each dot (a comma for example), so that we can differentiate between "1", "0"
, and "10"
.
What i want is by clicking the area of the pattern lock component to trigger the OnTouchListener which i have set on the root view ( view.setOnTouchListener(new View.OnTouchListener() { } ) in order to get the coordinates of the selected spot . By doing so when i click any other component the listener triggers but when click the area of the pattern lock the listener doesn't trigger.
Note: I have also set the PatterLockViewListener.
Parallel execution with configuration on demand is an incubating feature.
FAILURE: Build failed with an exception.
* Where:
Script 'https://raw.githubusercontent.com/nuuneoi/JCenter/master/bintrayv1.gradle' line: 34
* What went wrong:
A problem occurred evaluating script.
> /Users/nik/tmp/PatternLockView/local.properties (No such file or directory)
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
I have a situation where I need need to use scrollView as a parent of PattrenLockView and when I slide my finger vertically the focus is lost and scrolling happens.
how to use auto clean for wrong pattern?
remote: Permission to aritraroy/PatternLockView.git denied to lsyz0021.
fatal: unable to access 'https://github.com/aritraroy/PatternLockView.git/': The requested URL returned error: 403
I have got an exception from Firebase:
Fatal Exception: java.lang.NullPointerException
Attempt to read from field 'android.os.VibrationEffect com.android.server.VibratorService$Vibration.mEffect' on a null object reference
android.view.View.performHapticFeedback (View.java:23916)
com.andrognito.patternlockview.PatternLockView.detectAndAddHit (PatternLockView.java:814)
com.andrognito.patternlockview.PatternLockView.handleActionMove (PatternLockView.java:979)
com.andrognito.patternlockview.PatternLockView.onTouchEvent (PatternLockView.java:448)
android.view.View.dispatchTouchEvent (View.java:12629)
android.app.Activity.dispatchTouchEvent (Activity.java:3441)
If i use 4x4 or more dot, the patternlock result will be not unique , such as 12 5 is equal with 1 2 5. So it will be a good idea to use Hex in 4x4 or other encoding in more dot .
Hi,
I would like to add MotionEvent listener to PatternLockView in order to display X and Y touch screen position to user. How can I achieve that?
I am getting this exception on notifyListenersComplete patternLockView class
Fatal Exception: java.util.ConcurrentModificationException: at java.util.ArrayList$Itr.next(ArrayList.java:860) at com.andrognito.patternlockview.PatternLockView.notifyListenersComplete(PatternLockView.java:751) at com.andrognito.patternlockview.PatternLockView.notifyPatternDetected(PatternLockView.java:719) at com.andrognito.patternlockview.PatternLockView.handleActionUp(PatternLockView.java:1052) at com.andrognito.patternlockview.PatternLockView.onTouchEvent(PatternLockView.java:445) at android.view.View.dispatchTouchEvent(View.java:13488) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:3088) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2781) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:3088) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2781) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:3088) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2781) at android.view.View.dispatchPointerEvent(View.java:13749) at android.view.ViewRootImpl$ViewPostImeInputStage.processPointerEvent(ViewRootImpl.java:5616) at android.view.ViewRootImpl$ViewPostImeInputStage.onProcess(ViewRootImpl.java:5416) at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4917) at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:4970) at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:4936) at android.view.ViewRootImpl$AsyncInputStage.forward(ViewRootImpl.java:5076) at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:4944) at android.view.ViewRootImpl$AsyncInputStage.apply(ViewRootImpl.java:5133) at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4917) at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:4970) at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:4936) at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:4944) at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4917) at android.view.ViewRootImpl.deliverInputEvent(ViewRootImpl.java:7669) at android.view.ViewRootImpl.doProcessInputEvents(ViewRootImpl.java:7638) at android.view.ViewRootImpl.enqueueInputEvent(ViewRootImpl.java:7599) at android.view.ViewRootImpl$WindowInputEventReceiver.onInputEvent(ViewRootImpl.java:7797) at android.view.InputEventReceiver.dispatchInputEvent(InputEventReceiver.java:251) at android.os.MessageQueue.nativePollOnce(MessageQueue.java) at android.os.MessageQueue.next(MessageQueue.java:336) at android.os.Looper.loop(Looper.java:181) at android.app.ActivityThread.main(ActivityThread.java:7592) at java.lang.reflect.Method.invoke(Method.java) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:539) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:950)
I want to custom my pattern with 4 columns and 5 rows. How can i do ?
Hi there,
great library!
I want to add a simple time delay to this view so it doesn't accept input for a certain amount of time after the pattern has been input wrong.
Is there an easy way to achieve this?
My current code with missing parts:
Single
.fromCallable {
patternLockView
.setViewMode(PatternLockView.PatternViewMode.WRONG)
// TODO: disable touch input
}
.delay(1, TimeUnit.SECONDS)
.observeOn(Schedulers.io())
.subscribeOn(AndroidSchedulers.mainThread())
.subscribeBy(onSuccess = {
patternLockView
.clearPattern()
// TODO: enable touch input
})
how to change color like you did in second screenshot
in viewPager when dragging right to left viewpager change its page and this its is not working please fix
plz help, how remove drawn pattern(showing) after just finish drawing
where is code? help me. Thank
After Wrong Pattern i can set Pattern color to Red but how can i clear the Pattern after 5 sec when it is wrong. I try Thread to seep 5 sec , it clear the pattern after 5 sec but the color of wrong is not change to red.
how to make it recognize the wrong pattern?
I want to set length of pattern that user can select only 4 or 5 dots. How to achieve that?
Also i want to know that how can i set the correct password and then check if user entered correct one or not. If not then show choosen pattern in red color.
Hi,
i tried your library but i got this error
java.lang.ArrayIndexOutOfBoundsException: length=0; index=0 at com.andrognito.patternlockview.PatternLockView$Dot.of(PatternLockView.java:1195) at com.andrognito.patternlockview.PatternLockView.checkForNewHit(PatternLockView.java:925) at com.andrognito.patternlockview.PatternLockView.detectAndAddHit(PatternLockView.java:784) at com.andrognito.patternlockview.PatternLockView.handleActionDown(PatternLockView.java:1080) at com.andrognito.patternlockview.PatternLockView.onTouchEvent(PatternLockView.java:442) at android.view.View.dispatchTouchEvent(View.java:11721) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2593) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2593) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2593) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2593) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2593) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2961) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2593) at com.android.internal.policy.DecorView.superDispatchTouchEvent(DecorView.java:445) at com.android.internal.policy.PhoneWindow.superDispatchTouchEvent(PhoneWindow.java:1828) at android.app.Activity.dispatchTouchEvent(Activity.java:3292) at android.support.v7.view.WindowCallbackWrapper.dispatchTouchEvent(WindowCallbackWrapper.java:68) at com.android.internal.policy.DecorView.dispatchTouchEvent(DecorView.java:407) at android.view.View.dispatchPointerEvent(View.java:11960) at android.view.ViewRootImpl$ViewPostImeInputStage.processPointerEvent(ViewRootImpl.java:4776) at android.view.ViewRootImpl$ViewPostImeInputStage.onProcess(ViewRootImpl.java:4590) at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4128) at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:4181) at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:4147) at android.view.ViewRootImpl$AsyncInputStage.forward(ViewRootImpl.java:4274) at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:4155) at android.view.ViewRootImpl$AsyncInputStage.apply(ViewRootImpl.java:4331) at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4128) at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:4181) at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:4147) at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:4155) at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4128) at android.view.ViewRootImpl.deliverInputEvent(ViewRootImpl.java:6642) at android.view.ViewRootImpl.doProcessInputEvents(ViewRootImpl.java:6616) at android.view.ViewRootImpl.enqueueInputEvent(ViewRootImpl.java:6577) at android.view.ViewRootImpl$WindowInputEventReceiver.onInputEvent(ViewRootImpl.java:6745) at android.view.InputEventReceiver.dispatchInputEvent(InputEventReceiver.java:185) at android.os.MessageQueue.nativePollOnce(Native Method) at android.os.MessageQueue.next(MessageQueue.java:325) at android.os.Looper.loop(Looper.java:142) at android.app.ActivityThread.main(ActivityThread.java:6541) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.Zygote$MethodAndArgsCaller.run(Zygote.java:240) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:767)
this is my xml code
<com.andrognito.patternlockview.PatternLockView app:dotCount="3" app:aspectRatio="square" android:layout_gravity="center_horizontal" android:id="@+id/pattern_lock_view" android:layout_width="250dp" android:layout_height="250dp"/>
Could not find com.android.support:appcompat-v7:25.3.0.
Searched in the following locations:
- https://jcenter.bintray.com/com/android/support/appcompat-v7/25.3.0/appcompat-v7-25.3.0.pom
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.