TemplateInfo 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (226) hide show
  1. data/.DS_Store +0 -0
  2. data/.gitignore +2 -0
  3. data/TemplateInfo.gemspec +1 -1
  4. data/bin/tif_create.rb +157 -0
  5. data/lib/TemplateInfo/version.rb +1 -1
  6. data/test.xctemplate/.DS_Store +0 -0
  7. data/test.xctemplate/TemplateInfo.plist +2830 -0
  8. data/test.xctemplate/TemplateInfo.xml +2842 -0
  9. data/test.xctemplate/libs/BeeFramework/Bee.h +35 -0
  10. data/test.xctemplate/libs/BeeFramework/Bee_Precompile.h +143 -0
  11. data/test.xctemplate/libs/BeeFramework/Core/Bee_Core.h +36 -0
  12. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Bee_Foundation.h +54 -0
  13. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Bee_Foundation.mm +33 -0
  14. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Bee_Log.h +64 -0
  15. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Bee_Log.mm +164 -0
  16. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Bee_Performance.h +111 -0
  17. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Bee_Performance.mm +122 -0
  18. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Bee_Runtime.h +98 -0
  19. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Bee_Runtime.mm +437 -0
  20. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Bee_Sandbox.h +45 -0
  21. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Bee_Sandbox.mm +81 -0
  22. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Bee_Singleton.h +47 -0
  23. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Bee_Singleton.mm +34 -0
  24. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Bee_SystemInfo.h +62 -0
  25. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Bee_SystemInfo.m +147 -0
  26. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Bee_Thread.h +64 -0
  27. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Bee_Thread.mm +91 -0
  28. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSArray+BeeExtension.h +76 -0
  29. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSArray+BeeExtension.m +300 -0
  30. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSData+BeeExtension.h +44 -0
  31. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSData+BeeExtension.m +92 -0
  32. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSDate+BeeExtension.h +44 -0
  33. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSDate+BeeExtension.m +85 -0
  34. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSDictionary+BeeExtension.h +90 -0
  35. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSDictionary+BeeExtension.m +509 -0
  36. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSNumber+BeeExtension.h +50 -0
  37. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSNumber+BeeExtension.m +64 -0
  38. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSObject+BeeJSON.h +43 -0
  39. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSObject+BeeJSON.m +116 -0
  40. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSObject+BeeNotification.h +66 -0
  41. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSObject+BeeNotification.m +150 -0
  42. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSObject+BeeProperty.h +210 -0
  43. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSObject+BeeProperty.m +34 -0
  44. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSObject+BeeTicker.h +41 -0
  45. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSObject+BeeTicker.m +156 -0
  46. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSObject+BeeTypeConversion.h +49 -0
  47. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSObject+BeeTypeConversion.m +109 -0
  48. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSString+BeeExtension.h +86 -0
  49. data/test.xctemplate/libs/BeeFramework/Core/Foundation/Extension/NSString+BeeExtension.m +464 -0
  50. data/test.xctemplate/libs/BeeFramework/Core/Network/Bee_Network.h +36 -0
  51. data/test.xctemplate/libs/BeeFramework/Core/Network/Bee_Network.m +33 -0
  52. data/test.xctemplate/libs/BeeFramework/Core/Network/Bee_Request.h +144 -0
  53. data/test.xctemplate/libs/BeeFramework/Core/Network/Bee_Request.m +560 -0
  54. data/test.xctemplate/libs/BeeFramework/Core/Network/Bee_RequestQueue.h +99 -0
  55. data/test.xctemplate/libs/BeeFramework/Core/Network/Bee_RequestQueue.m +742 -0
  56. data/test.xctemplate/libs/BeeFramework/Core/Network/Extension/NSObject+BeeRequest.h +62 -0
  57. data/test.xctemplate/libs/BeeFramework/Core/Network/Extension/NSObject+BeeRequest.m +175 -0
  58. data/test.xctemplate/libs/BeeFramework/Core/Storage/0.2.4.zip +0 -0
  59. data/test.xctemplate/libs/BeeFramework/Core/Storage/Bee_ActiveBase.h +133 -0
  60. data/test.xctemplate/libs/BeeFramework/Core/Storage/Bee_ActiveBase.m +641 -0
  61. data/test.xctemplate/libs/BeeFramework/Core/Storage/Bee_ActiveRecord.h +106 -0
  62. data/test.xctemplate/libs/BeeFramework/Core/Storage/Bee_ActiveRecord.m +1956 -0
  63. data/test.xctemplate/libs/BeeFramework/Core/Storage/Bee_Cache.h +91 -0
  64. data/test.xctemplate/libs/BeeFramework/Core/Storage/Bee_Cache.m +318 -0
  65. data/test.xctemplate/libs/BeeFramework/Core/Storage/Bee_Database.h +223 -0
  66. data/test.xctemplate/libs/BeeFramework/Core/Storage/Bee_Database.m +3007 -0
  67. data/test.xctemplate/libs/BeeFramework/Core/Storage/Bee_Keychain.h +55 -0
  68. data/test.xctemplate/libs/BeeFramework/Core/Storage/Bee_Keychain.m +173 -0
  69. data/test.xctemplate/libs/BeeFramework/Core/Storage/Bee_Storage.h +39 -0
  70. data/test.xctemplate/libs/BeeFramework/Core/Storage/Bee_Storage.m +33 -0
  71. data/test.xctemplate/libs/BeeFramework/Core/Storage/Extension/NSObject+BeeDatabase.h +47 -0
  72. data/test.xctemplate/libs/BeeFramework/Core/Storage/Extension/NSObject+BeeDatabase.m +81 -0
  73. data/test.xctemplate/libs/BeeFramework/Core/Storage/Extension/NSObject+BeeKeychain.h +44 -0
  74. data/test.xctemplate/libs/BeeFramework/Core/Storage/Extension/NSObject+BeeKeychain.m +57 -0
  75. data/test.xctemplate/libs/BeeFramework/MVC/Bee_MVC.h +49 -0
  76. data/test.xctemplate/libs/BeeFramework/MVC/Controller/Bee_Controller.h +66 -0
  77. data/test.xctemplate/libs/BeeFramework/MVC/Controller/Bee_Controller.mm +228 -0
  78. data/test.xctemplate/libs/BeeFramework/MVC/Controller/Bee_Message.h +209 -0
  79. data/test.xctemplate/libs/BeeFramework/MVC/Controller/Bee_Message.mm +873 -0
  80. data/test.xctemplate/libs/BeeFramework/MVC/Controller/Bee_MessageQueue.h +75 -0
  81. data/test.xctemplate/libs/BeeFramework/MVC/Controller/Bee_MessageQueue.mm +389 -0
  82. data/test.xctemplate/libs/BeeFramework/MVC/Controller/Extension/BeeMessage+ActiveRecord.h +52 -0
  83. data/test.xctemplate/libs/BeeFramework/MVC/Controller/Extension/BeeMessage+ActiveRecord.m +150 -0
  84. data/test.xctemplate/libs/BeeFramework/MVC/Controller/Extension/BeeMessage+HTTP.h +49 -0
  85. data/test.xctemplate/libs/BeeFramework/MVC/Controller/Extension/BeeMessage+HTTP.mm +201 -0
  86. data/test.xctemplate/libs/BeeFramework/MVC/Controller/Extension/BeeMessage+JSON.h +52 -0
  87. data/test.xctemplate/libs/BeeFramework/MVC/Controller/Extension/BeeMessage+JSON.mm +118 -0
  88. data/test.xctemplate/libs/BeeFramework/MVC/Controller/Extension/BeeMessage+XML.h +49 -0
  89. data/test.xctemplate/libs/BeeFramework/MVC/Controller/Extension/BeeMessage+XML.mm +78 -0
  90. data/test.xctemplate/libs/BeeFramework/MVC/Controller/Extension/NSObject+BeeMessage.h +57 -0
  91. data/test.xctemplate/libs/BeeFramework/MVC/Controller/Extension/NSObject+BeeMessage.mm +138 -0
  92. data/test.xctemplate/libs/BeeFramework/MVC/Model/Bee_Model.h +64 -0
  93. data/test.xctemplate/libs/BeeFramework/MVC/Model/Bee_Model.m +190 -0
  94. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIActionSheet.h +71 -0
  95. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIActionSheet.m +307 -0
  96. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIActivityIndicatorView.h +52 -0
  97. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIActivityIndicatorView.m +152 -0
  98. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIAlertView.h +73 -0
  99. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIAlertView.m +234 -0
  100. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIButton.h +97 -0
  101. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIButton.m +424 -0
  102. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIDatePicker.h +78 -0
  103. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIDatePicker.m +362 -0
  104. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIGridCell.h +82 -0
  105. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIGridCell.m +298 -0
  106. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIImageView.h +110 -0
  107. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIImageView.m +541 -0
  108. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIKeyboard.h +74 -0
  109. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIKeyboard.m +243 -0
  110. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UILabel.h +46 -0
  111. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UILabel.m +99 -0
  112. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIMatrixView.h +124 -0
  113. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIMatrixView.m +821 -0
  114. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UINavigationBar.h +57 -0
  115. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UINavigationBar.m +161 -0
  116. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIOrientation.h +60 -0
  117. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIOrientation.m +146 -0
  118. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIPageControl.h +61 -0
  119. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIPageControl.m +190 -0
  120. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIProgressView.h +47 -0
  121. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIProgressView.m +113 -0
  122. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIPullLoader.h +71 -0
  123. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIPullLoader.m +236 -0
  124. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIScrollView.h +146 -0
  125. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIScrollView.m +1487 -0
  126. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UISegmentedControl.h +60 -0
  127. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UISegmentedControl.m +192 -0
  128. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UISignal.h +126 -0
  129. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UISignal.m +453 -0
  130. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UITabBar.h +70 -0
  131. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UITabBar.m +249 -0
  132. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UITextField.h +67 -0
  133. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UITextField.m +242 -0
  134. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UITextView.h +75 -0
  135. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UITextView.m +311 -0
  136. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UITipsView.h +184 -0
  137. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UITipsView.m +911 -0
  138. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIWebView.h +65 -0
  139. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIWebView.m +242 -0
  140. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIZoomView.h +91 -0
  141. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_UIZoomView.m +444 -0
  142. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_View.h +72 -0
  143. data/test.xctemplate/libs/BeeFramework/MVC/View/Bee_View.m +38 -0
  144. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/CGRect+BeeExtension.h +79 -0
  145. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/CGRect+BeeExtension.m +288 -0
  146. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIColor+BeeExtension.h +65 -0
  147. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIColor+BeeExtension.m +161 -0
  148. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIFont+BeeExtension.h +45 -0
  149. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIFont+BeeExtension.m +137 -0
  150. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIImage+BeeExtension.h +56 -0
  151. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIImage+BeeExtension.m +218 -0
  152. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIView+BeeExtension.h +105 -0
  153. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIView+BeeExtension.m +556 -0
  154. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIView+BeeUISignal.h +53 -0
  155. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIView+BeeUISignal.m +104 -0
  156. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIView+HoldGesture.h +52 -0
  157. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIView+HoldGesture.m +170 -0
  158. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIView+PanGesture.h +54 -0
  159. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIView+PanGesture.m +166 -0
  160. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIView+SwipeGesture.h +54 -0
  161. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIView+SwipeGesture.m +184 -0
  162. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIView+TapGesture.h +57 -0
  163. data/test.xctemplate/libs/BeeFramework/MVC/View/Extension/UIView+TapGesture.m +275 -0
  164. data/test.xctemplate/libs/BeeFramework/MVC/ViewController/Bee_UIBoard.h +212 -0
  165. data/test.xctemplate/libs/BeeFramework/MVC/ViewController/Bee_UIBoard.m +1219 -0
  166. data/test.xctemplate/libs/BeeFramework/MVC/ViewController/Bee_UIStack.h +111 -0
  167. data/test.xctemplate/libs/BeeFramework/MVC/ViewController/Bee_UIStack.m +694 -0
  168. data/test.xctemplate/libs/BeeFramework/MVC/ViewController/Bee_UIStackGroup.h +71 -0
  169. data/test.xctemplate/libs/BeeFramework/MVC/ViewController/Bee_UIStackGroup.m +258 -0
  170. data/test.xctemplate/libs/BeeFramework/MVC/ViewController/Bee_ViewController.h +45 -0
  171. data/test.xctemplate/libs/BeeFramework/MVC/ViewController/Bee_ViewController.m +36 -0
  172. data/test.xctemplate/libs/BeeFramework/MVC/ViewController/Extension/UIViewController+BeeExtension.h +57 -0
  173. data/test.xctemplate/libs/BeeFramework/MVC/ViewController/Extension/UIViewController+BeeExtension.m +151 -0
  174. data/test.xctemplate/libs/BeeFramework/MVC/ViewController/Extension/UIViewController+BeeUISignal.h +53 -0
  175. data/test.xctemplate/libs/BeeFramework/MVC/ViewController/Extension/UIViewController+BeeUISignal.m +92 -0
  176. data/test.xctemplate/libs/BeeFramework/MVC/ViewController/Extension/UIViewController+UINavigationBar.h +72 -0
  177. data/test.xctemplate/libs/BeeFramework/MVC/ViewController/Extension/UIViewController+UINavigationBar.m +175 -0
  178. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UICollection.h +59 -0
  179. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UICollection.m +249 -0
  180. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UILayout.h +199 -0
  181. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UILayout.m +1170 -0
  182. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UIQuery.h +113 -0
  183. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UIQuery.m +710 -0
  184. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UIStyle.h +66 -0
  185. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UIStyle.m +189 -0
  186. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UITemplate.h +69 -0
  187. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UITemplate.m +210 -0
  188. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UITemplateAndroid.h +45 -0
  189. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UITemplateAndroid.m +59 -0
  190. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UITemplateHTML.h +45 -0
  191. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UITemplateHTML.m +55 -0
  192. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UITemplateJSON.h +45 -0
  193. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UITemplateJSON.m +54 -0
  194. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UITemplateOmniGraffle.h +45 -0
  195. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UITemplateOmniGraffle.m +54 -0
  196. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UITemplateXML.h +45 -0
  197. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_UITemplateXML.m +438 -0
  198. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_ViewLayout.h +60 -0
  199. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Bee_ViewLayout.m +37 -0
  200. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/BeeUIQuery+BeeUIStyle.h +45 -0
  201. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/BeeUIQuery+BeeUIStyle.m +55 -0
  202. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/BeeUIStyle+BeeUIQuery.h +45 -0
  203. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/BeeUIStyle+BeeUIQuery.m +55 -0
  204. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UIButton+BeeUIStyle.h +41 -0
  205. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UIButton+BeeUIStyle.m +100 -0
  206. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UIImageView+BeeUIStyle.h +41 -0
  207. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UIImageView+BeeUIStyle.m +101 -0
  208. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UILabel+BeeUIStyle.h +41 -0
  209. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UILabel+BeeUIStyle.m +48 -0
  210. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UITextField+BeeUIStyle.h +41 -0
  211. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UITextField+BeeUIStyle.m +77 -0
  212. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UITextView+BeeUIStyle.h +41 -0
  213. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UITextView+BeeUIStyle.m +47 -0
  214. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UIView+BeeUILayout.h +52 -0
  215. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UIView+BeeUILayout.m +177 -0
  216. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UIView+BeeUIQuery.h +44 -0
  217. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UIView+BeeUIQuery.m +57 -0
  218. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UIView+BeeUIStyle.h +50 -0
  219. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UIView+BeeUIStyle.m +283 -0
  220. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UIViewController+BeeUILayout.h +52 -0
  221. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UIViewController+BeeUILayout.m +178 -0
  222. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UIViewController+BeeUIQuery.h +44 -0
  223. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UIViewController+BeeUIQuery.m +58 -0
  224. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UIViewController+BeeUIStyle.h +44 -0
  225. data/test.xctemplate/libs/BeeFramework/MVC/ViewLayout/Extension/UIViewController+BeeUIStyle.m +57 -0
  226. metadata +226 -3
@@ -0,0 +1,47 @@
1
+ //
2
+ // ______ ______ ______
3
+ // /\ __ \ /\ ___\ /\ ___\
4
+ // \ \ __< \ \ __\_ \ \ __\_
5
+ // \ \_____\ \ \_____\ \ \_____\
6
+ // \/_____/ \/_____/ \/_____/
7
+ //
8
+ // Copyright (c) 2012 BEE creators
9
+ // http://www.whatsbug.com
10
+ //
11
+ // Permission is hereby granted, free of charge, to any person obtaining a
12
+ // copy of this software and associated documentation files (the "Software"),
13
+ // to deal in the Software without restriction, including without limitation
14
+ // the rights to use, copy, modify, merge, publish, distribute, sublicense,
15
+ // and/or sell copies of the Software, and to permit persons to whom the
16
+ // Software is furnished to do so, subject to the following conditions:
17
+ //
18
+ // The above copyright notice and this permission notice shall be included in
19
+ // all copies or substantial portions of the Software.
20
+ //
21
+ // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22
+ // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23
+ // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24
+ // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25
+ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
26
+ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
27
+ // IN THE SOFTWARE.
28
+ //
29
+ //
30
+ // Bee_UIProgressView.h
31
+ //
32
+
33
+ #if (TARGET_OS_IPHONE || TARGET_IPHONE_SIMULATOR)
34
+
35
+ #import "Bee_Precompile.h"
36
+ #import "Bee_UISignal.h"
37
+
38
+ #pragma mark -
39
+
40
+ @interface BeeUIProgressView : UIProgressView
41
+
42
+ + (BeeUIProgressView *)spawn;
43
+ + (BeeUIProgressView *)spawn:(NSString *)tagString;
44
+
45
+ @end
46
+
47
+ #endif // #if (TARGET_OS_IPHONE || TARGET_IPHONE_SIMULATOR)
@@ -0,0 +1,113 @@
1
+ //
2
+ // ______ ______ ______
3
+ // /\ __ \ /\ ___\ /\ ___\
4
+ // \ \ __< \ \ __\_ \ \ __\_
5
+ // \ \_____\ \ \_____\ \ \_____\
6
+ // \/_____/ \/_____/ \/_____/
7
+ //
8
+ // Copyright (c) 2012 BEE creators
9
+ // http://www.whatsbug.com
10
+ //
11
+ // Permission is hereby granted, free of charge, to any person obtaining a
12
+ // copy of this software and associated documentation files (the "Software"),
13
+ // to deal in the Software without restriction, including without limitation
14
+ // the rights to use, copy, modify, merge, publish, distribute, sublicense,
15
+ // and/or sell copies of the Software, and to permit persons to whom the
16
+ // Software is furnished to do so, subject to the following conditions:
17
+ //
18
+ // The above copyright notice and this permission notice shall be included in
19
+ // all copies or substantial portions of the Software.
20
+ //
21
+ // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22
+ // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23
+ // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24
+ // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25
+ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
26
+ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
27
+ // IN THE SOFTWARE.
28
+ //
29
+ //
30
+ // Bee_UIProgressView.m
31
+ //
32
+
33
+ #if (TARGET_OS_IPHONE || TARGET_IPHONE_SIMULATOR)
34
+
35
+ #import "Bee_Precompile.h"
36
+ #import "Bee_UIProgressView.h"
37
+ #import "Bee_UISignal.h"
38
+ #import "Bee_SystemInfo.h"
39
+ #import "UIView+BeeExtension.h"
40
+
41
+ #pragma mark -
42
+
43
+ @interface BeeUIProgressView(Private)
44
+ - (void)initSelf:(UIProgressViewStyle)style;
45
+ @end
46
+
47
+ @implementation BeeUIProgressView
48
+
49
+ + (BeeUIProgressView *)spawn
50
+ {
51
+ return [[[BeeUIProgressView alloc] init] autorelease];
52
+ }
53
+
54
+ + (BeeUIProgressView *)spawn:(NSString *)tagString
55
+ {
56
+ BeeUIProgressView * view = [[[BeeUIProgressView alloc] init] autorelease];
57
+ view.tagString = tagString;
58
+ return view;
59
+ }
60
+
61
+ - (id)init
62
+ {
63
+ self = [super initWithFrame:CGRectZero];
64
+ if ( self )
65
+ {
66
+ [self initSelf:UIProgressViewStyleBar];
67
+ }
68
+ return self;
69
+ }
70
+
71
+ - (id)initWithFrame:(CGRect)frame
72
+ {
73
+ self = [super initWithFrame:frame];
74
+ if ( self )
75
+ {
76
+ [self initSelf:UIProgressViewStyleBar];
77
+ }
78
+ return self;
79
+ }
80
+
81
+ - (id)initWithProgressViewStyle:(UIProgressViewStyle)style
82
+ {
83
+ self = [super initWithProgressViewStyle:style];
84
+ if ( self )
85
+ {
86
+ [self initSelf:style];
87
+ }
88
+ return self;
89
+ }
90
+
91
+ - (void)initSelf:(UIProgressViewStyle)style
92
+ {
93
+ self.progressViewStyle = UIProgressViewStyleBar;
94
+
95
+ #if defined(__IPHONE_5_0)
96
+ if ( IOS5_OR_LATER )
97
+ {
98
+ self.progressTintColor = [UIColor whiteColor];
99
+ // self.trackTintColor = ;
100
+ // self.progressImage = ;
101
+ // self.trackImage = ;
102
+ }
103
+ #endif
104
+ }
105
+
106
+ - (void)dealloc
107
+ {
108
+ [super dealloc];
109
+ }
110
+
111
+ @end
112
+
113
+ #endif // #if (TARGET_OS_IPHONE || TARGET_IPHONE_SIMULATOR)
@@ -0,0 +1,71 @@
1
+ //
2
+ // ______ ______ ______
3
+ // /\ __ \ /\ ___\ /\ ___\
4
+ // \ \ __< \ \ __\_ \ \ __\_
5
+ // \ \_____\ \ \_____\ \ \_____\
6
+ // \/_____/ \/_____/ \/_____/
7
+ //
8
+ // Copyright (c) 2012 BEE creators
9
+ // http://www.whatsbug.com
10
+ //
11
+ // Permission is hereby granted, free of charge, to any person obtaining a
12
+ // copy of this software and associated documentation files (the "Software"),
13
+ // to deal in the Software without restriction, including without limitation
14
+ // the rights to use, copy, modify, merge, publish, distribute, sublicense,
15
+ // and/or sell copies of the Software, and to permit persons to whom the
16
+ // Software is furnished to do so, subject to the following conditions:
17
+ //
18
+ // The above copyright notice and this permission notice shall be included in
19
+ // all copies or substantial portions of the Software.
20
+ //
21
+ // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22
+ // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23
+ // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24
+ // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25
+ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
26
+ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
27
+ // IN THE SOFTWARE.
28
+ //
29
+ //
30
+ // Bee_UIPullLoader.h
31
+ //
32
+
33
+ #if (TARGET_OS_IPHONE || TARGET_IPHONE_SIMULATOR)
34
+
35
+ #import "Bee_Precompile.h"
36
+ #import "Bee_UISignal.h"
37
+
38
+ #pragma mark -
39
+
40
+ @class BeeUIActivityIndicatorView;
41
+
42
+ @interface BeeUIPullLoader : UIView
43
+ {
44
+ NSInteger _state;
45
+ UIImageView * _arrow;
46
+ BeeUIActivityIndicatorView * _indicator;
47
+ }
48
+
49
+ AS_INT( STATE_NORMAL )
50
+ AS_INT( STATE_PULLING )
51
+ AS_INT( STATE_LOADING )
52
+
53
+ AS_SIGNAL( STATE_CHANGED ) // 状态改变
54
+
55
+ @property (nonatomic, readonly) NSInteger state;
56
+ @property (nonatomic, assign) BOOL normal;
57
+ @property (nonatomic, assign) BOOL pulling;
58
+ @property (nonatomic, assign) BOOL loading;
59
+
60
+ @property (nonatomic, readonly) UIImageView * arrow;
61
+ @property (nonatomic, readonly) BeeUIActivityIndicatorView * indicator;
62
+
63
+ + (BeeUIPullLoader *)spawn;
64
+ + (BeeUIPullLoader *)spawn:(NSString *)tagString;
65
+
66
+ - (void)changeState:(NSInteger)state;
67
+ - (void)changeState:(NSInteger)state animated:(BOOL)animated;
68
+
69
+ @end
70
+
71
+ #endif // #if (TARGET_OS_IPHONE || TARGET_IPHONE_SIMULATOR)
@@ -0,0 +1,236 @@
1
+ //
2
+ // ______ ______ ______
3
+ // /\ __ \ /\ ___\ /\ ___\
4
+ // \ \ __< \ \ __\_ \ \ __\_
5
+ // \ \_____\ \ \_____\ \ \_____\
6
+ // \/_____/ \/_____/ \/_____/
7
+ //
8
+ // Copyright (c) 2012 BEE creators
9
+ // http://www.whatsbug.com
10
+ //
11
+ // Permission is hereby granted, free of charge, to any person obtaining a
12
+ // copy of this software and associated documentation files (the "Software"),
13
+ // to deal in the Software without restriction, including without limitation
14
+ // the rights to use, copy, modify, merge, publish, distribute, sublicense,
15
+ // and/or sell copies of the Software, and to permit persons to whom the
16
+ // Software is furnished to do so, subject to the following conditions:
17
+ //
18
+ // The above copyright notice and this permission notice shall be included in
19
+ // all copies or substantial portions of the Software.
20
+ //
21
+ // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22
+ // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23
+ // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24
+ // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25
+ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
26
+ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
27
+ // IN THE SOFTWARE.
28
+ //
29
+ //
30
+ // Bee_UIPullLoader.m
31
+ //
32
+
33
+ #if (TARGET_OS_IPHONE || TARGET_IPHONE_SIMULATOR)
34
+
35
+ #import "Bee_Precompile.h"
36
+ #import "Bee_UIPullLoader.h"
37
+ #import "Bee_UIActivityIndicatorView.h"
38
+ #import "Bee_UISignal.h"
39
+ #import "UIView+BeeExtension.h"
40
+ #import "UIView+BeeUISignal.h"
41
+
42
+ #pragma mark -
43
+
44
+ @interface BeeUIPullLoader(Private)
45
+ - (void)initSelf;
46
+ @end
47
+
48
+ @implementation BeeUIPullLoader
49
+
50
+ DEF_SIGNAL( STATE_CHANGED )
51
+
52
+ DEF_INT( STATE_NORMAL, 0 )
53
+ DEF_INT( STATE_PULLING, 1 )
54
+ DEF_INT( STATE_LOADING, 2 )
55
+
56
+ @synthesize state = _state;
57
+ @synthesize arrow = _arrow;
58
+ @synthesize indicator = _indicator;
59
+
60
+ @dynamic normal;
61
+ @dynamic pulling;
62
+ @dynamic loading;
63
+
64
+ + (BeeUIPullLoader *)spawn
65
+ {
66
+ return [[[BeeUIPullLoader alloc] init] autorelease];
67
+ }
68
+
69
+ + (BeeUIPullLoader *)spawn:(NSString *)tagString
70
+ {
71
+ BeeUIPullLoader * view = [[[BeeUIPullLoader alloc] init] autorelease];
72
+ view.tagString = tagString;
73
+ return view;
74
+ }
75
+
76
+ - (id)init
77
+ {
78
+ self = [super init];
79
+ if ( self )
80
+ {
81
+ [self initSelf];
82
+ }
83
+
84
+ return self;
85
+ }
86
+
87
+ - (id)initWithFrame:(CGRect)frame
88
+ {
89
+ self = [super initWithFrame:frame];
90
+ if ( self )
91
+ {
92
+ [self initSelf];
93
+ [self changeFrame:frame];
94
+ }
95
+
96
+ return self;
97
+ }
98
+
99
+ - (void)initSelf
100
+ {
101
+ self.backgroundColor = [UIColor clearColor];
102
+ self.autoresizingMask = UIViewAutoresizingFlexibleWidth;
103
+
104
+ _arrow = [[UIImageView alloc] initWithFrame:CGRectZero];
105
+ _arrow.contentMode = UIViewContentModeScaleAspectFit;
106
+ _arrow.backgroundColor = [UIColor clearColor];
107
+ _arrow.hidden = NO;
108
+ _arrow.image = [UIImage imageNamed:@"whiteArrow.png"];
109
+ [self addSubview:_arrow];
110
+
111
+ [_indicator release];
112
+ _indicator = [[BeeUIActivityIndicatorView alloc] initWithFrame:CGRectZero];
113
+ _indicator.hidden = YES;
114
+ _indicator.activityIndicatorViewStyle = UIActivityIndicatorViewStyleWhite;
115
+ [self addSubview:_indicator];
116
+
117
+ _state = BeeUIPullLoader.STATE_NORMAL;
118
+ }
119
+
120
+ - (void)changeFrame:(CGRect)frame
121
+ {
122
+ CGRect imageFrame;
123
+ imageFrame.size.width = frame.size.height * 0.5f;
124
+ imageFrame.size.height = frame.size.height * 0.5f;
125
+ imageFrame.origin.x = (frame.size.width - imageFrame.size.width) / 2.0f;
126
+ imageFrame.origin.y = (frame.size.height - imageFrame.size.height) / 2.0f;
127
+ _arrow.frame = imageFrame;
128
+
129
+ CGRect indicatorFrame;
130
+ indicatorFrame.size.width = 20.0f;
131
+ indicatorFrame.size.height = 20.0f;
132
+ indicatorFrame.origin.x = (frame.size.width - indicatorFrame.size.width) / 2.0f;
133
+ indicatorFrame.origin.y = (frame.size.height - indicatorFrame.size.height) / 2.0f;
134
+ _indicator.frame = indicatorFrame;
135
+ }
136
+
137
+ - (void)setFrame:(CGRect)frame
138
+ {
139
+ [super setFrame:frame];
140
+
141
+ [self changeFrame:frame];
142
+ }
143
+
144
+ - (void)dealloc
145
+ {
146
+ SAFE_RELEASE_SUBVIEW( _arrow );
147
+ SAFE_RELEASE_SUBVIEW( _indicator );
148
+
149
+ [super dealloc];
150
+ }
151
+
152
+ - (BOOL)normal
153
+ {
154
+ return (BeeUIPullLoader.STATE_NORMAL == _state) ? YES : NO;
155
+ }
156
+
157
+ - (void)setNormal:(BOOL)flag
158
+ {
159
+ if ( flag )
160
+ {
161
+ [self changeState:BeeUIPullLoader.STATE_NORMAL];
162
+ }
163
+ }
164
+
165
+ - (BOOL)pulling
166
+ {
167
+ return (BeeUIPullLoader.STATE_PULLING == _state) ? YES : NO;
168
+ }
169
+
170
+ - (void)setPulling:(BOOL)flag
171
+ {
172
+ if ( flag )
173
+ {
174
+ [self changeState:BeeUIPullLoader.STATE_PULLING];
175
+ }
176
+ }
177
+
178
+ - (BOOL)loading
179
+ {
180
+ return (BeeUIPullLoader.STATE_LOADING == _state) ? YES : NO;
181
+ }
182
+
183
+ - (void)setLoading:(BOOL)flag
184
+ {
185
+ if ( flag )
186
+ {
187
+ [self changeState:BeeUIPullLoader.STATE_LOADING];
188
+ }
189
+ }
190
+
191
+ - (void)changeState:(NSInteger)state
192
+ {
193
+ [self changeState:state animated:NO];
194
+ }
195
+
196
+ - (void)changeState:(NSInteger)state animated:(BOOL)animated
197
+ {
198
+ if ( _state == state )
199
+ return;
200
+
201
+ _state = state;
202
+
203
+ if ( BeeUIPullLoader.STATE_NORMAL == state )
204
+ {
205
+ [UIView beginAnimations:nil context:nil];
206
+ [UIView setAnimationDuration:0.3f];
207
+ _arrow.hidden = NO;
208
+ _arrow.transform = CGAffineTransformIdentity;
209
+ [UIView commitAnimations];
210
+
211
+ [_indicator stopAnimating];
212
+ }
213
+ else if ( BeeUIPullLoader.STATE_PULLING == state )
214
+ {
215
+ [UIView beginAnimations:nil context:nil];
216
+ [UIView setAnimationDuration:0.3f];
217
+ _arrow.hidden = NO;
218
+ _arrow.transform = CGAffineTransformRotate( CGAffineTransformIdentity, (M_PI / 360.0f) * -359.0f );
219
+ [UIView commitAnimations];
220
+ }
221
+ else if ( BeeUIPullLoader.STATE_LOADING == state )
222
+ {
223
+ [_indicator startAnimating];
224
+
225
+ [UIView beginAnimations:nil context:nil];
226
+ [UIView setAnimationDuration:0.3f];
227
+ _arrow.hidden = YES;
228
+ [UIView commitAnimations];
229
+ }
230
+
231
+ [self sendUISignal:BeeUIPullLoader.STATE_CHANGED];
232
+ }
233
+
234
+ @end
235
+
236
+ #endif // #if (TARGET_OS_IPHONE || TARGET_IPHONE_SIMULATOR)
@@ -0,0 +1,146 @@
1
+ //
2
+ // ______ ______ ______
3
+ // /\ __ \ /\ ___\ /\ ___\
4
+ // \ \ __< \ \ __\_ \ \ __\_
5
+ // \ \_____\ \ \_____\ \ \_____\
6
+ // \/_____/ \/_____/ \/_____/
7
+ //
8
+ // Copyright (c) 2012 BEE creators
9
+ // http://www.whatsbug.com
10
+ //
11
+ // Permission is hereby granted, free of charge, to any person obtaining a
12
+ // copy of this software and associated documentation files (the "Software"),
13
+ // to deal in the Software without restriction, including without limitation
14
+ // the rights to use, copy, modify, merge, publish, distribute, sublicense,
15
+ // and/or sell copies of the Software, and to permit persons to whom the
16
+ // Software is furnished to do so, subject to the following conditions:
17
+ //
18
+ // The above copyright notice and this permission notice shall be included in
19
+ // all copies or substantial portions of the Software.
20
+ //
21
+ // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22
+ // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23
+ // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24
+ // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25
+ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
26
+ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
27
+ // IN THE SOFTWARE.
28
+ //
29
+ //
30
+ // Bee_UITabBar.h
31
+ //
32
+
33
+ #if (TARGET_OS_IPHONE || TARGET_IPHONE_SIMULATOR)
34
+
35
+ #import "Bee_Precompile.h"
36
+ #import "Bee_UISignal.h"
37
+ #import "Bee_UIPullLoader.h"
38
+
39
+ #pragma mark -
40
+
41
+ #undef BEE_SCROLL_MAX_LINES
42
+ #define BEE_SCROLL_MAX_LINES (128)
43
+
44
+ #pragma mark -
45
+
46
+ @class BeeUIScrollView;
47
+
48
+ @protocol BeeUIScrollViewDataSource
49
+ - (NSInteger)numberOfLinesInScrollView:(BeeUIScrollView *)scrollView;
50
+ - (NSInteger)numberOfViewsInScrollView:(BeeUIScrollView *)scrollView;
51
+ - (UIView *)scrollView:(BeeUIScrollView *)scrollView viewForIndex:(NSInteger)index scale:(CGFloat)scale;
52
+ - (CGSize)scrollView:(BeeUIScrollView *)scrollView sizeForIndex:(NSInteger)index;
53
+ @end
54
+
55
+ @interface BeeUIScrollView : UIScrollView<BeeUIScrollViewDataSource, UIScrollViewDelegate>
56
+ {
57
+ id _dataSource;
58
+ NSInteger _direction;
59
+
60
+ NSInteger _visibleStart;
61
+ NSInteger _visibleEnd;
62
+
63
+ NSInteger _lineCount;
64
+ CGFloat _lineHeights[BEE_SCROLL_MAX_LINES];
65
+
66
+ NSInteger _total;
67
+ NSMutableArray * _items;
68
+
69
+ BOOL _shouldNotify;
70
+ BOOL _reloaded;
71
+ BOOL _reloading;
72
+ UIEdgeInsets _baseInsets;
73
+
74
+ BOOL _reachTop;
75
+ BOOL _reachEnd;
76
+ NSMutableArray * _reuseQueue;
77
+
78
+ CGPoint _scrollSpeed;
79
+ CGPoint _lastOffset;
80
+ NSTimeInterval _lastOffsetCapture;
81
+
82
+ BeeUIPullLoader * _headerLoader;
83
+ BeeUIPullLoader * _footerLoader;
84
+ }
85
+
86
+ AS_INT( DIRECTION_HORIZONTAL )
87
+ AS_INT( DIRECTION_VERTICAL )
88
+
89
+ @property (nonatomic, assign) id dataSource;
90
+ @property (nonatomic, assign) BOOL horizontal;
91
+ @property (nonatomic, assign) BOOL vertical;
92
+
93
+ @property (nonatomic, readonly) NSInteger visibleStart;
94
+ @property (nonatomic, readonly) NSInteger visibleEnd;
95
+
96
+ @property (nonatomic, readonly) NSRange visibleRange;
97
+ @property (nonatomic, readonly) NSUInteger visiblePageIndex;
98
+
99
+ @property (nonatomic, assign) BOOL reloaded;
100
+ @property (nonatomic, readonly) BOOL reloading;
101
+ @property (nonatomic, retain) NSMutableArray * reuseQueue;
102
+
103
+ @property (nonatomic, readonly) CGPoint scrollSpeed;
104
+ @property (nonatomic, readonly) CGFloat scrollPercent;
105
+ @property (nonatomic, readonly) CGFloat height;
106
+
107
+ @property (nonatomic, readonly) BeeUIPullLoader * headerLoader;
108
+ @property (nonatomic, readonly) BeeUIPullLoader * footerLoader;
109
+
110
+ AS_SIGNAL( RELOADED ) // 数据重新加载
111
+ AS_SIGNAL( REACH_TOP ) // 触顶
112
+ AS_SIGNAL( REACH_BOTTOM ) // 触底
113
+
114
+ AS_SIGNAL( DID_DRAG )
115
+ AS_SIGNAL( DID_STOP )
116
+ AS_SIGNAL( DID_SCROLL )
117
+
118
+ AS_SIGNAL( HEADER_REFRESH ) // 下拉刷新
119
+ AS_SIGNAL( FOOTER_REFRESH ) // 上拉刷新
120
+
121
+ + (BeeUIScrollView *)spawn;
122
+ + (BeeUIScrollView *)spawn:(NSString *)tagString;
123
+
124
+ - (id)dequeueWithContentClass:(Class)clazz;
125
+
126
+ - (void)scrollToFirstPage:(BOOL)animated;
127
+ - (void)scrollToLastPage:(BOOL)animated;
128
+ - (void)scrollToPrevPage:(BOOL)animated;
129
+ - (void)scrollToNextPage:(BOOL)animated;
130
+
131
+ - (void)setBaseInsets:(UIEdgeInsets)insets;
132
+ - (UIEdgeInsets)getBaseInsets;
133
+
134
+ - (void)reloadData;
135
+ - (void)syncReloadData;
136
+ - (void)asyncReloadData;
137
+ - (void)cancelReloadData;
138
+
139
+ - (void)showHeaderLoader:(BOOL)flag animated:(BOOL)animated;
140
+ - (void)showFooterLoader:(BOOL)flag animated:(BOOL)animated;
141
+ - (void)setHeaderLoading:(BOOL)en;
142
+ - (void)setFooterLoading:(BOOL)en;
143
+
144
+ @end
145
+
146
+ #endif // #if (TARGET_OS_IPHONE || TARGET_IPHONE_SIMULATOR)