summaryrefslogtreecommitdiff
path: root/indra/newview/llpreviewnotecard.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llpreviewnotecard.cpp')
-rw-r--r--indra/newview/llpreviewnotecard.cpp16
1 files changed, 7 insertions, 9 deletions
diff --git a/indra/newview/llpreviewnotecard.cpp b/indra/newview/llpreviewnotecard.cpp
index 59be35fe92..230def5362 100644
--- a/indra/newview/llpreviewnotecard.cpp
+++ b/indra/newview/llpreviewnotecard.cpp
@@ -46,7 +46,7 @@
#include "llselectmgr.h"
#include "lltrans.h"
#include "llviewertexteditor.h"
-#include "llvfile.h"
+#include "llfilesystem.h"
#include "llviewerinventory.h"
#include "llviewerobject.h"
#include "llviewerobjectlist.h"
@@ -352,8 +352,7 @@ void LLPreviewNotecard::loadAsset()
}
// static
-void LLPreviewNotecard::onLoadComplete(LLVFS *vfs,
- const LLUUID& asset_uuid,
+void LLPreviewNotecard::onLoadComplete(const LLUUID& asset_uuid,
LLAssetType::EType type,
void* user_data, S32 status, LLExtStat ext_status)
{
@@ -364,7 +363,7 @@ void LLPreviewNotecard::onLoadComplete(LLVFS *vfs,
{
if(0 == status)
{
- LLVFile file(vfs, asset_uuid, type, LLVFile::READ);
+ LLFileSystem file(asset_uuid, type, LLFileSystem::READ);
S32 file_length = file.getSize();
@@ -471,7 +470,7 @@ void LLPreviewNotecard::finishInventoryUpload(LLUUID itemId, LLUUID newAssetId,
LLPreviewNotecard* nc = LLFloaterReg::findTypedInstance<LLPreviewNotecard>("preview_notecard", LLSD(itemId));
if (nc)
{
- // *HACK: we have to delete the asset in the VFS so
+ // *HACK: we have to delete the asset in the cache so
// that the viewer will redownload it. This is only
// really necessary if the asset had to be modified by
// the uploader, so this can be optimized away in some
@@ -479,7 +478,7 @@ void LLPreviewNotecard::finishInventoryUpload(LLUUID itemId, LLUUID newAssetId,
// script actually changed the asset.
if (nc->hasEmbeddedInventory())
{
- gVFS->removeFile(newAssetId, LLAssetType::AT_NOTECARD);
+ LLFileSystem::removeFile(newAssetId, LLAssetType::AT_NOTECARD);
}
if (newItemId.isNull())
{
@@ -504,7 +503,7 @@ void LLPreviewNotecard::finishTaskUpload(LLUUID itemId, LLUUID newAssetId, LLUUI
{
if (nc->hasEmbeddedInventory())
{
- gVFS->removeFile(newAssetId, LLAssetType::AT_NOTECARD);
+ LLFileSystem::removeFile(newAssetId, LLAssetType::AT_NOTECARD);
}
nc->setAssetId(newAssetId);
nc->refreshFromInventory();
@@ -583,14 +582,13 @@ bool LLPreviewNotecard::saveIfNeeded(LLInventoryItem* copyitem, bool sync)
tid.generate();
asset_id = tid.makeAssetID(gAgent.getSecureSessionID());
- LLVFile file(gVFS, asset_id, LLAssetType::AT_NOTECARD, LLVFile::APPEND);
+ LLFileSystem file(asset_id, LLAssetType::AT_NOTECARD, LLFileSystem::APPEND);
LLSaveNotecardInfo* info = new LLSaveNotecardInfo(this, mItemUUID, mObjectUUID,
tid, copyitem);
S32 size = buffer.length() + 1;
- file.setMaxSize(size);
file.write((U8*)buffer.c_str(), size);
gAssetStorage->storeAssetData(tid, LLAssetType::AT_NOTECARD,