Merge branch 'master' of git://github.com/Lirusaito/SingularityViewer
This commit is contained in:
@@ -106,7 +106,7 @@ namespace HACD
|
|||||||
m_nMaxNodes = 0;
|
m_nMaxNodes = 0;
|
||||||
for(size_t k = 0; k < maxDepth; k++)
|
for(size_t k = 0; k < maxDepth; k++)
|
||||||
{
|
{
|
||||||
m_nMaxNodes += (1 << maxDepth);
|
m_nMaxNodes += (static_cast<size_t>(1) << maxDepth);
|
||||||
}
|
}
|
||||||
m_nodes = new RMNode[m_nMaxNodes];
|
m_nodes = new RMNode[m_nMaxNodes];
|
||||||
RMNode & root = m_nodes[AddNode()];
|
RMNode & root = m_nodes[AddNode()];
|
||||||
|
|||||||
@@ -60,10 +60,36 @@ const F32 SOUND_GAIN = 1.0f;
|
|||||||
|
|
||||||
LLPreviewSound::LLPreviewSound(const std::string& name, const LLRect& rect, const std::string& title, const LLUUID& item_uuid, const LLUUID& object_uuid) :
|
LLPreviewSound::LLPreviewSound(const std::string& name, const LLRect& rect, const std::string& title, const LLUUID& item_uuid, const LLUUID& object_uuid) :
|
||||||
LLPreview( name, rect, title, item_uuid, object_uuid)
|
LLPreview( name, rect, title, item_uuid, object_uuid)
|
||||||
|
, mIsCopyable(false)
|
||||||
{
|
{
|
||||||
|
|
||||||
LLUICtrlFactory::getInstance()->buildFloater(this,"floater_preview_sound.xml");
|
LLUICtrlFactory::getInstance()->buildFloater(this,"floater_preview_sound.xml");
|
||||||
|
|
||||||
|
setTitle(title);
|
||||||
|
|
||||||
|
if (!getHost())
|
||||||
|
{
|
||||||
|
LLRect curRect = getRect();
|
||||||
|
translate(rect.mLeft - curRect.mLeft, rect.mTop - curRect.mTop);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// virtual
|
||||||
|
BOOL LLPreviewSound::postBuild()
|
||||||
|
{
|
||||||
|
const LLInventoryItem* item = getItem();
|
||||||
|
if (item)
|
||||||
|
{
|
||||||
|
getChild<LLUICtrl>("desc")->setValue(item->getDescription());
|
||||||
|
mIsCopyable = (item->getPermissions().getCreator() == gAgentID);
|
||||||
|
if (gAudiop)
|
||||||
|
// <edit>
|
||||||
|
// that thing above doesn't actually start a sound transfer, so I will do it
|
||||||
|
if (LLAudioSource* asp = gAgentAvatarp->getAudioSource(gAgentID))
|
||||||
|
asp->preload(item->getAssetUUID()); // preload the sound
|
||||||
|
// </edit>
|
||||||
|
}
|
||||||
|
|
||||||
childSetAction("Sound play btn",&LLPreviewSound::playSound,this);
|
childSetAction("Sound play btn",&LLPreviewSound::playSound,this);
|
||||||
childSetAction("Sound audition btn",&LLPreviewSound::auditionSound,this);
|
childSetAction("Sound audition btn",&LLPreviewSound::auditionSound,this);
|
||||||
// <edit>
|
// <edit>
|
||||||
@@ -77,40 +103,10 @@ LLPreviewSound::LLPreviewSound(const std::string& name, const LLRect& rect, cons
|
|||||||
button = getChild<LLButton>("Sound audition btn");
|
button = getChild<LLButton>("Sound audition btn");
|
||||||
button->setSoundFlags(LLView::SILENT);
|
button->setSoundFlags(LLView::SILENT);
|
||||||
|
|
||||||
const LLInventoryItem* item = getItem();
|
|
||||||
|
|
||||||
mIsCopyable = false;
|
|
||||||
if(item)
|
|
||||||
{
|
|
||||||
const LLPermissions& perm = item->getPermissions();
|
|
||||||
mIsCopyable = (perm.getCreator() == gAgent.getID());
|
|
||||||
}
|
|
||||||
|
|
||||||
childSetCommitCallback("desc", LLPreview::onText, this);
|
childSetCommitCallback("desc", LLPreview::onText, this);
|
||||||
childSetText("desc", item->getDescription());
|
|
||||||
getChild<LLLineEditor>("desc")->setPrevalidate(&LLLineEditor::prevalidatePrintableNotPipe);
|
getChild<LLLineEditor>("desc")->setPrevalidate(&LLLineEditor::prevalidatePrintableNotPipe);
|
||||||
|
|
||||||
// preload the sound
|
|
||||||
if(item && gAudiop)
|
|
||||||
{
|
|
||||||
// <edit>
|
|
||||||
// that thing above doesn't actually start a sound transfer, so I will do it
|
|
||||||
LLAudioSource *asp = gAgentAvatarp->getAudioSource(gAgent.getID());
|
|
||||||
if(asp)
|
|
||||||
{
|
|
||||||
asp->preload(item->getAssetUUID());
|
|
||||||
}
|
|
||||||
// </edit>
|
|
||||||
}
|
|
||||||
|
|
||||||
setTitle(title);
|
|
||||||
|
|
||||||
if (!getHost())
|
|
||||||
{
|
|
||||||
LLRect curRect = getRect();
|
|
||||||
translate(rect.mLeft - curRect.mLeft, rect.mTop - curRect.mTop);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
return LLPreview::postBuild();
|
||||||
}
|
}
|
||||||
|
|
||||||
// static
|
// static
|
||||||
|
|||||||
@@ -65,6 +65,7 @@ public:
|
|||||||
// </edit>
|
// </edit>
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
/*virtual*/ BOOL postBuild();
|
||||||
virtual const char *getTitleName() const { return "Sound"; }
|
virtual const char *getTitleName() const { return "Sound"; }
|
||||||
// <edit>
|
// <edit>
|
||||||
virtual BOOL canSaveAs() const;
|
virtual BOOL canSaveAs() const;
|
||||||
|
|||||||
@@ -71,6 +71,7 @@
|
|||||||
<check_box label="Colocar los Botones en la misma línea del nombre en los IMs (Sólo afecta en Nuevos MIs)" name="im_concise_butt"/>
|
<check_box label="Colocar los Botones en la misma línea del nombre en los IMs (Sólo afecta en Nuevos MIs)" name="im_concise_butt"/>
|
||||||
<check_box label="Botones en chat de grupo en la línea del nombre del grupo (Afecta nuevos chats de grupo)" name="group_concise_butt"/>
|
<check_box label="Botones en chat de grupo en la línea del nombre del grupo (Afecta nuevos chats de grupo)" name="group_concise_butt"/>
|
||||||
<check_box label="Botones en la misma línea de título de conferencia (Afecta nuevas conferencias de Chat)" name="conf_concise_butt"/>
|
<check_box label="Botones en la misma línea de título de conferencia (Afecta nuevas conferencias de Chat)" name="conf_concise_butt"/>
|
||||||
|
<check_box label="Botón Historial abre editor externo (Solo en Windows)" name="legacy_log_launch"/>
|
||||||
<check_box label="Deshabilitar apertura atajo de Comunicación fuera de la lista de amigos" name="only_comm"/>
|
<check_box label="Deshabilitar apertura atajo de Comunicación fuera de la lista de amigos" name="only_comm"/>
|
||||||
<check_box label="Mensajes de acción en Itálica (/me)" name="italicize_actions"/>
|
<check_box label="Mensajes de acción en Itálica (/me)" name="italicize_actions"/>
|
||||||
</panel>
|
</panel>
|
||||||
|
|||||||
Reference in New Issue
Block a user