Changeset 6382 in vbox for trunk/src/VBox/Main/SharedFolderImpl.cpp
- Timestamp:
- Jan 18, 2008 5:37:39 PM (17 years ago)
- svn:sync-xref-src-repo-rev:
- 27325
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/SharedFolderImpl.cpp
r6379 r6382 58 58 * @param aName logical name of the shared folder 59 59 * @param aHostPath full path to the shared folder on the host 60 * @param aWritable writable if true, readonly otherwise61 60 * 62 61 * @return COM result indicator 63 62 */ 64 63 HRESULT SharedFolder::init (Machine *aMachine, 65 const BSTR aName, const BSTR aHostPath , bool aWritable)64 const BSTR aName, const BSTR aHostPath) 66 65 { 67 66 /* Enclose the state transition NotReady->InInit->Ready */ … … 71 70 unconst (mMachine) = aMachine; 72 71 73 HRESULT rc = protectedInit (aMachine, aName, aHostPath , aWritable);72 HRESULT rc = protectedInit (aMachine, aName, aHostPath); 74 73 75 74 /* Confirm a successful initialization when it's the case */ … … 101 100 102 101 HRESULT rc = protectedInit (aMachine, aThat->mData.mName, 103 aThat->mData.mHostPath , aThat->mData.mWritable);102 aThat->mData.mHostPath); 104 103 105 104 /* Confirm a successful initialization when it's the case */ … … 116 115 * @param aName logical name of the shared folder 117 116 * @param aHostPath full path to the shared folder on the host 118 * @param aWritable writable if true, readonly otherwise119 117 * 120 118 * @return COM result indicator 121 119 */ 122 120 HRESULT SharedFolder::init (Console *aConsole, 123 const BSTR aName, const BSTR aHostPath , bool aWritable)121 const BSTR aName, const BSTR aHostPath) 124 122 { 125 123 /* Enclose the state transition NotReady->InInit->Ready */ … … 129 127 unconst (mConsole) = aConsole; 130 128 131 HRESULT rc = protectedInit (aConsole, aName, aHostPath , aWritable);129 HRESULT rc = protectedInit (aConsole, aName, aHostPath); 132 130 133 131 /* Confirm a successful initialization when it's the case */ … … 144 142 * @param aName logical name of the shared folder 145 143 * @param aHostPath full path to the shared folder on the host 146 * @param aWritable writable if true, readonly otherwise147 144 * 148 145 * @return COM result indicator 149 146 */ 150 147 HRESULT SharedFolder::init (VirtualBox *aVirtualBox, 151 const BSTR aName, const BSTR aHostPath , bool aWritable)148 const BSTR aName, const BSTR aHostPath) 152 149 { 153 150 /* Enclose the state transition NotReady->InInit->Ready */ … … 157 154 unconst (mVirtualBox) = aVirtualBox; 158 155 159 HRESULT rc = protectedInit (aVirtualBox, aName, aHostPath , aWritable);156 HRESULT rc = protectedInit (aVirtualBox, aName, aHostPath); 160 157 161 158 /* Confirm a successful initialization when it's the case */ … … 173 170 */ 174 171 HRESULT SharedFolder::protectedInit (VirtualBoxBaseWithChildrenNEXT *aParent, 175 const BSTR aName, const BSTR aHostPath, bool aWritable) 176 { 177 LogFlowThisFunc (("aName={%ls}, aHostPath={%ls}, aWritable={%d}\n", 178 aName, aHostPath, aWritable)); 172 const BSTR aName, const BSTR aHostPath) 173 { 174 LogFlowThisFunc (("aName={%ls}, aHostPath={%ls}\n", aName, aHostPath)); 179 175 180 176 ComAssertRet (aParent && aName && aHostPath, E_INVALIDARG); … … 220 216 unconst (mData.mName) = aName; 221 217 unconst (mData.mHostPath) = hostPath; 222 mData.mWritable = aWritable;223 218 224 219 return S_OK; … … 312 307 } 313 308 314 STDMETHODIMP SharedFolder::COMGETTER(Writable) (BOOL *aWritable)315 {316 if (!aWritable)317 return E_POINTER;318 319 *aWritable = mData.mWritable;320 321 return S_OK;322 }
Note:
See TracChangeset
for help on using the changeset viewer.