Sync with viewer-beta
commit
b2e4486cf2
|
|
@ -393,6 +393,7 @@ Kitty Barnett
|
|||
STORM-288
|
||||
STORM-799
|
||||
STORM-800
|
||||
VWR-24217
|
||||
Kunnis Basiat
|
||||
VWR-82
|
||||
VWR-102
|
||||
|
|
@ -736,6 +737,7 @@ Thickbrick Sleaford
|
|||
VWR-9287
|
||||
VWR-13483
|
||||
VWR-13947
|
||||
VWR-24420
|
||||
Thraxis Epsilon
|
||||
SVC-371
|
||||
VWR-383
|
||||
|
|
|
|||
|
|
@ -50,8 +50,6 @@ LLPngWrapper::LLPngWrapper()
|
|||
mCompressionType( 0 ),
|
||||
mFilterMethod( 0 ),
|
||||
mFinalSize( 0 ),
|
||||
mHasBKGD(false),
|
||||
mBackgroundColor(),
|
||||
mGamma(0.f)
|
||||
{
|
||||
}
|
||||
|
|
@ -111,9 +109,9 @@ void LLPngWrapper::writeFlush(png_structp png_ptr)
|
|||
}
|
||||
|
||||
// Read the PNG file using the libpng. The low-level interface is used here
|
||||
// because we want to do various transformations (including setting the
|
||||
// matte background if any, and applying gama) which can't be done with
|
||||
// the high-level interface. The scanline also begins at the bottom of
|
||||
// because we want to do various transformations (including applying gama)
|
||||
// which can't be done with the high-level interface.
|
||||
// The scanline also begins at the bottom of
|
||||
// the image (per SecondLife conventions) instead of at the top, so we
|
||||
// must assign row-pointers in "reverse" order.
|
||||
BOOL LLPngWrapper::readPng(U8* src, LLImageRaw* rawImage, ImageInfo *infop)
|
||||
|
|
@ -201,8 +199,7 @@ void LLPngWrapper::normalizeImage()
|
|||
// 2. Convert grayscales to RGB
|
||||
// 3. Create alpha layer from transparency
|
||||
// 4. Ensure 8-bpp for all images
|
||||
// 5. Apply background matte if any
|
||||
// 6. Set (or guess) gamma
|
||||
// 5. Set (or guess) gamma
|
||||
|
||||
if (mColorType == PNG_COLOR_TYPE_PALETTE)
|
||||
{
|
||||
|
|
@ -229,12 +226,6 @@ void LLPngWrapper::normalizeImage()
|
|||
{
|
||||
png_set_strip_16(mReadPngPtr);
|
||||
}
|
||||
mHasBKGD = png_get_bKGD(mReadPngPtr, mReadInfoPtr, &mBackgroundColor);
|
||||
if (mHasBKGD)
|
||||
{
|
||||
png_set_background(mReadPngPtr, mBackgroundColor,
|
||||
PNG_BACKGROUND_GAMMA_FILE, 1, 1.0);
|
||||
}
|
||||
|
||||
#if LL_DARWIN
|
||||
const F64 SCREEN_GAMMA = 1.8;
|
||||
|
|
@ -261,7 +252,6 @@ void LLPngWrapper::updateMetaData()
|
|||
mBitDepth = png_get_bit_depth(mReadPngPtr, mReadInfoPtr);
|
||||
mColorType = png_get_color_type(mReadPngPtr, mReadInfoPtr);
|
||||
mChannels = png_get_channels(mReadPngPtr, mReadInfoPtr);
|
||||
mHasBKGD = png_get_bKGD(mReadPngPtr, mReadInfoPtr, &mBackgroundColor);
|
||||
}
|
||||
|
||||
// Method to write raw image into PNG at dest. The raw scanline begins
|
||||
|
|
|
|||
|
|
@ -88,9 +88,6 @@ private:
|
|||
|
||||
U32 mFinalSize;
|
||||
|
||||
bool mHasBKGD;
|
||||
png_color_16p mBackgroundColor;
|
||||
|
||||
F64 mGamma;
|
||||
|
||||
std::string mErrorMessage;
|
||||
|
|
|
|||
|
|
@ -468,7 +468,6 @@ LLLoginInstance::LLLoginInstance() :
|
|||
mLoginModule(new LLLogin()),
|
||||
mNotifications(NULL),
|
||||
mLoginState("offline"),
|
||||
mUserInteraction(true),
|
||||
mSkipOptionalUpdate(false),
|
||||
mAttemptComplete(false),
|
||||
mTransferRate(0.0f),
|
||||
|
|
@ -637,64 +636,57 @@ void LLLoginInstance::handleLoginFailure(const LLSD& event)
|
|||
LLSD response = event["data"];
|
||||
std::string reason_response = response["reason"].asString();
|
||||
std::string message_response = response["message"].asString();
|
||||
if(mUserInteraction)
|
||||
// For the cases of critical message or TOS agreement,
|
||||
// start the TOS dialog. The dialog response will be handled
|
||||
// by the LLLoginInstance::handleTOSResponse() callback.
|
||||
// The callback intiates the login attempt next step, either
|
||||
// to reconnect or to end the attempt in failure.
|
||||
if(reason_response == "tos")
|
||||
{
|
||||
// For the cases of critical message or TOS agreement,
|
||||
// start the TOS dialog. The dialog response will be handled
|
||||
// by the LLLoginInstance::handleTOSResponse() callback.
|
||||
// The callback intiates the login attempt next step, either
|
||||
// to reconnect or to end the attempt in failure.
|
||||
if(reason_response == "tos")
|
||||
{
|
||||
LLSD data(LLSD::emptyMap());
|
||||
data["message"] = message_response;
|
||||
data["reply_pump"] = TOS_REPLY_PUMP;
|
||||
gViewerWindow->setShowProgress(FALSE);
|
||||
LLFloaterReg::showInstance("message_tos", data);
|
||||
LLEventPumps::instance().obtain(TOS_REPLY_PUMP)
|
||||
.listen(TOS_LISTENER_NAME,
|
||||
boost::bind(&LLLoginInstance::handleTOSResponse,
|
||||
this, _1, "agree_to_tos"));
|
||||
}
|
||||
else if(reason_response == "critical")
|
||||
{
|
||||
LLSD data(LLSD::emptyMap());
|
||||
data["message"] = message_response;
|
||||
data["reply_pump"] = TOS_REPLY_PUMP;
|
||||
if(response.has("error_code"))
|
||||
{
|
||||
data["error_code"] = response["error_code"];
|
||||
}
|
||||
if(response.has("certificate"))
|
||||
{
|
||||
data["certificate"] = response["certificate"];
|
||||
}
|
||||
|
||||
gViewerWindow->setShowProgress(FALSE);
|
||||
LLFloaterReg::showInstance("message_critical", data);
|
||||
LLEventPumps::instance().obtain(TOS_REPLY_PUMP)
|
||||
.listen(TOS_LISTENER_NAME,
|
||||
boost::bind(&LLLoginInstance::handleTOSResponse,
|
||||
this, _1, "read_critical"));
|
||||
}
|
||||
else if(reason_response == "update" || gSavedSettings.getBOOL("ForceMandatoryUpdate"))
|
||||
{
|
||||
gSavedSettings.setBOOL("ForceMandatoryUpdate", FALSE);
|
||||
updateApp(true, message_response);
|
||||
}
|
||||
else if(reason_response == "optional")
|
||||
{
|
||||
updateApp(false, message_response);
|
||||
}
|
||||
else
|
||||
{
|
||||
attemptComplete();
|
||||
}
|
||||
LLSD data(LLSD::emptyMap());
|
||||
data["message"] = message_response;
|
||||
data["reply_pump"] = TOS_REPLY_PUMP;
|
||||
gViewerWindow->setShowProgress(FALSE);
|
||||
LLFloaterReg::showInstance("message_tos", data);
|
||||
LLEventPumps::instance().obtain(TOS_REPLY_PUMP)
|
||||
.listen(TOS_LISTENER_NAME,
|
||||
boost::bind(&LLLoginInstance::handleTOSResponse,
|
||||
this, _1, "agree_to_tos"));
|
||||
}
|
||||
else // no user interaction
|
||||
else if(reason_response == "critical")
|
||||
{
|
||||
LLSD data(LLSD::emptyMap());
|
||||
data["message"] = message_response;
|
||||
data["reply_pump"] = TOS_REPLY_PUMP;
|
||||
if(response.has("error_code"))
|
||||
{
|
||||
data["error_code"] = response["error_code"];
|
||||
}
|
||||
if(response.has("certificate"))
|
||||
{
|
||||
data["certificate"] = response["certificate"];
|
||||
}
|
||||
|
||||
gViewerWindow->setShowProgress(FALSE);
|
||||
LLFloaterReg::showInstance("message_critical", data);
|
||||
LLEventPumps::instance().obtain(TOS_REPLY_PUMP)
|
||||
.listen(TOS_LISTENER_NAME,
|
||||
boost::bind(&LLLoginInstance::handleTOSResponse,
|
||||
this, _1, "read_critical"));
|
||||
}
|
||||
else if(reason_response == "update" || gSavedSettings.getBOOL("ForceMandatoryUpdate"))
|
||||
{
|
||||
gSavedSettings.setBOOL("ForceMandatoryUpdate", FALSE);
|
||||
updateApp(true, message_response);
|
||||
}
|
||||
else if(reason_response == "optional")
|
||||
{
|
||||
updateApp(false, message_response);
|
||||
}
|
||||
else
|
||||
{
|
||||
attemptComplete();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void LLLoginInstance::handleLoginSuccess(const LLSD& event)
|
||||
|
|
|
|||
|
|
@ -61,12 +61,6 @@ public:
|
|||
// Only valid when authSuccess == true.
|
||||
const F64 getLastTransferRateBPS() { return mTransferRate; }
|
||||
|
||||
// Set whether this class will drive user interaction.
|
||||
// If not, login failures like 'need tos agreement' will
|
||||
// end the login attempt.
|
||||
void setUserInteraction(bool state) { mUserInteraction = state; }
|
||||
bool getUserInteraction() { return mUserInteraction; }
|
||||
|
||||
// Whether to tell login to skip optional update request.
|
||||
// False by default.
|
||||
void setSkipOptionalUpdate(bool state) { mSkipOptionalUpdate = state; }
|
||||
|
|
@ -100,7 +94,6 @@ private:
|
|||
std::string mLoginState;
|
||||
LLSD mRequestData;
|
||||
LLSD mResponseData;
|
||||
bool mUserInteraction;
|
||||
bool mSkipOptionalUpdate;
|
||||
bool mAttemptComplete;
|
||||
F64 mTransferRate;
|
||||
|
|
|
|||
|
|
@ -766,22 +766,12 @@ BOOL LLTaskCategoryBridge::startDrag(EDragAndDropType* type, LLUUID* id) const
|
|||
LLViewerObject* object = gObjectList.findObject(mPanel->getTaskUUID());
|
||||
if(object)
|
||||
{
|
||||
const LLInventoryItem *inv = dynamic_cast<LLInventoryItem*>(object->getInventoryObject(mUUID));
|
||||
if (inv)
|
||||
const LLInventoryObject* cat = object->getInventoryObject(mUUID);
|
||||
if ( (cat) && (move_inv_category_world_to_agent(mUUID, LLUUID::null, FALSE)) )
|
||||
{
|
||||
const LLPermissions& perm = inv->getPermissions();
|
||||
bool can_copy = gAgent.allowOperation(PERM_COPY, perm,
|
||||
GP_OBJECT_MANIPULATE);
|
||||
if((can_copy && perm.allowTransferTo(gAgent.getID()))
|
||||
|| object->permYouOwner())
|
||||
// || gAgent.isGodlike())
|
||||
|
||||
{
|
||||
*type = LLViewerAssetType::lookupDragAndDropType(inv->getType());
|
||||
|
||||
*id = inv->getUUID();
|
||||
return TRUE;
|
||||
}
|
||||
*type = LLViewerAssetType::lookupDragAndDropType(cat->getType());
|
||||
*id = mUUID;
|
||||
return TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -981,7 +981,6 @@ bool idle_startup()
|
|||
login->setSkipOptionalUpdate(true);
|
||||
}
|
||||
|
||||
login->setUserInteraction(show_connect_box);
|
||||
login->setSerialNumber(LLAppViewer::instance()->getSerialNumber());
|
||||
login->setLastExecEvent(gLastExecEvent);
|
||||
login->setUpdaterLauncher(boost::bind(&LLAppViewer::launchUpdater, LLAppViewer::instance()));
|
||||
|
|
|
|||
Loading…
Reference in New Issue