Page 2 of 2 FirstFirst 12
Results 11 to 12 of 12

Thread: closing a window with htmleditor throws permission denied error in IE

    Thank you for reporting this bug. We will make it our priority to review this report.
  1. #11
    Sencha User
    Join Date
    Aug 2014
    Posts
    7

    Default Bug accepted

    I had reported it using our company's premium support and Sencha has filed it in their bug tracking system under the ID -EXJS-15714


  2. #12
    Sencha User razvanioan's Avatar
    Join Date
    Feb 2008
    Location
    Romania
    Posts
    140

    Default

    I've just overridden Ext.isGarbage() method in order to wrap it in a try & catch scheme like this:

    Code:
    Ext.require('Ext.dom.Element', function () {
      Ext.isGarbage = function(dom) {
        var result = false;
    
        // try to catch error when is trying to access an iframe which although it's from the same domain is still raises permission errors
        try {
          // determines if the dom element is in the document or in the detached body element
          // use by collectGarbage and Ext.get()
          result = dom &&
            // window, document, documentElement, and body can never be garbage.
            dom.nodeType === 1 && dom.tagName !== 'BODY' && dom.tagName !== 'HTML' &&
            // if the element does not have a parent node, it is definitely not in the
            // DOM - we can exit immediately
            (!dom.parentNode ||
            // If the element has an offset parent we can bail right away, it is
            // definitely in the DOM.
            (!dom.offsetParent &&
            // if the element does not have an offsetParent it can mean the element is
            // either not in the dom or it is hidden.  The next step is to check to see
            // if it can be found by id using either document.all or getElementById(),
            // whichever is faster for the current browser.  Normally we would not
            // include IE-specific checks in the sencha-core package, however,  in this
            // case the function will be inlined and therefore cannot be overridden in
            // the ext package.
              ((Ext.isIE8 ? document.all[dom.id] : document.getElementById(dom.id)) !== dom) &&
              // finally if the element was not found in the dom by id, we need to check
              // the detachedBody element
              !(Ext.detachedBodyEl && Ext.detachedBodyEl.isAncestor(dom))));
        } catch (error) {}
    
        return result;
      };
    })
    Last edited by razvanioan; 16 Mar 2019 at 12:31 AM. Reason: working override
    ---
    Razvan Ioan ANASTASESCU
    Senior WEB Developer

Page 2 of 2 FirstFirst 12

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •