[vinagre/plugin] Implement get_file_filter in VNC plugin
- From: Jonh Wendell <jwendell src gnome org>
- To: svn-commits-list gnome org
- Subject: [vinagre/plugin] Implement get_file_filter in VNC plugin
- Date: Sat, 25 Jul 2009 16:04:22 +0000 (UTC)
commit c0a56df155a2988c61f72893a8d1e6a52551885e
Author: Jonh Wendell <jwendell gnome org>
Date: Sat Jul 25 13:03:42 2009 -0300
Implement get_file_filter in VNC plugin
plugins/vnc/vinagre-vnc-plugin.c | 14 ++++++++++++++
1 files changed, 14 insertions(+), 0 deletions(-)
---
diff --git a/plugins/vnc/vinagre-vnc-plugin.c b/plugins/vnc/vinagre-vnc-plugin.c
index b425c2a..1f7f4ff 100644
--- a/plugins/vnc/vinagre-vnc-plugin.c
+++ b/plugins/vnc/vinagre-vnc-plugin.c
@@ -241,6 +241,19 @@ impl_get_default_port (VinagrePlugin *plugin)
return 5900;
}
+static GtkFileFilter *
+impl_get_file_filter (VinagrePlugin *plugin)
+{
+ GtkFileFilter *filter;
+
+ filter = gtk_file_filter_new ();
+ /* Translators: this is a pattern to open *.vnc files in a open dialog. */
+ gtk_file_filter_set_name (filter, _("VNC Files"));
+ gtk_file_filter_add_pattern (filter, "*.vnc");
+
+ return filter;
+}
+
static void
vinagre_vnc_plugin_init (VinagreVncPlugin *plugin)
{
@@ -275,5 +288,6 @@ vinagre_vnc_plugin_class_init (VinagreVncPluginClass *klass)
plugin_class->new_tab = impl_new_tab;
plugin_class->get_connect_widget = impl_get_connect_widget;
plugin_class->get_default_port = impl_get_default_port;
+ plugin_class->get_file_filter = impl_get_file_filter;
}
/* vim: set ts=8: */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]