10 notes and Demo of Open Class Stanford iOS7, Stanford ios7

Source: Internet
Author: User

10 notes and Demo of Open Class Stanford iOS7, Stanford ios7

This section describes the serial queue in multiple threads and the scroll view UIScrollView.

I. Multithreading

This section briefly introduces the multi-threaded serial queue, that is, the task is added to the thread queue and then executed in sequence.

(1) Currently, iOS multithreading provides GCD and NSOperation methods. The former is at the C language level, and the latter is encapsulated and more object-oriented APIs.

(2) UI interaction operations are performed in the main thread. To ensure the comfortable interaction process, time-consuming operations such as downloading must be performed outside the main thread, otherwise, users cannot perform operations on their mobile phones.

In this case, multiple threads can be used to separate time-consuming operations such as image downloading. After the operation is completed, the main thread is called back and the UI interface is refreshed to make the interaction process smoother. For details, see DEMO.

Ii. UIScrollView

Note that contentSize is set. This is the content displayed in the scroll view. You can think of it as a canvas. The mobile phone moves on the canvas and the canvas content is displayed on the screen, you can also zoom in and out the canvas content.

Note that the "viewForZoomingInScrollView" proxy method is used to set the maximum and minimum scaling values. Otherwise, the UIScrollView scaling operation cannot be responded.

3. Use the built-in wait circle effect on iOS to make the interaction process more reasonable.

You can use the built-in UI control UIActivityIndicatorView. Check enable animation effects and hide the two effects after stopping the animation. After the download starts, rotate the animation and wait for the animation to start. After the task is completed, the animation stops and the control is hidden.

In addition, it is recommended that you set controls in the document view, especially when there are many UI controls, which is not only convenient, but you can also see the yellow exclamation point after using the Automatic Layout effect, so that you can easily select the appropriate automatic correction operation.

Http://files.cnblogs.com/colinhou/Imaginarium.zip)


How to restore the firmware when the iphone enters recovery mode

Download the ios5.1.1 firmware online. Then select shift + restore in itunes.
Maybe you have not recovered the data line.


Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.