Merge remote-tracking branch 'origin/master'

meow-7.2.2
Beq 2024-09-19 22:27:56 +01:00
commit 4646b6dd4a
8 changed files with 124 additions and 42 deletions

View File

@ -144,7 +144,6 @@ void LLPanelInventoryListItemBase::addWidgetToRightSide(const std::string& name,
void LLPanelInventoryListItemBase::addWidgetToRightSide(LLUICtrl* ctrl, bool show_widget/* = true*/)
{
if (ctrl == nullptr)return; // <FS:Beq/> avoid crash if ctrl is null
mRightSideWidgets.push_back(ctrl);
setShowWidget(ctrl, show_widget);
}

View File

@ -116,16 +116,10 @@ bool LLPanelWearableOutfitItem::postBuild()
LLPanelWearableListItem::postBuild();
//if(mShowWidgets) // <FS:Ansariel> Make Add/Remove buttons work
if(mShowWidgets)
{
// <FS:Ansariel> Make Add/Remove buttons work
//addWidgetToRightSide(mAddWearableBtn);
//addWidgetToRightSide(mAddWearableBtn);
LLViewerInventoryItem* inv_item = getItem();
mShowWidgets &= (inv_item->getType() != LLAssetType::AT_BODYPART);
addWidgetToRightSide(mAddWearableBtn, mShowWidgets);
addWidgetToRightSide(mAddWearableBtn, mShowWidgets);
// </FS:Ansariel>
addWidgetToRightSide(mAddWearableBtn);
addWidgetToRightSide(mRemoveWearableBtn);
mAddWearableBtn->setClickedCallback(boost::bind(&LLPanelWearableOutfitItem::onAddWearable, this));
mRemoveWearableBtn->setClickedCallback(boost::bind(&LLPanelWearableOutfitItem::onRemoveWearable, this));
@ -192,7 +186,6 @@ LLPanelWearableOutfitItem::LLPanelWearableOutfitItem(LLViewerInventoryItem* item
: LLPanelWearableListItem(item, params)
, mWornIndicationEnabled(worn_indication_enabled)
, mShowWidgets(show_widgets)
, mIsWorn(false) // <FS:Ansariel> Make Add/Remove buttons work
{
if(mShowWidgets)
{
@ -217,8 +210,6 @@ void LLPanelWearableOutfitItem::updateItem(const std::string& name,
// an inventory observer upon link in COF beind added or removed so actual
// worn status of a linked item may still remain unchanged.
bool is_worn = LLAppearanceMgr::instance().isLinkedInCOF(mInventoryItemUUID);
// <FS:Ansariel> Make Add/Remove buttons work
mIsWorn = is_worn;
// <FS:Ansariel> Better attachment list
//if (mWornIndicationEnabled && is_worn)
//{
@ -261,13 +252,10 @@ void LLPanelWearableOutfitItem::updateItem(const std::string& name,
{
setShowWidget(mAddWearableBtn, !is_worn);
// <FS:Ansariel> Make Add/Remove buttons work
//// Body parts can't be removed, only replaced
//LLViewerInventoryItem* inv_item = getItem();
//bool show_remove = is_worn && inv_item && (inv_item->getType() != LLAssetType::AT_BODYPART);
//setShowWidget("remove_wearable", show_remove);
setShowWidget(mRemoveWearableBtn, is_worn);
// </FS:Ansariel>
// Body parts can't be removed, only replaced
LLViewerInventoryItem* inv_item = getItem();
bool show_remove = is_worn && inv_item && (inv_item->getType() != LLAssetType::AT_BODYPART);
setShowWidget(mRemoveWearableBtn, show_remove);
if(mHovered)
{
@ -555,7 +543,7 @@ FSPanelCOFWearableOutfitListItem::FSPanelCOFWearableOutfitListItem(LLViewerInven
bool show_widgets,
const FSPanelCOFWearableOutfitListItem::Params& params)
: LLPanelWearableOutfitItem(item, worn_indication_enabled, params, show_widgets)
, mWeightCtrl(NULL)
, mWeightCtrl(nullptr)
{
LLTextBox::Params weight_params = params.item_weight;
applyXUILayout(weight_params, this);
@ -576,7 +564,8 @@ bool FSPanelCOFWearableOutfitListItem::postBuild()
// Reserve space for 'delete' button event if it is invisible.
setRightWidgetsWidth(mWeightCtrl->getRect().getWidth() + 5);
setWidgetsVisible(true);
mWeightCtrl->setVisible(true);
reshapeWidgets();
return true;
@ -597,19 +586,7 @@ void FSPanelCOFWearableOutfitListItem::updateItemWeight(U32 item_weight)
void FSPanelCOFWearableOutfitListItem::updateItem(const std::string& name, EItemState item_state)
{
LLPanelWearableOutfitItem::updateItem(name, item_state);
setShowWidget("add_wearable", false);
setShowWidget("remove_wearable", mShowWidgets && mIsWorn && mHovered);
setWidgetsVisible(true);
reshapeWidgets();
}
//virtual
void FSPanelCOFWearableOutfitListItem::onMouseEnter(S32 x, S32 y, MASK mask)
{
LLPanelInventoryListItemBase::onMouseEnter(x, y, mask);
setShowWidget("remove_wearable", mShowWidgets && mIsWorn);
setWidgetsVisible(true);
mWeightCtrl->setVisible(true);
reshapeWidgets();
}
@ -617,8 +594,8 @@ void FSPanelCOFWearableOutfitListItem::onMouseEnter(S32 x, S32 y, MASK mask)
void FSPanelCOFWearableOutfitListItem::onMouseLeave(S32 x, S32 y, MASK mask)
{
LLPanelInventoryListItemBase::onMouseLeave(x, y, mask);
setShowWidget("remove_wearable", false);
setWidgetsVisible(true);
setWidgetsVisible(false);
mWeightCtrl->setVisible(true); // setWidgetsVisible sets this invisible - make it visible again
reshapeWidgets();
}

View File

@ -107,11 +107,7 @@ private:
LLButton* mAddWearableBtn = nullptr;
LLButton* mRemoveWearableBtn = nullptr;
bool mWornIndicationEnabled;
// <FS:Ansariel> Make Add/Remove buttons work
protected:
bool mShowWidgets;
bool mIsWorn;
// </FS:Ansariel>
};
class LLPanelDeletableWearableListItem : public LLPanelWearableListItem
@ -259,7 +255,6 @@ public:
/*virtual*/ void updateItem(const std::string& name, EItemState item_state = IS_DEFAULT);
/*virtual*/ void onMouseEnter(S32 x, S32 y, MASK mask);
/*virtual*/ void onMouseLeave(S32 x, S32 y, MASK mask);
protected:

View File

@ -59,6 +59,7 @@
width="70" />
<add_btn
name="add_wearable"
visible="false"
layout="topleft"
follows="top|right"
image_unselected="Add_Icon"
@ -70,6 +71,7 @@
tab_stop="false" />
<remove_btn
name="remove_wearable"
visible="false"
layout="topleft"
follows="top|right"
image_unselected="Remove_Icon"

View File

@ -0,0 +1,33 @@
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<floater name="bulk_upload">
<layout_stack name="maint_layout">
<layout_panel name="count_panel">
<text name="number_of_items">
Éléments à envoyer : [COUNT]
</text>
</layout_panel>
<layout_panel name="warning_panel">
<text name="textures_2k_warning">
Par défaut, une ou plusieurs textures seront mises à l'échelle à 2048px.
</text>
</layout_panel>
<layout_panel name="checkbox_panel">
<check_box label="Mettre à l'échelle les textures jusqu'à un maximum de 1024px" name="upload_2k" />
</layout_panel>
<layout_panel name="cost_panel">
<text name="upload_cost">
Coût : [COST]L$
</text>
</layout_panel>
<layout_panel name="buttoms_panel">
<button label="Envoyer" name="upload_btn" />
<button label="Annuler" name="cancel_btn" />
</layout_panel>
<layout_panel name="link_panel">
<text name="new_folder_textbox">
Comment les textures envoyées sont mises à l'échelle :
https://wiki.secondlife.com/wiki/Limits#All_Viewers
</text>
</layout_panel>
</layout_stack>
</floater>

View File

@ -0,0 +1,24 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<floater name="gltf asset editor">
<floater.string name="floater_title" value="Éditeur de scènes GLTF" />
<floater.string name="scene_tittle" value="Scène" />
<floater.string name="node_tittle" value="Nœud" />
<floater.string name="mesh_tittle" value="Mesh" />
<floater.string name="skin_tittle" value="Peau" />
<layout_stack name="main_layout">
<layout_panel name="transforms_panel">
<menu_button name="clipboard_pos_btn" tool_tip="Options de collage" />
<text name="label position" tool_tip="Position (mètres)">
Position (m)
</text>
<menu_button name="clipboard_size_btn" tool_tip="Options de collage" />
<text name="label size" tool_tip="Taille (mètres)">
Taille (m)
</text>
<menu_button name="clipboard_rot_btn" tool_tip="Options de collage" />
<text name="label rotation" tool_tip="Rotation (degrés)">
Rotation (°)
</text>
</layout_panel>
</layout_stack>
</floater>

View File

@ -0,0 +1,39 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<floater name="floater_region_restart_schedule">
<text name="days_general">
Redémarrer la région ces jours-ci :
</text>
<check_box name="s_chk" tool_tip="Dimanche" />
<check_box name="m_chk" tool_tip="Lundi" />
<check_box name="t_chk" tool_tip="Mardi" />
<check_box name="w_chk" tool_tip="Mercredi" />
<check_box name="r_chk" tool_tip="Jeudi" />
<check_box name="f_chk" tool_tip="Vendredi" />
<check_box name="a_chk" tool_tip="Samedi" />
<text name="su_label">
Di
</text>
<text name="mo_label">
Lu
</text>
<text name="tu_label">
Ma
</text>
<text name="we_label">
Me
</text>
<text name="th_label">
Je
</text>
<text name="fr_label">
Ve
</text>
<text name="sa_label">
Sa
</text>
<text name="at_label">
à
</text>
<button name="save_btn" label="Enregistrer" />
<button name="cancel_btn" label="Annuler" />
</floater>

View File

@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<floater name="settings_color" title="Paramètres de couleur">
<filter_editor label="Texte à chercher" name="filter_input" />
<scroll_list name="setting_list">
<scroll_list.columns label="Couleur" name="color" />
</scroll_list>
<text name="color_name_txt">
Nom de la couleur
</text>
<spinner label="Alpha" name="alpha_spinner" />
<button label="Rétablir les valeurs par défaut" name="default_btn" />
<check_box label="Afficher uniquement les modifications" name="hide_default" />
</floater>