Changeset 71537 in vbox
- Timestamp:
- Mar 28, 2018 12:44:40 PM (7 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src/runtime/guestctrl
- Files:
-
- 2 edited
-
UIGuestFileTable.cpp (modified) (1 diff)
-
UIHostFileTable.cpp (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/runtime/guestctrl/UIGuestFileTable.cpp
r71509 r71537 246 246 QString destinationFilePath = UIPathOperations::mergePaths(guestDestinationPath, UIPathOperations::getObjectName(hostSourcePath)); 247 247 /** @todo listen to CProgress object to monitor copy operation: */ 248 /*CProgress comProgress =*/ m_comGuestSession.FileCopy FromGuest(hostSourcePath, destinationFilePath, flags);248 /*CProgress comProgress =*/ m_comGuestSession.FileCopyToGuest(hostSourcePath, destinationFilePath, flags); 249 249 } 250 250 else if(hostFileInfo.isDir()) 251 251 { 252 QVector<KDirectoryCopyFlag> aFlags(KDirectoryCopyFlag_ CopyIntoExisting);252 QVector<KDirectoryCopyFlag> aFlags(KDirectoryCopyFlag_None/*CopyIntoExisting*/); 253 253 /** @todo listen to CProgress object to monitor copy operation: */ 254 254 /*CProgress comProgress = */ m_comGuestSession.DirectoryCopyToGuest(hostSourcePath, guestDestinationPath, aFlags); -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/guestctrl/UIHostFileTable.cpp
r71531 r71537 335 335 return propertyString; 336 336 } 337 else 338 { 339 int fileCount = 0; 340 int directoryCount = 0; 341 ULONG64 totalSize = 0; 342 343 for(int i = 0; i < selectedObjects.size(); ++i) 344 { 345 QFileInfo fileInfo(selectedObjects.at(i)); 346 if (!fileInfo.exists()) 347 continue; 348 if (fileInfo.isFile()) 349 ++fileCount; 350 if (fileInfo.isDir()) 351 ++directoryCount; 352 totalSize += fileInfo.size(); 353 } 354 QString propertyString; 355 propertyString += "<b>Selected:</b> " + QString::number(fileCount) + " files "; 356 propertyString += "and " + QString::number(directoryCount) + " directories"; 357 propertyString += "<br/>"; 358 propertyString += "<b>Size:</b> " + QString::number(totalSize) + QString(" bytes"); 359 if (totalSize >= m_iKiloByte) 360 propertyString += " (" + humanReadableSize(totalSize) + ")"; 361 362 363 return propertyString; 364 } 365 return QString(); 337 338 int fileCount = 0; 339 int directoryCount = 0; 340 ULONG64 totalSize = 0; 341 342 for(int i = 0; i < selectedObjects.size(); ++i) 343 { 344 QFileInfo fileInfo(selectedObjects.at(i)); 345 if (!fileInfo.exists()) 346 continue; 347 if (fileInfo.isFile()) 348 ++fileCount; 349 if (fileInfo.isDir()) 350 ++directoryCount; 351 totalSize += fileInfo.size(); 352 } 353 QString propertyString; 354 propertyString += "<b>Selected:</b> " + QString::number(fileCount) + " files "; 355 propertyString += "and " + QString::number(directoryCount) + " directories"; 356 propertyString += "<br/>"; 357 propertyString += "<b>Size:</b> " + QString::number(totalSize) + QString(" bytes"); 358 if (totalSize >= m_iKiloByte) 359 propertyString += " (" + humanReadableSize(totalSize) + ")"; 360 361 return propertyString; 366 362 } 367 363
Note:
See TracChangeset
for help on using the changeset viewer.

