This repository has been archived by the owner on Nov 29, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
DZNEmptyDataSetView Frame Issue #147
Comments
Another idea – we could add a delegate method that provides the initial frame for positioning in the scroll view. |
I think the last idea is the simplest solution. I've opened a pull request: #148 |
👍 |
Thank you for such a quick reply and for this library. |
|
This solved the problem in my case:
|
@medinaonly useful |
It is very good. So clever. Thanks for share. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
DZNEmptyDataSetView
sets its frame to the scroll view's bounds. I'm experiencing problems with this when reloading theDZNEmptyDataSetView
while the scroll view is scrolled/scrolling.In my specific case – the refresh control I'm using (
SSPullToRefresh
) adjusts the scroll view's insets and offsets while reloading and animating. This causes theDZNEmptyDataSetView
to be in the "wrong" spot when I reload theDZNEmptyDataSetView
during this animation.The simplest solution for my use case is to do this:
Do you have any suggestions on how we could add this as an option to the project? We could possibly allow the delegate to provide a
DZNEmptyDataSetView
subclass to use. We could add an option for using a0
y origin. (non relative origin?). Even just exposing theDZNEmptyDataSetView
as areadonly
property would allow aUIScrollView
subclass to reposition the subview as needed.Any thoughts on this would be appreciated.
The text was updated successfully, but these errors were encountered: