diff --git a/indra/newview/hippogridmanager.cpp b/indra/newview/hippogridmanager.cpp index f1f13906e..0ba0d92c4 100644 --- a/indra/newview/hippogridmanager.cpp +++ b/indra/newview/hippogridmanager.cpp @@ -81,7 +81,7 @@ const std::string& HippoGridInfo::getGridOwner() const } else { - return this->getGridName(); + return getGridName(); } } @@ -102,8 +102,7 @@ void HippoGridInfo::setPlatform(Platform platform) void HippoGridInfo::setPlatform(const std::string& platform) { std::string tmp = platform; - for (unsigned i=0; imGridName == "") + if (self->mGridName.empty()) { self->mGridName.assign(s, len); } @@ -366,7 +365,7 @@ void HippoGridInfo::getGridInfo() // Make sure the uri ends on a '/'. std::string uri = mLoginUri; - if (uri.compare(uri.length() - 1, 1, "/") != 0) + if (uri.back() != '/') { uri += '/'; } @@ -482,7 +481,7 @@ std::string HippoGridInfo::getGridNick() const // static const char* HippoGridInfo::getPlatformString(Platform platform) { - static const char* platformStrings[PLATFORM_LAST] = + constexpr const char* platformStrings[PLATFORM_LAST] = { "Other", "WhiteCore", "OpenSim", "SecondLife" }; diff --git a/indra/newview/llfloatersnapshot.cpp b/indra/newview/llfloatersnapshot.cpp index 5c96b7c47..a4c27fe3e 100644 --- a/indra/newview/llfloatersnapshot.cpp +++ b/indra/newview/llfloatersnapshot.cpp @@ -3187,16 +3187,9 @@ BOOL LLSnapshotFloaterView::handleKey(KEY key, MASK mask, BOOL called_from_paren return LLFloaterView::handleKey(key, mask, called_from_parent); } - if (called_from_parent) - { - // pass all keystrokes down - LLFloaterView::handleKey(key, mask, called_from_parent); - } - else - { - // bounce keystrokes back down - LLFloaterView::handleKey(key, mask, TRUE); - } + // pass all keystrokes down + // bounce keystrokes back down + LLFloaterView::handleKey(key, mask, TRUE); return TRUE; }