<div>Hi Jacek:</div><div>I found that mshtml will not fire BeforeNavigate event<span style="line-height: 1.5;"> </span><span style="line-height: 1.5;">if the app: protocol hyper link is in a frame window,</span></div><div><span style="line-height: 1.5;">like this page </span><span style="line-height: 1.5;">http://www.imakevideo.com/app2.html </span></div><div><span style="line-height: 1.5;">I attached a patch solved this situation, do you think is it right?</span></div><div>The test app is here: <a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://www.imakevideo.com/mfc_web.zip" style="line-height: 1.5;">http://www.imakevideo.com/mfc_web.zip</a></div><div><br></div><div>Thank you.</div><div><br></div><div><sign signid="0"><div style="color:#909090;font-family:Arial Narrow;font-size:12px"><br><br>------------------</div><div style="font-size:14px;font-family:Verdana;color:#000;"><div>Regards,</div><div>Changhui.</div>
</div></sign></div><div> </div><div><includetail><div> </div><div> </div><div style="font:Verdana normal 14px;color:#000;"><div style="FONT-SIZE: 12px;FONT-FAMILY: Arial Narrow;padding:2px 0 2px 0;">------------------ Original ------------------</div><div style="FONT-SIZE: 12px;background:#efefef;padding:8px;"><div id="menu_sender"><b>From: </b> "Jacek Caban"<jacek@codeweavers.com>;</div><div><b>Date: </b> Fri, Jan 30, 2015 08:24 PM</div><div><b>To: </b> "Changhui Liu"<liuchanghui@linuxdeepin.com>; "wine-devel"<wine-devel@winehq.org>; <wbr></div><div></div><div><b>Subject: </b> Re: ieframe:add app: protocol support to make mshtml triggerBeforeNavigate2event when handle app: hyperlink</div></div><div> </div>
  
    
  
  
    <div class="moz-cite-prefix">Hi Changhui,<br>
      <br>
      No, there is no such thing as app protocol handler on Windows and
      we shouldn't have one. This means that loading will (correctly)
      fail for this protocol, but BeforeNavigate2 should happen before
      it has a chance to fail. To support that, we have our own onclick
      handler for anchor elements, where we initiate loading. See
      HTMLAnchorElement_handle_event in htmlanchor.c.<br>
      <br>
      I tried your test app and it works find for me with recent Wine.
      Are you testing it against current Git?<br>
      <br>
      Jacek<br>
      <br>
      On 01/30/15 09:53, Changhui Liu wrote:<br>
    </div>
    <blockquote cite="mid:tencent_43736252551BA93915E9C0F2@qq.com" type="cite">
      <div>Hi Jacek:</div>
      <div>I found that the real reason is urlmon!get_protocol_cf return
        MK_E_SYNTAX(0x800401e4<span style="line-height: 1.5;">) </span><span style="line-height: 1.5;">when it open this registry key </span><span style="line-height: 1.5;">“HKEY_CLASSES_ROOT\PROTOCOLS\Handler\</span><span style="line-height: 1.5;">app” failed.</span></div>
      <div>Do you think the right way is implement a new 'app:' protocol
        handle like "<span style="line-height: 1.5;">HKEY_CLASSES_ROOT\PROTOCOLS\Handler\</span><span style="line-height: 1.5;">http"?</span></div>
      <div><br>
      </div>
      <div>Thank you!</div>
      <div>
          <div style="color:#909090;font-family:Arial
            Narrow;font-size:12px"><br>
            <br>
            <br>
            <br>
            ------------------</div>
          <div style="font-size:14px;font-family:Verdana;color:#000;">
            <div>Regards,</div>
            <div>Changhui.</div>
          </div>
        </div>
      <div> </div>
      <div>
          <div> </div>
          <div> </div>
          <div style="font:Verdana normal 14px;color:#000;">
            <div style="FONT-SIZE: 12px;FONT-FAMILY: Arial
              Narrow;padding:2px 0 2px 0;">------------------ Original ------------------</div>
            <div style="FONT-SIZE: 12px;background:#efefef;padding:8px;">
              <div id="menu_sender"><b>From: </b> "Jacek
                Caban"<a class="moz-txt-link-rfc2396E" href="mailto:jacek@codeweavers.com"><jacek@codeweavers.com></a>;</div>
              <div><b>Date: </b> Thu, Jan 15, 2015 05:55 PM</div>
              <div><b>To: </b> "wine-devel"<a class="moz-txt-link-rfc2396E" href="mailto:wine-devel@winehq.org"><wine-devel@winehq.org></a>;
                <wbr></div>
              <div><b>Subject: </b> Re: ieframe:add app: protocol
                support to make mshtml triggerBeforeNavigate2 event when
                handle app: hyperlink</div>
            </div>
            <div> </div>
            <div class="moz-cite-prefix">Hi Changhui,<br>
              <br>
              On 01/15/15 02:39, Changhui Liu wrote:<br>
            </div>
            <blockquote cite="mid:tencent_361F1D250B0D4A5D74CF8031@qq.com" type="cite">
              <div>Hi, this verify test need the user click the app:
                hyperlink in browser, </div>
              <div>so it is hard to write a test in dlls/ieframe/tests.</div>
              <div><br>
              </div>
              <div>I upload the test html file and a test exe here:</div>
              <div><a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://www.imakevideo.com/app.html">http://www.imakevideo.com/app.html</a></div>
              <div><a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://www.imakevideo.com/mfc_web.zip">http://www.imakevideo.com/mfc_web.zip</a></div>
              <div><br>
              </div>
              <div>To run the test, extract mfc_web.zip, then run the
                mfc_web.exe, <span style="line-height: 1.5;">click the
                  Go button;</span></div>
              <div>A message "BeforeNavigate2 <a moz-do-not-send="true" class="moz-txt-link-freetext">app:xxx</a>" will popup
                when click the app: <span style="line-height: 1.5;">hyperlink</span><span style="line-height: 1.5;"> </span></div>
              <div><span style="line-height: 1.5;">if
                  the BeforeNavigate2 event was triggered as like IE in
                  windows, or nothing.</span></div>
            </blockquote>
            <br>
            It doesn't seem right. There is nothing special about app:
            protocol handling, BeforeNavigate2 should be called in this
            case the same way as for any other protocol. You need to
            find the real reason why it's not called instead of calling
            it in an error case. The bug is likely to be in mshtml.<br>
            <br>
            Jacek<br>
          </div>
          </div>
    </blockquote>
    <br>
  


</div><!--<![endif]--></includetail></div>