Merge Firestorm LGPL

master
Ansariel 2016-10-04 11:29:33 +02:00
commit 14cd18f021
18 changed files with 566 additions and 33 deletions

View File

@ -178,7 +178,7 @@ if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
message(STATUS "OS X SDK 10.9 found.")
else(IS_DIRECTORY "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk")
error("Unable to determine which OS X SDK to use. Giving up.")
endif(IS_DIRECTORY "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk")
endif(IS_DIRECTORY "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk")
set(CMAKE_XCODE_ATTRIBUTE_GCC_VERSION "com.apple.compilers.llvm.clang.1_0")
set(CMAKE_XCODE_ATTRIBUTE_GCC_OPTIMIZATION_LEVEL 3)

View File

@ -369,7 +369,8 @@ set(viewer_SOURCE_FILES
llfloatermodeluploadbase.cpp
llfloaternamedesc.cpp
llfloaternotificationsconsole.cpp
llfloaternotificationstabbed.cpp
llfloaternotificationstabbed.cpp
llfloateroutfitphotopreview.cpp
llfloateroutfitsnapshot.cpp
llfloaterobjectweights.cpp
llfloateropenobject.cpp
@ -1119,7 +1120,8 @@ set(viewer_HEADER_FILES
llfloatermodeluploadbase.h
llfloaternamedesc.h
llfloaternotificationsconsole.h
llfloaternotificationstabbed.h
llfloaternotificationstabbed.h
llfloateroutfitphotopreview.h
llfloateroutfitsnapshot.h
llfloaterobjectweights.h
llfloateropenobject.h

View File

@ -7444,6 +7444,17 @@
<key>Backup</key>
<integer>0</integer>
</map>
<key>LastAppearanceTab</key>
<map>
<key>Comment</key>
<string>Last selected tab in appearance floater</string>
<key>Persist</key>
<integer>1</integer>
<key>Type</key>
<string>S32</string>
<key>Value</key>
<integer>0</integer>
</map>
<key>LastMediaSettingsTab</key>
<map>
<key>Comment</key>
@ -24141,6 +24152,17 @@ Change of this parameter will affect the layout of buttons in notification toast
<key>Value</key>
<integer>1</integer>
</map>
<key>FSPermissionDebitDefaultDeny</key>
<map>
<key>Comment</key>
<string>If enabled, LSL script debit permission dialogs will default to deny. If disabled, they will default to allow.</string>
<key>Persist</key>
<integer>1</integer>
<key>Type</key>
<string>Boolean</string>
<key>Value</key>
<integer>1</integer>
</map>
</map>
</llsd>

View File

@ -46,15 +46,17 @@ const F32 PARCEL_WL_CHECK_TIME = 5.f;
const S32 PARCEL_WL_MIN_ALT_CHANGE = 3;
const std::string PARCEL_WL_DEFAULT = "Default";
const S32 NO_ZONES = -1; // Parcel WL is using default sky or region defaults (no height-mapped parcel WL)
const S32 NO_SETTINGS = -2; // We didn't receive any parcel WL settings yet
KCWindlightInterface::KCWindlightInterface() :
LLEventTimer(PARCEL_WL_CHECK_TIME),
mWLset(false),
mWeChangedIt(false),
mCurrentSpace(-2),
mCurrentSpace(NO_SETTINGS),
mLastParcelID(-1),
mLastRegion(NULL),
mRegionOverride(false),
mHasRegionOverride(false),
mHaveRegionSettings(false),
mDisabled(false)
{
@ -93,7 +95,7 @@ void KCWindlightInterface::parcelChange()
// will come in, we must check if the other has set something before this one for the current region.
if (gAgent.getRegion() != mLastRegion)
{
mRegionOverride = false;
mHasRegionOverride = false;
mHaveRegionSettings = false;
mLastRegion = gAgent.getRegion();
}
@ -110,7 +112,7 @@ void KCWindlightInterface::parcelChange()
mLastParcelID = this_parcel_id;
mLastParcelDesc = desc;
mCurrentSpace = -2;
mCurrentSpace = NO_SETTINGS;
mCurrentSettings.clear();
setWL_Status(false); //clear the status bar icon
const LLVector3& agent_pos_region = gAgent.getPositionAgent();
@ -178,7 +180,7 @@ void KCWindlightInterface::applySettings(const LLSD& settings)
{
mCurrentSettings = settings;
mRegionOverride = settings.has("region_override");
mHasRegionOverride = settings.has("region_override");
bool non_region_default_applied = applySkySettings(settings);
@ -188,9 +190,9 @@ void KCWindlightInterface::applySettings(const LLSD& settings)
// has set before.
if (non_region_default_applied)
{
if (settings.has("water") && (!mHaveRegionSettings || mRegionOverride))
if (settings.has("water") && (!mHaveRegionSettings || mHasRegionOverride))
{
LL_DEBUGS() << "Applying WL water set: " << settings["water"].asString() << LL_ENDL;
LL_INFOS() << "Applying WL water set: " << settings["water"].asString() << LL_ENDL;
LLEnvManagerNew::instance().setUseWaterPreset(settings["water"].asString(), gSavedSettings.getBOOL("FSInterpolateParcelWL"));
setWL_Status(true);
}
@ -206,6 +208,8 @@ bool KCWindlightInterface::applySkySettings(const LLSD& settings)
{
if (settings.has("sky"))
{
LL_DEBUGS() << "Checking if agent is in a defined zone" << LL_ENDL;
//TODO: there has to be a better way of doing this...
mEventTimer.reset();
mEventTimer.start();
@ -222,26 +226,38 @@ bool KCWindlightInterface::applySkySettings(const LLSD& settings)
if (lower != mCurrentSpace) //workaround: only apply once
{
mCurrentSpace = lower; //use lower as an id
LL_DEBUGS() << "Applying WL sky set: " << (*space_it)["preset"].asString() << LL_ENDL;
LL_INFOS() << "Applying WL sky set: " << (*space_it)["preset"].asString() << " (agent in zone " << lower << " to " << upper << ")" << LL_ENDL;
applyWindlightPreset((*space_it)["preset"].asString());
}
return true;
}
}
LL_DEBUGS() << "Agent is not within a defined zone. Trying default now" << LL_ENDL;
}
if (mCurrentSpace != -1)
if (mCurrentSpace != NO_ZONES)
{
mCurrentSpace = -1;
mCurrentSpace = NO_ZONES;
// set notes on KCWindlightInterface::haveParcelOverride
if (settings.has("sky_default") && (!mHaveRegionSettings || mRegionOverride))
if (settings.has("sky_default") && (!mHaveRegionSettings || mHasRegionOverride))
{
LL_DEBUGS() << "Applying WL sky set: " << settings["sky_default"] << " (Parcel WL Default)" << LL_ENDL;
LL_INFOS() << "Applying WL sky set: " << settings["sky_default"] << " (Parcel WL Default)" << LL_ENDL;
applyWindlightPreset(settings["sky_default"].asString());
}
else //reset to default
{
LL_DEBUGS() << "Applying WL sky set: Region Default" << LL_ENDL;
std::string reason;
if (!settings.has("sky_default"))
{
reason = "No zone or not in a defined zone and no default sky defined";
}
else if (mHaveRegionSettings && !mHasRegionOverride)
{
reason = "No zone defined or not in a defined zone, region has custom WL and \"RegionOverride\" parameter was not set";
}
LL_INFOS() << "Applying WL sky set \"Region Default\": " << reason << LL_ENDL;
applyWindlightPreset(PARCEL_WL_DEFAULT);
return false;
}
@ -607,15 +623,24 @@ bool KCWindlightInterface::haveParcelOverride(const LLEnvironmentSettings& new_s
// will come in, we must check if the other has set something before this one for the current region.
if (gAgent.getRegion() != mLastRegion)
{
mRegionOverride = false;
mHasRegionOverride = false;
mCurrentSettings.clear();
mLastRegion = gAgent.getRegion();
}
//*ASSUMPTION: if region day cycle is empty, its set to default
mHaveRegionSettings = new_settings.getWLDayCycle().size() > 0;
return mRegionOverride || mCurrentSpace != -1;
bool has_override = mHasRegionOverride || // "RegionOverride" parameter set
(mCurrentSpace == NO_ZONES && !mHaveRegionSettings) || // Custom parcel WL default sky and region default WL (no custom region default WL!)
(mCurrentSpace != NO_SETTINGS && mCurrentSpace != NO_ZONES); // Height-mapped parcel WL
if (!has_override)
{
LL_INFOS() << "Region environment settings received. Parcel WL settings will be overridden. Reason: No \"RegionOverride\", region not using default WL and no zones defined or Parcel WL settings received - Region settings taking precedence" << LL_ENDL;
}
return has_override;
}
void KCWindlightInterface::setWL_Status(bool pwl_status)
@ -636,9 +661,9 @@ bool KCWindlightInterface::checkSettings()
{
mCurrentSettings.clear();
mWeChangedIt = false;
mCurrentSpace = -2;
mCurrentSpace = NO_SETTINGS;
mLastParcelID = -1;
mRegionOverride = false;
mHasRegionOverride = false;
mHaveRegionSettings = false;
mLastRegion = NULL;
mEventTimer.stop();

View File

@ -83,7 +83,7 @@ protected:
bool mWeChangedIt; //dont reset anything if we didnt do it
bool mTPing; //agent just TP'd (hack, might be better way)
LLViewerRegion* mLastRegion;
bool mRegionOverride;
bool mHasRegionOverride;
bool mHaveRegionSettings;
bool mDisabled; // control bool to clear all states after being disabled
};

View File

@ -504,7 +504,7 @@ void LLEnvManagerNew::onRegionSettingsResponse(const LLSD& content)
LLWLParamManager::instance().refreshRegionPresets();
//<FS:KC> Use the region settings if parcel settings didnt override it already
if (KCWindlightInterface::instance().haveParcelOverride(new_settings))
if (!KCWindlightInterface::instance().haveParcelOverride(new_settings))
{
// If using server settings, update managers.
// if (getUseRegionSettings())

View File

@ -0,0 +1,289 @@
/**
* @file llfloateroutfitphotopreview.cpp
* @brief LLFloaterOutfitPhotoPreview class implementation
*
* $LicenseInfo:firstyear=2002&license=viewerlgpl$
* Second Life Viewer Source Code
* Copyright (C) 2010, Linden Research, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation;
* version 2.1 of the License only.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*
* Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
* $/LicenseInfo$
*/
#include "llviewerprecompiledheaders.h"
#include "llwindow.h"
#include "llfloateroutfitphotopreview.h"
#include "llagent.h"
#include "llappearancemgr.h"
#include "llbutton.h"
#include "llcombobox.h"
#include "llfilepicker.h"
#include "llfloaterreg.h"
#include "llimagetga.h"
#include "llimagepng.h"
#include "llinventory.h"
#include "llinventorymodel.h"
#include "llnotificationsutil.h"
#include "llresmgr.h"
#include "lltrans.h"
#include "lltextbox.h"
#include "lltextureview.h"
#include "llui.h"
#include "llviewerinventory.h"
#include "llviewertexture.h"
#include "llviewertexturelist.h"
#include "lluictrlfactory.h"
#include "llviewerwindow.h"
#include "lllineeditor.h"
const S32 MAX_OUTFIT_PHOTO_WIDTH = 256;
const S32 MAX_OUTFIT_PHOTO_HEIGHT = 256;
const S32 CLIENT_RECT_VPAD = 4;
LLFloaterOutfitPhotoPreview::LLFloaterOutfitPhotoPreview(const LLSD& key)
: LLPreview(key),
mUpdateDimensions(TRUE),
mImage(NULL),
mOutfitID(LLUUID()),
mImageOldBoostLevel(LLGLTexture::BOOST_NONE),
mExceedLimits(FALSE)
{
updateImageID();
}
LLFloaterOutfitPhotoPreview::~LLFloaterOutfitPhotoPreview()
{
LLLoadedCallbackEntry::cleanUpCallbackList(&mCallbackTextureList) ;
if (mImage.notNull())
{
mImage->setBoostLevel(mImageOldBoostLevel);
mImage = NULL;
}
}
// virtual
BOOL LLFloaterOutfitPhotoPreview::postBuild()
{
getChild<LLButton>("ok_btn")->setClickedCallback(boost::bind(&LLFloaterOutfitPhotoPreview::onOkBtn, this));
getChild<LLButton>("cancel_btn")->setClickedCallback(boost::bind(&LLFloaterOutfitPhotoPreview::onCancelBtn, this));
return LLPreview::postBuild();
}
void LLFloaterOutfitPhotoPreview::draw()
{
updateDimensions();
LLPreview::draw();
if (!isMinimized())
{
LLGLSUIDefault gls_ui;
gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
const LLRect& border = mClientRect;
LLRect interior = mClientRect;
interior.stretch( -PREVIEW_BORDER_WIDTH );
// ...border
gl_rect_2d( border, LLColor4(0.f, 0.f, 0.f, 1.f));
gl_rect_2d_checkerboard( interior );
if ( mImage.notNull() )
{
// Draw the texture
gGL.diffuseColor3f( 1.f, 1.f, 1.f );
gl_draw_scaled_image(interior.mLeft,
interior.mBottom,
interior.getWidth(),
interior.getHeight(),
mImage);
// Pump the texture priority
F32 pixel_area = (F32)(interior.getWidth() * interior.getHeight() );
mImage->addTextureStats( pixel_area );
S32 int_width = interior.getWidth();
S32 int_height = interior.getHeight();
mImage->setKnownDrawSize(int_width, int_height);
}
}
}
// virtual
void LLFloaterOutfitPhotoPreview::reshape(S32 width, S32 height, BOOL called_from_parent)
{
LLPreview::reshape(width, height, called_from_parent);
LLRect dim_rect(getChildView("dimensions")->getRect());
S32 horiz_pad = 2 * (LLPANEL_BORDER_WIDTH + PREVIEW_PAD) + PREVIEW_RESIZE_HANDLE_SIZE;
S32 info_height = dim_rect.mTop + CLIENT_RECT_VPAD;
LLRect client_rect(horiz_pad, getRect().getHeight(), getRect().getWidth() - horiz_pad, 0);
client_rect.mTop -= (PREVIEW_HEADER_SIZE + CLIENT_RECT_VPAD);
client_rect.mBottom += PREVIEW_BORDER + CLIENT_RECT_VPAD + info_height ;
S32 client_width = client_rect.getWidth();
S32 client_height = client_width;
if(client_height > client_rect.getHeight())
{
client_height = client_rect.getHeight();
client_width = client_height;
}
mClientRect.setLeftTopAndSize(client_rect.getCenterX() - (client_width / 2), client_rect.getCenterY() + (client_height / 2), client_width, client_height);
}
void LLFloaterOutfitPhotoPreview::updateDimensions()
{
if (!mImage)
{
return;
}
if ((mImage->getFullWidth() * mImage->getFullHeight()) == 0)
{
return;
}
if (mAssetStatus != PREVIEW_ASSET_LOADED)
{
mAssetStatus = PREVIEW_ASSET_LOADED;
mUpdateDimensions = TRUE;
}
getChild<LLUICtrl>("dimensions")->setTextArg("[WIDTH]", llformat("%d", mImage->getFullWidth()));
getChild<LLUICtrl>("dimensions")->setTextArg("[HEIGHT]", llformat("%d", mImage->getFullHeight()));
if ((mImage->getFullWidth() <= MAX_OUTFIT_PHOTO_WIDTH) && (mImage->getFullHeight() <= MAX_OUTFIT_PHOTO_HEIGHT))
{
getChild<LLButton>("ok_btn")->setEnabled(TRUE);
mExceedLimits = FALSE;
}
else
{
mExceedLimits = TRUE;
LLStringUtil::format_map_t args;
args["MAX_WIDTH"] = llformat("%d", MAX_OUTFIT_PHOTO_WIDTH);
args["MAX_HEIGHT"] = llformat("%d", MAX_OUTFIT_PHOTO_HEIGHT);
std::string label = getString("exceed_limits", args);
getChild<LLUICtrl>("notification")->setValue(label);
getChild<LLUICtrl>("notification")->setColor(LLColor4::yellow);
getChild<LLButton>("ok_btn")->setEnabled(FALSE);
}
if (mUpdateDimensions)
{
mUpdateDimensions = FALSE;
reshape(getRect().getWidth(), getRect().getHeight());
gFloaterView->adjustToFitScreen(this, FALSE);
}
}
void LLFloaterOutfitPhotoPreview::loadAsset()
{
if (mImage.notNull())
{
mImage->setBoostLevel(mImageOldBoostLevel);
}
mImage = LLViewerTextureManager::getFetchedTexture(mImageID, FTT_DEFAULT, MIPMAP_TRUE, LLGLTexture::BOOST_NONE, LLViewerTexture::LOD_TEXTURE);
mImageOldBoostLevel = mImage->getBoostLevel();
mImage->setBoostLevel(LLGLTexture::BOOST_PREVIEW);
mImage->forceToSaveRawImage(0) ;
mAssetStatus = PREVIEW_ASSET_LOADING;
mUpdateDimensions = TRUE;
updateDimensions();
}
LLPreview::EAssetStatus LLFloaterOutfitPhotoPreview::getAssetStatus()
{
if (mImage.notNull() && (mImage->getFullWidth() * mImage->getFullHeight() > 0))
{
mAssetStatus = PREVIEW_ASSET_LOADED;
}
return mAssetStatus;
}
void LLFloaterOutfitPhotoPreview::updateImageID()
{
const LLViewerInventoryItem *item = static_cast<const LLViewerInventoryItem*>(getItem());
if(item)
{
mImageID = item->getAssetUUID();
LLPermissions perm(item->getPermissions());
}
else
{
mImageID = mItemUUID;
}
}
/* virtual */
void LLFloaterOutfitPhotoPreview::setObjectID(const LLUUID& object_id)
{
mObjectUUID = object_id;
const LLUUID old_image_id = mImageID;
updateImageID();
if (mImageID != old_image_id)
{
mAssetStatus = PREVIEW_ASSET_UNLOADED;
loadAsset();
}
refreshFromItem();
}
void LLFloaterOutfitPhotoPreview::setOutfitID(const LLUUID& outfit_id)
{
mOutfitID = outfit_id;
LLViewerInventoryCategory* outfit_folder = gInventory.getCategory(mOutfitID);
if(outfit_folder && !mExceedLimits)
{
getChild<LLUICtrl>("notification")->setValue( getString("photo_confirmation"));
getChild<LLUICtrl>("notification")->setTextArg("[OUTFIT]", outfit_folder->getName());
getChild<LLUICtrl>("notification")->setColor(LLColor4::white);
}
}
void LLFloaterOutfitPhotoPreview::onOkBtn()
{
if(mOutfitID.notNull() && getItem())
{
LLAppearanceMgr::instance().removeOutfitPhoto(mOutfitID);
LLPointer<LLInventoryCallback> cb = NULL;
link_inventory_object(mOutfitID, LLConstPointer<LLInventoryObject>(getItem()), cb);
}
closeFloater();
}
void LLFloaterOutfitPhotoPreview::onCancelBtn()
{
closeFloater();
}

View File

@ -0,0 +1,77 @@
/**
* @file llfloateroutfitphotopreview.h
* @brief LLFloaterOutfitPhotoPreview class definition
*
* $LicenseInfo:firstyear=2002&license=viewerlgpl$
* Second Life Viewer Source Code
* Copyright (C) 2010, Linden Research, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation;
* version 2.1 of the License only.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*
* Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
* $/LicenseInfo$
*/
#ifndef LL_LLFLOATEROUTFITPHOTOPREVIEW_H
#define LL_LLFLOATEROUTFITPHOTOPREVIEW_H
#include "llpreview.h"
#include "llbutton.h"
#include "llframetimer.h"
#include "llviewertexture.h"
class LLComboBox;
class LLImageRaw;
class LLFloaterOutfitPhotoPreview : public LLPreview
{
public:
LLFloaterOutfitPhotoPreview(const LLSD& key);
~LLFloaterOutfitPhotoPreview();
virtual void draw();
virtual void loadAsset();
virtual EAssetStatus getAssetStatus();
virtual void reshape(S32 width, S32 height, BOOL called_from_parent = TRUE);
/*virtual*/ void setObjectID(const LLUUID& object_id);
void setOutfitID(const LLUUID& outfit_id);
void onOkBtn();
void onCancelBtn();
protected:
void init();
/* virtual */ BOOL postBuild();
private:
void updateImageID(); // set what image is being uploaded.
void updateDimensions();
LLUUID mImageID;
LLUUID mOutfitID;
LLPointer<LLViewerFetchedTexture> mImage;
S32 mImageOldBoostLevel;
// This is stored off in a member variable, because the save-as
// button and drag and drop functionality need to know.
BOOL mUpdateDimensions;
BOOL mExceedLimits;
LLLoadedCallbackEntry::source_callback_list_t mCallbackTextureList ;
};
#endif // LL_LLFLOATEROUTFITPHOTOPREVIEW_H

View File

@ -41,6 +41,7 @@
#include "llfloateropenobject.h"
#include "llfloaterreg.h"
#include "llfloatermarketplacelistings.h"
#include "llfloateroutfitphotopreview.h"
#include "llfloatersidepanelcontainer.h"
#include "llfloaterworldmap.h"
#include "llfolderview.h"
@ -4783,7 +4784,7 @@ static BOOL can_move_to_outfit(LLInventoryItem* inv_item, BOOL move_is_into_curr
if((inv_type == LLInventoryType::IT_TEXTURE) || (inv_type == LLInventoryType::IT_SNAPSHOT))
{
return TRUE;
return !move_is_into_current_outfit;
}
if (move_is_into_current_outfit && get_is_item_worn(inv_item->getUUID()))
@ -4838,9 +4839,15 @@ void LLFolderBridge::dropToOutfit(LLInventoryItem* inv_item, BOOL move_is_into_c
{
if((inv_item->getInventoryType() == LLInventoryType::IT_TEXTURE) || (inv_item->getInventoryType() == LLInventoryType::IT_SNAPSHOT))
{
LLAppearanceMgr::instance().removeOutfitPhoto(mUUID);
LLPointer<LLInventoryCallback> cb = NULL;
link_inventory_object(mUUID, LLConstPointer<LLInventoryObject>(inv_item), cb);
const LLUUID &my_outifts_id = getInventoryModel()->findCategoryUUIDForType(LLFolderType::FT_MY_OUTFITS, false);
if(mUUID != my_outifts_id)
{
LLFloaterOutfitPhotoPreview* photo_preview = LLFloaterReg::showTypedInstance<LLFloaterOutfitPhotoPreview>("outfit_photo_preview", inv_item->getUUID());
if(photo_preview)
{
photo_preview->setOutfitID(mUUID);
}
}
return;
}

View File

@ -42,6 +42,7 @@
#include "llpanelwearing.h"
#include "llsaveoutfitcombobtn.h"
#include "llsidepanelappearance.h"
#include "llviewercontrol.h"
#include "llviewerfoldertype.h"
static const std::string OUTFITS_TAB_NAME = "outfitslist_tab";
@ -70,6 +71,11 @@ LLPanelOutfitsInventory::LLPanelOutfitsInventory() :
LLPanelOutfitsInventory::~LLPanelOutfitsInventory()
{
if (mAppearanceTabs)
{
gSavedSettings.setS32("LastAppearanceTab", mAppearanceTabs->getCurrentPanelIndex());
}
// <FS:Ansariel> FIRE-17626: Attachment count in appearance floater
if (gInventory.containsObserver(mCategoriesObserver))
{
@ -97,6 +103,9 @@ BOOL LLPanelOutfitsInventory::postBuild()
mSaveComboBtn.reset(new LLSaveOutfitComboBtn(this, true));
if (!mAppearanceTabs->selectTab(gSavedSettings.getS32("LastAppearanceTab")))
mAppearanceTabs->selectFirstTab();
return TRUE;
}

View File

@ -1084,7 +1084,7 @@ void LLPanelPeople::updateButtons()
// <FS:Ansariel> Fix warning about missing gear button on blocklist panel
//if (!group_tab_active)
if (!group_tab_active && cur_tab != BLOCKED_TAB_NAME)
if (!group_tab_active && !nearby_tab_active && cur_tab != BLOCKED_TAB_NAME)
// </FS:Ansariel>
{
cur_panel->getChildView("gear_btn")->setEnabled(multiple_selected);

View File

@ -28,6 +28,7 @@
#include "llbutton.h"
#include "llnotifications.h"
#include "lltoastscriptquestion.h"
#include "llviewercontrol.h"
const int LEFT_PAD = 10;
const int BUTTON_HEIGHT = 27;
@ -132,7 +133,10 @@ void LLToastScriptQuestion::createButtons()
buttons_width += rect.getWidth() + LEFT_PAD;
if (form_element.has("default") && form_element["default"].asBoolean())
// <FS:Ansariel> FIRE-20064: Option to restore debit permission default to allow
//if (form_element.has("default") && form_element["default"].asBoolean())
if (form_element.has("default") && form_element["default"].asBoolean() && (mNotification->getName() != "ScriptQuestionCaution" || gSavedSettings.getBOOL("FSPermissionDebitDefaultDeny")))
// </FS:Ansariel>
{
button->setFocus(TRUE);
setDefaultBtn(button);

View File

@ -274,8 +274,8 @@ bool LLToolMgr::canEdit()
bool LLToolMgr::buildEnabledOrActive()
{
// <FS:Ansariel> RLVa check
//return inEdit() || canEdit();
return inEdit() || RlvUIEnabler::isBuildEnabled();
//return LLFloaterReg::instanceVisible("build") || canEdit();
return LLFloaterReg::instanceVisible("build") || RlvUIEnabler::isBuildEnabled();
// </FS:Ansariel>
}

View File

@ -93,6 +93,7 @@
#include "llfloaternotificationstabbed.h"
#include "llfloaterobjectweights.h"
#include "llfloateropenobject.h"
#include "llfloateroutfitphotopreview.h"
#include "llfloateroutfitsnapshot.h"
#include "llfloaterpathfindingcharacters.h"
#include "llfloaterpathfindingconsole.h"
@ -340,6 +341,7 @@ void LLViewerFloaterReg::registerFloaters()
LLFloaterReg::add("object_weights", "floater_object_weights.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterObjectWeights>);
LLFloaterReg::add("openobject", "floater_openobject.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterOpenObject>);
LLFloaterReg::add("outgoing_call", "floater_outgoing_call.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLOutgoingCallDialog>);
LLFloaterReg::add("outfit_photo_preview", "floater_outfit_photo_preview.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterOutfitPhotoPreview>);
LLFloaterPayUtil::registerFloater();
LLFloaterReg::add("pathfinding_characters", "floater_pathfinding_characters.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterPathfindingCharacters>);

View File

@ -0,0 +1,17 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<floater name="outfit_photo_preview">
<floater.string name="Title">
Textur: [NAME]
</floater.string>
<floater.string name="exceed_limits">
Max. Outfit-Fotogröße ist [MAX_WIDTH]*[MAX_HEIGHT]. Bitte andere Textur auswählen.
</floater.string>
<floater.string name="photo_confirmation">
Diese Textur als Outfit-Foto für [OUTFIT] verwenden?
</floater.string>
<text name="dimensions">
[WIDTH]px x [HEIGHT]px
</text>
<button label="OK" name="ok_btn"/>
<button label="Abbrechen" name="cancel_btn"/>
</floater>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<floater
legacy_header_height="18"
positioning="centered"
can_resize="false"
height="325"
layout="topleft"
name="outfit_photo_preview"
help_topic="preview_texture"
width="410">
<floater.string
name="Title">
Texture: [NAME]
</floater.string>
<floater.string
name="exceed_limits">
Max outfit photo size is [MAX_WIDTH]*[MAX_HEIGHT]. Please select another texture.
</floater.string>
<floater.string
name="photo_confirmation">
Set this as Outfit Photo for [OUTFIT]?
</floater.string>
<text
type="string"
halign="right"
length="1"
follows="right|bottom"
height="16"
layout="topleft"
left="110"
name="dimensions"
top="255"
width="200">
[WIDTH]px x [HEIGHT]px
</text>
<text
type="string"
follows="left|top"
height="16"
layout="topleft"
name="notification"
left="25"
halign="center"
top_pad="5"
width="360">
</text>
<button
follows="right|bottom"
height="22"
label="OK"
layout="topleft"
name="ok_btn"
top_pad="5"
right="-115"
top_delta="0"
width="90" />
<button
follows="right|bottom"
height="22"
label="Cancel"
layout="topleft"
name="cancel_btn"
right="-20"
top_delta="0"
width="90" />
</floater>

View File

@ -1804,9 +1804,9 @@ Hover your mouse cursor over UUID field to show its default value.
left="5"
height="14"
width="150"
tool_tip="Sound UUID played on incoming conference instant message. This setting is shared with Chat &gt; Notifications &gt; 'When receiving AdHoc Instant Messages'."
tool_tip="Sound UUID played on incoming conference instant message. This setting is shared with Chat &gt; Notifications &gt; 'When receiving ad-hoc Instant Messages'."
name="textFSNewConferenceIncomingIMSession">
AdHoc Instant Message:
Ad-hoc Instant Message:
</text>
<line_editor
follows="left|top"

View File

@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<floater name="outfit_photo_preview">
<floater.string name="Title">
Tekstura: [NAME]
</floater.string>
<floater.string name="exceed_limits">
Maks. rozmiar zdjęcia stroju to [MAX_WIDTH]*[MAX_HEIGHT]. Wybierz inną teksturę.
</floater.string>
<floater.string name="photo_confirmation">
Ustawić to zdjęcie dla stroju [OUTFIT]?
</floater.string>
<button label="Anuluj" name="cancel_btn" />
</floater>