diff options
| author | su_v <suv-sf@users.sourceforge.net> | 2013-03-19 02:26:40 +0000 |
|---|---|---|
| committer | ~suv <suv-sf@users.sourceforge.net> | 2013-03-19 02:26:40 +0000 |
| commit | 5c8a7b8df6203791610487d2435646f86a0eed96 (patch) | |
| tree | 3bf6c7a52f27978f84b267482bb69389051c4085 /src/ui/dialog/export.cpp | |
| parent | changes_2013_03_18c.patch (diff) | |
| parent | Drop remaining unused functions (diff) | |
| download | inkscape-5c8a7b8df6203791610487d2435646f86a0eed96.tar.gz inkscape-5c8a7b8df6203791610487d2435646f86a0eed96.zip | |
merge from trunk (r12224)
(bzr r11668.1.60)
Diffstat (limited to 'src/ui/dialog/export.cpp')
| -rw-r--r-- | src/ui/dialog/export.cpp | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/src/ui/dialog/export.cpp b/src/ui/dialog/export.cpp index 66c9e6ed0..99a8c08d2 100644 --- a/src/ui/dialog/export.cpp +++ b/src/ui/dialog/export.cpp @@ -133,6 +133,15 @@ namespace Inkscape { namespace UI { namespace Dialog { +/** A list of strings that is used both in the preferences, and in the + data fields to describe the various values of \c selection_type. */ +static const char * selection_names[SELECTION_NUMBER_OF] = { + "page", "drawing", "selection", "custom"}; + +/** The names on the buttons for the various selection types. */ +static const char * selection_labels[SELECTION_NUMBER_OF] = { + N_("_Page"), N_("_Drawing"), N_("_Selection"), N_("_Custom")}; + Export::Export (void) : UI::Widget::Panel ("", "/dialogs/export/", SP_VERB_DIALOG_EXPORT), current_key(SELECTION_PAGE), @@ -419,7 +428,6 @@ void Export::set_default_filename () { if ( SP_ACTIVE_DOCUMENT && SP_ACTIVE_DOCUMENT->getURI() ) { - gchar *name; SPDocument * doc = SP_ACTIVE_DOCUMENT; const gchar *uri = doc->getURI(); const gchar *text_extension = get_file_save_extension (Inkscape::Extension::FILE_SAVE_METHOD_SAVE_AS).c_str(); @@ -448,7 +456,7 @@ void Export::set_default_filename () { g_free(uri_copy); } } else { - name = g_strconcat(uri, ".png", NULL); + gchar *name = g_strconcat(uri, ".png", NULL); filename_entry.set_text(name); filename_entry.set_position(strlen(name)); @@ -1317,7 +1325,7 @@ void Export::onBrowse () WCHAR _filename[_MAX_PATH + 1]; memset(_filename, 0, sizeof(_filename)); gunichar2* utf16_path_string = g_utf8_to_utf16(filename.c_str(), -1, NULL, NULL, NULL); - wcsncpy(_filename, (wchar_t*)utf16_path_string, _MAX_PATH); + wcsncpy(_filename, reinterpret_cast<wchar_t*>(utf16_path_string), _MAX_PATH); g_free(utf16_path_string); opf.hwndOwner = (HWND)(GDK_WINDOW_HWND(gtk_widget_get_window(GTK_WIDGET(this)))); |
