gtk+: remove 2.6.10

git-svn-id: https://svn.o-hand.com/repos/poky/trunk@4660 311d38ba-8fff-0310-9ca6-ca027cbcb966
This commit is contained in:
Ross Burton
2008-06-16 10:14:57 +00:00
parent 0a2c4cd9bd
commit 0d007363d7
17 changed files with 0 additions and 5659 deletions

View File

@@ -1,24 +0,0 @@
--- gtk+-2.4.1/docs/tutorial/Makefile.am~ 2003-05-06 22:54:20.000000000 +0100
+++ gtk+-2.4.1/docs/tutorial/Makefile.am 2004-05-08 12:31:41.000000000 +0100
@@ -52,21 +52,5 @@
dist-hook: html
cp -Rp $(srcdir)/html $(distdir)
-else
-html:
- echo "***"
- echo "*** Warning: Tutorial not built"
- echo "***"
-
-pdf:
- echo "***"
- echo "*** Warning: Tutorial not built"
- echo "***"
-
-dist-hook:
- echo "***"
- echo "*** Warning: Tutorial not built"
- echo "*** DISTRIBUTION IS INCOMPLETE"
- echo "***"
endif

View File

@@ -1,67 +0,0 @@
Index: gtk/gtkcombobox.c
===================================================================
RCS file: /cvs/gnome/gtk+/gtk/gtkcombobox.c,v
retrieving revision 1.185
diff -u -p -r1.185 gtkcombobox.c
--- gtk/gtkcombobox.c 12 Oct 2006 13:48:07 -0000 1.185
+++ gtk/gtkcombobox.c 1 Nov 2006 19:01:09 -0000
@@ -756,6 +756,25 @@ gtk_combo_box_class_init (GtkComboBoxCla
FALSE,
GTK_PARAM_READABLE));
+ /**
+ * GtkComboBox:arrow-size:
+ *
+ * Sets the minimum size of the arrow in the combo box. Note
+ * that the arrow size is coupled to the font size, so in case
+ * a larger font is used, the arrow will be larger than set
+ * by arrow size.
+ *
+ * Since: 2.12
+ */
+ gtk_widget_class_install_style_property (widget_class,
+ g_param_spec_int ("arrow-size",
+ P_("Arrow Size"),
+ P_("The minimum size of the arrow in the combo box"),
+ 0,
+ G_MAXINT,
+ 15,
+ G_PARAM_READABLE));
+
g_type_class_add_private (object_class, sizeof (GtkComboBoxPrivate));
}
@@ -1897,7 +1916,12 @@ gtk_combo_box_size_request (GtkWidget
{
gint width, height;
gint focus_width, focus_pad;
+ gint font_size;
+ gint arrow_size;
GtkRequisition bin_req;
+ PangoContext *context;
+ PangoFontMetrics *metrics;
+ PangoFontDescription *font_desc;
GtkComboBox *combo_box = GTK_COMBO_BOX (widget);
@@ -1910,7 +1934,20 @@ gtk_combo_box_size_request (GtkWidget
gtk_widget_style_get (GTK_WIDGET (widget),
"focus-line-width", &focus_width,
"focus-padding", &focus_pad,
+ "arrow-size", &arrow_size,
NULL);
+
+ font_desc = GTK_BIN (widget)->child->style->font_desc;
+ context = gtk_widget_get_pango_context (widget);
+ metrics = pango_context_get_metrics (context, font_desc,
+ pango_context_get_language (context));
+ font_size = PANGO_PIXELS (pango_font_metrics_get_ascent (metrics) +
+ pango_font_metrics_get_descent (metrics));
+ pango_font_metrics_unref (metrics);
+
+ arrow_size = MAX (arrow_size, font_size);
+
+ gtk_widget_set_size_request (combo_box->priv->arrow, arrow_size, arrow_size);
if (!combo_box->priv->tree_view)
{

View File

@@ -1,11 +0,0 @@
--- gtk+-2.4.3/gtk/gtktooltips.c.old 2004-07-04 18:52:04.000000000 +0100
+++ gtk+-2.4.3/gtk/gtktooltips.c 2004-07-04 18:52:08.000000000 +0100
@@ -118,7 +118,7 @@
tooltips->tips_data_list = NULL;
tooltips->delay = DEFAULT_DELAY;
- tooltips->enabled = TRUE;
+ tooltips->enabled = FALSE;
tooltips->timer_tag = 0;
tooltips->use_sticky_delay = FALSE;
tooltips->last_popdown.tv_sec = -1;

File diff suppressed because it is too large Load Diff

View File

@@ -1,77 +0,0 @@
--- gtk+-2.6.8/gtk/gtkfilechooserdialog.c.orig 2007-02-09 12:18:25.000000000 +0000
+++ gtk+-2.6.8/gtk/gtkfilechooserdialog.c 2007-02-09 12:18:25.000000000 +0000
@@ -62,8 +62,6 @@
static void gtk_file_chooser_dialog_map (GtkWidget *widget);
static void gtk_file_chooser_dialog_unmap (GtkWidget *widget);
-static void gtk_file_chooser_dialog_style_set (GtkWidget *widget,
- GtkStyle *previous_style);
static void response_cb (GtkDialog *dialog,
gint response_id);
@@ -122,7 +120,6 @@
widget_class->map = gtk_file_chooser_dialog_map;
widget_class->unmap = gtk_file_chooser_dialog_unmap;
- widget_class->style_set = gtk_file_chooser_dialog_style_set;
_gtk_file_chooser_install_properties (gobject_class);
@@ -135,13 +132,19 @@
GtkFileChooserDialogPrivate *priv = G_TYPE_INSTANCE_GET_PRIVATE (dialog,
GTK_TYPE_FILE_CHOOSER_DIALOG,
GtkFileChooserDialogPrivate);
+
+ GtkDialog *fc_dialog = GTK_DIALOG (dialog);
+
dialog->priv = priv;
dialog->priv->default_width = -1;
dialog->priv->default_height = -1;
dialog->priv->resize_horizontally = TRUE;
dialog->priv->resize_vertically = TRUE;
- gtk_dialog_set_has_separator (GTK_DIALOG (dialog), FALSE);
+ gtk_dialog_set_has_separator (fc_dialog, FALSE);
+ gtk_container_set_border_width (GTK_CONTAINER (fc_dialog), 5);
+ gtk_box_set_spacing (GTK_BOX (fc_dialog->vbox), 2); /* 2 * 5 + 2 = 12 */
+ gtk_container_set_border_width (GTK_CONTAINER (fc_dialog->action_area), 5);
/* We do a signal connection here rather than overriding the method in
* class_init because GtkDialog::response is a RUN_LAST signal. We want *our*
@@ -394,6 +397,7 @@
g_signal_connect (priv->widget, "default-size-changed",
G_CALLBACK (file_chooser_widget_default_size_changed), object);
+ gtk_container_set_border_width (GTK_CONTAINER (priv->widget), 5);
gtk_box_pack_start (GTK_BOX (GTK_DIALOG (object)->vbox), priv->widget, TRUE, TRUE, 0);
gtk_widget_show (priv->widget);
@@ -522,28 +526,6 @@
gtk_widget_unmap (priv->widget);
}
-static void
-gtk_file_chooser_dialog_style_set (GtkWidget *widget,
- GtkStyle *previous_style)
-{
- GtkDialog *dialog;
-
- if (GTK_WIDGET_CLASS (parent_class)->style_set)
- GTK_WIDGET_CLASS (parent_class)->style_set (widget, previous_style);
-
- dialog = GTK_DIALOG (widget);
-
- /* Override the style properties with HIG-compliant spacings. Ugh.
- * http://developer.gnome.org/projects/gup/hig/1.0/layout.html#layout-dialogs
- * http://developer.gnome.org/projects/gup/hig/1.0/windows.html#alert-spacing
- */
-
- gtk_container_set_border_width (GTK_CONTAINER (dialog->vbox), 12);
- gtk_box_set_spacing (GTK_BOX (dialog->vbox), 24);
-
- gtk_container_set_border_width (GTK_CONTAINER (dialog->action_area), 0);
- gtk_box_set_spacing (GTK_BOX (dialog->action_area), 6);
-}
/* GtkDialog::response handler */
static void

View File

@@ -1,182 +0,0 @@
--- gtk+-2.6.8/gtk/gtkfilesystemunix.c.orig 2007-02-08 12:01:19.000000000 +0000
+++ gtk+-2.6.8/gtk/gtkfilesystemunix.c 2007-02-08 12:01:19.000000000 +0000
@@ -33,6 +33,7 @@
#include <errno.h>
#include <string.h>
#include <sys/stat.h>
+#include <sys/statvfs.h>
#include <sys/types.h>
#include <pwd.h>
#ifdef HAVE_UNISTD_H
@@ -358,7 +359,49 @@
static GSList *
gtk_file_system_unix_list_volumes (GtkFileSystem *file_system)
{
- return g_slist_append (NULL, get_root_volume ());
+ struct statvfs stv;
+ struct stat st;
+ GSList * l = g_slist_append (NULL, get_root_volume ());
+
+ if (!statvfs ("/.", &stv))
+ {
+ fsblkcnt_t root_blocks = stv.f_blocks;
+ fsfilcnt_t root_files = stv.f_files;
+
+ GDir * dir;
+ if ((dir = g_dir_open ("/media", 0, NULL)) != NULL)
+ {
+ const gchar * name;
+ while ((name = g_dir_read_name (dir)) != NULL)
+ {
+ gchar * abs_name = g_strconcat ("/media/", name, NULL);
+
+ if (!stat (abs_name, &st) && S_ISDIR (st.st_mode))
+ {
+ gchar * dot = g_strconcat (abs_name, "/.", NULL);
+ if (!statvfs (dot, &stv) &&
+ (stv.f_blocks != root_blocks ||
+ stv.f_files != root_files))
+ {
+ GtkFilePath * path =
+ gtk_file_system_filename_to_path (file_system,
+ abs_name);
+
+ if (path)
+ l = g_slist_append (l, path);
+ }
+
+ g_free (dot);
+ }
+
+ g_free (abs_name);
+ }
+
+ g_dir_close (dir);
+ }
+ }
+
+ return l;
}
static GtkFileSystemVolume *
@@ -375,10 +418,15 @@
len = strlen (filename);
- if (len > 1 && filename[len - 1] == '/')
- return g_strndup (filename, len - 1);
- else
- return g_memdup (filename, len + 1);
+ if (len > 1)
+ {
+ gchar *c = g_utf8_prev_char (filename + len);
+
+ if (c && *c == '/')
+ return g_strndup (filename, len - 1);
+ }
+
+ return g_memdup (filename, len + 1);
}
static GtkFileFolder *
@@ -590,7 +638,7 @@
gtk_file_system_unix_volume_get_base_path (GtkFileSystem *file_system,
GtkFileSystemVolume *volume)
{
- return gtk_file_path_new_dup ("/");
+ return gtk_file_path_copy ((GtkFilePath*)volume);
}
static gboolean
@@ -616,7 +664,32 @@
gtk_file_system_unix_volume_get_display_name (GtkFileSystem *file_system,
GtkFileSystemVolume *volume)
{
- return g_strdup (_("Filesystem")); /* Same as Nautilus */
+ gchar * slash;
+ gchar * path;
+ gchar * c;
+
+ g_return_val_if_fail (file_system && volume, NULL);
+
+ path = gtk_file_system_path_to_filename (file_system, (GtkFilePath*) volume);
+
+ g_return_val_if_fail (path && *path, NULL);
+
+ if (path[0] == '/' && !path[1])
+ return g_strdup (_("Filesystem")); /* Same as Nautilus */
+
+ /* Now the media volumes */
+ /* strip trailing / if any */
+ c = g_utf8_prev_char (path + strlen(path));
+
+ if (*c == '/')
+ *c = 0;
+
+ slash = g_utf8_strrchr (path, -1, '/');
+
+ if (!slash)
+ return g_strdup (path);
+
+ return g_strdup (slash + 1);
}
static IconType
@@ -787,11 +860,54 @@
GError **error)
{
GdkPixbuf *pixbuf;
+ gchar * slash;
+ gchar * path;
+ gchar * c;
+ const gchar * id = NULL;
+
+ g_return_val_if_fail (file_system && volume, NULL);
+
+ path = gtk_file_system_path_to_filename (file_system, (GtkFilePath*) volume);
- pixbuf = get_cached_icon (widget, "gnome-fs-blockdev", pixel_size);
- if (pixbuf)
- return pixbuf;
+ g_return_val_if_fail (path && *path, NULL);
+
+ if (path[0] == '/' && !path[1])
+ id = "gnome-fs-blockdev";
+ else
+ {
+ /* Now the media volumes */
+ /* strip trailing / if any */
+ c = g_utf8_prev_char (path + strlen(path));
+
+ if (*c == '/')
+ *c = 0;
+
+ slash = g_utf8_strrchr (path, -1, '/');
+ if (slash)
+ {
+ slash++;
+
+ if (!strcmp (slash, "card"))
+ id = "gnome-dev-media-sdmmc";
+ else if (!strcmp (slash, "cf"))
+ id = "gnome-dev-media-cf";
+ else if (!strncmp (slash, "mmc", 3))
+ id = "gnome-dev-media-sdmmc";
+ else if (!strcmp (slash, "usbhdd"))
+ id = "gnome-dev-removable-usb";
+ else
+ id = "gnome-dev-removable";
+ }
+ }
+
+ if (id)
+ {
+ pixbuf = get_cached_icon (widget, id, pixel_size);
+ if (pixbuf)
+ return pixbuf;
+ }
+
pixbuf = get_fallback_icon (widget, ICON_BLOCK_DEVICE, error);
g_assert (pixbuf != NULL);

View File

@@ -1,236 +0,0 @@
--- gtk+-2.4.1/gtk/gtkarrow.c 2004-03-13 09:51:13.000000000 +1100
+++ gtk+-2.4.1/gtk/gtkarrow.c 2004-05-26 14:52:17.000000000 +1000
@@ -29,7 +29,7 @@
#include "gtkarrow.h"
#include "gtkintl.h"
-#define MIN_ARROW_SIZE 15
+#define MIN_ARROW_SIZE 7
enum {
PROP_0,
@@ -53,6 +53,8 @@
guint prop_id,
GValue *value,
GParamSpec *pspec);
+static void gtk_arrow_size_request (GtkWidget *arrow,
+ GtkRequisition *requisition);
GType
gtk_arrow_get_type (void)
@@ -111,6 +113,7 @@
G_PARAM_READABLE | G_PARAM_WRITABLE));
widget_class->expose_event = gtk_arrow_expose;
+ widget_class->size_request = gtk_arrow_size_request;
}
static void
@@ -166,13 +169,18 @@
}
static void
+gtk_arrow_size_request (GtkWidget *arrow,
+ GtkRequisition *requisition)
+{
+ requisition->width = MIN_ARROW_SIZE + GTK_MISC (arrow)->xpad * 2;
+ requisition->height = MIN_ARROW_SIZE + GTK_MISC (arrow)->ypad * 2;
+}
+
+static void
gtk_arrow_init (GtkArrow *arrow)
{
GTK_WIDGET_SET_FLAGS (arrow, GTK_NO_WINDOW);
- GTK_WIDGET (arrow)->requisition.width = MIN_ARROW_SIZE + GTK_MISC (arrow)->xpad * 2;
- GTK_WIDGET (arrow)->requisition.height = MIN_ARROW_SIZE + GTK_MISC (arrow)->ypad * 2;
-
arrow->arrow_type = GTK_ARROW_RIGHT;
arrow->shadow_type = GTK_SHADOW_OUT;
}
--- gtk+-2.4.1/gtk/gtkcalendar.c 2004-03-06 14:37:26.000000000 +1100
+++ gtk+-2.4.1/gtk/gtkcalendar.c 2004-05-26 14:58:57.000000000 +1000
@@ -340,6 +340,9 @@
static void gtk_calendar_select_and_focus_day (GtkCalendar *calendar,
guint day);
+static void gtk_calendar_do_select_day (GtkCalendar *calendar,
+ guint day);
+
static void gtk_calendar_paint_arrow (GtkWidget *widget,
guint arrow);
static void gtk_calendar_paint_day_num (GtkWidget *widget,
@@ -861,13 +864,13 @@
if (month_len < calendar->selected_day)
{
calendar->selected_day = 0;
- gtk_calendar_select_day (calendar, month_len);
+ gtk_calendar_do_select_day (calendar, month_len);
}
else
{
if (calendar->selected_day < 0)
calendar->selected_day = calendar->selected_day + 1 + month_length[leap (calendar->year)][calendar->month + 1];
- gtk_calendar_select_day (calendar, calendar->selected_day);
+ gtk_calendar_do_select_day (calendar, calendar->selected_day);
}
gtk_widget_queue_draw (GTK_WIDGET (calendar));
@@ -908,10 +911,10 @@
if (month_len < calendar->selected_day)
{
calendar->selected_day = 0;
- gtk_calendar_select_day (calendar, month_len);
+ gtk_calendar_do_select_day (calendar, month_len);
}
else
- gtk_calendar_select_day (calendar, calendar->selected_day);
+ gtk_calendar_do_select_day (calendar, calendar->selected_day);
gtk_widget_queue_draw (GTK_WIDGET (calendar));
gtk_calendar_thaw (calendar);
@@ -939,10 +942,10 @@
if (month_len < calendar->selected_day)
{
calendar->selected_day = 0;
- gtk_calendar_select_day (calendar, month_len);
+ gtk_calendar_do_select_day (calendar, month_len);
}
else
- gtk_calendar_select_day (calendar, calendar->selected_day);
+ gtk_calendar_do_select_day (calendar, calendar->selected_day);
gtk_widget_queue_draw (GTK_WIDGET (calendar));
gtk_calendar_thaw (calendar);
@@ -974,10 +977,10 @@
if (month_len < calendar->selected_day)
{
calendar->selected_day = 0;
- gtk_calendar_select_day (calendar, month_len);
+ gtk_calendar_do_select_day (calendar, month_len);
}
else
- gtk_calendar_select_day (calendar, calendar->selected_day);
+ gtk_calendar_do_select_day (calendar, calendar->selected_day);
gtk_widget_queue_draw (GTK_WIDGET (calendar));
gtk_calendar_thaw (calendar);
@@ -2480,9 +2483,9 @@
return TRUE;
}
-void
-gtk_calendar_select_day (GtkCalendar *calendar,
- guint day)
+static void
+gtk_calendar_do_select_day (GtkCalendar *calendar,
+ guint day)
{
g_return_if_fail (GTK_IS_CALENDAR (calendar));
g_return_if_fail (day <= 31);
@@ -2499,6 +2502,13 @@
if (GTK_WIDGET_DRAWABLE (GTK_WIDGET (calendar)))
gtk_calendar_paint_day_num (GTK_WIDGET (calendar), selected_day);
}
+}
+
+void
+gtk_calendar_select_day (GtkCalendar *calendar,
+ guint day)
+{
+ gtk_calendar_do_select_day (calendar, day);
calendar->selected_day = day;
--- gtk+-2.4.1/gtk/gtkentry.c 2004-04-22 08:08:08.000000000 +1000
+++ gtk+-2.4.1/gtk/gtkentry.c 2004-05-26 14:52:17.000000000 +1000
@@ -557,6 +557,15 @@
0.0,
G_PARAM_READABLE | G_PARAM_WRITABLE));
+ gtk_widget_class_install_style_property (widget_class,
+ g_param_spec_int ("min_width",
+ _("Minimum width"),
+ _("Minimum width of the entry field"),
+ 0,
+ G_MAXINT,
+ MIN_ENTRY_WIDTH,
+ G_PARAM_READABLE));
+
signals[POPULATE_POPUP] =
g_signal_new ("populate_popup",
G_OBJECT_CLASS_TYPE (gobject_class),
@@ -1124,7 +1133,7 @@
{
GtkEntry *entry = GTK_ENTRY (widget);
PangoFontMetrics *metrics;
- gint xborder, yborder;
+ gint xborder, yborder, min_width;
PangoContext *context;
gtk_widget_ensure_style (widget);
@@ -1140,9 +1149,11 @@
xborder += INNER_BORDER;
yborder += INNER_BORDER;
-
+
+ gtk_widget_style_get (widget, "min_width", &min_width, NULL);
+
if (entry->width_chars < 0)
- requisition->width = MIN_ENTRY_WIDTH + xborder * 2;
+ requisition->width = min_width + xborder * 2;
else
{
gint char_width = pango_font_metrics_get_approximate_char_width (metrics);
--- gtk+-2.4.1/gtk/gtkrange.c 2004-03-06 14:38:08.000000000 +1100
+++ gtk+-2.4.1/gtk/gtkrange.c 2004-05-26 14:52:17.000000000 +1000
@@ -180,6 +180,7 @@
static GtkWidgetClass *parent_class = NULL;
static guint signals[LAST_SIGNAL];
+static GdkAtom recognize_protocols_atom, atom_atom;
GType
gtk_range_get_type (void)
@@ -220,6 +221,9 @@
object_class = (GtkObjectClass*) class;
widget_class = (GtkWidgetClass*) class;
+ recognize_protocols_atom = gdk_atom_intern ("RECOGNIZE_PROTOCOLS", FALSE);
+ atom_atom = gdk_atom_intern ("ATOM", FALSE);
+
parent_class = g_type_class_peek_parent (class);
gobject_class->set_property = gtk_range_set_property;
@@ -815,6 +819,12 @@
&attributes, attributes_mask);
gdk_window_set_user_data (range->event_window, range);
+ gdk_property_change (range->event_window,
+ recognize_protocols_atom,
+ atom_atom,
+ 32, GDK_PROP_MODE_REPLACE,
+ NULL, 0);
+
widget->style = gtk_style_attach (widget->style, widget->window);
}
@@ -1186,7 +1196,7 @@
/* ignore presses when we're already doing something else. */
if (range->layout->grab_location != MOUSE_OUTSIDE)
- return FALSE;
+ return TRUE;
range->layout->mouse_x = event->x;
range->layout->mouse_y = event->y;
@@ -1364,7 +1374,7 @@
return TRUE;
}
- return FALSE;
+ return TRUE;
}
/**

View File

@@ -1,10 +0,0 @@
--- gtk+-2.4.3/gtk/gtklabel.c~ 2004-06-11 13:50:34.000000000 +0100
+++ gtk+-2.4.3/gtk/gtklabel.c 2004-07-05 13:33:57.000000000 +0100
@@ -1623,6 +1623,7 @@
/* We have to clear the layout, fonts etc. may have changed */
gtk_label_clear_layout (label);
+ gtk_widget_queue_resize (GTK_WIDGET (label));
}
static void

View File

@@ -1,29 +0,0 @@
--- gtk+-2.6.0/configure.in.old 2005-01-01 16:23:45.000000000 +0000
+++ gtk+-2.6.0/configure.in 2005-01-01 16:24:03.000000000 +0000
@@ -360,7 +360,7 @@
AC_MSG_CHECKING([Whether to write dependencies into .pc files])
case $enable_explicit_deps in
auto)
- deplib_check_method=`(./libtool --config; echo eval echo \\$deplib_check_method) | sh`
+ deplib_check_method=`($host_alias-libtool --config; echo eval echo \\$deplib_check_method) | sh`
if test "X$deplib_check_method" = Xnone || test "x$enable_static" = xyes ; then
enable_explicit_deps=yes
else
@@ -688,7 +688,7 @@
dnl Now we check to see if our libtool supports shared lib deps
dnl (in a rather ugly way even)
if $dynworks; then
- pixbuf_libtool_config="${CONFIG_SHELL-/bin/sh} ./libtool --config"
+ pixbuf_libtool_config="${CONFIG_SHELL-/bin/sh} $host_alias-libtool --config"
pixbuf_deplibs_check=`$pixbuf_libtool_config | \
grep '^[[a-z_]]*check[[a-z_]]*_method=[['\''"]]' | \
sed 's/.*[['\''"]]\(.*\)[['\''"]]$/\1/'`
@@ -1512,7 +1512,7 @@
#
# We are using gmodule-no-export now, but I'm leaving the stripping
# code in place for now, since pango and atk still require gmodule.
-export_dynamic=`(./libtool --config; echo eval echo \\$export_dynamic_flag_spec) | sh`
+export_dynamic=`($host_alias-libtool --config; echo eval echo \\$export_dynamic_flag_spec) | sh`
if test -n "$export_dynamic"; then
GDK_PIXBUF_DEP_LIBS=`echo $GDK_PIXBUF_DEP_LIBS | sed -e "s/$export_dynamic//"`
GDK_PIXBUF_XLIB_DEP_LIBS=`echo $GDK_PIXBUF_XLIB_DEP_LIBS | sed -e "s/$export_dynamic//"`

View File

@@ -1,50 +0,0 @@
--- gtk+-2.4.4/gtk/gtkmenushell.c.old Thu Aug 26 23:45:28 2004
+++ gtk+-2.4.4/gtk/gtkmenushell.c Fri Aug 27 00:13:33 2004
@@ -37,7 +37,7 @@
#include "gtktearoffmenuitem.h"
#include "gtkwindow.h"
-#define MENU_SHELL_TIMEOUT 500
+#define MENU_SHELL_TIMEOUT 2000
enum {
DEACTIVATE,
@@ -156,6 +156,7 @@
static GtkContainerClass *parent_class = NULL;
static guint menu_shell_signals[LAST_SIGNAL] = { 0 };
+static int last_crossing_time;
GType
gtk_menu_shell_get_type (void)
@@ -418,6 +419,7 @@
gtk_grab_add (GTK_WIDGET (menu_shell));
menu_shell->have_grab = TRUE;
menu_shell->active = TRUE;
+ last_crossing_time = 0;
}
}
@@ -545,6 +547,13 @@
menu_shell->activate_time = 0;
deactivate = FALSE;
}
+
+ if (last_crossing_time != 0
+ && ((event->time - last_crossing_time) < 500))
+ {
+ last_crossing_time = 0;
+ deactivate = FALSE;
+ }
if (deactivate)
{
@@ -597,6 +606,8 @@
if (menu_shell->active)
{
menu_item = gtk_get_event_widget ((GdkEvent*) event);
+
+ last_crossing_time = event->time;
if (!menu_item ||
(GTK_IS_MENU_ITEM (menu_item) &&

View File

@@ -1,10 +0,0 @@
--- gtk+-2.4.1/Makefile.am~ 2004-01-17 22:15:56.000000000 +0000
+++ gtk+-2.4.1/Makefile.am 2004-05-08 12:25:32.000000000 +0100
@@ -1,6 +1,6 @@
## Makefile.am for GTK+
-SRC_SUBDIRS = gdk-pixbuf gdk gtk modules demos tests contrib
+SRC_SUBDIRS = gdk-pixbuf gdk gtk modules tests contrib
SUBDIRS = po po-properties $(SRC_SUBDIRS) docs build m4macros
# require automake 1.4

View File

@@ -1,151 +0,0 @@
diff -urNd ../gtk+-2.6.0-r2/gtk+-2.6.0/gdk/x11/gdkdrawable-x11.c gtk+-2.6.0/gdk/x11/gdkdrawable-x11.c
--- ../gtk+-2.6.0-r2/gtk+-2.6.0/gdk/x11/gdkdrawable-x11.c 2004-11-30 14:57:14 +00:00
+++ gtk+-2.6.0/gdk/x11/gdkdrawable-x11.c 2005-01-02 15:38:06 +00:00
@@ -576,12 +576,14 @@
GDK_GC_GET_XGC (gc), x, y, (XChar2b *) text, text_length / 2);
}
}
+#ifdef HAVE_XWC
else if (font->type == GDK_FONT_FONTSET)
{
XFontSet fontset = (XFontSet) GDK_FONT_XFONT (font);
XmbDrawString (xdisplay, impl->xid,
fontset, GDK_GC_GET_XGC (gc), x, y, text, text_length);
}
+#endif
else
g_error("undefined font type\n");
}
@@ -613,6 +615,7 @@
GDK_GC_GET_XGC (gc), x, y, text_8bit, text_length);
g_free (text_8bit);
}
+#ifdef HAVE_XWC
else if (font->type == GDK_FONT_FONTSET)
{
if (sizeof(GdkWChar) == sizeof(wchar_t))
@@ -633,6 +636,7 @@
g_free (text_wchar);
}
}
+#endif
else
g_error("undefined font type\n");
}
diff -urNd ../gtk+-2.6.0-r2/gtk+-2.6.0/gdk/x11/gdkfont-x11.c gtk+-2.6.0/gdk/x11/gdkfont-x11.c
--- ../gtk+-2.6.0-r2/gtk+-2.6.0/gdk/x11/gdkfont-x11.c 2004-08-26 01:23:46 +01:00
+++ gtk+-2.6.0/gdk/x11/gdkfont-x11.c 2005-01-02 15:45:39 +00:00
@@ -525,10 +525,12 @@
width = XTextWidth16 (xfont, (XChar2b *) text, text_length / 2);
}
break;
+#ifdef HAVE_XWC
case GDK_FONT_FONTSET:
fontset = (XFontSet) private->xfont;
width = XmbTextEscapement (fontset, text, text_length);
break;
+#endif
default:
width = 0;
}
@@ -578,6 +580,7 @@
width = 0;
}
break;
+#ifdef HAVE_XWC
case GDK_FONT_FONTSET:
if (sizeof(GdkWChar) == sizeof(wchar_t))
{
@@ -595,6 +598,7 @@
g_free (text_wchar);
}
break;
+#endif
default:
width = 0;
}
@@ -667,6 +671,7 @@
if (descent)
*descent = overall.descent;
break;
+#ifdef HAVE_XWC
case GDK_FONT_FONTSET:
fontset = (XFontSet) private->xfont;
XmbTextExtents (fontset, text, text_length, &ink, &logical);
@@ -681,6 +686,7 @@
if (descent)
*descent = ink.y + ink.height;
break;
+#endif
}
}
@@ -753,6 +759,7 @@
*descent = overall.descent;
break;
}
+#ifdef HAVE_XWC
case GDK_FONT_FONTSET:
fontset = (XFontSet) private->xfont;
@@ -780,6 +787,7 @@
if (descent)
*descent = ink.y + ink.height;
break;
+#endif
}
}
diff -urNd ../gtk+-2.6.0-r2/gtk+-2.6.0/gdk/x11/gdkim-x11.c gtk+-2.6.0/gdk/x11/gdkim-x11.c
--- ../gtk+-2.6.0-r2/gtk+-2.6.0/gdk/x11/gdkim-x11.c 2004-11-17 00:55:10 +00:00
+++ gtk+-2.6.0/gdk/x11/gdkim-x11.c 2005-01-02 15:42:04 +00:00
@@ -48,6 +48,7 @@
void
_gdk_x11_initialize_locale (void)
{
+#ifdef HAVE_XWC
wchar_t result;
gchar *current_locale;
static char *last_locale = NULL;
@@ -93,7 +94,8 @@
GDK_NOTE (XIM,
g_message ("%s multi-byte string functions.",
gdk_use_mb ? "Using" : "Not using"));
-
+#endif
+
return;
}
@@ -136,6 +138,7 @@
{
gchar *mbstr;
+#ifdef HAVE_XWC
if (gdk_use_mb)
{
GdkDisplay *display = find_a_display ();
@@ -178,6 +181,7 @@
XFree (tpr.value);
}
else
+#endif
{
gint length = 0;
gint i;
@@ -210,6 +214,7 @@
gint
gdk_mbstowcs (GdkWChar *dest, const gchar *src, gint dest_max)
{
+#ifdef HAVE_XWC
if (gdk_use_mb)
{
GdkDisplay *display = find_a_display ();
@@ -242,6 +247,7 @@
return len_cpy;
}
else
+#endif
{
gint i;

View File

@@ -1,18 +0,0 @@
Index: gtk/gtkrange.c
===================================================================
--- gtk/gtkrange.c (revision 18542)
+++ gtk/gtkrange.c (working copy)
@@ -1569,9 +1569,12 @@
gtk_widget_queue_draw (GTK_WIDGET (range));
/* This is so we don't lag the widget being scrolled. */
+#if 0
+ /* Disable this, the scroll bar lags a bit but the end result is that
+ scrolling treeviews is *a lot* smoother. See GNOME #460534. */
if (GTK_WIDGET_REALIZED (range))
gdk_window_process_updates (GTK_WIDGET (range)->window, FALSE);
-
+#endif
/* Note that we don't round off to range->round_digits here.
* that's because it's really broken to change a value
* in response to a change signal on that value; round_digits

View File

@@ -1,15 +0,0 @@
--- gtk+-2.4.4/gtk/gtkrange.c~ 2004-08-23 01:50:22.000000000 +0100
+++ gtk+-2.4.4/gtk/gtkrange.c 2004-08-27 15:48:49.000000000 +0100
@@ -35,9 +35,9 @@
#include "gtkintl.h"
#include "gtkscrollbar.h"
-#define SCROLL_INITIAL_DELAY 250 /* must hold button this long before ... */
-#define SCROLL_LATER_DELAY 100 /* ... it starts repeating at this rate */
-#define UPDATE_DELAY 300 /* Delay for queued update */
+#define SCROLL_INITIAL_DELAY 500 /* must hold button this long before ... */
+#define SCROLL_LATER_DELAY 200 /* ... it starts repeating at this rate */
+#define UPDATE_DELAY 1000 /* Delay for queued update */
enum {
PROP_0,

View File

@@ -1,47 +0,0 @@
Index: gtkfilechooserdefault.c
===================================================================
RCS file: /cvs/gnome/gtk+/gtk/gtkfilechooserdefault.c,v
retrieving revision 1.240.2.25
diff -u -p -r1.240.2.25 gtkfilechooserdefault.c
--- gtk+/gtk/gtkfilechooserdefault.c 7 Jul 2005 17:14:09 -0000 1.240.2.25
+++ gtk+/gtk/gtkfilechooserdefault.c 27 Oct 2006 14:22:28 -0000
@@ -3728,6 +3728,7 @@ browse_widgets_create (GtkFileChooserDef
GtkWidget *vbox;
GtkWidget *hpaned;
GtkWidget *widget;
+ GtkWidget *shortcuts_pane;
GtkSizeGroup *size_group;
/* size group is used by the [+][-] buttons and the filter combo */
@@ -3740,12 +3741,29 @@ browse_widgets_create (GtkFileChooserDef
gtk_paned_set_position (GTK_PANED (hpaned), 200); /* FIXME: this sucks */
gtk_box_pack_start (GTK_BOX (vbox), hpaned, TRUE, TRUE, 0);
- widget = shortcuts_pane_create (impl, size_group);
- gtk_paned_pack1 (GTK_PANED (hpaned), widget, FALSE, FALSE);
+ shortcuts_pane = shortcuts_pane_create (impl, size_group);
+ gtk_paned_pack1 (GTK_PANED (hpaned), shortcuts_pane, FALSE, FALSE);
widget = file_pane_create (impl, size_group);
gtk_paned_pack2 (GTK_PANED (hpaned), widget, TRUE, FALSE);
g_object_unref (size_group);
+
+
+ /* remove excess baggage from the filechooser for small displays */
+
+ /* get the columns in the tree view and remove the last column (should be Modified column) */
+ GList *column_list;
+ column_list = gtk_tree_view_get_columns (GTK_TREE_VIEW (impl->browse_files_tree_view));
+ gtk_tree_view_remove_column (GTK_TREE_VIEW (impl->browse_files_tree_view), (g_list_last (column_list))->data);
+ g_list_free (column_list);
+
+ /* hide the tree view headers */
+ gtk_tree_view_set_headers_visible (GTK_TREE_VIEW (impl->browse_files_tree_view), FALSE);
+
+ /* hide the shortcuts pane */
+ gtk_widget_hide (GTK_WIDGET (shortcuts_pane));
+
+
return vbox;
}

View File

@@ -1,69 +0,0 @@
Index: gtk/gtkcellrenderertoggle.c
===================================================================
--- gtk/gtkcellrenderertoggle.c (revision 18542)
+++ gtk/gtkcellrenderertoggle.c (working copy)
@@ -80,6 +80,8 @@
typedef struct _GtkCellRendererTogglePrivate GtkCellRendererTogglePrivate;
struct _GtkCellRendererTogglePrivate
{
+ gint indicator_size;
+ GtkWidget *cached_widget;
guint inconsistent : 1;
};
@@ -281,6 +283,27 @@
}
static void
+on_widget_style_set (GtkWidget *widget, GtkStyle *previous, gpointer user_data)
+{
+ GtkCellRendererTogglePrivate *priv = user_data;
+ PangoContext *context;
+ PangoFontMetrics *metrics;
+ int height;
+
+ context = gtk_widget_get_pango_context (widget);
+ metrics = pango_context_get_metrics (context,
+ widget->style->font_desc,
+ pango_context_get_language (context));
+
+ height = pango_font_metrics_get_ascent (metrics) +
+ pango_font_metrics_get_descent (metrics);
+
+ pango_font_metrics_unref (metrics);
+
+ priv->indicator_size = PANGO_PIXELS (height * 0.85);
+}
+
+static void
gtk_cell_renderer_toggle_get_size (GtkCellRenderer *cell,
GtkWidget *widget,
GdkRectangle *cell_area,
@@ -291,10 +314,25 @@
{
gint calc_width;
gint calc_height;
+ GtkCellRendererTogglePrivate *priv;
- calc_width = (gint) cell->xpad * 2 + TOGGLE_WIDTH;
- calc_height = (gint) cell->ypad * 2 + TOGGLE_WIDTH;
+ priv = GTK_CELL_RENDERER_TOGGLE_GET_PRIVATE (cell);
+ if (priv->cached_widget != widget) {
+ if (priv->cached_widget) {
+ g_object_remove_weak_pointer (widget, &priv->cached_widget);
+ g_signal_handlers_disconnect_by_func (priv->cached_widget, on_widget_style_set, priv);
+ }
+ priv->cached_widget = widget;
+ g_object_add_weak_pointer (widget, &priv->cached_widget);
+ g_signal_connect (widget, "style-set", on_widget_style_set, priv);
+
+ on_widget_style_set (widget, NULL, priv);
+ }
+
+ calc_width = (gint) cell->xpad * 2 + priv->indicator_size;
+ calc_height = (gint) cell->ypad * 2 + priv->indicator_size;
+
if (width)
*width = calc_width;

View File

@@ -1,54 +0,0 @@
require gtk+.inc
PR = "r15"
SRC_URI = "ftp://ftp.gtk.org/pub/gtk/v2.6/gtk+-${PV}.tar.bz2 \
file://no-demos.patch;patch=1 \
file://no-xwc.patch;patch=1 \
file://automake-lossage.patch;patch=1 \
file://gtk+-handhelds.patch;patch=1 \
file://hardcoded_libtool.patch;patch=1 \
file://disable-tooltips.patch;patch=1 \
file://gtklabel-resize-patch;patch=1 \
file://menu-deactivate.patch;patch=1 \
file://scroll-timings.patch;patch=1 \
file://filesystem-volumes.patch;patch=1 \
file://filechooser-respect-style.patch;patch=1 \
file://filechooser-default.patch;patch=1 \
file://toggle-font.diff;patch=1;pnum=0 \
file://combo-arrow-size.patch;patch=1;pnum=0 \
file://range-no-redraw.patch;patch=1;pnum=0 \
"
EXTRA_OECONF = "--without-libtiff --disable-xkb --disable-glibtest"
LIBV = "2.4.0"
LEAD_SONAME = "libgtk-x11*"
do_configure_prepend() {
for i in `find . -name "Makefile.am"`
do
sed -i -e s,-DG_DISABLE_DEPRECATED,-DSED_ROCKS_DUDES, $i
done
}
PACKAGES_DYNAMIC = "gdk-pixbuf-loader-* gtk-immodule-*"
python populate_packages_prepend () {
import os.path
prologue = bb.data.getVar("postinst_prologue", d, 1)
postinst_pixbufloader = bb.data.getVar("postinst_pixbufloader", d, 1)
gtk_libdir = bb.data.expand('${libdir}/gtk-2.0/${LIBV}', d)
loaders_root = os.path.join(gtk_libdir, 'loaders')
immodules_root = os.path.join(gtk_libdir, 'immodules')
do_split_packages(d, loaders_root, '^libpixbufloader-(.*)\.so$', 'gdk-pixbuf-loader-%s', 'GDK pixbuf loader for %s', postinst_pixbufloader)
do_split_packages(d, immodules_root, '^im-(.*)\.so$', 'gtk-immodule-%s', 'GTK input module for %s', prologue + 'gtk-query-immodules-2.0 > /etc/gtk-2.0/gtk.immodules')
if (bb.data.getVar('DEBIAN_NAMES', d, 1)):
bb.data.setVar('PKG_${PN}', 'libgtk-2.0', d)
}