From a408bac29378072fbf36864164149458c978cfcc Mon Sep 17 00:00:00 2001 From: Jacek Antonelli Date: Fri, 15 Aug 2008 23:44:59 -0500 Subject: Second Life viewer sources 1.17.1.0 --- linden/indra/newview/llviewermenufile.cpp | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'linden/indra/newview/llviewermenufile.cpp') diff --git a/linden/indra/newview/llviewermenufile.cpp b/linden/indra/newview/llviewermenufile.cpp index 6954b1c..19dfebe 100644 --- a/linden/indra/newview/llviewermenufile.cpp +++ b/linden/indra/newview/llviewermenufile.cpp @@ -561,6 +561,21 @@ void upload_new_resource(const LLString& src_filename, std::string name, return; } } + else if( LLString::compareInsensitive(ext.c_str(),".png") == 0 ) + { + asset_type = LLAssetType::AT_TEXTURE; + if (!LLViewerImageList::createUploadFile(src_filename, + filename, + IMG_CODEC_PNG )) + { + sprintf(error_message, "Problem with file %s:\n\n%s\n", + src_filename.c_str(), LLImageBase::getLastError().c_str()); + args["[FILE]"] = src_filename; + args["[ERROR]"] = LLImageBase::getLastError(); + upload_error(error_message, "ProblemWithFile", filename, args); + return; + } + } else if(LLString::compareInsensitive(ext.c_str(),".wav") == 0) { asset_type = LLAssetType::AT_SOUND; // tag it as audio -- cgit v1.1