summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/file.cpp4
-rw-r--r--src/ui/dialog/filedialogimpl-gtkmm.cpp16
2 files changed, 13 insertions, 7 deletions
diff --git a/src/file.cpp b/src/file.cpp
index 3e469b00b..9e8e3723c 100644
--- a/src/file.cpp
+++ b/src/file.cpp
@@ -395,10 +395,6 @@ sp_file_open_dialog(Gtk::Window &parentWindow, gpointer object, gpointer data)
open_path,
Inkscape::UI::Dialog::SVG_TYPES,
(char const *)_("Select file to open"));
- // allow easy access to our examples folder
- if (Inkscape::IO::file_test(INKSCAPE_EXAMPLESDIR, (GFileTest)(G_FILE_TEST_EXISTS | G_FILE_TEST_IS_DIR))) {
- dynamic_cast<Gtk::FileChooser *>(openDialogInstance)->add_shortcut_folder(INKSCAPE_EXAMPLESDIR);
- }
}
diff --git a/src/ui/dialog/filedialogimpl-gtkmm.cpp b/src/ui/dialog/filedialogimpl-gtkmm.cpp
index d3016e0f3..0550b8021 100644
--- a/src/ui/dialog/filedialogimpl-gtkmm.cpp
+++ b/src/ui/dialog/filedialogimpl-gtkmm.cpp
@@ -22,6 +22,8 @@
#include "filedialogimpl-gtkmm.h"
#include "dialogs/dialog-events.h"
#include "interface.h"
+#include "io/sys.h"
+#include "path-prefix.h"
#ifdef WITH_GNOME_VFS
# include <libgnomevfs/gnome-vfs.h>
@@ -73,7 +75,8 @@ fileDialogExtensionToPattern(Glib::ustring &pattern,
}
}
- void
+
+void
findEntryWidgets(Gtk::Container *parent,
std::vector<Gtk::Entry *> &result)
{
@@ -711,9 +714,15 @@ FileOpenDialogImplGtk::FileOpenDialogImplGtk(Gtk::Window& parentWindow,
//###### Add the file types menu
createFilterMenu();
-
add_button(Gtk::Stock::CANCEL, Gtk::RESPONSE_CANCEL);
set_default(*add_button(Gtk::Stock::OPEN, Gtk::RESPONSE_OK));
+
+ //###### Allow easy access to our examples folder
+ if(Inkscape::IO::file_test(INKSCAPE_EXAMPLESDIR,
+ (GFileTest)(G_FILE_TEST_EXISTS | G_FILE_TEST_IS_DIR)))
+ {
+ add_shortcut_folder(INKSCAPE_EXAMPLESDIR);
+ }
}
/**
@@ -1597,7 +1606,8 @@ FileExportDialogImpl::getFilename()
{
return myFilename;
}
-
+
+
} //namespace Dialog
} //namespace UI
} //namespace Inkscape