Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-368

Supporting RegFree-COM in ActiveQt's container tools

    XMLWordPrintable

Details

    • Suggestion
    • Resolution: Unresolved
    • P3: Somewhat important
    • Some future release
    • None
    • ActiveX Support
    • None

    Description

      With Windows XP and Vista, RegFree-COM allows the usage of COM controls that are not registered on the system. This requires the inclusion of some XML in the application's manifest file, but makes it unnecessary to actually register the COM servers (in fact, the entries in the manifest will override any information in the Windows registry).

      The entries for the Windows Media Player, CLSID would be

      <?xml version="1.0" encoding="utf-8"?>
      <assembly xsi:schemaLocation="urn:schemas-microsoft-com:asm.v1
      assembly.adaptive.xsd" manifestVersion="1.0"
      xmlns:asmv1="urn:schemas-microsoft-com:asm.v1"
      xmlns:asmv2="urn:schemas-microsoft-com:asm.v2"
      xmlns:dsig="http://www.w3.org/2000/09/xmldsig#"
      xmlns="urn:schemas-microsoft-com:asm.v1"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

      <assemblyIdentity name="test.exe" version="1.0.0.0" type="win32" />
      <file name="wmp.dll">
      <typelib tlbid="

      {6BF52A50-394A-11d3-B153-00C04F79FAA6}" version="1.0" helpdir="" resourceid="0" flags="HASDISKIMAGE" />
      <comClass clsid="{6BF52A52-394A-11D3-B153-00C04F79FAA6}" threadingModel="Apartment" progid="WMPlayer.OCX.7" tlbid="{6BF52A50-394A-11d3-B153-00C04F79FAA6}

      " />
      </file>
      </assembly>

      There is no need for change in the code instantiating the COM objects, i.e. the following would work even without a registered media player as long as a test.exe.manifest is deployed together with test.exe:

      QAxWidget *w = new QAxWidget("WMPlayer.OCX.7"); //

      {6BF52A52-394A-11D3-B153-00C04F79FAA6}

      w->setProperty("URL", "c:\\windows
      clock.avi");
      w->show();

      It would be nice if the QAxContainer tools (i.e. testcon and the Designer integration, or dumpcpp) could generate the respective XML for any COM server. The server would have to be registered on the development machine of course.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            sorvig Morten Sørvig
            vhilshei Volker Hilsheimer
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes