Changeset 39661 in vbox
- Timestamp:
- Dec 20, 2011 1:35:17 PM (13 years ago)
- Location:
- trunk/src/VBox/Main
- Files:
-
- 4 edited
-
idl/VirtualBox.xidl (modified) (2 diffs)
-
include/ExtPackManagerImpl.h (modified) (2 diffs)
-
include/ExtPackUtil.h (modified) (1 diff)
-
src-all/ExtPackManagerImpl.cpp (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/idl/VirtualBox.xidl
r39650 r39661 15987 15987 <interface 15988 15988 name="IExtPackBase" extends="$unknown" 15989 uuid=" 5ffb0b64-0ad6-467d-af62-1157e7dc3c99"15989 uuid="f79b75d8-2890-4f34-ffff-ffffa144e82c" 15990 15990 wsmap="suppress" 15991 15991 > … … 16002 16002 <attribute name="version" type="wstring" readonly="yes"> 16003 16003 <desc> 16004 The extension pack version string. This is on the same form as16005 other VirtualBox version strings, i.e.: "1.2.3", "1.2.3_BETA1", 16006 "1.2.3-OSE", "1.2.3r45678", "1.2.3r45678-OSE", "1.2.3_BETA1-r45678" 16007 or "1.2.3_BETA1-r45678-OSE" 16004 The extension pack version string. This is restricted to the dotted 16005 version number and a build indicator. No tree revision or tag will be 16006 included in the string as those things are available as separate 16007 properties. Examples: "1.2.3", "1.2.3_BETA1" and "1.2.3_RC2". 16008 16008 </desc> 16009 16009 </attribute> 16010 16010 <attribute name="revision" type="unsigned long" readonly="yes"> 16011 16011 <desc>The extension pack internal revision number.</desc> 16012 </attribute> 16013 <attribute name="edition" type="wstring" readonly="yes"> 16014 <desc> 16015 Edition indicator. This is usually empty. 16016 16017 Can for instance be used to help distinguishing between two editions 16018 of the same extension pack where only the license, service contract or 16019 something differs. 16020 </desc> 16012 16021 </attribute> 16013 16022 <attribute name="VRDEModule" type="wstring" readonly="yes"> -
trunk/src/VBox/Main/include/ExtPackManagerImpl.h
r37843 r39661 55 55 STDMETHOD(COMGETTER(Version))(BSTR *a_pbstrVersion); 56 56 STDMETHOD(COMGETTER(Revision))(ULONG *a_puRevision); 57 STDMETHOD(COMGETTER(Edition))(BSTR *a_pbstrEdition); 57 58 STDMETHOD(COMGETTER(VRDEModule))(BSTR *a_pbstrVrdeModule); 58 59 STDMETHOD(COMGETTER(PlugIns))(ComSafeArrayOut(IExtPackPlugIn *, a_paPlugIns)); … … 118 119 STDMETHOD(COMGETTER(Version))(BSTR *a_pbstrVersion); 119 120 STDMETHOD(COMGETTER(Revision))(ULONG *a_puRevision); 121 STDMETHOD(COMGETTER(Edition))(BSTR *a_pbstrEdition); 120 122 STDMETHOD(COMGETTER(VRDEModule))(BSTR *a_pbstrVrdeModule); 121 123 STDMETHOD(COMGETTER(PlugIns))(ComSafeArrayOut(IExtPackPlugIn *, a_paPlugIns)); -
trunk/src/VBox/Main/include/ExtPackUtil.h
r39180 r39661 113 113 114 114 void VBoxExtPackInitDesc(PVBOXEXTPACKDESC a_pExtPackDesc); 115 RTCString *VBoxExtPackLoadDesc(const char *a_pszDir, PVBOXEXTPACKDESC a_pExtPackDesc, PRTFSOBJINFO a_pObjInfo);116 RTCString *VBoxExtPackLoadDescFromVfsFile(RTVFSFILE hVfsFile, PVBOXEXTPACKDESC a_pExtPackDesc, PRTFSOBJINFO a_pObjInfo);117 RTCString *VBoxExtPackExtractNameFromTarballPath(const char *pszTarball);115 RTCString *VBoxExtPackLoadDesc(const char *a_pszDir, PVBOXEXTPACKDESC a_pExtPackDesc, PRTFSOBJINFO a_pObjInfo); 116 RTCString *VBoxExtPackLoadDescFromVfsFile(RTVFSFILE hVfsFile, PVBOXEXTPACKDESC a_pExtPackDesc, PRTFSOBJINFO a_pObjInfo); 117 RTCString *VBoxExtPackExtractNameFromTarballPath(const char *pszTarball); 118 118 void VBoxExtPackFreeDesc(PVBOXEXTPACKDESC a_pExtPackDesc); 119 119 bool VBoxExtPackIsValidName(const char *pszName); 120 120 bool VBoxExtPackIsValidMangledName(const char *pszMangledName, size_t cchMax = RTSTR_MAX); 121 RTCString *VBoxExtPackMangleName(const char *pszName);122 RTCString *VBoxExtPackUnmangleName(const char *pszMangledName, size_t cbMax);121 RTCString *VBoxExtPackMangleName(const char *pszName); 122 RTCString *VBoxExtPackUnmangleName(const char *pszMangledName, size_t cbMax); 123 123 int VBoxExtPackCalcDir(char *pszExtPackDir, size_t cbExtPackDir, const char *pszParentDir, const char *pszName); 124 124 bool VBoxExtPackIsValidVersionString(const char *pszVersion); -
trunk/src/VBox/Main/src-all/ExtPackManagerImpl.cpp
r39180 r39661 390 390 if (SUCCEEDED(hrc)) 391 391 { 392 /* HACK ALERT: This is for easing backporting to 4.1. The edition stuff393 will be changed into a separate */394 if (m->Desc.strEdition.isEmpty())395 {396 Bstr str(m->Desc.strVersion); 397 str.cloneTo(a_pbstrVersion); 398 } 399 else 400 {401 RTCString strHack(m->Desc.strVersion); 402 strHack.append('-');403 strHack.append(m->Desc.strEdition);404 405 Bstr str(strHack);406 str.cloneTo(a_pbstrVersion);407 }392 Bstr str(m->Desc.strVersion); 393 str.cloneTo(a_pbstrVersion); 394 } 395 return hrc; 396 } 397 398 STDMETHODIMP ExtPackFile::COMGETTER(Edition)(BSTR *a_pbstrEdition) 399 { 400 CheckComArgOutPointerValid(a_pbstrEdition); 401 402 AutoCaller autoCaller(this); 403 HRESULT hrc = autoCaller.rc(); 404 if (SUCCEEDED(hrc)) 405 { 406 Bstr str(m->Desc.strEdition); 407 str.cloneTo(a_pbstrEdition); 408 408 } 409 409 return hrc; … … 1624 1624 if (SUCCEEDED(hrc)) 1625 1625 { 1626 /* HACK ALERT: This is for easing backporting to 4.1. The edition stuff 1627 will be changed into a separate */ 1628 if (m->Desc.strEdition.isEmpty()) 1629 { 1630 Bstr str(m->Desc.strVersion); 1631 str.cloneTo(a_pbstrVersion); 1632 } 1633 else 1634 { 1635 RTCString strHack(m->Desc.strVersion); 1636 strHack.append('-'); 1637 strHack.append(m->Desc.strEdition); 1638 1639 Bstr str(strHack); 1640 str.cloneTo(a_pbstrVersion); 1641 } 1626 Bstr str(m->Desc.strVersion); 1627 str.cloneTo(a_pbstrVersion); 1642 1628 } 1643 1629 return hrc; … … 1652 1638 if (SUCCEEDED(hrc)) 1653 1639 *a_puRevision = m->Desc.uRevision; 1640 return hrc; 1641 } 1642 1643 STDMETHODIMP ExtPack::COMGETTER(Edition)(BSTR *a_pbstrEdition) 1644 { 1645 CheckComArgOutPointerValid(a_pbstrEdition); 1646 1647 AutoCaller autoCaller(this); 1648 HRESULT hrc = autoCaller.rc(); 1649 if (SUCCEEDED(hrc)) 1650 { 1651 Bstr str(m->Desc.strEdition); 1652 str.cloneTo(a_pbstrEdition); 1653 } 1654 1654 return hrc; 1655 1655 }
Note:
See TracChangeset
for help on using the changeset viewer.

