|
Post by kimjoeun on Feb 24, 2020 5:16:47 GMT
* I don't speak english well. please understand me.
Hi, I used I do not speak English well.echo17's plugins well(Enhanced scroller, signaler). Thank you for release plugins.
I'm using this plug-in to create snapped page-style UI. (like archero - mobile game)
Then i found a bug.
The snap function does not work while dragging the scroller after stop the mouse movement and mouse up.
Reproduction 1. Open demo scene - 06. 2. Disable gameObject for drag. Touch block, Overlay. 3. Play this scene. 4. Start drag anywhere. 5. stop mouse movement with maintain click down. 6. After a while, up mouse button with keep mouse position. 7. Snap does not worked.
this bug is reproducted on mobile too.
Thank you for reading. Have a nice day. - joeun
* p.s. I have a question about signaler. If 'subscriber' component is destroyed, is 'subscribe' automatically released?
|
|
|
Post by kimjoeun on Feb 24, 2020 5:49:04 GMT
Shortly after writing the thread, I solved the problem using ScrollRectEx class.
/// <summary> /// End drag event /// </summary> public override void OnEndDrag(UnityEngine.EventSystems.PointerEventData eventData) { if (_routeToParent) DoForParents<IEndDragHandler>((parent) => { parent.OnEndDrag(eventData); }); else { base.OnEndDrag(eventData); if(_scroller.snapping) _scroller.Snap(); } _routeToParent = false; }
|
|
|
Post by echo17 on Feb 24, 2020 14:03:07 GMT
Thanks for the follow up post. Here is a link that might be helpful too: link
|
|