Solve Issue 1755: Change Appearance Save button to a flyout option, and move File->Update Outfit
Update Outfit is now at the bottom of the inventory's File menu.
This commit is contained in:
@@ -38,6 +38,7 @@
|
||||
#include "llagentcamera.h"
|
||||
#include "llagentwearables.h"
|
||||
#include "llappearancemgr.h"
|
||||
#include "llflyoutbutton.h"
|
||||
#include "llmakeoutfitdialog.h"
|
||||
#include "llmorphview.h"
|
||||
#include "llnotificationsutil.h"
|
||||
@@ -154,11 +155,9 @@ LLFloaterCustomize::~LLFloaterCustomize()
|
||||
// virtual
|
||||
BOOL LLFloaterCustomize::postBuild()
|
||||
{
|
||||
mMakeOutfitBtn = getChild<LLUICtrl>("Make Outfit");
|
||||
getChild<LLUICtrl>("Make Outfit")->setCommitCallback(boost::bind(&LLFloaterCustomize::onBtnMakeOutfit, this));
|
||||
mSaveOutfitBtn = getChild<LLUICtrl>("Save Outfit");
|
||||
mSaveOutfitBtn->setCommitCallback(boost::bind(&LLAppearanceMgr::updateBaseOutfit, LLAppearanceMgr::getInstance()));
|
||||
refreshCurrentOutfitName(); // Initialize tooltip for save outfit button
|
||||
mMakeOutfitBtn = getChild<LLFlyoutButton>("Make Outfit");
|
||||
mMakeOutfitBtn->setCommitCallback(boost::bind(&LLFloaterCustomize::onBtnMakeOutfit, this, _2));
|
||||
refreshCurrentOutfitName(); // Initialize flyout list entry for save outfit
|
||||
getChild<LLUICtrl>("Ok")->setCommitCallback(boost::bind(&LLFloaterCustomize::onBtnOk, this));
|
||||
getChild<LLUICtrl>("Cancel")->setCommitCallback(boost::bind(&LLFloater::onClickClose, this));
|
||||
|
||||
@@ -201,11 +200,11 @@ BOOL LLFloaterCustomize::postBuild()
|
||||
void LLFloaterCustomize::refreshCurrentOutfitName(const std::string& name)
|
||||
{
|
||||
// Set current outfit status (wearing/unsaved).
|
||||
bool dirty = LLAppearanceMgr::getInstance()->isOutfitDirty();
|
||||
//bool dirty = LLAppearanceMgr::getInstance()->isOutfitDirty();
|
||||
//std::string cof_status_str = getString(dirty ? "Unsaved Changes" : "Now Wearing");
|
||||
//mOutfitStatus->setText(cof_status_str);
|
||||
mSaveOutfitBtn->setEnabled(dirty); // No use saving unless dirty
|
||||
|
||||
mMakeOutfitBtn->remove(0);
|
||||
if (name.empty())
|
||||
{
|
||||
std::string outfit_name;
|
||||
@@ -214,22 +213,21 @@ void LLFloaterCustomize::refreshCurrentOutfitName(const std::string& name)
|
||||
//mCurrentLookName->setText(outfit_name);
|
||||
LLStringUtil::format_map_t args;
|
||||
args["[OUTFIT]"] = outfit_name;
|
||||
mSaveOutfitBtn->setToolTip(getString("Save changes to", args));
|
||||
mMakeOutfitBtn->add(getString("Save changes to", args), true);
|
||||
return;
|
||||
}
|
||||
|
||||
std::string string_name = gAgentWearables.isCOFChangeInProgress() ? "Changing outfits" : "No Outfit";
|
||||
//mCurrentLookName->setText(getString(string_name));
|
||||
mSaveOutfitBtn->setToolTip(getString(string_name));
|
||||
mMakeOutfitBtn->add(getString(string_name), false);
|
||||
//mOpenOutfitBtn->setEnabled(FALSE);
|
||||
mSaveOutfitBtn->setEnabled(false); // Can't save right now
|
||||
}
|
||||
else
|
||||
{
|
||||
//mCurrentLookName->setText(name);
|
||||
LLStringUtil::format_map_t args;
|
||||
args["[OUTFIT]"] = name;
|
||||
mSaveOutfitBtn->setToolTip(getString("Save changes to", args));
|
||||
mMakeOutfitBtn->add(getString("Save changes to", args), true);
|
||||
// Can't just call update verbs since the folder link may not have been created yet.
|
||||
//mOpenOutfitBtn->setEnabled(TRUE);
|
||||
}
|
||||
@@ -539,9 +537,12 @@ void LLFloaterCustomize::onBtnOk()
|
||||
close(false);
|
||||
}
|
||||
|
||||
void LLFloaterCustomize::onBtnMakeOutfit()
|
||||
void LLFloaterCustomize::onBtnMakeOutfit(const LLSD& val)
|
||||
{
|
||||
new LLMakeOutfitDialog(true); // LLMakeOutfitDialog deletes itself.
|
||||
if (val && LLAppearanceMgr::instance().isOutfitDirty()) // No use saving unless dirty
|
||||
LLAppearanceMgr::instance().updateBaseOutfit();
|
||||
else
|
||||
new LLMakeOutfitDialog(true); // LLMakeOutfitDialog deletes itself.
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
@@ -99,7 +99,7 @@ public:
|
||||
private:
|
||||
// Callbacks
|
||||
void onBtnOk();
|
||||
void onBtnMakeOutfit();
|
||||
void onBtnMakeOutfit(const LLSD& val);
|
||||
void onBtnImport();
|
||||
void onBtnImport_continued(AIFilePicker* filepicker);
|
||||
void onBtnExport();
|
||||
@@ -120,7 +120,7 @@ private:
|
||||
LLScrollingPanelList* mScrollingPanelList;
|
||||
LLScrollContainer* mScrollContainer;
|
||||
LLView *mMetricHeight, *mImperialHeight;
|
||||
LLUICtrl *mMakeOutfitBtn, *mSaveOutfitBtn;
|
||||
class LLFlyoutButton* mMakeOutfitBtn;
|
||||
LLTabContainer* mTabContainer;
|
||||
LLPointer<LLVisualParamReset> mResetParams;
|
||||
|
||||
|
||||
@@ -398,8 +398,7 @@ und dieses anziehen.</text>
|
||||
<button name="Export" label="Exportieren" tool_tip="Exportiere das gewählte Kleidungsteil; das Kleidungsteil muss copy/mod/trans sein, und sie müssen der Ersteller sein."/>
|
||||
<button label="Abbrechen" label_selected="Abbrechen" name="Cancel"/>
|
||||
<button label="OK" label_selected="OK" name="Ok"/>
|
||||
<button label="Outfit erstellen..." label_selected="Outfit erstellen..." name="Make Outfit"/>
|
||||
<button name="Save Outfit" label="Outfit speichern"/>
|
||||
<flyout_button label="Outfit erstellen..." label_selected="Outfit erstellen..." name="Make Outfit"/>
|
||||
<string name="Save changes to" value="Änderungen zu [OUTFIT] speichern"/>
|
||||
<string name="No Outfit" value="Kein Outfit"/>
|
||||
<string name="Changing outfits" value="Outfits ändern"/>
|
||||
|
||||
@@ -45,7 +45,6 @@
|
||||
<menu_bar name="Inventory Menu">
|
||||
<menu label="Datei" name="File">
|
||||
<menu_item_call label="Öffnen" name="Open"/>
|
||||
<menu_item_call label="Outfit aktualisieren" name="Update Outfit"/>
|
||||
|
||||
<menu_item_call label="Neues Fenster" name="New Window"/>
|
||||
|
||||
@@ -55,6 +54,7 @@
|
||||
|
||||
<menu_item_call label="Papierkorb ausleeren" name="Empty Trash"/>
|
||||
<menu_item_call label="Inventar aktualisieren" name="Refresh Inventory"/>
|
||||
<menu_item_call label="Outfit aktualisieren" name="Update Outfit"/>
|
||||
</menu>
|
||||
<menu label="Erstellen" name="Create">
|
||||
<menu_item_call label="Neuer Ordner" name="New Folder"/>
|
||||
|
||||
@@ -1445,11 +1445,10 @@ one from scratch and wear it.
|
||||
<button bottom="-536" follows="right|bottom" font="SansSerif" halign="center"
|
||||
height="20" label="OK" label_selected="OK" mouse_opaque="true"
|
||||
name="Ok" right="-116" scale_image="true" width="100" />
|
||||
<button bottom="-536" follows="left|bottom" font="SansSerif" halign="center"
|
||||
<flyout_button bottom="-536" follows="left|bottom" font="SansSerif" halign="center"
|
||||
height="20" label="Make Outfit..." label_selected="Make Outfit..."
|
||||
mouse_opaque="true" name="Make Outfit" left="10" scale_image="true"
|
||||
width="100" />
|
||||
<button bottom="-536" follows="left|bottom" height="20" left="110" width="100" name="Save Outfit" label="Save Outfit"/>
|
||||
width="120" />
|
||||
<string name="Save changes to" value="Save changes to [OUTFIT]"/>
|
||||
<string name="No Outfit" value="No Outfit"/>
|
||||
<string name="Changing outfits" value="Changing outfits"/>
|
||||
|
||||
@@ -72,9 +72,6 @@
|
||||
name="Open" width="128">
|
||||
<on_click filter="" function="Inventory.DoToSelected" userdata="open" />
|
||||
</menu_item_call>
|
||||
<menu_item_call label="Update Outfit" mouse_opaque="true" name="Update Outfit">
|
||||
<on_click filter="" function="Inventory.DoCreate" userdata="update outfit"/>
|
||||
</menu_item_call>
|
||||
<menu_item_separator bottom_delta="-8" height="8" left="0" mouse_opaque="true" name="separator"
|
||||
width="128" />
|
||||
<menu_item_call bottom_delta="-18" height="18" label="New Window" left="0" mouse_opaque="true"
|
||||
@@ -105,6 +102,9 @@
|
||||
name="Refresh Inventory" width="128">
|
||||
<on_click filter="" function="Inventory.RefreshInvModel" userdata="" />
|
||||
</menu_item_call>
|
||||
<menu_item_call label="Update Outfit" name="Update Outfit">
|
||||
<on_click function="Inventory.DoCreate" userdata="update outfit"/>
|
||||
</menu_item_call>
|
||||
</menu>
|
||||
<menu bottom_delta="80" drop_shadow="true" height="121"
|
||||
label="Create" left="0" mouse_opaque="false" name="Create" opaque="true"
|
||||
|
||||
@@ -648,8 +648,7 @@ una nueva y vistiéndotela.
|
||||
<button name="Export" label="Exportar" tool_tip="Export currently selected wearable; asset must be copy/mod/trans and you need to be the creator"/>
|
||||
<button label="Cancelar" label_selected="Cancelar" name="Cancel"/>
|
||||
<button label="OK" label_selected="OK" name="Ok"/>
|
||||
<button label="Hacer Vestuario..." label_selected="Hacer Vestuario..." name="Make Outfit" width="120"/>
|
||||
<button name="Save Outfit" label="Guardar Vestuario" left="140" width="120"/>
|
||||
<flyout_button label="Hacer Vestuario..." label_selected="Hacer Vestuario..." name="Make Outfit" width="140"/>
|
||||
<string name="Save changes to" value="Guardar cambios en [OUTFIT]"/>
|
||||
<string name="No Outfit" value="No hay vestuario"/>
|
||||
<string name="Changing outfits" value="Cambiar de vestuario"/>
|
||||
|
||||
@@ -98,13 +98,13 @@
|
||||
<menu_bar name="Inventory Menu">
|
||||
<menu label="Archivo" name="File">
|
||||
<menu_item_call label="Abrir" name="Open"/>
|
||||
<menu_item_call label="Actualizar Vestuario" name="Update Outfit"/>
|
||||
<menu_item_call label="Nueva Ventana" name="New Window"/>
|
||||
<menu_item_call label="Mostrar Filtros" name="Show Filters"/>
|
||||
<menu_item_call label="Restablecer Filtros" name="Reset Current"/>
|
||||
<menu_item_call label="Cerrar todas las Carpetas" name="Close All Folders"/>
|
||||
<menu_item_call label="Vaciar la Papelera" name="Empty Trash"/>
|
||||
<menu_item_call label="Actualizar Inventario" name="Refresh Inventory"/>
|
||||
<menu_item_call label="Actualizar Vestuario" name="Update Outfit"/>
|
||||
</menu>
|
||||
<menu label="Crear" name="Create">
|
||||
<menu_item_call label="Nueva Carpeta" name="New Folder"/>
|
||||
|
||||
@@ -485,8 +485,7 @@ inventaire. Vous pouvez aussi en créer une nouvelle et la porter.
|
||||
<button name="Export" label="Exporter"/>
|
||||
<button label="Annuler" label_selected="Annuler" name="Cancel"/>
|
||||
<button label="OK" label_selected="OK" name="Ok"/>
|
||||
<button label="Créer un ensemble" label_selected="Créer un ensemble" name="Make Outfit" left="200" width="125"/>
|
||||
<button left="90" name="Save Outfit" label="sauvegarder"/>
|
||||
<flyout_button label="Créer un ensemble" label_selected="Créer un ensemble" name="Make Outfit" left="200" width="145"/>
|
||||
<string name="No Outfit" value="Aucune tenue"/>
|
||||
<string name="Changing outfits" value="Changement de tenue"/>
|
||||
</floater>
|
||||
|
||||
@@ -468,5 +468,5 @@ In alternativa, puoi crearne una nuova da zero ed indossarla.
|
||||
<scroll_container left="254" name="panel_container"/>
|
||||
<button label="Annulla" label_selected="Annulla" name="Cancel"/>
|
||||
<button label="OK" label_selected="OK" name="Ok"/>
|
||||
<button label="Crea Outfit..." label_selected="Crea Outfit..." name="Make Outfit"/>
|
||||
<flyout_button label="Crea Outfit..." label_selected="Crea Outfit..." name="Make Outfit"/>
|
||||
</floater>
|
||||
|
||||
@@ -479,7 +479,7 @@ partir de um esboço e usá-lo.
|
||||
<scroll_container left="249" name="panel_container"/>
|
||||
<button label="Cancelar" label_selected="Cancelar" name="Cancel"/>
|
||||
<button label="OK" label_selected="OK" name="Ok"/>
|
||||
<button label="Criar Vestimenta..." label_selected="Criar Vestimenta..." name="Make Outfit" left="117" width="125" />
|
||||
<flyout_button label="Criar Vestimenta..." label_selected="Criar Vestimenta..." name="Make Outfit" left="117" width="145" />
|
||||
<string name="No Outfit" value="Nenhum"/>
|
||||
<string name="Changing outfits" value="Mudando de look"/>
|
||||
</floater>
|
||||
|
||||
Reference in New Issue
Block a user