Fixed the bug that artdialog would automatically close when double-clicking the mask layer .... Do it yourself ....

Source: Internet
Author: User

From: http://vb2005xu.iteye.com/blog/1540082

When I used it today, I found that double-click the mask layer will automatically close it. The version I used is 5.0, which should be the latest version ........

 

The reason is that a double-click event is bound to the mask layer to close the event... helpless... but this feature is not useless ....

 

Here I made the following enhancement: add the dblclick_hide item to the configuration parameters, for example:

JS Code
  1. VaR frm_user_art = art. Dialog ({
  2. Title: 'modify user information ',
  3. Width: "360px ",
  4. ESC: false, lock: True, dblclick_hide: false,
  5. Content: $ ('# K-Info-show'). Get (0 ),
  6. Beforeunload: function (){
  7. $ ('# K-Info-show'). Hide (). Empty ();
  8. Window. art_frm_user_update = NULL;
  9. }
  10. }). Lock ();

 

If this parameter is set to false, double-click the mask layer and choose not to close it. Otherwise, the mask layer is disabled. The default value is false.

 

Changed the source file artdialog. js.

 

JS Code
  1. $ Div. BIND ('click', function (){
  2. That. _ reset ();
  3. }). BIND ('dblclick', function (){
  4. If (config. dblclick_hide ){
  5. That. _ click ('cancel ');
  6. }
  7. });

 

You can search for it by yourself. Find this location and change the code to this location. In fact, the line if (config. dblclick_hide) is added for judgment.

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.