Solve Issue 1234: Enable opening of chat logs in external editor under linux too
Requires xdg-open, but meh~
This commit is contained in:
@@ -1001,15 +1001,19 @@ void LLFloaterIMPanel::onFlyoutCommit(LLComboBox* flyout, const LLSD& value)
|
||||
|
||||
void show_log_browser(const std::string& name, const std::string& id)
|
||||
{
|
||||
#if LL_WINDOWS || LL_DARWIN // Singu TODO: Linux?
|
||||
const std::string file(LLLogChat::makeLogFileName(name));
|
||||
if (gSavedSettings.getBOOL("LiruLegacyLogLaunch"))
|
||||
{
|
||||
gViewerWindow->getWindow()->ShellEx(LLLogChat::makeLogFileName(name));
|
||||
#if LL_WINDOWS || LL_DARWIN
|
||||
gViewerWindow->getWindow()->ShellEx(file);
|
||||
#elif LL_LINUX
|
||||
// xdg-open might not actually be installed on all distros, but it's our best bet.
|
||||
if (!std::system(("/usr/bin/xdg-open \"" + file +'"').c_str())) // 0 = success, otherwise fallback on internal browser.
|
||||
#endif
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
LLFloaterWebContent::Params p;
|
||||
p.url("file:///" + LLLogChat::makeLogFileName(name));
|
||||
p.url("file:///" + file);
|
||||
p.id(id);
|
||||
p.show_chrome(false);
|
||||
p.trusted_content(true);
|
||||
|
||||
@@ -101,7 +101,7 @@
|
||||
<check_box bottom_delta="-24" left="10" control_name="UseConciseIMButtons" follows="top" height="16" label="Buttons on the same line as name for IMs (Affects new IMs)" name="im_concise_butt"/>
|
||||
<check_box bottom_delta="-20" control_name="UseConciseGroupChatButtons" follows="top" height="16" label="Buttons on group chat name line (Affects new group chats)" name="group_concise_butt"/>
|
||||
<check_box bottom_delta="-20" control_name="UseConciseConferenceButtons" follows="top" height="16" label="Buttons on conference title line (Affects new conferences)" name="conf_concise_butt"/>
|
||||
<check_box bottom_delta="-20" follows="top" height="16" control_name="LiruLegacyLogLaunch" label="Log button opens external text editor (Windows and Mac only)" name="legacy_log_launch"/>
|
||||
<check_box bottom_delta="-20" follows="top" height="16" control_name="LiruLegacyLogLaunch" label="Log button opens external text editor" name="legacy_log_launch"/>
|
||||
<check_box bottom_delta="-20" follows="top" height="16" initial_value="false" label="Disallow communicate shortcut opening detached friends list" control_name="CommunicateSpecificShortcut" name="only_comm"/>
|
||||
<check_box bottom_delta="-20" follows="top" control_name="LiruLegacyScrollToEnd" label="Autoscroll to the end of chats when they regain focus" name="scroll_to_end_on_focus"/>
|
||||
<check_box bottom_delta="-20" follows="top" height="16" control_name="LiruItalicizeActions" label="Italicize action messages (/me)" name="italicize_actions"/>
|
||||
|
||||
@@ -106,7 +106,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="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="Botón Historial abre editor externo (Solo en Windows y Mac)" name="legacy_log_launch"/>
|
||||
<check_box label="Botón Historial abre editor externo" 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="Desplazamiento automático al final de chats cuando recuperan el foco" name="scroll_to_end_on_focus"/>
|
||||
<check_box label="Mensajes de acción en Itálica (/me)" name="italicize_actions"/>
|
||||
|
||||
@@ -74,7 +74,7 @@
|
||||
<check_box label="Boutons sur la même ligne que les noms pour les IMs" name="im_concise_butt"/>
|
||||
<check_box label="Boutons sur la ligne des noms des chats de groupe" name="group_concise_butt"/>
|
||||
<check_box label="Boutons sur la ligne de titre des conférences" name="conf_concise_butt"/>
|
||||
<check_box label="Ouvre les logs avec un éditeur de texte externe (windows/mac)" name="legacy_log_launch"/>
|
||||
<check_box label="Ouvre les logs avec un éditeur de texte externe" name="legacy_log_launch"/>
|
||||
<check_box label="Désactive le raccourci ouvrant détacher la liste d'amis" name="only_comm"/>
|
||||
<check_box label="Ecrit en Italiques le /me" name="italicize_actions"/>
|
||||
</panel>
|
||||
|
||||
Reference in New Issue
Block a user