]> git.pld-linux.org Git - packages/vim.git/blob - 7.3.506
- up to 7.3.600
[packages/vim.git] / 7.3.506
1 To: vim_dev@googlegroups.com
2 Subject: Patch 7.3.506
3 Fcc: outbox
4 From: Bram Moolenaar <Bram@moolenaar.net>
5 Mime-Version: 1.0
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
8 ------------
9
10 Patch 7.3.506
11 Problem:    GTK gives an error when selecting a non-existent file.
12 Solution:   Add a handler to avoid the error. (Christian Brabandt)
13 Files:      src/gui_gtk.c
14
15
16 *** ../vim-7.3.505/src/gui_gtk.c        2011-06-26 04:48:56.000000000 +0200
17 --- src/gui_gtk.c       2012-04-25 17:08:58.000000000 +0200
18 ***************
19 *** 90,95 ****
20 --- 90,100 ----
21   static void entry_activate_cb(GtkWidget *widget, gpointer data);
22   static void entry_changed_cb(GtkWidget *entry, GtkWidget *dialog);
23   static void find_replace_cb(GtkWidget *widget, gpointer data);
24 + static void recent_func_log_func(
25 +       const gchar *log_domain,
26 +       GLogLevelFlags log_level,
27 +       const gchar *message,
28 +       gpointer user_data);
29   
30   #if defined(FEAT_TOOLBAR)
31   /*
32 ***************
33 *** 839,844 ****
34 --- 844,851 ----
35       GtkWidget         *fc;
36   #endif
37       char_u            dirbuf[MAXPATHL];
38 +     guint             log_handler;
39 +     const gchar               *domain = "Gtk";
40   
41       title = CONVERT_TO_UTF8(title);
42   
43 ***************
44 *** 853,858 ****
45 --- 860,870 ----
46       /* If our pointer is currently hidden, then we should show it. */
47       gui_mch_mousehide(FALSE);
48   
49 +     /* Hack: The GTK file dialog warns when it can't access a new file, this
50 +      * makes it shut up. http://bugzilla.gnome.org/show_bug.cgi?id=664587 */
51 +     log_handler = g_log_set_handler(domain, G_LOG_LEVEL_WARNING,
52 +                                                 recent_func_log_func, NULL);
53
54   #ifdef USE_FILE_CHOOSER
55       /* We create the dialog each time, so that the button text can be "Open"
56        * or "Save" according to the action. */
57 ***************
58 *** 916,921 ****
59 --- 928,934 ----
60       gtk_widget_show(gui.filedlg);
61       gtk_main();
62   #endif
63 +     g_log_remove_handler(domain, log_handler);
64   
65       CONVERT_TO_UTF8_FREE(title);
66       if (gui.browse_fname == NULL)
67 ***************
68 *** 1882,1884 ****
69 --- 1895,1908 ----
70        * backwards compatibility anyway. */
71       do_cmdline_cmd((char_u *)"emenu ToolBar.FindHelp");
72   }
73
74 +     static void
75 + recent_func_log_func(const gchar *log_domain UNUSED,
76 +                    GLogLevelFlags log_level UNUSED,
77 +                    const gchar *message UNUSED,
78 +                    gpointer user_data UNUSED)
79 + {
80 +     /* We just want to suppress the warnings. */
81 +     /* http://bugzilla.gnome.org/show_bug.cgi?id=664587 */
82 + }
83
84 *** ../vim-7.3.505/src/version.c        2012-04-25 16:50:44.000000000 +0200
85 --- src/version.c       2012-04-25 17:08:28.000000000 +0200
86 ***************
87 *** 716,717 ****
88 --- 716,719 ----
89   {   /* Add new patch number below this line */
90 + /**/
91 +     506,
92   /**/
93
94 -- 
95 Compilation process failed successfully.
96
97  /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
98 ///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
99 \\\  an exciting new programming language -- http://www.Zimbu.org        ///
100  \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///
This page took 0.027496 seconds and 3 git commands to generate.