pull-to-refresh

Pull to refresh not working in iOS WebView

我们两清 提交于 2019-11-30 20:21:26
I've implemented a straight forward WKWebView in iOS. var refreshControl = UIRefreshControl() refreshControl.addTarget(self, action: Selector("refreshWebView"), forControlEvents: UIControlEvents.ValueChanged) This is in viewDidLoad() And the corresponding refreshWebView function. But when I run it on mobile or simulator, no matter how much I drag, there is no pull to refresh action. Nothing is triggered, and it almost feels like I am stuck to the upper bounds of the screen. Where can be going wrong? Try to change your code like this, If you want to pull to refresh the webView you need to

simple example on how to use SwipeRefreshLayout with ListView

守給你的承諾、 提交于 2019-11-30 19:19:09
Does anyone have a simple example on how to use SwipeRefreshLayout with a ListView? Here is my situation: I have a class SynchDogs that pulls data from the server. So that class serves as the source for my adapter. I want to use SwipeRefreshLayout for refreshing the adapter and so the ListView. DogActivity is an Observer of SynchDogs so that DogActivity implements an update method that is called when new data is ready. So I implement onRefresh as @Override public void onRefresh() { SynchDogs.getInstance().synchronizeWithServer(); } So I am supposing this is all I need to initiate the start of

Android - how can i know when gridview has reached the bottom?

筅森魡賤 提交于 2019-11-30 12:20:34
I'm building an app that loads images from JSON and displays them as grid view. the problem is that there are hundreds of images and i want to load 20 each time, I want to download more pictures from the server when the scroll reaches the bottom. so, how can i tell when the grid view reaches the bottom? I've searched the web and couldn't figure this one... anyone have ideas? I'm adding a photo of an app that does something very similar to what i want. thanks. gahfy You can use setOnScrollListener to your GridView. Here is the code example: gridView.setOnScrollListener(new OnScrollListener(){

PullToRefresh list with pinned section header

时光毁灭记忆、已成空白 提交于 2019-11-30 07:29:53
Does anyone has practice of using Pull to refresh list with Pinned section header ? I use Android-PullToRefresh lib with my list and I want to add ability of showing pinned section header at the top of list. I used PinnedHeaderListView lib in another project for pinned section. But I can't combine these two libraries into one. Is Android-PullToRefresh can show pinned section header? Perhaps any other Pull to refresh lib can do it? It's possible to integrate the Actionbar-PullToRefresh library with the StickyListHeaders library, but you need to use a custom Delegate in order to get Actionbar

Pull To Refresh in iOS 7

六月ゝ 毕业季﹏ 提交于 2019-11-30 03:38:48
I'm trying to get the pull to refresh feature working properly on iOS 7 in my Table View. On viewDidLoad, I have: self.refreshControl = [[UIRefreshControl alloc] init]; [self.refreshControl addTarget:self action:@selector(refreshInvoked:forState:) forControlEvents:UIControlEventValueChanged]; I then run: -(void) refreshInvoked:(id)sender forState:(UIControlState)state { // Refresh table here... [_allEntries removeAllObjects]; [self.tableView reloadData]; [self refresh]; } When the request that the refresh method invokes is done, in the didCompleteRequest code, I have: [self.refreshControl

Android Lollipop - Pull to refresh

只谈情不闲聊 提交于 2019-11-29 20:19:32
I am trying to implement pull-to-refresh in Android. I know there is SwipeRefreshLayout but with all the newly designed Google apps like Drive (see attached) for Lollipop, I have noticed there is a new refresh icon that comes in the view when pulled. I tried looking it online but in vain. Has Android released this as a part of the Material Design? Any ideas about how to implement it? EDIT: Some people have pointed out how this is a duplicate of How to implement a Pull-to-refresh . It is not the same question. You'll see it if you read the question properly. This is SwipeRefreshLayout . Version

Android - how can i know when gridview has reached the bottom?

半世苍凉 提交于 2019-11-29 17:38:21
问题 I'm building an app that loads images from JSON and displays them as grid view. the problem is that there are hundreds of images and i want to load 20 each time, I want to download more pictures from the server when the scroll reaches the bottom. so, how can i tell when the grid view reaches the bottom? I've searched the web and couldn't figure this one... anyone have ideas? I'm adding a photo of an app that does something very similar to what i want. thanks. 回答1: You can use

Pull down to refresh on mobile web browser [closed]

丶灬走出姿态 提交于 2019-11-29 10:27:27
问题 I am giving mobile support for a web application. I have a requirement in my application that pull down screen to refresh the page to get the latest updates. I have seen this feature in iPhone native applications and it was also implemented in twitter and foursquare mobile sites. I have seen some posts here but i unable to understand what exactly they are saying.. I am very new to this environment. please guide me in doing this feature. Is there any javascript libraries or jqueries are there

PullToRefresh list with pinned section header

╄→гoц情女王★ 提交于 2019-11-29 09:20:56
问题 Does anyone has practice of using Pull to refresh list with Pinned section header ? I use Android-PullToRefresh lib with my list and I want to add ability of showing pinned section header at the top of list. I used PinnedHeaderListView lib in another project for pinned section. But I can't combine these two libraries into one. Is Android-PullToRefresh can show pinned section header? Perhaps any other Pull to refresh lib can do it? 回答1: It's possible to integrate the Actionbar-PullToRefresh

Error:In <declare-styleable> SherlockSpinner, unable to find attribute android:popupPromptView

|▌冷眼眸甩不掉的悲伤 提交于 2019-11-29 06:07:05
My project contains "ActionBar Sherlock Pull to refresh" and compiles and runs fine with API level 21 and earlier but when i am trying to compile it with API 22, i'm getting this error: Error:In <declare-styleable> SherlockSpinner, unable to find attribute android:popupPromptView Error:Execution failed for task ':app:processDebugResources'. com.android.ide.common.internal.LoggedErrorException: Failed to run command: /Users/m./Android_SDK/build-tools/21.1.2/aapt package -f --no-crunch -I /Users/m./Android_SDK/platforms/android-22/android.jar -M /Users/m./AndroidStudioProjects/-android/android