How to adjust the position of the Imgage component in the flex mxml View

Source: Internet
Author: User
Override public function invalidateProperties (): void {super. invalidateProperties (); setImage ();} private function setImage (): void {if (image) {try {var cls: Class = getDefinitionByName ("zorn. external. externalCall ") as Class; image. source = ".. /resources/districticons/"+ districtId + ". png ");} catch (e: Error) {var cls: Class = getDefinitionByName (" com. util. resourceURL ") as Class; var ret: String = cls [" create "] (" districticons/"+ districtId + ". png "); image. source = ret ;}}}

Recently, the project encountered such a requirement that the Image component should be used to load external images. The length and width of these external images are different. How can we adjust the x and y of these images, to make these images fit, you can think of a way to run the entire project and open the panel where these mage components are located, then, record how to adjust the x and y attributes of each Image in the book. If not, re-run the entire project and run it again.

There is no error in this method, that is, low productivity. A better method is to use the above Code.

Here, we will explain that 'zorn. external. externalcall' cannot find this package path in our entire project file. Our frontend leader found this string through decompilation.

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.