4 From: Bram Moolenaar <Bram@moolenaar.net>
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
10 Patch 7.2.444 (after 7.2.442)
11 Problem: Can't build with GTK 1, gtk_selection_clear_targets() is not
12 available. (Patrick Texier)
13 Solution: Don't change the targets for GTK 1, set them once.
14 Files: src/gui_gtk_x11.c, src/option.c
17 *** ../vim-7.2.443/src/gui_gtk_x11.c 2010-06-05 12:49:40.000000000 +0200
18 --- src/gui_gtk_x11.c 2010-06-13 02:26:24.000000000 +0200
22 for (i = 0; i < (int)N_SELECTION_TARGETS; ++i)
25 /* OpenOffice tries to use TARGET_HTML and fails when it doesn't
26 * return something, instead of trying another target. Therefore only
27 * offer TARGET_HTML when it works. */
30 for (i = 0; i < (int)N_SELECTION_TARGETS; ++i)
32 ! #if defined(FEAT_MBYTE) && defined(HAVE_GTK2)
33 /* OpenOffice tries to use TARGET_HTML and fails when it doesn't
34 * return something, instead of trying another target. Therefore only
35 * offer TARGET_HTML when it works. */
39 targets[j++] = selection_targets[i];
42 + #ifdef HAVE_GTK2 /* GTK 1 doesn't have this function */
43 gtk_selection_clear_targets(gui.drawarea, (GdkAtom)GDK_SELECTION_PRIMARY);
44 gtk_selection_clear_targets(gui.drawarea, (GdkAtom)clip_plus.gtk_sel_atom);
46 gtk_selection_add_targets(gui.drawarea,
47 (GdkAtom)GDK_SELECTION_PRIMARY,
49 *** ../vim-7.2.443/src/option.c 2010-06-05 12:49:40.000000000 +0200
50 --- src/option.c 2010-06-13 02:27:36.000000000 +0200
54 vim_free(clip_exclude_prog);
55 clip_exclude_prog = new_exclude_prog;
59 gui_gtk_set_selection_targets();
62 vim_free(clip_exclude_prog);
63 clip_exclude_prog = new_exclude_prog;
64 ! #ifdef HAVE_GTK2 /* for GTK 1 we can't change the list of targets */
67 gui_gtk_set_selection_targets();
68 *** ../vim-7.2.443/src/version.c 2010-06-12 20:11:53.000000000 +0200
69 --- src/version.c 2010-06-13 02:29:18.000000000 +0200
73 { /* Add new patch number below this line */
79 hundred-and-one symptoms of being an internet addict:
80 195. Your cat has its own home page.
82 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
83 /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
84 \\\ download, build and distribute -- http://www.A-A-P.org ///
85 \\\ help me help AIDS victims -- http://ICCF-Holland.org ///