Merge branch 'DRTVWR-513-maint' of https://bitbucket.org/lindenlab/viewer

master
Ansariel 2020-10-15 11:37:14 +02:00
commit 95b4dd072e
17 changed files with 127 additions and 78 deletions

View File

@ -448,9 +448,9 @@
<key>archive</key>
<map>
<key>hash</key>
<string>471b0b350955152fd87518575057dfc4</string>
<string>ee1e3e1a18e7b123e69516e9725d5bbc</string>
<key>url</key>
<string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/60326/566593/bugsplat-1.0.7.542667-darwin64-542667.tar.bz2</string>
<string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/69791/674226/bugsplat-1.0.7.550056-darwin64-550056.tar.bz2</string>
</map>
<key>name</key>
<string>darwin64</string>
@ -460,9 +460,9 @@
<key>archive</key>
<map>
<key>hash</key>
<string>70e8bf46145c4cbae6f93e8b70ba5499</string>
<string>4682feb72e972e0790615de7046877ee</string>
<key>url</key>
<string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/60320/566541/bugsplat-3.6.0.4.542667-windows-542667.tar.bz2</string>
<string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/69789/674221/bugsplat-3.6.0.4.550056-windows-550056.tar.bz2</string>
</map>
<key>name</key>
<string>windows</string>
@ -472,16 +472,16 @@
<key>archive</key>
<map>
<key>hash</key>
<string>a73696e859fad3f19f835740815a2bd3</string>
<string>e8be5b56ebee7e3f9ce5c212f90dc70c</string>
<key>url</key>
<string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/60321/566542/bugsplat-3.6.0.4.542667-windows64-542667.tar.bz2</string>
<string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/69790/674223/bugsplat-3.6.0.4.550056-windows64-550056.tar.bz2</string>
</map>
<key>name</key>
<string>windows64</string>
</map>
</map>
<key>version</key>
<string>1.0.7.542667</string>
<string>3.6.0.4.550056</string>
</map>
<key>colladadom</key>
<map>

View File

@ -477,10 +477,12 @@ then
fi
# Run upload extensions
# Ex: bugsplat
if [ -d ${build_dir}/packages/upload-extensions ]; then
for extension in ${build_dir}/packages/upload-extensions/*.sh; do
begin_section "Upload Extension $extension"
. $extension
[ $? -eq 0 ] || fatal "Upload of extension $extension failed"
end_section "Upload Extension $extension"
done
fi

View File

@ -329,12 +329,10 @@ void LLFloater::initFloater(const Params& p)
mButtonsEnabled[BUTTON_CLOSE] = TRUE;
}
// Help button: '?'
if ( !mHelpTopic.empty() )
{
mButtonsEnabled[BUTTON_HELP] = TRUE;
}
// Help button: '?'
//SL-14050 Disable all Help question marks
mButtonsEnabled[BUTTON_HELP] = FALSE;
// Minimize button only for top draggers
if ( !mDragOnLeft && mCanMinimize )
{

View File

@ -1010,6 +1010,18 @@ boost::signals2::connection LLAgent::addParcelChangedCallback(parcel_changed_cal
return mParcelChangedSignal.connect(cb);
}
// static
void LLAgent::capabilityReceivedCallback(const LLUUID &region_id)
{
LLViewerRegion* region = gAgent.getRegion();
if (region && region->getRegionID() == region_id)
{
region->requestSimulatorFeatures();
LLAppViewer::instance()->updateNameLookupUrl();
}
}
//-----------------------------------------------------------------------------
// setRegion()
//-----------------------------------------------------------------------------
@ -1055,10 +1067,11 @@ void LLAgent::setRegion(LLViewerRegion *regionp)
if (regionp->capabilitiesReceived())
{
regionp->requestSimulatorFeatures();
LLAppViewer::instance()->updateNameLookupUrl();
}
else
{
regionp->setCapabilitiesReceivedCallback(boost::bind(&LLViewerRegion::requestSimulatorFeatures, regionp));
regionp->setCapabilitiesReceivedCallback(LLAgent::capabilityReceivedCallback);
}
}

View File

@ -265,6 +265,8 @@ public:
boost::signals2::connection addParcelChangedCallback(parcel_changed_callback_t);
private:
static void capabilityReceivedCallback(const LLUUID &region_id);
typedef boost::signals2::signal<void()> parcel_changed_signal_t;
parcel_changed_signal_t mParcelChangedSignal;

View File

@ -2066,7 +2066,7 @@ bool LLAppearanceMgr::getCanReplaceCOF(const LLUUID& outfit_cat_id)
}
// Moved from LLWearableList::ContextMenu for wider utility.
bool LLAppearanceMgr::canAddWearables(const uuid_vec_t& item_ids)
bool LLAppearanceMgr::canAddWearables(const uuid_vec_t& item_ids) const
{
// TODO: investigate wearables may not be loaded at this point EXT-8231
@ -2076,7 +2076,7 @@ bool LLAppearanceMgr::canAddWearables(const uuid_vec_t& item_ids)
// Count given clothes (by wearable type) and objects.
for (uuid_vec_t::const_iterator it = item_ids.begin(); it != item_ids.end(); ++it)
{
LLViewerInventoryItem* item = gInventory.getItem(*it);
const LLViewerInventoryItem* item = gInventory.getItem(*it);
if (!item)
{
return false;

View File

@ -106,7 +106,7 @@ public:
bool getCanReplaceCOF(const LLUUID& outfit_cat_id);
// Can we add all referenced items to the avatar?
bool canAddWearables(const uuid_vec_t& item_ids);
bool canAddWearables(const uuid_vec_t& item_ids) const;
// Copy all items in a category.
void shallowCopyCategoryContents(const LLUUID& src_id, const LLUUID& dst_id,

View File

@ -6034,11 +6034,56 @@ void LLAppViewer::sendLogoutRequest()
}
}
void LLAppViewer::updateNameLookupUrl()
{
LLViewerRegion* region = gAgent.getRegion();
if (!region || !region->capabilitiesReceived())
{
return;
}
LLAvatarNameCache *name_cache = LLAvatarNameCache::getInstance();
bool had_capability = LLAvatarNameCache::getInstance()->hasNameLookupURL();
std::string name_lookup_url;
name_lookup_url.reserve(128); // avoid a memory allocation below
name_lookup_url = region->getCapability("GetDisplayNames");
bool have_capability = !name_lookup_url.empty();
if (have_capability)
{
// we have support for display names, use it
U32 url_size = name_lookup_url.size();
// capabilities require URLs with slashes before query params:
// https://<host>:<port>/cap/<uuid>/?ids=<blah>
// but the caps are granted like:
// https://<host>:<port>/cap/<uuid>
if (url_size > 0 && name_lookup_url[url_size - 1] != '/')
{
name_lookup_url += '/';
}
name_cache->setNameLookupURL(name_lookup_url);
}
else
{
// Display names not available on this region
name_cache->setNameLookupURL(std::string());
}
// Error recovery - did we change state?
if (had_capability != have_capability)
{
// name tags are persistant on screen, so make sure they refresh
LLVOAvatar::invalidateNameTags();
}
}
void LLAppViewer::idleNameCache()
{
// Neither old nor new name cache can function before agent has a region
LLViewerRegion* region = gAgent.getRegion();
if (!region) return;
if (!region)
{
return;
}
// deal with any queued name requests and replies.
gCacheName->processPending();
@ -6046,47 +6091,12 @@ void LLAppViewer::idleNameCache()
// Can't run the new cache until we have the list of capabilities
// for the agent region, and can therefore decide whether to use
// display names or fall back to the old name system.
if (!region->capabilitiesReceived()) return;
if (!region->capabilitiesReceived())
{
return;
}
// Agent may have moved to a different region, so need to update cap URL
// for name lookups. Can't do this in the cap grant code, as caps are
// granted to neighbor regions before the main agent gets there. Can't
// do it in the move-into-region code because cap not guaranteed to be
// granted yet, for example on teleport.
LLAvatarNameCache *name_cache = LLAvatarNameCache::getInstance();
bool had_capability = LLAvatarNameCache::getInstance()->hasNameLookupURL();
std::string name_lookup_url;
name_lookup_url.reserve(128); // avoid a memory allocation below
name_lookup_url = region->getCapability("GetDisplayNames");
bool have_capability = !name_lookup_url.empty();
if (have_capability)
{
// we have support for display names, use it
U32 url_size = name_lookup_url.size();
// capabilities require URLs with slashes before query params:
// https://<host>:<port>/cap/<uuid>/?ids=<blah>
// but the caps are granted like:
// https://<host>:<port>/cap/<uuid>
if (url_size > 0 && name_lookup_url[url_size-1] != '/')
{
name_lookup_url += '/';
}
name_cache->setNameLookupURL(name_lookup_url);
}
else
{
// Display names not available on this region
name_cache->setNameLookupURL( std::string() );
}
// Error recovery - did we change state?
if (had_capability != have_capability)
{
// name tags are persistant on screen, so make sure they refresh
LLVOAvatar::invalidateNameTags();
}
name_cache->idle();
LLAvatarNameCache::getInstance()->idle();
}
//

View File

@ -217,7 +217,9 @@ public:
// llcorehttp init/shutdown/config information.
LLAppCoreHttp & getAppCoreHttp() { return mAppCoreHttp; }
void updateNameLookupUrl();
protected:
virtual bool initWindow(); // Initialize the viewer's window.
virtual void initLoggingAndGetLastDuration(); // Initialize log files, logging system

View File

@ -612,6 +612,11 @@ bool LLCurrencyUIManager::bought()
return impl.mBought;
}
void LLCurrencyUIManager::clearError()
{
impl.clearError();
}
bool LLCurrencyUIManager::hasError()
{
return impl.mError;

View File

@ -80,6 +80,8 @@ public:
bool buying(); // are we in the process of buying?
bool bought(); // did the buy() transaction complete successfully
void clearError();
bool hasError();
std::string errorMessage();
std::string errorURI();

View File

@ -184,6 +184,7 @@ void LLFloaterBuyCurrencyUI::updateUI()
args["TITLE"] = getString("info_cannot_buy");
args["MESSAGE"] = mManager.errorMessage();
LLNotificationsUtil::add("CouldNotBuyCurrency", args);
mManager.clearError();
closeFloater();
}
else

View File

@ -457,19 +457,23 @@ void LLFloaterIMContainer::idleUpdate()
const LLConversationItem *current_session = getCurSelectedViewModelItem();
if (current_session)
{
// Update moderator options visibility
LLFolderViewModelItemCommon::child_list_t::const_iterator current_participant_model = current_session->getChildrenBegin();
LLFolderViewModelItemCommon::child_list_t::const_iterator end_participant_model = current_session->getChildrenEnd();
bool is_moderator = isGroupModerator();
bool can_ban = haveAbilityToBan();
while (current_participant_model != end_participant_model)
if (current_session->getType() == LLConversationItem::CONV_SESSION_GROUP)
{
LLConversationItemParticipant* participant_model = dynamic_cast<LLConversationItemParticipant*>(*current_participant_model);
participant_model->setModeratorOptionsVisible(is_moderator);
participant_model->setGroupBanVisible(can_ban && participant_model->getUUID() != gAgentID);
// Update moderator options visibility
LLFolderViewModelItemCommon::child_list_t::const_iterator current_participant_model = current_session->getChildrenBegin();
LLFolderViewModelItemCommon::child_list_t::const_iterator end_participant_model = current_session->getChildrenEnd();
bool is_moderator = isGroupModerator();
bool can_ban = haveAbilityToBan();
while (current_participant_model != end_participant_model)
{
LLConversationItemParticipant* participant_model = dynamic_cast<LLConversationItemParticipant*>(*current_participant_model);
participant_model->setModeratorOptionsVisible(is_moderator);
participant_model->setGroupBanVisible(can_ban && participant_model->getUUID() != gAgentID);
current_participant_model++;
current_participant_model++;
}
}
// Update floater's title as required by the currently selected session or use the default title
LLFloaterIMSession * conversation_floaterp = LLFloaterIMSession::findInstance(current_session->getUUID());
setTitle(conversation_floaterp && conversation_floaterp->needsTitleOverwrite() ? conversation_floaterp->getTitle() : mGeneralTitle);

View File

@ -8515,11 +8515,11 @@ void LLFolderViewGroupedItemBridge::groupFilterContextMenu(folder_view_item_dequ
disable_context_entries_if_present(menu, disabled_items);
}
bool LLFolderViewGroupedItemBridge::canWearSelected(uuid_vec_t item_ids)
bool LLFolderViewGroupedItemBridge::canWearSelected(const uuid_vec_t& item_ids) const
{
for (uuid_vec_t::const_iterator it = item_ids.begin(); it != item_ids.end(); ++it)
{
LLViewerInventoryItem* item = gInventory.getItem(*it);
const LLViewerInventoryItem* item = gInventory.getItem(*it);
// <FS:Ansariel> Fix broken add wearable check
//if (!item || (item->getType() >= LLAssetType::AT_COUNT) || (item->getType() <= LLAssetType::AT_NONE))
if (!item || (item->getType() != LLAssetType::AT_CLOTHING && item->getType() != LLAssetType::AT_OBJECT && item->getType() != LLAssetType::AT_BODYPART && item->getType() != LLAssetType::AT_GESTURE))

View File

@ -823,7 +823,7 @@ class LLFolderViewGroupedItemBridge: public LLFolderViewGroupedItemModel
public:
LLFolderViewGroupedItemBridge();
virtual void groupFilterContextMenu(folder_view_item_deque& selected_items, LLMenuGL& menu);
bool canWearSelected(uuid_vec_t item_ids);
bool canWearSelected(const uuid_vec_t& item_ids) const;
};
#endif // LL_LLINVENTORYBRIDGE_H

View File

@ -298,6 +298,7 @@ void LLViewerRegionImpl::requestBaseCapabilitiesCoro(U64 regionHandle)
LL_INFOS("AppInit", "Capabilities") << "Requesting seed from " << url
<< " region name " << regionp->getName()
<< " region id " << regionp->getRegionID()
<< " (attempt #" << mSeedCapAttempts + 1 << ")" << LL_ENDL;
LL_DEBUGS("AppInit", "Capabilities") << "Capabilities requested: " << capabilityNames << LL_ENDL;
@ -416,7 +417,7 @@ void LLViewerRegionImpl::requestBaseCapabilitiesCompleteCoro(U64 regionHandle)
LLSD capabilityNames = LLSD::emptyArray();
buildCapabilityNames(capabilityNames);
LL_INFOS("AppInit", "Capabilities") << "Requesting second Seed from " << url << LL_ENDL;
LL_INFOS("AppInit", "Capabilities") << "Requesting second Seed from " << url << " for region " << regionp->getRegionID() << LL_ENDL;
regionp = NULL;
result = httpAdapter->postAndSuspend(httpRequest, url, capabilityNames);
@ -2387,7 +2388,7 @@ void LLViewerRegion::requestSimulatorFeatures()
LLCoros::instance().launch("LLViewerRegionImpl::requestSimulatorFeatureCoro",
boost::bind(&LLViewerRegionImpl::requestSimulatorFeatureCoro, mImpl, url, getHandle()));
LL_INFOS("AppInit", "SimulatorFeatures") << "Launching " << coroname << " requesting simulator features from " << url << LL_ENDL;
LL_INFOS("AppInit", "SimulatorFeatures") << "Launching " << coroname << " requesting simulator features from " << url << " for region " << getRegionID() << LL_ENDL;
}
else
{
@ -3254,7 +3255,7 @@ void LLViewerRegion::setSeedCapability(const std::string& url)
if (getCapability("Seed") == url)
{
setCapabilityDebug("Seed", url);
LL_WARNS("CrossingCaps") << "Received duplicate seed capability, posting to seed " <<
LL_WARNS("CrossingCaps") << "Received duplicate seed capability for " << getRegionID() << ", posting to seed " <<
url << LL_ENDL;
//Instead of just returning we build up a second set of seed caps and compare them
@ -3275,7 +3276,7 @@ void LLViewerRegion::setSeedCapability(const std::string& url)
LLCoros::instance().launch("LLViewerRegionImpl::requestBaseCapabilitiesCoro",
boost::bind(&LLViewerRegionImpl::requestBaseCapabilitiesCoro, mImpl, getHandle()));
LL_INFOS("AppInit", "Capabilities") << "Launching " << coroname << " requesting seed capabilities from " << url << LL_ENDL;
LL_INFOS("AppInit", "Capabilities") << "Launching " << coroname << " requesting seed capabilities from " << url << " for region " << getRegionID() << LL_ENDL;
}
S32 LLViewerRegion::getNumSeedCapRetries()

View File

@ -324,6 +324,9 @@ class ViewerManifest(LLManifest,FSViewerManifest):
return CHANNEL_VENDOR_BASE + app_suffix
#</FS:ND>
def exec_name(self):
return "SecondLifeViewer"
def app_name_oneword(self):
return ''.join(self.app_name().split())
@ -487,10 +490,12 @@ class WindowsManifest(ViewerManifest):
build_data_json_platform = 'win'
def final_exe(self):
return self.app_name_oneword()+".exe"
return self.exec_name()+".exe"
def final_pdb(self):
return self.exec_name()+".pdb"
def finish_build_data_dict(self, build_data_dict):
#MAINT-7294: Windows exe names depend on channel name, so write that in also
build_data_dict['Executable'] = self.final_exe()
build_data_dict['AppName'] = self.app_name()
return build_data_dict
@ -555,6 +560,10 @@ class WindowsManifest(ViewerManifest):
if self.is_packaging_viewer():
# Find secondlife-bin.exe in the 'configuration' dir, then rename it to the result of final_exe.
self.path(src='%s/firestorm-bin.exe' % self.args['configuration'], dst=self.final_exe())
# Bugsplat for some reason requires a match between user's exe and supplied pdb on Windows 10
# this feels wrong and doesn't make any sense, since often we are supposed to match a whole
# folder of symbol files to a random exe. But Bugsplat says 'it's expected' so just rename files.
self.ccopyfile(src='%s/secondlife-bin.pdb' % self.args['configuration'], dst='%s/%s' % (self.args['configuration'], self.final_pdb()))
# <FS:Ansariel> Remove VMP
#with self.prefix(src=os.path.join(pkgdir, "VMP")):