EXT core API-Ext. Fly

Source: Internet
Author: User

Syntax: Fly (string/htmlelement El, [String named]): Element

Note:

  •  

    • Get a global shared floating element El. If there are multiple floating elements, you can use the name to avoid potential conflicts.
    • Some people ask what are the advantages of this? The advantage is big. If there are 1000 elements, you need to call their hide to hide them. If Ext. get will create 1000 element objects. If fly is used, only one object will be created. This greatly improves the performance. Therefore, it is better to use fly for batch operations.
    • What should I first understand about fly?Flyweight (meta Mode)

Example:

  • VaR CLS = ext. Fly ("input_id"). getattributens ('ext ', 'cls ');
  • This. rowheight = ext. Fly (this. View. getnode (0). getheight ();

This function is very useful.

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.