This commit is contained in:
wu736139669
2015-03-30 22:33:17 +08:00
parent 63fea769d6
commit cbb6fa41bf
374 changed files with 4069 additions and 5 deletions
+19
View File
@@ -0,0 +1,19 @@
Copyright (C) 2011 by BJ Basañes, http://shikii.net
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
+28
View File
@@ -0,0 +1,28 @@
STableViewController
====================================================================================================
STableViewController is a custom table view controller that supports **pull-to-refresh** and
**load-more**. It was designed to have views and behaviors that can be easily customized.
See the demo project in `Demo/Demo.xcodeproj`.
Usage
----------------------------------------------------------------------------------------------------
To start, simply copy `STableViewController.h` and `STableViewController.m` into your project file.
STableViewController is not very useful on its own. It has to be subclassed to apply your custom
views and adjust any behavior. To get started quickly, you may include these files for reference:
* `DemoTableViewController` - subclass of `STableViewController`. This declares what views
to use for pull-to-refresh and load-more. Also includes samples on what methods to override
for data loading and a sample customization to interact with the header and footer views
depending on the situation.
* `DemoTableHeaderView` - the view used for pull-to-refresh
* `DemoTableFooterView` - the view used for load-more
You may also opt to implement your own subclass for `STableViewController` and use your own
views for pull-to-refresh and load-more.
See `STableViewController.h` for more information on the methods available.