diff options
author | Ima Mechanique <none@none> | 2011-12-01 12:31:56 +0000 |
---|---|---|
committer | Ima Mechanique <none@none> | 2011-12-01 12:31:56 +0000 |
commit | 5535722ea5c2f64a25ca569c930e969f2e989af9 (patch) | |
tree | 4ee10a14f8a6e5a26cbdae523d18419ad4eeee06 | |
parent | 413cd15f070c6c0406026c96e0b70698120366ef (diff) |
STORM-1708 Linux UI additions
-rw-r--r-- | indra/newview/llfilepicker.cpp | 14 | ||||
-rw-r--r-- | indra/newview/skins/default/xui/en/strings.xml | 5 |
2 files changed, 16 insertions, 3 deletions
diff --git a/indra/newview/llfilepicker.cpp b/indra/newview/llfilepicker.cpp index 3cbc4e5648..d259e02452 100644 --- a/indra/newview/llfilepicker.cpp +++ b/indra/newview/llfilepicker.cpp @@ -1197,7 +1197,12 @@ static std::string add_imageload_filter_to_gtkchooser(GtkWindow *picker) add_common_filters_to_gtkchooser(gfilter, picker, filtername); return filtername; } - + +static std::string add_script_filter_to_gtkchooser(GtkWindow *picker) +{ + return add_simple_mime_filter_to_gtkchooser(picker, "text/plain", + LLTrans::getString("script_files") + " (*.lsl)"); +} BOOL LLFilePicker::getSaveFile( ESaveFilter filter, const std::string& filename ) { @@ -1263,6 +1268,10 @@ BOOL LLFilePicker::getSaveFile( ESaveFilter filter, const std::string& filename LLTrans::getString("compressed_image_files") + " (*.j2c)"); suggest_ext = ".j2c"; break; + case FFSAVE_SCRIPT: + caption += add_script_filter_to_gtkchooser(picker); + suggest_ext = ".lsl"; + break; default:; break; } @@ -1328,6 +1337,9 @@ BOOL LLFilePicker::getOpenFile( ELoadFilter filter, bool blocking ) case FFLOAD_IMAGE: filtername = add_imageload_filter_to_gtkchooser(picker); break; + case FFLOAD_SCRIPT: + filtername = add_script_filter_to_gtkchooser(picker); + break; default:; break; } diff --git a/indra/newview/skins/default/xui/en/strings.xml b/indra/newview/skins/default/xui/en/strings.xml index befcc5dd87..0d26465dfa 100644 --- a/indra/newview/skins/default/xui/en/strings.xml +++ b/indra/newview/skins/default/xui/en/strings.xml @@ -427,9 +427,10 @@ Please try logging in again in a minute.</string> <string name="compressed_image_files">Compressed Images</string> <string name="load_files">Load Files</string> <string name="choose_the_directory">Choose Directory</string> + <string name="script_files">Scripts</string> - <!-- LSL Usage Hover Tips --> - <!-- NOTE: For now these are set as translate="false", until DEV-40761 is implemented (to internationalize the rest of tooltips in the same window). + <!-- LSL Usage Hover Tips --> + <!-- NOTE: For now these are set as translate="false", until DEV-40761 is implemented (to internationalize the rest of tooltips in the same window). This has no effect on viewer code, but prevents Linden Lab internal localization tool from scraping these strings. --> <string name="LSLTipSleepTime" translate="false"> Sleeps script for [SLEEP_TIME] seconds. |