summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorManolo Gouy <Manolo>2011-06-03 16:08:42 +0000
committerManolo Gouy <Manolo>2011-06-03 16:08:42 +0000
commit6fde8226fa1e415678cce6e2ab47a163dad0e441 (patch)
tree6255d91872d16733ce8ec540da1e14e1b6d879f3 /src
parentf5de82aac5b6bedd90f841eb53fadf582046e4f1 (diff)
Mac OS: allow internationalization of file dialogs.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8776 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src')
-rw-r--r--src/Fl_Native_File_Chooser_MAC.mm7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/Fl_Native_File_Chooser_MAC.mm b/src/Fl_Native_File_Chooser_MAC.mm
index 80e3b4901..e96a9c2c6 100644
--- a/src/Fl_Native_File_Chooser_MAC.mm
+++ b/src/Fl_Native_File_Chooser_MAC.mm
@@ -40,6 +40,7 @@
#include <FL/Fl.H>
#include <FL/Fl_Native_File_Chooser.H>
+#include <FL/Fl_File_Chooser.H>
#include <FL/filename.H>
// FREE PATHNAMES ARRAY, IF IT HAS ANY CONTENTS
@@ -543,10 +544,10 @@ int Fl_Native_File_Chooser::post() {
NSPopUpButton *popup = nil;
if (_filt_total) {
char *t = prepareMacFilter(_filt_total, _filter, _filt_patt);
- popup = createPopupAccessory((NSSavePanel*)_panel, t, "Enable:", 0);
+ popup = createPopupAccessory((NSSavePanel*)_panel, t, Fl_File_Chooser::show_label, 0);
delete[] t;
[[popup menu] addItem:[NSMenuItem separatorItem]];
- [popup addItemWithTitle:@"All Documents"];
+ [popup addItemWithTitle:[[NSString alloc] initWithUTF8String:Fl_File_Chooser::all_files_label]];
[popup setAction:@selector(validateVisibleColumns)];
[popup setTarget:(NSObject*)_panel];
static FLopenDelegate *openDelegate = nil;
@@ -604,7 +605,7 @@ int Fl_Native_File_Chooser::post() {
if (_directory && !dir) dir = [[NSString alloc] initWithUTF8String:_directory];
if (_filt_total) {
char *t = prepareMacFilter(_filt_total, _filter, _filt_patt);
- popup = createPopupAccessory((NSSavePanel*)_panel, t, "Format:", _filt_value);
+ popup = createPopupAccessory((NSSavePanel*)_panel, t, [[(NSSavePanel*)_panel nameFieldLabel] UTF8String], _filt_value);
delete[] t;
}
retval = [(NSSavePanel*)_panel runModalForDirectory:dir file:fname];