aboutsummaryrefslogtreecommitdiffstats
path: root/packages/gtk+/gtk+-2.6.4-1.osso7
diff options
context:
space:
mode:
Diffstat (limited to 'packages/gtk+/gtk+-2.6.4-1.osso7')
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/.mtn2git_empty0
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/000_gtk+-2.0.6-exportsymbols.patch26
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/000_gtk+-2.2.0-buildfix-immodule.patch33
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/002_xpmico.patch18
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/003_iconcache.patch11
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/automake-lossage.patch24
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/configure.diff1885
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/configure.in.diff53
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/disable-tooltips.patch11
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gdkwindow-x11.c.diff38
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtk+-handhelds.patch236
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtk.h.diff10
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtk_Makefile.am.diff27
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtk_Makefile.in.diff292
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkalias.h.diff17
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkbutton.c.diff471
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkbutton.h.diff23
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkcalendar.c.diff2464
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkcalendar.h.diff12
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellrenderertext.c.diff66
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellrenderertoggle.c.diff11
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellview.c.diff19
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellview.h.diff10
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkcheckbutton.c.diff520
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkcombobox.c.diff950
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkcomboboxentry.c.diff24
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkcontainer.c.diff284
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkdialog.c.diff451
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkdnd.c.diff12
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkentry.c.diff1308
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkenums.h.diff15
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkfilesystem.c.diff12
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkfilesystem.h.diff12
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkframe.c.diff82
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkhashtable.c.diff102
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkhashtable.h.diff64
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkhbbox.c.diff344
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkhseparator.c.diff40
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkiconfactory.c.diff69
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkicontheme.c.diff48
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkimcontext.c.diff52
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkimcontext.h.diff29
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkimmulticontext.c.diff155
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel-resize-patch10
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel.c.diff390
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel.h.diff29
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkmain.c.diff35
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshal.c.diff266
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshal.h.diff284
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshalers.c.diff606
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshalers.h.diff622
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenu.c.diff1223
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenu.h.diff12
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenuitem.c.diff457
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenuitem.h.diff10
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenushell.c.diff490
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenushell.h.diff12
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtknotebook.c.diff831
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkprogress.c.diff20
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkprogressbar.c.diff141
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkradiobutton.c.diff244
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkrange.c.diff845
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkrange.h.diff29
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkrbtree.c.diff48
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkrc.c.diff581
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkrc.h.diff19
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkscrolledwindow.c.diff162
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkseparator.c.diff21
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkseparatortoolitem.c.diff90
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtksettings.c.diff66
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkspinbutton.c.diff50
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkstyle.c.diff250
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkstyle.h.diff13
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktable.c.diff95
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktextbuffer.c.diff443
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktextbuffer.h.diff17
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktextbufferserialize.c.diff1688
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktextbufferserialize.h.diff40
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktextview.c.diff417
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktoolbar.c.diff252
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktoolbutton.c.diff65
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktoolbutton.h.diff10
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktreemodelfilter.c.diff52
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktreemodelsort.c.diff21
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktreeprivate.h.diff58
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktreeselection.c.diff91
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktreeview.c.diff2253
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktreeview.h.diff18
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktreeviewcolumn.c.diff51
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktypebuiltins.c.diff86
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtktypebuiltins.h.diff24
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkvseparator.c.diff45
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkwidget.c.diff1046
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkwidget.h.diff59
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkwindow.c.diff78
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/gtkwindow.h.diff13
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/hardcoded_libtool.patch29
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/io-gif-animation.c.diff108
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/io-gif.c.diff37
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/menu-deactivate.patch50
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/no-demos.patch10
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/no-xwc.patch151
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/scroll-timings.patch15
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/single-click.patch54
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/small-gtkfilesel.patch267
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/spinbutton.patch128
-rw-r--r--packages/gtk+/gtk+-2.6.4-1.osso7/xsettings.patch16
107 files changed, 25973 insertions, 0 deletions
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/.mtn2git_empty b/packages/gtk+/gtk+-2.6.4-1.osso7/.mtn2git_empty
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/.mtn2git_empty
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/000_gtk+-2.0.6-exportsymbols.patch b/packages/gtk+/gtk+-2.6.4-1.osso7/000_gtk+-2.0.6-exportsymbols.patch
index e69de29bb2..736473696f 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/000_gtk+-2.0.6-exportsymbols.patch
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/000_gtk+-2.0.6-exportsymbols.patch
@@ -0,0 +1,26 @@
+diff -ruN gtk+-2.0.6.orig/configure gtk+-2.0.6/configure
+--- gtk+-2.0.6.orig/configure 2002-08-31 03:49:07.000000000 +0900
++++ gtk+-2.0.6/configure 2002-08-31 03:52:45.000000000 +0900
+@@ -7904,7 +7904,8 @@
+ if test "$os_win32" != yes; then
+ # libtool option to control which symbols are exported
+ # right now, symbols starting with _ are not exported
+- LIBTOOL_EXPORT_OPTIONS='-export-symbols-regex "^[^_].*"'
++ # Disabled until -export-symbols-regex works (RH patch)
++ LIBTOOL_EXPORT_OPTIONS=
+ else
+ # We currently use .def files on Windows (for gdk-pixbuf, gdk and gtk)
+ LIBTOOL_EXPORT_OPTIONS=
+diff -ruN gtk+-2.0.6.orig/configure.in gtk+-2.0.6/configure.in
+--- gtk+-2.0.6.orig/configure.in 2002-08-31 03:49:07.000000000 +0900
++++ gtk+-2.0.6/configure.in 2002-08-31 03:51:22.000000000 +0900
+@@ -273,7 +273,8 @@
+ if test "$os_win32" != yes; then
+ # libtool option to control which symbols are exported
+ # right now, symbols starting with _ are not exported
+- LIBTOOL_EXPORT_OPTIONS='-export-symbols-regex "^[[^_]].*"'
++ # Disabled until -export-symbols-regex works (RH patch)
++ LIBTOOL_EXPORT_OPTIONS=
+ else
+ # We currently use .def files on Windows (for gdk-pixbuf, gdk and gtk)
+ LIBTOOL_EXPORT_OPTIONS=
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/000_gtk+-2.2.0-buildfix-immodule.patch b/packages/gtk+/gtk+-2.6.4-1.osso7/000_gtk+-2.2.0-buildfix-immodule.patch
index e69de29bb2..5d80daf0bc 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/000_gtk+-2.2.0-buildfix-immodule.patch
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/000_gtk+-2.2.0-buildfix-immodule.patch
@@ -0,0 +1,33 @@
+diff -ruN gtk+-2.2.0.orig/modules/input/Makefile.am gtk+-2.2.0/modules/input/Makefile.am
+--- gtk+-2.2.0.orig/modules/input/Makefile.am 2003-01-06 23:40:37.000000000 +0900
++++ gtk+-2.2.0/modules/input/Makefile.am 2003-01-06 23:46:35.000000000 +0900
+@@ -118,7 +118,12 @@
+ im-viqr.la
+
+ gtk.immodules: Makefile.am $(module_LTLIBRARIES)
+- $(top_builddir)/gtk/gtk-query-immodules-2.0 $(module_LTLIBRARIES) > gtk.immodules
++ @if $(RUN_QUERY_IMMODULES_TEST) ; then \
++ $(top_builddir)/gtk/gtk-query-immodules-2.0 $(module_LTLIBRARIES) > gtk.immodules ; \
++ else \
++ touch $@ ; \
++ fi
++
+
+ CLEANFILES = gtk.immodules
+
+diff -ruN gtk+-2.2.0.orig/modules/input/Makefile.in gtk+-2.2.0/modules/input/Makefile.in
+--- gtk+-2.2.0.orig/modules/input/Makefile.in 2003-01-06 23:39:08.000000000 +0900
++++ gtk+-2.2.0/modules/input/Makefile.in 2003-01-06 23:46:44.000000000 +0900
+@@ -785,7 +785,11 @@
+ rm -f $(DESTDIR)$(sysconfdir)/gtk-2.0/gtk.immodules
+
+ gtk.immodules: Makefile.am $(module_LTLIBRARIES)
+- $(top_builddir)/gtk/gtk-query-immodules-2.0 $(module_LTLIBRARIES) > gtk.immodules
++ @if $(RUN_QUERY_IMMODULES_TEST) ; then \
++ $(top_builddir)/gtk/gtk-query-immodules-2.0 $(module_LTLIBRARIES) > gtk.immodules ; \
++ else \
++ touch $@ ; \
++ fi
+
+ @CROSS_COMPILING_FALSE@all-local: gtk.immodules
+ # Tell versions [3.59,3.63) of GNU make to not export all variables.
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/002_xpmico.patch b/packages/gtk+/gtk+-2.6.4-1.osso7/002_xpmico.patch
index e69de29bb2..21500db65a 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/002_xpmico.patch
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/002_xpmico.patch
@@ -0,0 +1,18 @@
+diff -Nur gtk+-2.4.9.orig/gdk-pixbuf/io-ico.c gtk+-2.4.9/gdk-pixbuf/io-ico.c
+--- gtk+-2.4.9.orig/gdk-pixbuf/io-ico.c 2004-08-25 18:52:18.000000000 +0200
++++ gtk+-2.4.9/gdk-pixbuf/io-ico.c 2004-09-15 00:40:17.000000000 +0200
+@@ -210,6 +210,14 @@
+
+ State->HeaderSize = 6 + IconCount*16;
+
++ if (State->HeaderSize < 0) {
++ g_set_error (error,
++ GDK_PIXBUF_ERROR,
++ GDK_PIXBUF_ERROR_CORRUPT_IMAGE,
++ _("Invalid header in icon"));
++ return;
++ }
++
+ if (State->HeaderSize>State->BytesInHeaderBuf) {
+ guchar *tmp=g_try_realloc(State->HeaderBuf,State->HeaderSize);
+ if (!tmp) {
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/003_iconcache.patch b/packages/gtk+/gtk+-2.6.4-1.osso7/003_iconcache.patch
index e69de29bb2..e579c8e208 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/003_iconcache.patch
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/003_iconcache.patch
@@ -0,0 +1,11 @@
+--- gtk/updateiconcache.c.orig 2005-02-06 21:08:09.638762480 +0100
++++ gtk+-2.6.2/gtk/updateiconcache.c 2005-02-06 21:15:13.639304600 +0100
+@@ -53,7 +53,7 @@
+ gchar *cache_path;
+ int retval;
+
+- retval = g_stat (path, &path_stat);
++ retval = stat (path, &path_stat);
+
+ if (retval < 0)
+ {
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/automake-lossage.patch b/packages/gtk+/gtk+-2.6.4-1.osso7/automake-lossage.patch
index e69de29bb2..0d423ddbb9 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/automake-lossage.patch
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/automake-lossage.patch
@@ -0,0 +1,24 @@
+--- 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
+
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/configure.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/configure.diff
index e69de29bb2..77cda1ce27 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/configure.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/configure.diff
@@ -0,0 +1,1885 @@
+--- gtk+-2.6.4/configure 2005-03-30 15:05:06.000000000 +0300
++++ gtk+-2.6.4/configure 2005-03-30 15:07:58.000000000 +0300
+@@ -1057,6 +1057,7 @@
+ --enable-xkb support XKB [default=maybe]
+ --disable-rebuilds disable all source autogeneration rules
+ --disable-visibility don't use ELF visibility attributes
++ --disable-shortcuts disable keyboard shortcuts
+ --disable-shadowfb disable shadowfb support for linux-fb
+ --enable-fbmanager enable framebuffer manager support (GtkFB)
+ --enable-explicit-deps=[yes/no/auto]
+@@ -1197,7 +1198,7 @@
+ else
+ echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
+ fi
+- cd $ac_popdir
++ cd "$ac_popdir"
+ done
+ fi
+
+@@ -2663,8 +2664,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -2722,8 +2722,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -2839,8 +2838,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -2894,8 +2892,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -2940,8 +2937,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -2985,8 +2981,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -3759,7 +3754,7 @@
+ ;;
+ *-*-irix6*)
+ # Find out which ABI we are using.
+- echo '#line 3762 "configure"' > conftest.$ac_ext
++ echo '#line 3757 "configure"' > conftest.$ac_ext
+ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+@@ -3879,8 +3874,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -4189,8 +4183,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -4360,8 +4353,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -4428,8 +4420,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -4689,8 +4680,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_cxx_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -4748,8 +4738,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_cxx_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -4820,8 +4809,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_cxx_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -4865,8 +4853,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_cxx_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -5331,7 +5318,7 @@
+
+
+ # Provide some information about the compiler.
+-echo "$as_me:5334:" \
++echo "$as_me:5321:" \
+ "checking for Fortran 77 compiler version" >&5
+ ac_compiler=`set X $ac_compile; echo $2`
+ { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
+@@ -5377,8 +5364,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_f77_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_f77_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -5427,8 +5413,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_f77_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_f77_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -6388,11 +6373,11 @@
+ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
+ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
+ -e 's:$: $lt_compiler_flag:'`
+- (eval echo "\"\$as_me:6391: $lt_compile\"" >&5)
++ (eval echo "\"\$as_me:6376: $lt_compile\"" >&5)
+ (eval "$lt_compile" 2>conftest.err)
+ ac_status=$?
+ cat conftest.err >&5
+- echo "$as_me:6395: \$? = $ac_status" >&5
++ echo "$as_me:6380: \$? = $ac_status" >&5
+ if (exit $ac_status) && test -s "$ac_outfile"; then
+ # The compiler can only warn and ignore the option if not recognized
+ # So say no if there are warnings
+@@ -6631,11 +6616,11 @@
+ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
+ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
+ -e 's:$: $lt_compiler_flag:'`
+- (eval echo "\"\$as_me:6634: $lt_compile\"" >&5)
++ (eval echo "\"\$as_me:6619: $lt_compile\"" >&5)
+ (eval "$lt_compile" 2>conftest.err)
+ ac_status=$?
+ cat conftest.err >&5
+- echo "$as_me:6638: \$? = $ac_status" >&5
++ echo "$as_me:6623: \$? = $ac_status" >&5
+ if (exit $ac_status) && test -s "$ac_outfile"; then
+ # The compiler can only warn and ignore the option if not recognized
+ # So say no if there are warnings
+@@ -6691,11 +6676,11 @@
+ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
+ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
+ -e 's:$: $lt_compiler_flag:'`
+- (eval echo "\"\$as_me:6694: $lt_compile\"" >&5)
++ (eval echo "\"\$as_me:6679: $lt_compile\"" >&5)
+ (eval "$lt_compile" 2>out/conftest.err)
+ ac_status=$?
+ cat out/conftest.err >&5
+- echo "$as_me:6698: \$? = $ac_status" >&5
++ echo "$as_me:6683: \$? = $ac_status" >&5
+ if (exit $ac_status) && test -s out/conftest2.$ac_objext
+ then
+ # The compiler can only warn and ignore the option if not recognized
+@@ -7082,8 +7067,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -7143,8 +7127,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -8026,7 +8009,7 @@
+ libsuff=
+ case "$host_cpu" in
+ x86_64*|s390x*|powerpc64*)
+- echo '#line 8029 "configure"' > conftest.$ac_ext
++ echo '#line 8012 "configure"' > conftest.$ac_ext
+ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+@@ -8357,8 +8340,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -8461,8 +8443,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -8527,8 +8508,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -8621,8 +8601,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -8687,8 +8666,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -8754,8 +8732,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -8821,8 +8798,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -8897,7 +8873,7 @@
+ lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+ lt_status=$lt_dlunknown
+ cat > conftest.$ac_ext <<EOF
+-#line 8900 "configure"
++#line 8876 "configure"
+ #include "confdefs.h"
+
+ #if HAVE_DLFCN_H
+@@ -8995,7 +8971,7 @@
+ lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+ lt_status=$lt_dlunknown
+ cat > conftest.$ac_ext <<EOF
+-#line 8998 "configure"
++#line 8974 "configure"
+ #include "confdefs.h"
+
+ #if HAVE_DLFCN_H
+@@ -10032,8 +10008,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_cxx_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -10094,8 +10069,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_cxx_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -11188,11 +11162,11 @@
+ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
+ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
+ -e 's:$: $lt_compiler_flag:'`
+- (eval echo "\"\$as_me:11191: $lt_compile\"" >&5)
++ (eval echo "\"\$as_me:11165: $lt_compile\"" >&5)
+ (eval "$lt_compile" 2>conftest.err)
+ ac_status=$?
+ cat conftest.err >&5
+- echo "$as_me:11195: \$? = $ac_status" >&5
++ echo "$as_me:11169: \$? = $ac_status" >&5
+ if (exit $ac_status) && test -s "$ac_outfile"; then
+ # The compiler can only warn and ignore the option if not recognized
+ # So say no if there are warnings
+@@ -11248,11 +11222,11 @@
+ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
+ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
+ -e 's:$: $lt_compiler_flag:'`
+- (eval echo "\"\$as_me:11251: $lt_compile\"" >&5)
++ (eval echo "\"\$as_me:11225: $lt_compile\"" >&5)
+ (eval "$lt_compile" 2>out/conftest.err)
+ ac_status=$?
+ cat out/conftest.err >&5
+- echo "$as_me:11255: \$? = $ac_status" >&5
++ echo "$as_me:11229: \$? = $ac_status" >&5
+ if (exit $ac_status) && test -s out/conftest2.$ac_objext
+ then
+ # The compiler can only warn and ignore the option if not recognized
+@@ -11759,7 +11733,7 @@
+ libsuff=
+ case "$host_cpu" in
+ x86_64*|s390x*|powerpc64*)
+- echo '#line 11762 "configure"' > conftest.$ac_ext
++ echo '#line 11736 "configure"' > conftest.$ac_ext
+ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+@@ -12090,8 +12064,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_cxx_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -12194,8 +12167,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_cxx_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -12260,8 +12232,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_cxx_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -12354,8 +12325,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_cxx_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -12420,8 +12390,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_cxx_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -12487,8 +12456,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_cxx_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -12554,8 +12522,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_cxx_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -12630,7 +12597,7 @@
+ lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+ lt_status=$lt_dlunknown
+ cat > conftest.$ac_ext <<EOF
+-#line 12633 "configure"
++#line 12600 "configure"
+ #include "confdefs.h"
+
+ #if HAVE_DLFCN_H
+@@ -12728,7 +12695,7 @@
+ lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+ lt_status=$lt_dlunknown
+ cat > conftest.$ac_ext <<EOF
+-#line 12731 "configure"
++#line 12698 "configure"
+ #include "confdefs.h"
+
+ #if HAVE_DLFCN_H
+@@ -13565,11 +13532,11 @@
+ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
+ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
+ -e 's:$: $lt_compiler_flag:'`
+- (eval echo "\"\$as_me:13568: $lt_compile\"" >&5)
++ (eval echo "\"\$as_me:13535: $lt_compile\"" >&5)
+ (eval "$lt_compile" 2>conftest.err)
+ ac_status=$?
+ cat conftest.err >&5
+- echo "$as_me:13572: \$? = $ac_status" >&5
++ echo "$as_me:13539: \$? = $ac_status" >&5
+ if (exit $ac_status) && test -s "$ac_outfile"; then
+ # The compiler can only warn and ignore the option if not recognized
+ # So say no if there are warnings
+@@ -13625,11 +13592,11 @@
+ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
+ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
+ -e 's:$: $lt_compiler_flag:'`
+- (eval echo "\"\$as_me:13628: $lt_compile\"" >&5)
++ (eval echo "\"\$as_me:13595: $lt_compile\"" >&5)
+ (eval "$lt_compile" 2>out/conftest.err)
+ ac_status=$?
+ cat out/conftest.err >&5
+- echo "$as_me:13632: \$? = $ac_status" >&5
++ echo "$as_me:13599: \$? = $ac_status" >&5
+ if (exit $ac_status) && test -s out/conftest2.$ac_objext
+ then
+ # The compiler can only warn and ignore the option if not recognized
+@@ -14006,8 +13973,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_f77_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_f77_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -14057,8 +14023,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_f77_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_f77_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -14940,7 +14905,7 @@
+ libsuff=
+ case "$host_cpu" in
+ x86_64*|s390x*|powerpc64*)
+- echo '#line 14943 "configure"' > conftest.$ac_ext
++ echo '#line 14908 "configure"' > conftest.$ac_ext
+ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+@@ -15681,11 +15646,11 @@
+ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
+ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
+ -e 's:$: $lt_compiler_flag:'`
+- (eval echo "\"\$as_me:15684: $lt_compile\"" >&5)
++ (eval echo "\"\$as_me:15649: $lt_compile\"" >&5)
+ (eval "$lt_compile" 2>conftest.err)
+ ac_status=$?
+ cat conftest.err >&5
+- echo "$as_me:15688: \$? = $ac_status" >&5
++ echo "$as_me:15653: \$? = $ac_status" >&5
+ if (exit $ac_status) && test -s "$ac_outfile"; then
+ # The compiler can only warn and ignore the option if not recognized
+ # So say no if there are warnings
+@@ -15924,11 +15889,11 @@
+ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
+ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
+ -e 's:$: $lt_compiler_flag:'`
+- (eval echo "\"\$as_me:15927: $lt_compile\"" >&5)
++ (eval echo "\"\$as_me:15892: $lt_compile\"" >&5)
+ (eval "$lt_compile" 2>conftest.err)
+ ac_status=$?
+ cat conftest.err >&5
+- echo "$as_me:15931: \$? = $ac_status" >&5
++ echo "$as_me:15896: \$? = $ac_status" >&5
+ if (exit $ac_status) && test -s "$ac_outfile"; then
+ # The compiler can only warn and ignore the option if not recognized
+ # So say no if there are warnings
+@@ -15984,11 +15949,11 @@
+ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
+ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
+ -e 's:$: $lt_compiler_flag:'`
+- (eval echo "\"\$as_me:15987: $lt_compile\"" >&5)
++ (eval echo "\"\$as_me:15952: $lt_compile\"" >&5)
+ (eval "$lt_compile" 2>out/conftest.err)
+ ac_status=$?
+ cat out/conftest.err >&5
+- echo "$as_me:15991: \$? = $ac_status" >&5
++ echo "$as_me:15956: \$? = $ac_status" >&5
+ if (exit $ac_status) && test -s out/conftest2.$ac_objext
+ then
+ # The compiler can only warn and ignore the option if not recognized
+@@ -16375,8 +16340,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -16436,8 +16400,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -17319,7 +17282,7 @@
+ libsuff=
+ case "$host_cpu" in
+ x86_64*|s390x*|powerpc64*)
+- echo '#line 17322 "configure"' > conftest.$ac_ext
++ echo '#line 17285 "configure"' > conftest.$ac_ext
+ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+@@ -17650,8 +17613,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -17754,8 +17716,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -17820,8 +17781,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -17914,8 +17874,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -17980,8 +17939,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -18047,8 +18005,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -18114,8 +18071,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -18190,7 +18146,7 @@
+ lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+ lt_status=$lt_dlunknown
+ cat > conftest.$ac_ext <<EOF
+-#line 18193 "configure"
++#line 18149 "configure"
+ #include "confdefs.h"
+
+ #if HAVE_DLFCN_H
+@@ -18288,7 +18244,7 @@
+ lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+ lt_status=$lt_dlunknown
+ cat > conftest.$ac_ext <<EOF
+-#line 18291 "configure"
++#line 18247 "configure"
+ #include "confdefs.h"
+
+ #if HAVE_DLFCN_H
+@@ -19354,8 +19310,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -19384,8 +19339,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -19455,8 +19409,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -19508,8 +19461,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -19580,8 +19532,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -19633,8 +19584,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -19849,6 +19799,18 @@
+ else
+ enable_visibility=yes
+ fi;
++# modification for Device to disable keyboard shortcuts
++# Check whether --enable-shortcuts or --disable-shortcuts was given.
++if test "${enable_shortcuts+set}" = set; then
++ enableval="$enable_shortcuts"
++
++else
++ enable_shortcuts=yes
++fi;
++
++if test "x$enable_shortcuts" = "xno"; then
++ GTK_EXTRA_CFLAGS="$GTK_EXTRA_CFLAGS -DDISABLE_KEYBOARD_SHORTCUTS"
++fi;
+
+
+ # Check whether --with-xinput or --without-xinput was given.
+@@ -20018,8 +19980,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -20124,8 +20085,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -20652,8 +20612,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -20716,8 +20675,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -20753,7 +20711,7 @@
+ # sure that both po/ and po-properties/ have .po files that correspond
+ # to your language. If you only add one to po/, the build will break
+ # in po-properties/.
+-ALL_LINGUAS="af am ar az az_IR be bg bn br bs ca cs cy da de el en_CA en_GB es et eu fa fi fr ga gl gu he hi hr hu ia id is it ja ko li lt lv mi mk ml mn mr ms nb ne nl nn no nso pa pl pt pt_BR ro ru rw sk sl sq sr sr@ije sr@Latn sv ta th tk tr uk uz uz@Latn vi wa xh yi zh_CN zh_TW"
++ALL_LINGUAS=""
+
+
+ for ac_header in locale.h
+@@ -20789,8 +20747,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -20935,8 +20892,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -21007,8 +20963,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -21152,8 +21107,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -21211,8 +21165,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -21309,8 +21262,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -21389,8 +21341,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -21454,8 +21405,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -21519,8 +21469,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -21597,8 +21546,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -21662,8 +21610,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -21779,8 +21726,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -21947,8 +21893,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -22081,8 +22026,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -22167,8 +22111,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -22469,8 +22412,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -22514,8 +22456,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -22822,8 +22763,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -22949,8 +22889,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -23018,8 +22957,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -23171,8 +23109,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -23324,8 +23261,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -23486,8 +23422,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -23572,8 +23507,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -23666,8 +23600,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -23876,8 +23809,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -23949,8 +23881,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -24014,8 +23945,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -24199,8 +24129,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -24477,8 +24406,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -24579,8 +24507,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -24678,8 +24605,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -24896,8 +24822,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -24962,8 +24887,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -25037,8 +24961,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -25249,8 +25172,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -25306,8 +25228,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -25460,8 +25381,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -25517,8 +25437,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -25671,8 +25590,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -25728,8 +25646,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -25905,8 +25822,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -26022,8 +25938,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -26127,8 +26042,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -26184,8 +26098,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -26330,8 +26243,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -26488,8 +26400,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -26560,8 +26471,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -26881,8 +26791,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -26939,8 +26848,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -27183,8 +27091,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -27295,8 +27202,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -27347,8 +27253,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -27424,8 +27329,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -27480,8 +27384,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -27549,8 +27452,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -27658,8 +27560,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -27723,8 +27624,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -27792,8 +27692,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -27897,8 +27796,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -27962,8 +27860,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -28060,8 +27957,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -28125,8 +28021,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -28223,8 +28118,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -28288,8 +28182,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -28368,8 +28261,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -28462,8 +28354,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -28537,8 +28428,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -28609,8 +28499,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -28709,8 +28598,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -28766,8 +28654,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -28856,8 +28743,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -28907,8 +28793,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -28999,8 +28884,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -29043,8 +28927,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -29119,8 +29002,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -29198,8 +29080,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -29272,8 +29153,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -29350,8 +29230,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -29447,8 +29326,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -29558,8 +29436,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -29609,8 +29486,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -29809,8 +29685,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -29860,8 +29735,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -30015,6 +29889,116 @@
+ GDK_EXTRA_LIBS="`$PKG_CONFIG --libs xfixes` $GDK_EXTRA_LIBS"
+ fi
+
++ # Checks for XFixes extension
++
++ have_xfixes=false
++
++ succeeded=no
++
++ if test -z "$PKG_CONFIG"; then
++ # Extract the first word of "pkg-config", so it can be a program name with args.
++set dummy pkg-config; ac_word=$2
++echo "$as_me:$LINENO: checking for $ac_word" >&5
++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
++if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
++ echo $ECHO_N "(cached) $ECHO_C" >&6
++else
++ case $PKG_CONFIG in
++ [\\/]* | ?:[\\/]*)
++ ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
++ ;;
++ *)
++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
++for as_dir in $PATH
++do
++ IFS=$as_save_IFS
++ test -z "$as_dir" && as_dir=.
++ for ac_exec_ext in '' $ac_executable_extensions; do
++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
++ ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
++ break 2
++ fi
++done
++done
++
++ test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
++ ;;
++esac
++fi
++PKG_CONFIG=$ac_cv_path_PKG_CONFIG
++
++if test -n "$PKG_CONFIG"; then
++ echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5
++echo "${ECHO_T}$PKG_CONFIG" >&6
++else
++ echo "$as_me:$LINENO: result: no" >&5
++echo "${ECHO_T}no" >&6
++fi
++
++ fi
++
++ if test "$PKG_CONFIG" = "no" ; then
++ echo "*** The pkg-config script could not be found. Make sure it is"
++ echo "*** in your path, or set the PKG_CONFIG environment variable"
++ echo "*** to the full path to pkg-config."
++ echo "*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config."
++ else
++ PKG_CONFIG_MIN_VERSION=0.9.0
++ if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
++ echo "$as_me:$LINENO: checking for xfixes" >&5
++echo $ECHO_N "checking for xfixes... $ECHO_C" >&6
++
++ if $PKG_CONFIG --exists "xfixes" ; then
++ echo "$as_me:$LINENO: result: yes" >&5
++echo "${ECHO_T}yes" >&6
++ succeeded=yes
++
++ echo "$as_me:$LINENO: checking XFIXES_CFLAGS" >&5
++echo $ECHO_N "checking XFIXES_CFLAGS... $ECHO_C" >&6
++ XFIXES_CFLAGS=`$PKG_CONFIG --cflags "xfixes"`
++ echo "$as_me:$LINENO: result: $XFIXES_CFLAGS" >&5
++echo "${ECHO_T}$XFIXES_CFLAGS" >&6
++
++ echo "$as_me:$LINENO: checking XFIXES_LIBS" >&5
++echo $ECHO_N "checking XFIXES_LIBS... $ECHO_C" >&6
++ XFIXES_LIBS=`$PKG_CONFIG --libs "xfixes"`
++ echo "$as_me:$LINENO: result: $XFIXES_LIBS" >&5
++echo "${ECHO_T}$XFIXES_LIBS" >&6
++ else
++ XFIXES_CFLAGS=""
++ XFIXES_LIBS=""
++ ## If we have a custom action on failure, don't print errors, but
++ ## do set a variable so people can do so.
++ XFIXES_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "xfixes"`
++
++ fi
++
++
++
++ else
++ echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
++ echo "*** See http://www.freedesktop.org/software/pkgconfig"
++ fi
++ fi
++
++ if test $succeeded = yes; then
++ have_xfixes=true
++ else
++ :
++ fi
++
++
++ if $have_xfixes ; then
++
++cat >>confdefs.h <<\_ACEOF
++#define HAVE_XFIXES 1
++_ACEOF
++
++ GDK_EXTRA_CFLAGS="`$PKG_CONFIG --cflags xfixes` $GDK_EXTRA_CFLAGS"
++ GDK_EXTRA_LIBS="`$PKG_CONFIG --libs xfixes` $GDK_EXTRA_LIBS"
++ fi
++
+ # Xshm checks
+
+ if test "x$enable_shm" = "xyes"; then
+@@ -30049,8 +30033,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -30196,8 +30179,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -30355,8 +30337,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -30651,8 +30632,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -30765,8 +30745,7 @@
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+- { ac_try='test -z "$ac_c_werror_flag"
+- || test ! -s conftest.err'
++ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+@@ -30798,7 +30777,6 @@
+
+ GTK_PACKAGES=atk
+ GTK_EXTRA_LIBS=
+-GTK_EXTRA_CFLAGS=
+ GTK_DEP_LIBS="$GDK_EXTRA_LIBS $GTK_DEP_LIBS_FOR_X `$PKG_CONFIG --libs $GDK_PIXBUF_PACKAGES $GDK_PACKAGES $GTK_PACKAGES` $GTK_EXTRA_LIBS $GDK_PIXBUF_EXTRA_LIBS"
+ GTK_DEP_CFLAGS="`$PKG_CONFIG --cflags gthread-2.0 $GDK_PIXBUF_PACKAGES $GDK_PACKAGES $GTK_PACKAGES` $GDK_PIXBUF_EXTRA_CFLAGS $GDK_EXTRA_CFLAGS $GTK_EXTRA_CFLAGS"
+
+@@ -32514,11 +32492,6 @@
+ *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
+ esac
+
+- if test x"$ac_file" != x-; then
+- { echo "$as_me:$LINENO: creating $ac_file" >&5
+-echo "$as_me: creating $ac_file" >&6;}
+- rm -f "$ac_file"
+- fi
+ # Let's still pretend it is `configure' which instantiates (i.e., don't
+ # use $as_me), people would be surprised to read:
+ # /* config.h. Generated by config.status. */
+@@ -32557,6 +32530,12 @@
+ fi;;
+ esac
+ done` || { (exit 1); exit 1; }
++
++ if test x"$ac_file" != x-; then
++ { echo "$as_me:$LINENO: creating $ac_file" >&5
++echo "$as_me: creating $ac_file" >&6;}
++ rm -f "$ac_file"
++ fi
+ _ACEOF
+ cat >>$CONFIG_STATUS <<_ACEOF
+ sed "$ac_vpsub
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/configure.in.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/configure.in.diff
index e69de29bb2..8573b11739 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/configure.in.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/configure.in.diff
@@ -0,0 +1,53 @@
+--- gtk+-2.6.4/configure.in 2005-03-30 15:05:06.000000000 +0300
++++ gtk+-2.6.4/configure.in 2005-03-30 15:07:36.000000000 +0300
+@@ -202,6 +202,15 @@
+ [AC_HELP_STRING([--disable-visibility],
+ [don't use ELF visibility attributes])],,
+ [enable_visibility=yes])
++# modification for Device to disable keyboard shortcuts
++AC_ARG_ENABLE(shortcuts,
++ [AC_HELP_STRING([--disable-shortcuts],
++ [disable keyboard shortcuts])],,
++ [enable_shortcuts=yes])
++
++if test "x$enable_shortcuts" = "xno"; then
++ GTK_EXTRA_CFLAGS="$GTK_EXTRA_CFLAGS -DDISABLE_KEYBOARD_SHORTCUTS"
++fi;
+
+ AC_ARG_WITH(xinput,
+ [AC_HELP_STRING([--with-xinput=@<:@no/yes@:>@], [support XInput])])
+@@ -418,7 +427,7 @@
+ # sure that both po/ and po-properties/ have .po files that correspond
+ # to your language. If you only add one to po/, the build will break
+ # in po-properties/.
+-ALL_LINGUAS="af am ar az az_IR be bg bn br bs ca cs cy da de el en_CA en_GB es et eu fa fi fr ga gl gu he hi hr hu ia id is it ja ko li lt lv mi mk ml mn mr ms nb ne nl nn no nso pa pl pt pt_BR ro ru rw sk sl sq sr sr@ije sr@Latn sv ta th tk tr uk uz uz@Latn vi wa xh yi zh_CN zh_TW"
++ALL_LINGUAS=""
+ AM_GLIB_GNU_GETTEXT
+ LIBS="$LIBS $INTLLIBS"
+ AC_OUTPUT_COMMANDS([case "$CONFIG_FILES" in *po-properties/Makefile.in*)
+@@ -1283,6 +1292,17 @@
+ GDK_EXTRA_CFLAGS="`$PKG_CONFIG --cflags xfixes` $GDK_EXTRA_CFLAGS"
+ GDK_EXTRA_LIBS="`$PKG_CONFIG --libs xfixes` $GDK_EXTRA_LIBS"
+ fi
++
++ # Checks for XFixes extension
++
++ have_xfixes=false
++ PKG_CHECK_MODULES(XFIXES, xfixes, have_xfixes=true, :)
++
++ if $have_xfixes ; then
++ AC_DEFINE(HAVE_XFIXES, 1, Have the XFIXES X extension)
++ GDK_EXTRA_CFLAGS="`$PKG_CONFIG --cflags xfixes` $GDK_EXTRA_CFLAGS"
++ GDK_EXTRA_LIBS="`$PKG_CONFIG --libs xfixes` $GDK_EXTRA_LIBS"
++ fi
+
+ # Xshm checks
+
+@@ -1492,7 +1512,6 @@
+
+ GTK_PACKAGES=atk
+ GTK_EXTRA_LIBS=
+-GTK_EXTRA_CFLAGS=
+ GTK_DEP_LIBS="$GDK_EXTRA_LIBS $GTK_DEP_LIBS_FOR_X `$PKG_CONFIG --libs $GDK_PIXBUF_PACKAGES $GDK_PACKAGES $GTK_PACKAGES` $GTK_EXTRA_LIBS $GDK_PIXBUF_EXTRA_LIBS"
+ GTK_DEP_CFLAGS="`$PKG_CONFIG --cflags gthread-2.0 $GDK_PIXBUF_PACKAGES $GDK_PACKAGES $GTK_PACKAGES` $GDK_PIXBUF_EXTRA_CFLAGS $GDK_EXTRA_CFLAGS $GTK_EXTRA_CFLAGS"
+
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/disable-tooltips.patch b/packages/gtk+/gtk+-2.6.4-1.osso7/disable-tooltips.patch
index e69de29bb2..d71d839c3c 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/disable-tooltips.patch
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/disable-tooltips.patch
@@ -0,0 +1,11 @@
+--- 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;
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gdkwindow-x11.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gdkwindow-x11.c.diff
index e69de29bb2..8104eb8559 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gdkwindow-x11.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gdkwindow-x11.c.diff
@@ -0,0 +1,38 @@
+--- gtk+-2.6.4/gdk/x11/gdkwindow-x11.c 2005-01-25 20:51:36.000000000 +0200
++++ gtk+-2.6.4/gdk/x11/gdkwindow-x11.c 2005-04-06 16:19:35.350164320 +0300
+@@ -1286,6 +1286,7 @@
+ GdkToplevelX11 *toplevel;
+ Atom atoms[7];
+ gint i;
++ gint propmode;
+
+ private = (GdkWindowObject*) window;
+ toplevel = _gdk_x11_window_get_toplevel (window);
+@@ -1295,6 +1296,12 @@
+
+ update_wm_hints (window, TRUE);
+
++ /* If the window has _NET_WM_STATE key specified, use it as the property mode */
++ propmode = (gint)g_object_get_data (G_OBJECT (window), "_NET_WM_STATE");
++
++ if (!propmode)
++ propmode = PropModeReplace;
++
+ /* We set the spec hints regardless of whether the spec is supported,
+ * since it can't hurt and it's kind of expensive to check whether
+ * it's supported.
+@@ -1366,10 +1373,11 @@
+ XChangeProperty (xdisplay,
+ xwindow,
+ gdk_x11_get_xatom_by_name_for_display (display, "_NET_WM_STATE"),
+- XA_ATOM, 32, PropModeReplace,
++ XA_ATOM, 32, propmode,
+ (guchar*) atoms, i);
+- }
+- else
++ }
++ /* Don't delete the property, unless we are replacing it */
++ else if (propmode == PropModeReplace )
+ {
+ XDeleteProperty (xdisplay,
+ xwindow,
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtk+-handhelds.patch b/packages/gtk+/gtk+-2.6.4-1.osso7/gtk+-handhelds.patch
index e69de29bb2..20481f059b 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtk+-handhelds.patch
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtk+-handhelds.patch
@@ -0,0 +1,236 @@
+--- 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;
+ }
+
+ /**
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtk.h.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtk.h.diff
index e69de29bb2..090d0da0eb 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtk.h.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtk.h.diff
@@ -0,0 +1,10 @@
+--- gtk+-2.6.4/gtk/gtk.h 2004-09-27 21:37:33.000000000 +0300
++++ gtk+-2.6.4/gtk/gtk.h 2005-04-06 16:19:35.812094096 +0300
+@@ -156,6 +156,7 @@
+ #include <gtk/gtktearoffmenuitem.h>
+ #include <gtk/gtktext.h>
+ #include <gtk/gtktextbuffer.h>
++#include <gtk/gtktextbufferserialize.h>
+ #include <gtk/gtktextview.h>
+ #include <gtk/gtktipsquery.h>
+ #include <gtk/gtktoggleaction.h>
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtk_Makefile.am.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtk_Makefile.am.diff
index e69de29bb2..0672df19b0 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtk_Makefile.am.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtk_Makefile.am.diff
@@ -0,0 +1,27 @@
+--- gtk+-2.6.4/gtk/Makefile.am 2005-01-13 17:18:21.000000000 +0200
++++ gtk+-2.6.4/gtk/Makefile.am 2005-04-06 16:19:35.806095008 +0300
+@@ -246,6 +246,7 @@
+ gtktearoffmenuitem.h \
+ gtktext.h \
+ gtktextbuffer.h \
++ gtktextbufferserialize.h\
+ gtktextchild.h \
+ gtktextdisplay.h \
+ gtktextiter.h \
+@@ -387,6 +388,8 @@
+ gtkframe.c \
+ gtkgamma.c \
+ gtkgc.c \
++ gtkhashtable.c \
++ gtkhashtable.h \
+ gtkhandlebox.c \
+ gtkhbbox.c \
+ gtkhbox.c \
+@@ -470,6 +473,7 @@
+ gtktext.c \
+ gtktextbtree.c \
+ gtktextbuffer.c \
++ gtktextbufferserialize.c\
+ gtktextchild.c \
+ gtktextdisplay.c \
+ gtktextiter.c \
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtk_Makefile.in.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtk_Makefile.in.diff
index e69de29bb2..56eca02b03 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtk_Makefile.in.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtk_Makefile.in.diff
@@ -0,0 +1,292 @@
+--- gtk+-2.6.4/gtk/Makefile.in 2005-03-01 17:31:32.000000000 +0200
++++ gtk+-2.6.4/gtk/Makefile.in 2005-04-06 16:19:35.808094704 +0300
+@@ -485,6 +485,7 @@
+ gtktearoffmenuitem.h \
+ gtktext.h \
+ gtktextbuffer.h \
++ gtktextbufferserialize.h\
+ gtktextchild.h \
+ gtktextdisplay.h \
+ gtktextiter.h \
+@@ -629,6 +630,8 @@
+ gtkframe.c \
+ gtkgamma.c \
+ gtkgc.c \
++ gtkhashtable.c \
++ gtkhashtable.h \
+ gtkhandlebox.c \
+ gtkhbbox.c \
+ gtkhbox.c \
+@@ -712,6 +715,7 @@
+ gtktext.c \
+ gtktextbtree.c \
+ gtktextbuffer.c \
++ gtktextbufferserialize.c\
+ gtktextchild.c \
+ gtktextdisplay.c \
+ gtktextiter.c \
+@@ -927,14 +931,14 @@
+ gtkfilechooserdefault.c gtkfilechooserutils.c \
+ gtkfilechooserwidget.c gtkfilefilter.c gtkfilesel.c \
+ gtkfilesystem.c gtkfilesystemmodel.c gtkfixed.c gtkfontbutton.c \
+- gtkfontsel.c gtkframe.c gtkgamma.c gtkgc.c gtkhandlebox.c \
+- gtkhbbox.c gtkhbox.c gtkhpaned.c gtkhruler.c gtkhscale.c \
+- gtkhscrollbar.c gtkhseparator.c gtkhsv.c gtkhsv.h \
+- gtkiconfactory.c gtkiconcache.c gtkicontheme.c gtkiconview.c \
+- gtkimage.c gtkimagemenuitem.c gtkimcontext.c \
+- gtkimcontextsimple.c gtkimmodule.c gtkimmulticontext.c \
+- gtkinputdialog.c gtkintl.h gtkinvisible.c gtkitem.c \
+- gtkitemfactory.c gtkkeyhash.c gtkkeyhash.h gtklabel.c \
++ gtkfontsel.c gtkframe.c gtkgamma.c gtkgc.c gtkhashtable.c \
++ gtkhashtable.h gtkhandlebox.c gtkhbbox.c gtkhbox.c gtkhpaned.c \
++ gtkhruler.c gtkhscale.c gtkhscrollbar.c gtkhseparator.c \
++ gtkhsv.c gtkhsv.h gtkiconfactory.c gtkiconcache.c \
++ gtkicontheme.c gtkiconview.c gtkimage.c gtkimagemenuitem.c \
++ gtkimcontext.c gtkimcontextsimple.c gtkimmodule.c \
++ gtkimmulticontext.c gtkinputdialog.c gtkintl.h gtkinvisible.c \
++ gtkitem.c gtkitemfactory.c gtkkeyhash.c gtkkeyhash.h gtklabel.c \
+ gtklayout.c gtklist.c gtklistitem.c gtkliststore.c gtkmain.c \
+ gtkmarshal.c gtkmarshalers.c gtkmenu.c gtkmenubar.c \
+ gtkmenuitem.c gtkmenushell.c gtkmenutoolbutton.c \
+@@ -949,21 +953,21 @@
+ gtkseparatortoolitem.c gtksettings.c gtksignal.c gtksizegroup.c \
+ gtkspinbutton.c gtkstatusbar.c gtkstock.c gtkstyle.c gtktable.c \
+ gtktearoffmenuitem.c gtktext.c gtktextbtree.c gtktextbuffer.c \
+- gtktextchild.c gtktextdisplay.c gtktextiter.c \
+- gtktextiterprivate.h gtktextlayout.c gtktextmark.c \
+- gtktextmarkprivate.h gtktextsegment.c gtktexttag.c \
+- gtktexttagtable.c gtktexttypes.c gtktextutil.c gtktextview.c \
+- gtkthemes.c gtktipsquery.c gtktoggleaction.c gtktogglebutton.c \
+- gtktoggletoolbutton.c gtktoolbar.c gtktoolbutton.c \
+- gtktoolitem.c gtktooltips.c gtktree.c gtktreedatalist.c \
+- gtktreednd.c gtktreeitem.c gtktreemodel.c gtktreemodelfilter.c \
+- gtktreemodelsort.c gtktreeselection.c gtktreesortable.c \
+- gtktreestore.c gtktreeview.c gtktreeviewcolumn.c \
+- gtktypebuiltins.c gtktypeutils.c gtkuimanager.c gtkvbbox.c \
+- gtkvbox.c gtkviewport.c gtkvpaned.c gtkvruler.c gtkvscale.c \
+- gtkvscrollbar.c gtkvseparator.c gtkwidget.c \
+- gtkwindow-decorate.c gtkwindow.c xembed.h gtkfilesystemunix.c \
+- gtkfilesystemwin32.c
++ gtktextbufferserialize.c gtktextchild.c gtktextdisplay.c \
++ gtktextiter.c gtktextiterprivate.h gtktextlayout.c \
++ gtktextmark.c gtktextmarkprivate.h gtktextsegment.c \
++ gtktexttag.c gtktexttagtable.c gtktexttypes.c gtktextutil.c \
++ gtktextview.c gtkthemes.c gtktipsquery.c gtktoggleaction.c \
++ gtktogglebutton.c gtktoggletoolbutton.c gtktoolbar.c \
++ gtktoolbutton.c gtktoolitem.c gtktooltips.c gtktree.c \
++ gtktreedatalist.c gtktreednd.c gtktreeitem.c gtktreemodel.c \
++ gtktreemodelfilter.c gtktreemodelsort.c gtktreeselection.c \
++ gtktreesortable.c gtktreestore.c gtktreeview.c \
++ gtktreeviewcolumn.c gtktypebuiltins.c gtktypeutils.c \
++ gtkuimanager.c gtkvbbox.c gtkvbox.c gtkviewport.c gtkvpaned.c \
++ gtkvruler.c gtkvscale.c gtkvscrollbar.c gtkvseparator.c \
++ gtkwidget.c gtkwindow-decorate.c gtkwindow.c xembed.h \
++ gtkfilesystemunix.c gtkfilesystemwin32.c
+ @OS_UNIX_TRUE@am__objects_1 = gtkfilesystemunix.lo
+ @OS_WIN32_TRUE@am__objects_2 = gtkfilesystemwin32.lo
+ am__objects_3 = fnmatch.lo gtkaboutdialog.lo gtkaccelgroup.lo \
+@@ -986,16 +990,16 @@
+ gtkfilechooserutils.lo gtkfilechooserwidget.lo gtkfilefilter.lo \
+ gtkfilesel.lo gtkfilesystem.lo gtkfilesystemmodel.lo \
+ gtkfixed.lo gtkfontbutton.lo gtkfontsel.lo gtkframe.lo \
+- gtkgamma.lo gtkgc.lo gtkhandlebox.lo gtkhbbox.lo gtkhbox.lo \
+- gtkhpaned.lo gtkhruler.lo gtkhscale.lo gtkhscrollbar.lo \
+- gtkhseparator.lo gtkhsv.lo gtkiconfactory.lo gtkiconcache.lo \
+- gtkicontheme.lo gtkiconview.lo gtkimage.lo gtkimagemenuitem.lo \
+- gtkimcontext.lo gtkimcontextsimple.lo gtkimmodule.lo \
+- gtkimmulticontext.lo gtkinputdialog.lo gtkinvisible.lo \
+- gtkitem.lo gtkitemfactory.lo gtkkeyhash.lo gtklabel.lo \
+- gtklayout.lo gtklist.lo gtklistitem.lo gtkliststore.lo \
+- gtkmain.lo gtkmarshal.lo gtkmarshalers.lo gtkmenu.lo \
+- gtkmenubar.lo gtkmenuitem.lo gtkmenushell.lo \
++ gtkgamma.lo gtkgc.lo gtkhashtable.lo gtkhandlebox.lo \
++ gtkhbbox.lo gtkhbox.lo gtkhpaned.lo gtkhruler.lo gtkhscale.lo \
++ gtkhscrollbar.lo gtkhseparator.lo gtkhsv.lo gtkiconfactory.lo \
++ gtkiconcache.lo gtkicontheme.lo gtkiconview.lo gtkimage.lo \
++ gtkimagemenuitem.lo gtkimcontext.lo gtkimcontextsimple.lo \
++ gtkimmodule.lo gtkimmulticontext.lo gtkinputdialog.lo \
++ gtkinvisible.lo gtkitem.lo gtkitemfactory.lo gtkkeyhash.lo \
++ gtklabel.lo gtklayout.lo gtklist.lo gtklistitem.lo \
++ gtkliststore.lo gtkmain.lo gtkmarshal.lo gtkmarshalers.lo \
++ gtkmenu.lo gtkmenubar.lo gtkmenuitem.lo gtkmenushell.lo \
+ gtkmenutoolbutton.lo gtkmessagedialog.lo gtkmisc.lo \
+ gtkmnemonichash.lo gtkmodules.lo gtknotebook.lo gtkobject.lo \
+ gtkoldeditable.lo gtkoptionmenu.lo gtkpaned.lo gtkpathbar.lo \
+@@ -1007,14 +1011,15 @@
+ gtkseparatormenuitem.lo gtkseparatortoolitem.lo gtksettings.lo \
+ gtksignal.lo gtksizegroup.lo gtkspinbutton.lo gtkstatusbar.lo \
+ gtkstock.lo gtkstyle.lo gtktable.lo gtktearoffmenuitem.lo \
+- gtktext.lo gtktextbtree.lo gtktextbuffer.lo gtktextchild.lo \
+- gtktextdisplay.lo gtktextiter.lo gtktextlayout.lo \
+- gtktextmark.lo gtktextsegment.lo gtktexttag.lo \
+- gtktexttagtable.lo gtktexttypes.lo gtktextutil.lo \
+- gtktextview.lo gtkthemes.lo gtktipsquery.lo gtktoggleaction.lo \
+- gtktogglebutton.lo gtktoggletoolbutton.lo gtktoolbar.lo \
+- gtktoolbutton.lo gtktoolitem.lo gtktooltips.lo gtktree.lo \
+- gtktreedatalist.lo gtktreednd.lo gtktreeitem.lo gtktreemodel.lo \
++ gtktext.lo gtktextbtree.lo gtktextbuffer.lo \
++ gtktextbufferserialize.lo gtktextchild.lo gtktextdisplay.lo \
++ gtktextiter.lo gtktextlayout.lo gtktextmark.lo \
++ gtktextsegment.lo gtktexttag.lo gtktexttagtable.lo \
++ gtktexttypes.lo gtktextutil.lo gtktextview.lo gtkthemes.lo \
++ gtktipsquery.lo gtktoggleaction.lo gtktogglebutton.lo \
++ gtktoggletoolbutton.lo gtktoolbar.lo gtktoolbutton.lo \
++ gtktoolitem.lo gtktooltips.lo gtktree.lo gtktreedatalist.lo \
++ gtktreednd.lo gtktreeitem.lo gtktreemodel.lo \
+ gtktreemodelfilter.lo gtktreemodelsort.lo gtktreeselection.lo \
+ gtktreesortable.lo gtktreestore.lo gtktreeview.lo \
+ gtktreeviewcolumn.lo gtktypebuiltins.lo gtktypeutils.lo \
+@@ -1042,14 +1047,14 @@
+ gtkfilechooserdefault.c gtkfilechooserutils.c \
+ gtkfilechooserwidget.c gtkfilefilter.c gtkfilesel.c \
+ gtkfilesystem.c gtkfilesystemmodel.c gtkfixed.c gtkfontbutton.c \
+- gtkfontsel.c gtkframe.c gtkgamma.c gtkgc.c gtkhandlebox.c \
+- gtkhbbox.c gtkhbox.c gtkhpaned.c gtkhruler.c gtkhscale.c \
+- gtkhscrollbar.c gtkhseparator.c gtkhsv.c gtkhsv.h \
+- gtkiconfactory.c gtkiconcache.c gtkicontheme.c gtkiconview.c \
+- gtkimage.c gtkimagemenuitem.c gtkimcontext.c \
+- gtkimcontextsimple.c gtkimmodule.c gtkimmulticontext.c \
+- gtkinputdialog.c gtkintl.h gtkinvisible.c gtkitem.c \
+- gtkitemfactory.c gtkkeyhash.c gtkkeyhash.h gtklabel.c \
++ gtkfontsel.c gtkframe.c gtkgamma.c gtkgc.c gtkhashtable.c \
++ gtkhashtable.h gtkhandlebox.c gtkhbbox.c gtkhbox.c gtkhpaned.c \
++ gtkhruler.c gtkhscale.c gtkhscrollbar.c gtkhseparator.c \
++ gtkhsv.c gtkhsv.h gtkiconfactory.c gtkiconcache.c \
++ gtkicontheme.c gtkiconview.c gtkimage.c gtkimagemenuitem.c \
++ gtkimcontext.c gtkimcontextsimple.c gtkimmodule.c \
++ gtkimmulticontext.c gtkinputdialog.c gtkintl.h gtkinvisible.c \
++ gtkitem.c gtkitemfactory.c gtkkeyhash.c gtkkeyhash.h gtklabel.c \
+ gtklayout.c gtklist.c gtklistitem.c gtkliststore.c gtkmain.c \
+ gtkmarshal.c gtkmarshalers.c gtkmenu.c gtkmenubar.c \
+ gtkmenuitem.c gtkmenushell.c gtkmenutoolbutton.c \
+@@ -1064,21 +1069,21 @@
+ gtkseparatortoolitem.c gtksettings.c gtksignal.c gtksizegroup.c \
+ gtkspinbutton.c gtkstatusbar.c gtkstock.c gtkstyle.c gtktable.c \
+ gtktearoffmenuitem.c gtktext.c gtktextbtree.c gtktextbuffer.c \
+- gtktextchild.c gtktextdisplay.c gtktextiter.c \
+- gtktextiterprivate.h gtktextlayout.c gtktextmark.c \
+- gtktextmarkprivate.h gtktextsegment.c gtktexttag.c \
+- gtktexttagtable.c gtktexttypes.c gtktextutil.c gtktextview.c \
+- gtkthemes.c gtktipsquery.c gtktoggleaction.c gtktogglebutton.c \
+- gtktoggletoolbutton.c gtktoolbar.c gtktoolbutton.c \
+- gtktoolitem.c gtktooltips.c gtktree.c gtktreedatalist.c \
+- gtktreednd.c gtktreeitem.c gtktreemodel.c gtktreemodelfilter.c \
+- gtktreemodelsort.c gtktreeselection.c gtktreesortable.c \
+- gtktreestore.c gtktreeview.c gtktreeviewcolumn.c \
+- gtktypebuiltins.c gtktypeutils.c gtkuimanager.c gtkvbbox.c \
+- gtkvbox.c gtkviewport.c gtkvpaned.c gtkvruler.c gtkvscale.c \
+- gtkvscrollbar.c gtkvseparator.c gtkwidget.c \
+- gtkwindow-decorate.c gtkwindow.c xembed.h gtkfilesystemunix.c \
+- gtkfilesystemwin32.c
++ gtktextbufferserialize.c gtktextchild.c gtktextdisplay.c \
++ gtktextiter.c gtktextiterprivate.h gtktextlayout.c \
++ gtktextmark.c gtktextmarkprivate.h gtktextsegment.c \
++ gtktexttag.c gtktexttagtable.c gtktexttypes.c gtktextutil.c \
++ gtktextview.c gtkthemes.c gtktipsquery.c gtktoggleaction.c \
++ gtktogglebutton.c gtktoggletoolbutton.c gtktoolbar.c \
++ gtktoolbutton.c gtktoolitem.c gtktooltips.c gtktree.c \
++ gtktreedatalist.c gtktreednd.c gtktreeitem.c gtktreemodel.c \
++ gtktreemodelfilter.c gtktreemodelsort.c gtktreeselection.c \
++ gtktreesortable.c gtktreestore.c gtktreeview.c \
++ gtktreeviewcolumn.c gtktypebuiltins.c gtktypeutils.c \
++ gtkuimanager.c gtkvbbox.c gtkvbox.c gtkviewport.c gtkvpaned.c \
++ gtkvruler.c gtkvscale.c gtkvscrollbar.c gtkvseparator.c \
++ gtkwidget.c gtkwindow-decorate.c gtkwindow.c xembed.h \
++ gtkfilesystemunix.c gtkfilesystemwin32.c
+ am_libgtk_win32_2_0_la_OBJECTS = $(am__objects_3)
+ libgtk_win32_2_0_la_OBJECTS = $(am_libgtk_win32_2_0_la_OBJECTS)
+ @OS_UNIX_TRUE@libgtk_x11_2_0_la_DEPENDENCIES = \
+@@ -1106,14 +1111,14 @@
+ gtkfilechooserdefault.c gtkfilechooserutils.c \
+ gtkfilechooserwidget.c gtkfilefilter.c gtkfilesel.c \
+ gtkfilesystem.c gtkfilesystemmodel.c gtkfixed.c gtkfontbutton.c \
+- gtkfontsel.c gtkframe.c gtkgamma.c gtkgc.c gtkhandlebox.c \
+- gtkhbbox.c gtkhbox.c gtkhpaned.c gtkhruler.c gtkhscale.c \
+- gtkhscrollbar.c gtkhseparator.c gtkhsv.c gtkhsv.h \
+- gtkiconfactory.c gtkiconcache.c gtkicontheme.c gtkiconview.c \
+- gtkimage.c gtkimagemenuitem.c gtkimcontext.c \
+- gtkimcontextsimple.c gtkimmodule.c gtkimmulticontext.c \
+- gtkinputdialog.c gtkintl.h gtkinvisible.c gtkitem.c \
+- gtkitemfactory.c gtkkeyhash.c gtkkeyhash.h gtklabel.c \
++ gtkfontsel.c gtkframe.c gtkgamma.c gtkgc.c gtkhashtable.c \
++ gtkhashtable.h gtkhandlebox.c gtkhbbox.c gtkhbox.c gtkhpaned.c \
++ gtkhruler.c gtkhscale.c gtkhscrollbar.c gtkhseparator.c \
++ gtkhsv.c gtkhsv.h gtkiconfactory.c gtkiconcache.c \
++ gtkicontheme.c gtkiconview.c gtkimage.c gtkimagemenuitem.c \
++ gtkimcontext.c gtkimcontextsimple.c gtkimmodule.c \
++ gtkimmulticontext.c gtkinputdialog.c gtkintl.h gtkinvisible.c \
++ gtkitem.c gtkitemfactory.c gtkkeyhash.c gtkkeyhash.h gtklabel.c \
+ gtklayout.c gtklist.c gtklistitem.c gtkliststore.c gtkmain.c \
+ gtkmarshal.c gtkmarshalers.c gtkmenu.c gtkmenubar.c \
+ gtkmenuitem.c gtkmenushell.c gtkmenutoolbutton.c \
+@@ -1128,22 +1133,22 @@
+ gtkseparatortoolitem.c gtksettings.c gtksignal.c gtksizegroup.c \
+ gtkspinbutton.c gtkstatusbar.c gtkstock.c gtkstyle.c gtktable.c \
+ gtktearoffmenuitem.c gtktext.c gtktextbtree.c gtktextbuffer.c \
+- gtktextchild.c gtktextdisplay.c gtktextiter.c \
+- gtktextiterprivate.h gtktextlayout.c gtktextmark.c \
+- gtktextmarkprivate.h gtktextsegment.c gtktexttag.c \
+- gtktexttagtable.c gtktexttypes.c gtktextutil.c gtktextview.c \
+- gtkthemes.c gtktipsquery.c gtktoggleaction.c gtktogglebutton.c \
+- gtktoggletoolbutton.c gtktoolbar.c gtktoolbutton.c \
+- gtktoolitem.c gtktooltips.c gtktree.c gtktreedatalist.c \
+- gtktreednd.c gtktreeitem.c gtktreemodel.c gtktreemodelfilter.c \
+- gtktreemodelsort.c gtktreeselection.c gtktreesortable.c \
+- gtktreestore.c gtktreeview.c gtktreeviewcolumn.c \
+- gtktypebuiltins.c gtktypeutils.c gtkuimanager.c gtkvbbox.c \
+- gtkvbox.c gtkviewport.c gtkvpaned.c gtkvruler.c gtkvscale.c \
+- gtkvscrollbar.c gtkvseparator.c gtkwidget.c \
+- gtkwindow-decorate.c gtkwindow.c xembed.h gtkfilesystemunix.c \
+- gtkfilesystemwin32.c gtkplug.c gtksocket.c gtkxembed.c \
+- gtkxembed.h
++ gtktextbufferserialize.c gtktextchild.c gtktextdisplay.c \
++ gtktextiter.c gtktextiterprivate.h gtktextlayout.c \
++ gtktextmark.c gtktextmarkprivate.h gtktextsegment.c \
++ gtktexttag.c gtktexttagtable.c gtktexttypes.c gtktextutil.c \
++ gtktextview.c gtkthemes.c gtktipsquery.c gtktoggleaction.c \
++ gtktogglebutton.c gtktoggletoolbutton.c gtktoolbar.c \
++ gtktoolbutton.c gtktoolitem.c gtktooltips.c gtktree.c \
++ gtktreedatalist.c gtktreednd.c gtktreeitem.c gtktreemodel.c \
++ gtktreemodelfilter.c gtktreemodelsort.c gtktreeselection.c \
++ gtktreesortable.c gtktreestore.c gtktreeview.c \
++ gtktreeviewcolumn.c gtktypebuiltins.c gtktypeutils.c \
++ gtkuimanager.c gtkvbbox.c gtkvbox.c gtkviewport.c gtkvpaned.c \
++ gtkvruler.c gtkvscale.c gtkvscrollbar.c gtkvseparator.c \
++ gtkwidget.c gtkwindow-decorate.c gtkwindow.c xembed.h \
++ gtkfilesystemunix.c gtkfilesystemwin32.c gtkplug.c gtksocket.c \
++ gtkxembed.c gtkxembed.h
+ am__objects_4 = gtkplug.lo gtksocket.lo gtkxembed.lo
+ am_libgtk_x11_2_0_la_OBJECTS = $(am__objects_3) $(am__objects_4)
+ libgtk_x11_2_0_la_OBJECTS = $(am_libgtk_x11_2_0_la_OBJECTS)
+@@ -1224,6 +1229,7 @@
+ @AMDEP_TRUE@ ./$(DEPDIR)/gtkfontsel.Plo ./$(DEPDIR)/gtkframe.Plo \
+ @AMDEP_TRUE@ ./$(DEPDIR)/gtkgamma.Plo ./$(DEPDIR)/gtkgc.Plo \
+ @AMDEP_TRUE@ ./$(DEPDIR)/gtkhandlebox.Plo \
++@AMDEP_TRUE@ ./$(DEPDIR)/gtkhashtable.Plo \
+ @AMDEP_TRUE@ ./$(DEPDIR)/gtkhbbox.Plo ./$(DEPDIR)/gtkhbox.Plo \
+ @AMDEP_TRUE@ ./$(DEPDIR)/gtkhpaned.Plo ./$(DEPDIR)/gtkhruler.Plo \
+ @AMDEP_TRUE@ ./$(DEPDIR)/gtkhscale.Plo \
+@@ -1292,6 +1298,7 @@
+ @AMDEP_TRUE@ ./$(DEPDIR)/gtktext.Plo \
+ @AMDEP_TRUE@ ./$(DEPDIR)/gtktextbtree.Plo \
+ @AMDEP_TRUE@ ./$(DEPDIR)/gtktextbuffer.Plo \
++@AMDEP_TRUE@ ./$(DEPDIR)/gtktextbufferserialize.Plo \
+ @AMDEP_TRUE@ ./$(DEPDIR)/gtktextchild.Plo \
+ @AMDEP_TRUE@ ./$(DEPDIR)/gtktextdisplay.Plo \
+ @AMDEP_TRUE@ ./$(DEPDIR)/gtktextiter.Plo \
+@@ -1524,6 +1531,7 @@
+ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gtkgamma.Plo@am__quote@
+ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gtkgc.Plo@am__quote@
+ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gtkhandlebox.Plo@am__quote@
++@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gtkhashtable.Plo@am__quote@
+ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gtkhbbox.Plo@am__quote@
+ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gtkhbox.Plo@am__quote@
+ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gtkhpaned.Plo@am__quote@
+@@ -1604,6 +1612,7 @@
+ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gtktext.Plo@am__quote@
+ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gtktextbtree.Plo@am__quote@
+ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gtktextbuffer.Plo@am__quote@
++@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gtktextbufferserialize.Plo@am__quote@
+ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gtktextchild.Plo@am__quote@
+ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gtktextdisplay.Plo@am__quote@
+ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gtktextiter.Plo@am__quote@
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkalias.h.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkalias.h.diff
index e69de29bb2..8c87424ce8 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkalias.h.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkalias.h.diff
@@ -0,0 +1,17 @@
+--- gtk+-2.6.4/gtk/gtkalias.h 2005-03-01 17:58:16.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkalias.h 2005-04-06 16:19:36.020062480 +0300
+@@ -5782,6 +5782,14 @@
+ extern __typeof (gtk_menu_shell_select_item) gtk_menu_shell_select_item __attribute((alias("IA__gtk_menu_shell_select_item"), visibility("default")));
+ #define gtk_menu_shell_select_item IA__gtk_menu_shell_select_item
+
++extern __typeof (gtk_menu_shell_set_take_focus) IA__gtk_menu_shell_set_take_focus __attribute((visibility("hidden")));
++extern __typeof (gtk_menu_shell_set_take_focus) gtk_menu_shell_set_take_focus __attribute((alias("IA__gtk_menu_shell_set_take_focus"), visibility("default")));
++#define gtk_menu_shell_set_take_focus IA__gtk_menu_shell_set_take_focus
++
++extern __typeof (gtk_menu_shell_get_take_focus) IA__gtk_menu_shell_get_take_focus __attribute((visibility("hidden")));
++extern __typeof (gtk_menu_shell_get_take_focus) gtk_menu_shell_get_take_focus __attribute((alias("IA__gtk_menu_shell_get_take_focus"), visibility("default")));
++#define gtk_menu_shell_get_take_focus IA__gtk_menu_shell_get_take_focus
++
+ extern __typeof (gtk_menu_tool_button_get_menu) IA__gtk_menu_tool_button_get_menu __attribute((visibility("hidden")));
+ extern __typeof (gtk_menu_tool_button_get_menu) gtk_menu_tool_button_get_menu __attribute((alias("IA__gtk_menu_tool_button_get_menu"), visibility("default")));
+ #define gtk_menu_tool_button_get_menu IA__gtk_menu_tool_button_get_menu
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkbutton.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkbutton.c.diff
index e69de29bb2..e5a007372a 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkbutton.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkbutton.c.diff
@@ -0,0 +1,471 @@
+--- gtk+-2.6.4/gtk/gtkbutton.c 2005-01-25 22:54:43.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkbutton.c 2005-04-06 16:19:36.249027672 +0300
+@@ -24,6 +24,10 @@
+ * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
+ */
+
++/* Modified for Nokia Oyj during 2002-2005. See CHANGES file for list
++ * of changes.
++ */
++
+ #include <config.h>
+ #include <string.h>
+ #include "gtkalias.h"
+@@ -38,8 +42,33 @@
+ #include "gtkiconfactory.h"
+ #include "gtkintl.h"
+
++/* Osso addition:
++ * Here are the details for each attach
++ * bitmask combination. */
++const gchar *osso_gtk_button_attach_details [OSSO_GTK_BUTTON_ATTACH_ENUM_END] =
++ { "osso_button",
++ "osso_button_n",
++ "osso_button_e",
++ "osso_button_ne",
++ "osso_button_s",
++ "osso_button_ns",
++ "osso_button_es",
++ "osso_button_nes",
++ "osso_button_w",
++ "osso_button_nw",
++ "osso_button_ew",
++ "osso_button_new",
++ "osso_button_sw",
++ "osso_button_nsw",
++ "osso_button_esw",
++ "osso_button_nesw",
++ };
++
+ #define CHILD_SPACING 1
+
++/* Take this away after font drawing is fixed */
++#define OSSO_FONT_HACK TRUE
++
+ static const GtkBorder default_default_border = { 1, 1, 1, 1 };
+ static const GtkBorder default_default_outside_border = { 0, 0, 0, 0 };
+
+@@ -68,6 +97,9 @@
+ PROP_FOCUS_ON_CLICK,
+ PROP_XALIGN,
+ PROP_YALIGN,
++ PROP_DETAIL,
++ PROP_AUTOMATIC_DETAIL,
++ PROP_KEYBOARD_BUTTON
+ };
+
+ #define GTK_BUTTON_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), GTK_TYPE_BUTTON, GtkButtonPrivate))
+@@ -80,6 +112,10 @@
+ GtkWidget *image;
+ guint align_set : 1;
+ guint image_is_stock : 1;
++ gchar *detail;
++ gboolean automatic_detail;
++ gboolean keyboard_button;
++ GtkLabel *keyboard_label;
+ };
+
+ static void gtk_button_class_init (GtkButtonClass *klass);
+@@ -231,6 +267,14 @@
+ G_PARAM_READWRITE | G_PARAM_CONSTRUCT));
+
+ g_object_class_install_property (gobject_class,
++ PROP_KEYBOARD_BUTTON,
++ g_param_spec_boolean ("keyboard_button",
++ P_("Keyboard button"),
++ P_("If set, label foo"),
++ FALSE,
++ G_PARAM_READWRITE | G_PARAM_CONSTRUCT));
++
++ g_object_class_install_property (gobject_class,
+ PROP_USE_STOCK,
+ g_param_spec_boolean ("use_stock",
+ P_("Use stock"),
+@@ -418,6 +462,77 @@
+ P_("Whether stock icons should be shown in buttons"),
+ TRUE,
+ G_PARAM_READWRITE));
++
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("child_spacing",
++ _("Child spacing"),
++ _("Spacing between button edges and child."),
++ 0,
++ G_MAXINT,
++ CHILD_SPACING,
++ G_PARAM_READABLE));
++ /* Osso additions below */
++ g_object_class_install_property (gobject_class,
++ PROP_DETAIL,
++ g_param_spec_string ("detail",
++ P_("Detail"),
++ P_("The detail the button is drawn with."),
++ "buttondefault",
++ G_PARAM_READWRITE));
++
++ g_object_class_install_property (gobject_class,
++ PROP_AUTOMATIC_DETAIL,
++ g_param_spec_boolean ("automatic_detail",
++ P_("Automatic Detail"),
++ P_("Whether setting detail is automatic based on GtkTable/GtkHButtonBox."),
++ TRUE,
++ G_PARAM_READWRITE));
++
++
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("child_offset_y",
++ _("Child Y Offset"),
++ _("Enable hack how many pixels to add/take away from GtkButton's child size allocation."),
++ G_MININT,
++ G_MAXINT,
++ 0,
++ G_PARAM_READABLE));
++
++ /* OSSO: This is used to find out whether
++ * button is a GtkTreeView column Listbox
++ * header or not */
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_boolean ("listboxheader",
++ P_( "Listbox header" ),
++ P_( "Listbox header ( FALSE / TRUE )" ),
++ FALSE,
++ G_PARAM_READABLE));
++
++ /* OSSO: Column Listbox header separator height */
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("separator-height",
++ P_( "Separator height" ),
++ P_( "Listbox header separator height ( FALSE / TRUE )" ),
++ 0,
++ G_MAXINT,
++ 0,
++ G_PARAM_READABLE));
++
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_boxed ("padding",
++ P_("Padding"),
++ P_("Paddings around the button child"),
++ GTK_TYPE_BORDER,
++ G_PARAM_READABLE));
++
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("minimum_width",
++ P_("Minimum Width"),
++ P_("Minimum width of the button"),
++ 0,
++ G_MAXINT,
++ 0,
++ G_PARAM_READABLE));
+
+ g_type_class_add_private (gobject_class, sizeof (GtkButtonPrivate));
+ }
+@@ -445,7 +560,14 @@
+ priv->xalign = 0.5;
+ priv->yalign = 0.5;
+ priv->align_set = 0;
++ priv->detail = g_strdup("buttondefault");
++ priv->automatic_detail = TRUE;
++ priv->keyboard_button = FALSE;
++ priv->keyboard_label = NULL;
+ priv->image_is_stock = TRUE;
++
++ g_object_set (G_OBJECT (button), "tap_and_hold_state",
++ GTK_STATE_ACTIVE, NULL);
+ }
+
+ static void
+@@ -560,6 +682,18 @@
+ case PROP_YALIGN:
+ gtk_button_set_alignment (button, priv->xalign, g_value_get_float (value));
+ break;
++ case PROP_DETAIL:
++ if (priv->detail)
++ g_free (priv->detail);
++ priv->detail = g_strdup (g_value_get_string (value));
++ gtk_widget_queue_draw (GTK_WIDGET (button));
++ break;
++ case PROP_AUTOMATIC_DETAIL:
++ priv->automatic_detail = g_value_get_boolean (value);
++ break;
++ case PROP_KEYBOARD_BUTTON:
++ priv->keyboard_button = g_value_get_boolean (value);
++ break;
+ default:
+ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
+ break;
+@@ -601,6 +735,15 @@
+ case PROP_YALIGN:
+ g_value_set_float (value, priv->yalign);
+ break;
++ case PROP_DETAIL:
++ g_value_set_string (value, priv->detail);
++ break;
++ case PROP_AUTOMATIC_DETAIL:
++ g_value_set_boolean (value, priv->automatic_detail);
++ break;
++ case PROP_KEYBOARD_BUTTON:
++ g_value_set_boolean (value, priv->keyboard_button);
++ break;
+ default:
+ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
+ break;
+@@ -641,6 +784,26 @@
+ if (button->label_text == NULL)
+ return;
+
++ if (priv->keyboard_button)
++ {
++ if (priv->keyboard_label)
++ {
++ gtk_label_set_label (priv->keyboard_label, button->label_text);
++ }
++ else
++ {
++ GtkWidget *label = gtk_label_new (button->label_text);
++ priv->keyboard_label = GTK_LABEL (label);
++
++ if (priv->align_set)
++ gtk_misc_set_alignment (GTK_MISC (label),
++ priv->xalign, priv->yalign);
++ gtk_widget_show (priv->keyboard_label);
++ gtk_container_add (GTK_CONTAINER (button), label);
++ }
++ return;
++ }
++
+ if (GTK_BIN (button)->child)
+ {
+ if (priv->image && !priv->image_is_stock)
+@@ -944,16 +1107,20 @@
+ GtkBorder default_border;
+ gint focus_width;
+ gint focus_pad;
++ gint child_spacing;
++ gint separator_height;
+
+ gtk_button_get_props (button, &default_border, NULL, NULL);
+ gtk_widget_style_get (GTK_WIDGET (widget),
+ "focus-line-width", &focus_width,
+ "focus-padding", &focus_pad,
++ "child-spacing", &child_spacing,
++ "separator-height", &separator_height,
+ NULL);
+
+- requisition->width = (GTK_CONTAINER (widget)->border_width + CHILD_SPACING +
++ requisition->width = (GTK_CONTAINER (widget)->border_width + child_spacing +
+ GTK_WIDGET (widget)->style->xthickness) * 2;
+- requisition->height = (GTK_CONTAINER (widget)->border_width + CHILD_SPACING +
++ requisition->height = (GTK_CONTAINER (widget)->border_width + child_spacing +
+ GTK_WIDGET (widget)->style->ythickness) * 2;
+
+ if (GTK_WIDGET_CAN_DEFAULT (widget))
+@@ -965,15 +1132,35 @@
+ if (GTK_BIN (button)->child && GTK_WIDGET_VISIBLE (GTK_BIN (button)->child))
+ {
+ GtkRequisition child_requisition;
++ GtkBorder *padding;
++ gint minimum_width;
+
+ gtk_widget_size_request (GTK_BIN (button)->child, &child_requisition);
+
++ gtk_widget_style_get (widget,
++ "padding",
++ &padding,
++ "minimum_width",
++ &minimum_width,
++ NULL);
++
++ if ( padding )
++ {
++ requisition->width += padding->left + padding->right;
++ requisition->height += padding->top + padding->bottom;
++ }
++
+ requisition->width += child_requisition.width;
+ requisition->height += child_requisition.height;
++
++ if (requisition->width < minimum_width)
++ requisition->width = minimum_width;
+ }
+
+ requisition->width += 2 * (focus_width + focus_pad);
+ requisition->height += 2 * (focus_width + focus_pad);
++
++ requisition->height += separator_height;
+ }
+
+ static void
+@@ -989,14 +1176,15 @@
+ GtkBorder default_border;
+ gint focus_width;
+ gint focus_pad;
++ gint child_spacing;
+
+ gtk_button_get_props (button, &default_border, NULL, NULL);
+ gtk_widget_style_get (GTK_WIDGET (widget),
+ "focus-line-width", &focus_width,
+ "focus-padding", &focus_pad,
++ "child-spacing", &child_spacing,
+ NULL);
+-
+-
++
+ widget->allocation = *allocation;
+
+ if (GTK_WIDGET_REALIZED (widget))
+@@ -1008,14 +1196,27 @@
+
+ if (GTK_BIN (button)->child && GTK_WIDGET_VISIBLE (GTK_BIN (button)->child))
+ {
+- child_allocation.x = widget->allocation.x + border_width + CHILD_SPACING + xthickness;
+- child_allocation.y = widget->allocation.y + border_width + CHILD_SPACING + ythickness;
++ child_allocation.x = widget->allocation.x + border_width + child_spacing + xthickness;
++ child_allocation.y = widget->allocation.y + border_width + child_spacing + ythickness;
+
+- child_allocation.width = MAX (1, widget->allocation.width - (CHILD_SPACING + xthickness) * 2 -
++ child_allocation.width = MAX (1, widget->allocation.width - (child_spacing + xthickness) * 2 -
+ border_width * 2);
+- child_allocation.height = MAX (1, widget->allocation.height - (CHILD_SPACING + ythickness) * 2 -
++ child_allocation.height = MAX (1, widget->allocation.height - (child_spacing + ythickness) * 2 -
+ border_width * 2);
+
++#ifdef OSSO_FONT_HACK
++ {
++ gint child_offset_y;
++
++ gtk_widget_style_get (widget, "child_offset_y", &child_offset_y, NULL);
++
++ if( GTK_IS_LABEL(GTK_BIN (button)->child) )
++ {
++ child_allocation.y += child_offset_y;
++ }
++ }
++#endif
++
+ if (GTK_WIDGET_CAN_DEFAULT (button))
+ {
+ child_allocation.x += default_border.left;
+@@ -1066,7 +1267,14 @@
+ gboolean interior_focus;
+ gint focus_width;
+ gint focus_pad;
+-
++ gint separator_height;
++ gboolean listboxheader;
++ GtkButtonPrivate *priv;
++
++ g_return_if_fail (GTK_IS_BUTTON (button));
++
++ priv = GTK_BUTTON_GET_PRIVATE (button);
++
+ if (GTK_WIDGET_DRAWABLE (button))
+ {
+ widget = GTK_WIDGET (button);
+@@ -1076,6 +1284,8 @@
+ gtk_widget_style_get (GTK_WIDGET (widget),
+ "focus-line-width", &focus_width,
+ "focus-padding", &focus_pad,
++ "listboxheader", &listboxheader,
++ "separator-height", &separator_height,
+ NULL);
+
+ x = widget->allocation.x + border_width;
+@@ -1083,13 +1293,55 @@
+ width = widget->allocation.width - border_width * 2;
+ height = widget->allocation.height - border_width * 2;
+
++ if (listboxheader)
++ {
++ /* this changes everything! */
++ PangoLayout *layout;
++ int layout_height;
++
++ /* construct layout - see get_layout in gtkcellrenderertext.c */
++ layout = gtk_widget_create_pango_layout (widget, /* use parent treeview instead? */
++ button->label_text);
++ pango_layout_set_width (layout, -1);
++ pango_layout_get_pixel_size (layout, NULL, &layout_height);
++
++ /* render text */
++ gtk_paint_layout (widget->style,
++ widget->window,
++ GTK_STATE_NORMAL,
++ TRUE,
++ area,
++ widget,
++ "listboxheader",
++ x,
++ y,
++ layout);
++
++ g_object_unref (layout);
++
++ /* draw separator */
++ gtk_paint_hline (widget->style,
++ widget->window,
++ GTK_STATE_NORMAL,
++ area,
++ widget,
++ "listboxseparator",
++ area->x - focus_width - focus_pad,
++ area->x + area->width + focus_width + focus_pad,
++ layout_height + separator_height * 2);
++ return;
++ }
++
+ if (GTK_WIDGET_HAS_DEFAULT (widget) &&
+ GTK_BUTTON (widget)->relief == GTK_RELIEF_NORMAL)
+ {
+- gtk_paint_box (widget->style, widget->window,
++ /* This comment is here because it's part of the
++ * normal GtkButton
++ */
++ /* gtk_paint_box (widget->style, widget->window,
+ GTK_STATE_NORMAL, GTK_SHADOW_IN,
+ area, widget, "buttondefault",
+- x, y, width, height);
++ x, y, width, height); */
+
+ x += default_border.left;
+ y += default_border.top;
+@@ -1116,7 +1368,7 @@
+ GTK_WIDGET_STATE(widget) == GTK_STATE_PRELIGHT)
+ gtk_paint_box (widget->style, widget->window,
+ state_type,
+- shadow_type, area, widget, "button",
++ shadow_type, area, widget, priv->detail,
+ x, y, width, height);
+
+ if (GTK_WIDGET_HAS_FOCUS (widget))
+@@ -1151,10 +1403,14 @@
+ x += child_displacement_x;
+ y += child_displacement_y;
+ }
+-
++ /* Comment exists, because it is part of normal GtkButton
+ gtk_paint_focus (widget->style, widget->window, GTK_WIDGET_STATE (widget),
+ area, widget, "button",
+ x, y, width, height);
++ */
++ gtk_paint_focus (widget->style, widget->window, GTK_WIDGET_STATE (widget),
++ area, widget, priv->detail,
++ x, y, width, height);
+ }
+ }
+ }
+@@ -1786,5 +2042,13 @@
+
+ return priv->image;
+ }
+-
+-
++void osso_gtk_button_set_detail_from_attach_flags (GtkButton *button,OssoGtkButtonAttachFlags flags)
++{
++ g_return_if_fail (GTK_IS_BUTTON (button));
++ g_object_set (G_OBJECT (button),
++ "automatic_detail",
++ FALSE,
++ "detail",
++ osso_gtk_button_attach_details[flags],
++ NULL);
++}
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkbutton.h.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkbutton.h.diff
index e69de29bb2..4c233f905b 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkbutton.h.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkbutton.h.diff
@@ -0,0 +1,23 @@
+--- gtk+-2.6.4/gtk/gtkbutton.h 2004-11-15 22:56:28.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkbutton.h 2005-04-06 16:19:36.264025392 +0300
+@@ -134,6 +134,20 @@
+ const gchar *main_detail,
+ const gchar *default_detail);
+
++/* Osso addition : Button attach flags */
++typedef enum {
++ OSSO_GTK_BUTTON_ATTACH_NORTH = 1 << 0,
++ OSSO_GTK_BUTTON_ATTACH_EAST = 1 << 1,
++ OSSO_GTK_BUTTON_ATTACH_SOUTH = 1 << 2,
++ OSSO_GTK_BUTTON_ATTACH_WEST = 1 << 3,
++ OSSO_GTK_BUTTON_ATTACH_ENUM_END = 1 << 4
++} OssoGtkButtonAttachFlags;
++
++extern const gchar *osso_gtk_button_attach_details [OSSO_GTK_BUTTON_ATTACH_ENUM_END];
++
++void osso_gtk_button_set_detail_from_attach_flags (GtkButton *button,
++ OssoGtkButtonAttachFlags flags);
++
+ #ifdef __cplusplus
+ }
+ #endif /* __cplusplus */
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcalendar.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcalendar.c.diff
index e69de29bb2..e32c05452d 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcalendar.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcalendar.c.diff
@@ -0,0 +1,2464 @@
+--- gtk+-2.6.4/gtk/gtkcalendar.c 2004-11-12 19:51:58.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkcalendar.c 2005-04-06 16:19:36.267024936 +0300
+@@ -169,14 +169,23 @@
+
+ /*** END OF lib_date routines ********************************************/
+
++/* HILDON: Spacings modified */
++
++#define HILDON_ARROW_WIDTH 20
++#define HILDON_ARROW_HEIGHT 27
++#define HILDON_ARROW_SEP 5 /* Space between arrows and data */
++
++#define HILDON_DAY_WIDTH 26
++#define HILDON_DAY_HEIGHT 25
++
+ /* Spacing around day/week headers and main area, inside those windows */
+ #define CALENDAR_MARGIN 0
+ /* Spacing around day/week headers and main area, outside those windows */
+-#define INNER_BORDER 4
++#define INNER_BORDER 0 /* 4 */
+ /* Separation between day headers and main area */
+-#define CALENDAR_YSEP 4
++#define CALENDAR_YSEP 3 /* 4 */
+ /* Separation between week headers and main area */
+-#define CALENDAR_XSEP 4
++#define CALENDAR_XSEP 6 /* 4 */
+
+ #define DAY_XSEP 0 /* not really good for small calendar */
+ #define DAY_YSEP 0 /* not really good for small calendar */
+@@ -193,6 +202,10 @@
+ #define BACKGROUND_COLOR(widget) (& (widget)->style->base[GTK_WIDGET_STATE (widget)])
+ #define HIGHLIGHT_BACK_COLOR(widget) (& (widget)->style->mid[GTK_WIDGET_STATE (widget)])
+
++/* Default Min/Max years for hildon calendar */
++#define HILDON_MIN_YEAR 0
++#define HILDON_MAX_YEAR 2999
++
+ enum {
+ ARROW_YEAR_LEFT,
+ ARROW_YEAR_RIGHT,
+@@ -214,6 +227,8 @@
+ NEXT_MONTH_SIGNAL,
+ PREV_YEAR_SIGNAL,
+ NEXT_YEAR_SIGNAL,
++ ERRONEOUS_DATE_SIGNAL,
++ SELECTED_DATE_SIGNAL,
+ LAST_SIGNAL
+ };
+
+@@ -238,16 +253,19 @@
+ struct _GtkCalendarPrivateData
+ {
+ GdkWindow *header_win;
++ GdkWindow *footer_win; /* HILDON: Added below calendar */
+ GdkWindow *day_name_win;
+ GdkWindow *main_win;
+ GdkWindow *week_win;
+ GdkWindow *arrow_win[4];
+
++ gint year_before;
+ guint header_h;
+ guint day_name_h;
+ guint main_h;
+
+ guint arrow_state[4];
++ /* guint arrow_width; This is now defined constant. Even normal Gtk don't allow to change this */
+ guint arrow_width;
+ guint max_month_width;
+ guint max_year_width;
+@@ -271,7 +289,7 @@
+ guint dirty_main : 1;
+ guint dirty_week : 1;
+
+- guint year_before : 1;
++/* guint year_before : 1;*/
+
+ guint need_timer : 1;
+
+@@ -281,6 +299,27 @@
+ guint32 timer;
+ gint click_child;
+
++ /* Following variables are for current date */
++ guint current_day;
++ guint current_month;
++ guint current_year;
++
++ /* Keep track of day and month
++ * where mouse button was pressed
++ */
++ guint pressed_day;
++ guint pressed_month;
++
++ /* Boolean value to indicate if
++ * out of bound day was selected
++ */
++ gboolean is_bad_day;
++
++ /* Must check if we are sliding stylus */
++ gboolean slide_stylus;
++ gint prev_row;
++ gint prev_col;
++
+ gint week_start;
+
+ gint drag_start_x;
+@@ -336,6 +375,8 @@
+ static void gtk_calendar_style_set (GtkWidget *widget,
+ GtkStyle *previous_style);
+ static void gtk_calendar_paint_header (GtkWidget *widget);
++static void gtk_calendar_paint_footer (GtkWidget *widget);
++
+ static void gtk_calendar_paint_day_names (GtkWidget *widget);
+ static void gtk_calendar_paint_week_numbers (GtkWidget *widget);
+ static void gtk_calendar_paint_main (GtkWidget *widget);
+@@ -381,7 +422,13 @@
+ gint x,
+ gint y,
+ guint time);
+-
++
++/* This function was added because we need to mark current day according to
++ * specifications
++ */
++static void
++gtk_calendar_check_current_date (GtkCalendar *calendar, gint x, gint y);
++
+ static char *default_abbreviated_dayname[7];
+ static char *default_monthname[12];
+
+@@ -461,6 +508,8 @@
+ class->next_month = NULL;
+ class->prev_year = NULL;
+ class->next_year = NULL;
++ class->erroneous_date = NULL;
++ class->selected_date = NULL;
+
+ g_object_class_install_property (gobject_class,
+ PROP_YEAR,
+@@ -543,6 +592,31 @@
+ FALSE,
+ G_PARAM_READWRITE));
+
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("min-year",
++ P_("Minimum year for calendar"),
++ P_("Set minimum year calendar accepts"),
++ 0,
++ G_MAXINT,
++ HILDON_MIN_YEAR,
++ G_PARAM_READWRITE));
++
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("max-year",
++ P_("Maximum year for calendar"),
++ P_("Set max year that calendar accepts"),
++ 0,
++ G_MAXINT,
++ HILDON_MAX_YEAR,
++ G_PARAM_READWRITE));
++
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_boolean ("hildonlike",
++ _("Size request"),
++ _("Size allocate"),
++ FALSE,
++ G_PARAM_READABLE));
++
+ gtk_calendar_signals[MONTH_CHANGED_SIGNAL] =
+ g_signal_new ("month_changed",
+ G_OBJECT_CLASS_TYPE (gobject_class),
+@@ -599,6 +673,22 @@
+ NULL, NULL,
+ _gtk_marshal_VOID__VOID,
+ G_TYPE_NONE, 0);
++ gtk_calendar_signals[ERRONEOUS_DATE_SIGNAL] =
++ g_signal_new ("erroneous_date",
++ G_OBJECT_CLASS_TYPE(gobject_class),
++ G_SIGNAL_RUN_FIRST,
++ G_STRUCT_OFFSET (GtkCalendarClass, erroneous_date),
++ NULL, NULL,
++ _gtk_marshal_VOID__VOID,
++ G_TYPE_NONE, 0);
++ gtk_calendar_signals[SELECTED_DATE_SIGNAL] =
++ g_signal_new ("selected_date",
++ G_OBJECT_CLASS_TYPE(gobject_class),
++ G_SIGNAL_RUN_FIRST,
++ G_STRUCT_OFFSET (GtkCalendarClass, selected_date),
++ NULL, NULL,
++ _gtk_marshal_VOID__VOID,
++ G_TYPE_NONE, 0);
+ }
+
+ static void
+@@ -611,8 +701,10 @@
+ time_t tmp_time;
+ GtkWidget *widget;
+ GtkCalendarPrivateData *private_data;
+- gchar *year_before;
++/* gchar *year_before;*/
+ gchar *week_start;
++/* gint row;
++ gint col; */
+
+ widget = GTK_WIDGET (calendar);
+ GTK_WIDGET_SET_FLAGS (widget, GTK_CAN_FOCUS);
+@@ -645,16 +737,29 @@
+ for (i=0;i<31;i++)
+ calendar->marked_date[i] = FALSE;
+ calendar->num_marked_dates = 0;
+- calendar->selected_day = tm->tm_mday;
+-
++ calendar->selected_day = tm->tm_mday;
++
+ calendar->display_flags = ( GTK_CALENDAR_SHOW_HEADING |
+ GTK_CALENDAR_SHOW_DAY_NAMES );
+
++ /* Hildon: we should mark current day and we need to store current date */
++ private_data->current_day = tm->tm_mday;
++ private_data->current_month = tm->tm_mon;
++ private_data->current_year = tm->tm_year + 1900;
++
++ /* Hildon: following lines are for stylus sliding */
++ private_data->slide_stylus = FALSE;
++ private_data->prev_row = -1;
++ private_data->prev_col = -1;
++
++ /* Hildon: is_bad_day indicate if day was selected out of legal range */
++ private_data->is_bad_day = FALSE;
++
+ calendar->highlight_row = -1;
+- calendar->highlight_col = -1;
++ calendar->highlight_col = -1;
+
+ calendar->focus_row = -1;
+- calendar->focus_col = -1;
++ calendar->focus_col = -1;
+ calendar->xor_gc = NULL;
+
+ private_data->max_year_width = 0;
+@@ -667,7 +772,7 @@
+ private_data->max_label_char_ascent = 0;
+ private_data->max_label_char_descent = 0;
+
+- private_data->arrow_width = 10;
++/* private_data->arrow_width = 10;*/
+
+ private_data->freeze_count = 0;
+
+@@ -686,6 +791,7 @@
+ gtk_drag_dest_set (widget, 0, NULL, 0, GDK_ACTION_COPY);
+ gtk_drag_dest_add_text_targets (widget);
+
++#if 0
+ private_data->year_before = 0;
+
+ /* Translate to calendar:YM if you want years to be displayed
+@@ -702,11 +808,13 @@
+ private_data->year_before = 1;
+ else if (strcmp (year_before, "calendar:MY") != 0)
+ g_warning ("Whoever translated calendar:MY did so wrongly.\n");
++#endif
+
+ /* Translate to calendar:week_start:0 if you want Sunday to be the
+ * first day of the week to calendar:week_start:1 if you want Monday
+ * to be the first day of the week, and so on.
+ */
++
+ week_start = _("calendar:week_start:0");
+
+ if (strncmp (week_start, "calendar:week_start:", 20) == 0)
+@@ -752,7 +860,7 @@
+
+ return column;
+ }
+-
++#if 0
+ static gint
+ row_height (GtkCalendar *calendar)
+ {
+@@ -760,7 +868,7 @@
+ - ((calendar->display_flags & GTK_CALENDAR_SHOW_DAY_NAMES)
+ ? CALENDAR_YSEP : CALENDAR_MARGIN)) / 6;
+ }
+-
++#endif
+
+ /* row_from_y: returns the row 0-5 that the
+ * y pixel of the xwindow is in */
+@@ -769,16 +877,15 @@
+ gint event_y)
+ {
+ gint r, row;
+- gint height;
++ /*gint height;*/
+ gint y_top, y_bottom;
+
+- height = row_height (calendar);
+ row = -1;
+
+ for (r = 0; r < 6; r++)
+ {
+ y_top = top_y_for_row (calendar, r);
+- y_bottom = y_top + height;
++ y_bottom = y_top + HILDON_DAY_HEIGHT /*height*/;
+
+ if (event_y >= y_top && event_y < y_bottom)
+ {
+@@ -796,16 +903,16 @@
+ {
+ gint width;
+ gint x_left;
+-
++
+ if (gtk_widget_get_direction (GTK_WIDGET (calendar)) == GTK_TEXT_DIR_RTL)
+ column = 6 - column;
+-
++
+ width = GTK_CALENDAR_PRIVATE_DATA (calendar)->day_width;
+ if (calendar->display_flags & GTK_CALENDAR_SHOW_WEEK_NUMBERS)
+ x_left = CALENDAR_XSEP + (width + DAY_XSEP) * column;
+ else
+ x_left = CALENDAR_MARGIN + (width + DAY_XSEP) * column;
+-
++
+ return x_left;
+ }
+
+@@ -818,25 +925,41 @@
+
+ return (GTK_CALENDAR_PRIVATE_DATA (calendar)->main_h
+ - (CALENDAR_MARGIN + (6 - row)
+- * row_height (calendar)));
++ * HILDON_DAY_HEIGHT));
+ }
+
+ static void
+ gtk_calendar_set_month_prev (GtkCalendar *calendar)
+ {
+ gint month_len;
+-
++ gint min_year;
++ gboolean hildonlike;
++
++ gtk_widget_style_get (GTK_WIDGET (calendar), "hildonlike", &hildonlike,
++ "min-year", &min_year, NULL);
++
+ if (calendar->display_flags & GTK_CALENDAR_NO_MONTH_CHANGE)
+ return;
+
+ if (calendar->month == 0)
+- {
+- calendar->month = 11;
+- calendar->year--;
+- }
+- else
+- calendar->month--;
+-
++ {
++ if (hildonlike)
++ {
++ if (calendar->year > min_year)
++ {
++ calendar->month = 11;
++ calendar->year--;
++ }
++ }
++ else
++ {
++ calendar->month = 11;
++ calendar->year--;
++ }
++ }
++ else
++ calendar->month--;
++
+ month_len = month_length[leap (calendar->year)][calendar->month + 1];
+
+ gtk_calendar_freeze (calendar);
+@@ -870,17 +993,32 @@
+ gtk_calendar_set_month_next (GtkCalendar *calendar)
+ {
+ gint month_len;
++ gint max_year;
++ gboolean hildonlike;
+
+ g_return_if_fail (GTK_IS_WIDGET (calendar));
+
++ gtk_widget_style_get (GTK_WIDGET (calendar), "hildonlike", &hildonlike,
++ "max-year", &max_year, NULL);
++
+ if (calendar->display_flags & GTK_CALENDAR_NO_MONTH_CHANGE)
+ return;
+
+-
+ if (calendar->month == 11)
+ {
+- calendar->month = 0;
+- calendar->year++;
++ if (hildonlike)
++ {
++ if (calendar->year < max_year)
++ {
++ calendar->month = 0;
++ calendar->year++;
++ }
++ }
++ else
++ {
++ calendar->month = 0;
++ calendar->year++;
++ }
+ }
+ else
+ calendar->month++;
+@@ -912,10 +1050,22 @@
+ gtk_calendar_set_year_prev (GtkCalendar *calendar)
+ {
+ gint month_len;
+-
++ gint min_year;
++ gboolean hildonlike;
++
+ g_return_if_fail (GTK_IS_WIDGET (calendar));
+
+- calendar->year--;
++ gtk_widget_style_get (GTK_WIDGET (calendar), "hildonlike", &hildonlike,
++ "min-year", &min_year, NULL);
++
++ if (hildonlike)
++ {
++ if (calendar->year > min_year)
++ calendar->year--;
++ }
++ else
++ calendar->year--;
++
+ gtk_calendar_freeze (calendar);
+ gtk_calendar_compute_days (calendar);
+ g_signal_emit (calendar,
+@@ -944,14 +1094,26 @@
+ {
+ gint month_len;
+ GtkWidget *widget;
++ gint max_year;
++ gboolean hildonlike;
+
+ g_return_if_fail (GTK_IS_WIDGET (calendar));
+
+ widget = GTK_WIDGET (calendar);
++
++ gtk_widget_style_get(widget, "hildonlike", &hildonlike,
++ "max-year", &max_year, NULL);
+
+ gtk_calendar_freeze (calendar);
+
+- calendar->year++;
++ if (hildonlike)
++ {
++ if (calendar->year < max_year)
++ calendar->year++;
++ }
++ else
++ calendar->year++;
++
+ gtk_calendar_compute_days (calendar);
+ g_signal_emit (calendar,
+ gtk_calendar_signals[NEXT_YEAR_SIGNAL],
+@@ -969,7 +1131,6 @@
+ }
+ else
+ gtk_calendar_select_day (calendar, calendar->selected_day);
+-
+ gtk_widget_queue_draw (GTK_WIDGET (calendar));
+ gtk_calendar_thaw (calendar);
+ }
+@@ -984,6 +1145,8 @@
+ gint row, col;
+ gint day_month;
+ gint day;
++ gint max_year, min_year;
++ gboolean hildonlike;
+
+ calendar = GTK_CALENDAR (widget);
+ private_data = GTK_CALENDAR_PRIVATE_DATA (widget);
+@@ -997,20 +1160,36 @@
+ /* If row or column isn't found, just return. */
+ if (row == -1 || col == -1)
+ return;
+-
+- day_month = calendar->day_month[row][col];
+
+- if (event->type == GDK_BUTTON_PRESS)
++ gtk_widget_style_get (GTK_WIDGET (calendar), "hildonlike", &hildonlike,
++ "max-year", &max_year, "min-year", &min_year, NULL);
++ day_month = calendar->day_month[row][col];
++
++ if (hildonlike)
++ {
++ if ((calendar->year == min_year && calendar->month == 0 && day_month == MONTH_PREV)
++ || (calendar->year == max_year && calendar->month == 11 && day_month == MONTH_NEXT))
++ {
++ private_data->is_bad_day = TRUE;
++ g_signal_emit (calendar, gtk_calendar_signals[ERRONEOUS_DATE_SIGNAL], 0);
++ return;
++ }
++ }
++ if (event->type == (hildonlike ? GDK_BUTTON_RELEASE : GDK_BUTTON_PRESS))
+ {
+ day = calendar->day[row][col];
+
+ if (day_month == MONTH_PREV)
+- gtk_calendar_set_month_prev (calendar);
++ {
++ gtk_calendar_set_month_prev (calendar);
++ }
+ else if (day_month == MONTH_NEXT)
+- gtk_calendar_set_month_next (calendar);
++ {
++ gtk_calendar_set_month_next (calendar);
++ }
+
+ if (!GTK_WIDGET_HAS_FOCUS (widget))
+- gtk_widget_grab_focus (widget);
++ gtk_widget_grab_focus (widget);
+
+ if (event->button == 1)
+ {
+@@ -1025,9 +1204,8 @@
+ {
+ private_data->in_drag = 0;
+ if (day_month == MONTH_CURRENT)
+- g_signal_emit (calendar,
+- gtk_calendar_signals[DAY_SELECTED_DOUBLE_CLICK_SIGNAL],
+- 0);
++ g_signal_emit (calendar,
++ gtk_calendar_signals[DAY_SELECTED_DOUBLE_CLICK_SIGNAL], 0);
+ }
+ }
+
+@@ -1039,18 +1217,18 @@
+ GdkWindowAttr attributes;
+ gint attributes_mask;
+ gint i;
+- gboolean year_left;
++ /*gboolean year_left;*/
+
+ g_return_if_fail (GTK_IS_CALENDAR (widget));
+
+ calendar = GTK_CALENDAR (widget);
+ private_data = GTK_CALENDAR_PRIVATE_DATA (widget);
+-
++/*
+ if (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_LTR)
+ year_left = private_data->year_before;
+ else
+ year_left = !private_data->year_before;
+-
++*/
+ /* Arrow windows ------------------------------------- */
+ if (! (calendar->display_flags & GTK_CALENDAR_NO_MONTH_CHANGE)
+ && (calendar->display_flags & GTK_CALENDAR_SHOW_HEADING))
+@@ -1063,10 +1241,26 @@
+ | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK
+ | GDK_ENTER_NOTIFY_MASK | GDK_LEAVE_NOTIFY_MASK);
+ attributes_mask = GDK_WA_X | GDK_WA_Y | GDK_WA_VISUAL | GDK_WA_COLORMAP;
+- attributes.y = 3;
+- attributes.width = private_data->arrow_width;
+- attributes.height = private_data->header_h - 7;
+- for (i = 0; i < 4; i++)
++ attributes.y = 0;
++ attributes.width = HILDON_ARROW_WIDTH;
++ attributes.height = HILDON_ARROW_HEIGHT;
++
++ attributes.x = (widget->allocation.width - private_data->max_year_width) / 2 - HILDON_ARROW_WIDTH - HILDON_ARROW_SEP;
++ private_data->arrow_win[ARROW_YEAR_LEFT] = gdk_window_new (private_data->header_win,
++ &attributes, attributes_mask);
++
++ attributes.x = (widget->allocation.width + private_data->max_year_width) / 2 + HILDON_ARROW_SEP;
++ private_data->arrow_win[ARROW_YEAR_RIGHT] = gdk_window_new (private_data->header_win,
++ &attributes, attributes_mask);
++ attributes.x = (widget->allocation.width - private_data->max_month_width) / 2 - HILDON_ARROW_WIDTH - HILDON_ARROW_SEP;
++ private_data->arrow_win[ARROW_MONTH_LEFT] = gdk_window_new (private_data->footer_win,
++ &attributes, attributes_mask);
++ attributes.x = (widget->allocation.width + private_data->max_month_width) / 2 + HILDON_ARROW_SEP;
++ private_data->arrow_win[ARROW_MONTH_RIGHT] = gdk_window_new (private_data->footer_win,
++ &attributes, attributes_mask);
++
++/*
++for (i = 0; i < 4; i++)
+ {
+ switch (i)
+ {
+@@ -1105,7 +1299,10 @@
+ }
+ private_data->arrow_win[i] = gdk_window_new (private_data->header_win,
+ &attributes,
+- attributes_mask);
++ attributes_mask);*/
++
++ for (i = 0; i < 4; i++)
++ {
+ if (GTK_WIDGET_IS_SENSITIVE (widget))
+ private_data->arrow_state[i] = GTK_STATE_NORMAL;
+ else
+@@ -1145,23 +1342,33 @@
+ attributes.colormap = gtk_widget_get_colormap (widget);
+ attributes.event_mask = gtk_widget_get_events (widget) | GDK_EXPOSURE_MASK;
+ attributes_mask = GDK_WA_X | GDK_WA_Y | GDK_WA_VISUAL | GDK_WA_COLORMAP;
+- attributes.x = widget->style->xthickness;
+- attributes.y = widget->style->ythickness;
+- attributes.width = widget->allocation.width - 2 * attributes.x;
+- attributes.height = private_data->header_h - 2 * attributes.y;
++ attributes.x = 0 /*widget->style->xthickness*/;
++ attributes.y = 0 /*widget->style->ythickness*/;
++ attributes.width = widget->allocation.width; /* - 2 * attributes.x */;
++ attributes.height = HILDON_ARROW_HEIGHT /*private_data->header_h - 2 * attributes.y*/;
+ private_data->header_win = gdk_window_new (widget->window,
+ &attributes, attributes_mask);
+-
++
++ attributes.y = HILDON_ARROW_HEIGHT + 2 * CALENDAR_YSEP + private_data->main_h + private_data->day_name_h;
++
++ private_data->footer_win = gdk_window_new(widget->window,
++ &attributes, attributes_mask);
++
+ gdk_window_set_background (private_data->header_win,
+- HEADER_BG_COLOR (GTK_WIDGET (calendar)));
++ HEADER_BG_COLOR (widget));
++ gdk_window_set_background (private_data->footer_win,
++ HEADER_BG_COLOR (widget));
++
+ gdk_window_show (private_data->header_win);
++ gdk_window_show (private_data->footer_win);
+ gdk_window_set_user_data (private_data->header_win, widget);
+-
++ gdk_window_set_user_data (private_data->footer_win, widget);
+ }
+ else
+ {
+ private_data->header_win = NULL;
+- }
++ private_data->footer_win = NULL;
++ }
+ gtk_calendar_realize_arrows (widget);
+ }
+
+@@ -1172,7 +1379,7 @@
+ GtkCalendarPrivateData *private_data;
+ GdkWindowAttr attributes;
+ gint attributes_mask;
+-
++
+ g_return_if_fail (GTK_IS_CALENDAR (widget));
+
+ calendar = GTK_CALENDAR (widget);
+@@ -1187,18 +1394,16 @@
+ attributes.colormap = gtk_widget_get_colormap (widget);
+ attributes.event_mask = gtk_widget_get_events (widget) | GDK_EXPOSURE_MASK;
+ attributes_mask = GDK_WA_X | GDK_WA_Y | GDK_WA_VISUAL | GDK_WA_COLORMAP;
+- attributes.x = (widget->style->xthickness + INNER_BORDER);
+- attributes.y = private_data->header_h + (widget->style->ythickness
+- + INNER_BORDER);
+- attributes.width = (widget->allocation.width
+- - (widget->style->xthickness + INNER_BORDER)
+- * 2);
++ attributes.x = /*private_data->week_width*/ (widget->style->xthickness + INNER_BORDER);
++ attributes.y = private_data->header_h;
++ attributes.width = widget->allocation.width - attributes.x;
+ attributes.height = private_data->day_name_h;
+ private_data->day_name_win = gdk_window_new (widget->window,
+ &attributes,
+ attributes_mask);
+ gdk_window_set_background (private_data->day_name_win,
+- BACKGROUND_COLOR ( GTK_WIDGET ( calendar)));
++ BACKGROUND_COLOR ( GTK_WIDGET (calendar)));
++
+ gdk_window_show (private_data->day_name_win);
+ gdk_window_set_user_data (private_data->day_name_win, widget);
+ }
+@@ -1215,7 +1420,7 @@
+ GtkCalendarPrivateData *private_data;
+ GdkWindowAttr attributes;
+ gint attributes_mask;
+-
++
+ g_return_if_fail (GTK_IS_CALENDAR (widget));
+
+ calendar = GTK_CALENDAR (widget);
+@@ -1231,15 +1436,15 @@
+ attributes.event_mask = gtk_widget_get_events (widget) | GDK_EXPOSURE_MASK;
+
+ attributes_mask = GDK_WA_X | GDK_WA_Y | GDK_WA_VISUAL | GDK_WA_COLORMAP;
+- attributes.x = widget->style->xthickness + INNER_BORDER;
+- attributes.y = (private_data->header_h + private_data->day_name_h
+- + (widget->style->ythickness + INNER_BORDER));
+- attributes.width = private_data->week_width;
+- attributes.height = private_data->main_h;
++ attributes.x = 0 /*widget->style->xthickness + INNER_BORDER*/;
++ attributes.y = private_data->header_h;
++ /*+ (widget->style->ythickness + INNER_BORDER))*/;
++ attributes.width = HILDON_DAY_WIDTH;
++ attributes.height = private_data->main_h + private_data->day_name_h;
+ private_data->week_win = gdk_window_new (widget->window,
+- &attributes, attributes_mask);
++ &attributes, attributes_mask);
+ gdk_window_set_background (private_data->week_win,
+- BACKGROUND_COLOR (GTK_WIDGET (calendar)));
++ BACKGROUND_COLOR (GTK_WIDGET (calendar)));
+ gdk_window_show (private_data->week_win);
+ gdk_window_set_user_data (private_data->week_win, widget);
+ }
+@@ -1318,7 +1523,6 @@
+ GDK_GC_FOREGROUND |
+ GDK_GC_FUNCTION);
+ }
+-
+ static void
+ gtk_calendar_unrealize (GtkWidget *widget)
+ {
+@@ -1343,7 +1547,10 @@
+ gdk_window_set_user_data (private_data->header_win, NULL);
+ gdk_window_destroy (private_data->header_win);
+ private_data->header_win = NULL;
+- }
++ gdk_window_set_user_data (private_data->footer_win, NULL);
++ gdk_window_destroy (private_data->footer_win);
++ private_data->footer_win = NULL;
++ }
+
+ if (private_data->week_win)
+ {
+@@ -1382,10 +1589,10 @@
+ PangoLayout *layout;
+ PangoRectangle logical_rect;
+
+- gint height;
++ /*gint height;*/
+ gint i;
+ gchar buffer[255];
+- gint calendar_margin = CALENDAR_MARGIN;
++ /*gint calendar_margin = CALENDAR_MARGIN;*/
+ gint header_width, main_width;
+ gint max_header_height = 0;
+ gint focus_width;
+@@ -1401,20 +1608,20 @@
+ layout = gtk_widget_create_pango_layout (widget, NULL);
+
+ /*
+- * Calculate the requisition width for the widget.
++ * Calculate the requisition width for the widget.
+ */
+
+ /* Header width */
+-
++
+ if (calendar->display_flags & GTK_CALENDAR_SHOW_HEADING)
+- {
++ {
+ private_data->max_month_width = 0;
+ for (i = 0; i < 12; i++)
+ {
+ pango_layout_set_text (layout, default_monthname[i], -1);
+ pango_layout_get_pixel_extents (layout, NULL, &logical_rect);
+ private_data->max_month_width = MAX (private_data->max_month_width,
+- logical_rect.width + 8);
++ logical_rect.width +8 );
+ max_header_height = MAX (max_header_height, logical_rect.height);
+ }
+ private_data->max_year_width = 0;
+@@ -1427,13 +1634,13 @@
+ logical_rect.width + 8);
+ max_header_height = MAX (max_header_height, logical_rect.height);
+ }
+- }
++ }
+ else
+ {
+ private_data->max_month_width = 0;
+ private_data->max_year_width = 0;
+ }
+-
++
+ if (calendar->display_flags & GTK_CALENDAR_NO_MONTH_CHANGE)
+ header_width = (private_data->max_month_width
+ + private_data->max_year_width
+@@ -1494,45 +1701,30 @@
+ + (private_data->max_week_char_width
+ ? private_data->max_week_char_width * 2 + (focus_padding + focus_width) * 2 + CALENDAR_XSEP * 2
+ : 0));
+-
+-
++
+ requisition->width = MAX (header_width, main_width + INNER_BORDER * 2) + widget->style->xthickness * 2;
++ /* FIXME: header_width is broken, when Calendar is themed !
++ * Next line is workaround for this bug
++ */
++ requisition->width = (main_width + INNER_BORDER * 2) + widget->style->xthickness * 2;
+
+ /*
+ * Calculate the requisition height for the widget.
++ * This is Hildon calculation
+ */
+-
++
+ if (calendar->display_flags & GTK_CALENDAR_SHOW_HEADING)
+- {
+- private_data->header_h = (max_header_height + CALENDAR_YSEP * 2);
+- }
++ private_data->header_h = HILDON_ARROW_HEIGHT + CALENDAR_YSEP;
+ else
+- {
+ private_data->header_h = 0;
+- }
+-
++
+ if (calendar->display_flags & GTK_CALENDAR_SHOW_DAY_NAMES)
+- {
+- private_data->day_name_h = (private_data->max_label_char_ascent
+- + private_data->max_label_char_descent
+- + 2 * (focus_padding + focus_width) + calendar_margin);
+- calendar_margin = CALENDAR_YSEP;
+- }
++ private_data->day_name_h = HILDON_DAY_HEIGHT;
+ else
+- {
+ private_data->day_name_h = 0;
+- }
+
+- private_data->main_h = (CALENDAR_MARGIN + calendar_margin
+- + 6 * (private_data->max_day_char_ascent
+- + private_data->max_day_char_descent
+- + 2 * (focus_padding + focus_width))
+- + DAY_YSEP * 5);
+-
+- height = (private_data->header_h + private_data->day_name_h
+- + private_data->main_h);
+-
+- requisition->height = height + (widget->style->ythickness + INNER_BORDER) * 2;
++ private_data->main_h = 6 * HILDON_DAY_HEIGHT;
++ requisition->height = 2 * private_data->header_h + private_data->day_name_h + private_data->main_h;
+
+ g_object_unref (layout);
+ }
+@@ -1544,7 +1736,7 @@
+ GtkCalendar *calendar;
+ GtkCalendarPrivateData *private_data;
+ gint xthickness = widget->style->xthickness;
+- gint ythickness = widget->style->xthickness;
++ /*gint ythickness = widget->style->xthickness;*/
+ gboolean year_left;
+
+ widget->allocation = *allocation;
+@@ -1569,58 +1761,24 @@
+ }
+ else
+ {
+- private_data->day_width = (allocation->width
++ private_data->day_width = (allocation->width
+ - (xthickness + INNER_BORDER) * 2
+ - (CALENDAR_MARGIN * 2)
+ - (DAY_XSEP * 6))/7;
+ private_data->week_width = 0;
+ }
+-
++
+ if (GTK_WIDGET_REALIZED (widget))
+ {
+ gdk_window_move_resize (widget->window,
+- allocation->x, allocation->y,
+- allocation->width, allocation->height);
++ widget->allocation.x, widget->allocation.y,
++ widget->allocation.width, widget->allocation.height);
+ if (private_data->header_win)
+ gdk_window_move_resize (private_data->header_win,
+- xthickness, ythickness,
+- allocation->width - 2 * xthickness, private_data->header_h);
+- if (private_data->arrow_win[ARROW_MONTH_LEFT])
+- {
+- if (year_left)
+- gdk_window_move_resize (private_data->arrow_win[ARROW_MONTH_LEFT],
+- (allocation->width - 2 * xthickness
+- - (3 + 2*private_data->arrow_width
+- + private_data->max_month_width)),
+- 3,
+- private_data->arrow_width,
+- private_data->header_h - 7);
+- else
+- gdk_window_move_resize (private_data->arrow_win[ARROW_MONTH_LEFT],
+- 3, 3,
+- private_data->arrow_width,
+- private_data->header_h - 7);
+- }
+- if (private_data->arrow_win[ARROW_MONTH_RIGHT])
+- {
+- if (year_left)
+- gdk_window_move_resize (private_data->arrow_win[ARROW_MONTH_RIGHT],
+- (allocation->width - 2 * xthickness
+- - 3 - private_data->arrow_width),
+- 3,
+- private_data->arrow_width,
+- private_data->header_h - 7);
+- else
+- gdk_window_move_resize (private_data->arrow_win[ARROW_MONTH_RIGHT],
+- (private_data->arrow_width
+- + private_data->max_month_width),
+- 3,
+- private_data->arrow_width,
+- private_data->header_h - 7);
+- }
++ 0, 0, widget->allocation.width, HILDON_ARROW_HEIGHT);
+ if (private_data->arrow_win[ARROW_YEAR_LEFT])
+ {
+- if (year_left)
++ /* if (year_left)
+ gdk_window_move_resize (private_data->arrow_win[ARROW_YEAR_LEFT],
+ 3, 3,
+ private_data->arrow_width,
+@@ -1632,11 +1790,14 @@
+ + private_data->max_year_width)),
+ 3,
+ private_data->arrow_width,
+- private_data->header_h - 7);
++ private_data->header_h - 7);*/
++
++ gdk_window_move (private_data->arrow_win[ARROW_YEAR_LEFT],
++ (widget->allocation.width - private_data->max_year_width) / 2 - HILDON_ARROW_WIDTH - HILDON_ARROW_SEP, 0);
+ }
+ if (private_data->arrow_win[ARROW_YEAR_RIGHT])
+ {
+- if (year_left)
++/* if (year_left)
+ gdk_window_move_resize (private_data->arrow_win[ARROW_YEAR_RIGHT],
+ (private_data->arrow_width
+ + private_data->max_year_width),
+@@ -1649,55 +1810,102 @@
+ - 3 - private_data->arrow_width),
+ 3,
+ private_data->arrow_width,
++ private_data->header_h - 7);*/
++ gdk_window_move (private_data->arrow_win[ARROW_YEAR_RIGHT],
++ (widget->allocation.width + private_data->max_year_width) / 2 + HILDON_ARROW_SEP, 0);
++ }
++ if (private_data->footer_win)
++ gdk_window_move_resize (private_data->footer_win,
++ 0, private_data->header_h + private_data->day_name_h + private_data->main_h + CALENDAR_YSEP,
++ widget->allocation.width, HILDON_ARROW_HEIGHT);
++
++ if (private_data->arrow_win[ARROW_MONTH_LEFT])
++ {
++/* if (year_left)
++ gdk_window_move_resize (private_data->arrow_win[ARROW_MONTH_LEFT],
++ (allocation->width - 2 * xthickness
++ - (3 + 2*private_data->arrow_width
++ + private_data->max_month_width)),
++ 3,
++ private_data->arrow_width,
+ private_data->header_h - 7);
++ else
++ gdk_window_move_resize (private_data->arrow_win[ARROW_MONTH_LEFT],
++ 3, 3,
++ private_data->arrow_width,
++ private_data->header_h - 7);
++*/
++
++ gdk_window_move (private_data->arrow_win[ARROW_MONTH_LEFT],
++ (widget->allocation.width - private_data->max_month_width) / 2 - HILDON_ARROW_WIDTH - HILDON_ARROW_SEP, 0);
++ }
++ if (private_data->arrow_win[ARROW_MONTH_RIGHT])
++ {
++/* if (year_left)
++ gdk_window_move_resize (private_data->arrow_win[ARROW_MONTH_RIGHT],
++ (allocation->width - 2 * xthickness
++ - 3 - private_data->arrow_width),
++ 3,
++ private_data->arrow_width,
++ private_data->header_h - 7);
++ else
++ gdk_window_move_resize (private_data->arrow_win[ARROW_MONTH_RIGHT],
++ (private_data->arrow_width
++ + private_data->max_month_width),
++ 3,
++ private_data->arrow_width,
++ private_data->header_h - 7);*/
++ gdk_window_move (private_data->arrow_win[ARROW_MONTH_RIGHT],
++ (widget->allocation.width + private_data->max_month_width) / 2 + HILDON_ARROW_SEP, 0);
+ }
++
++
+ if (private_data->day_name_win)
+ gdk_window_move_resize (private_data->day_name_win,
+- xthickness + INNER_BORDER,
+- private_data->header_h + (widget->style->ythickness + INNER_BORDER),
+- allocation->width - (xthickness + INNER_BORDER) * 2,
++ private_data->week_width, /*xthickness + INNER_BORDER*/
++ private_data->header_h /*+ (widget->style->ythickness + INNER_BORDER)*/,
++ widget->allocation.width - private_data->week_width /*- (xthickness + INNER_BORDER) * 2*/,
+ private_data->day_name_h);
+ if (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_LTR)
+ {
+ if (private_data->week_win)
+ gdk_window_move_resize (private_data->week_win,
+- (xthickness + INNER_BORDER),
+- private_data->header_h + private_data->day_name_h
+- + (widget->style->ythickness + INNER_BORDER),
+- private_data->week_width,
+- private_data->main_h);
++ 0 /*(xthickness + INNER_BORDER)*/,
++ private_data->header_h /*+ (widget->style->ythickness + INNER_BORDER)*/,
++ HILDON_DAY_WIDTH,
++ private_data->main_h + private_data->day_name_h);
+ gdk_window_move_resize (private_data->main_win,
+- private_data->week_width + (xthickness + INNER_BORDER),
++ private_data->week_width /* + (xthickness + INNER_BORDER)*/,
+ private_data->header_h + private_data->day_name_h
+- + (widget->style->ythickness + INNER_BORDER),
+- allocation->width
+- - private_data->week_width
+- - (xthickness + INNER_BORDER) * 2,
++ /*+ (widget->style->ythickness + INNER_BORDER)*/,
++ widget->allocation.width - private_data->week_width
++ /*- (xthickness + INNER_BORDER) * 2*/,
+ private_data->main_h);
+ }
+ else
+ {
+ gdk_window_move_resize (private_data->main_win,
+- (xthickness + INNER_BORDER),
++ 0 /*(xthickness + INNER_BORDER)*/,
+ private_data->header_h + private_data->day_name_h
+- + (widget->style->ythickness + INNER_BORDER),
+- allocation->width
++ /*+ (widget->style->ythickness + INNER_BORDER)*/,
++ widget->allocation.width
+ - private_data->week_width
+- - (xthickness + INNER_BORDER) * 2,
++ /*- (xthickness + INNER_BORDER) * 2*/,
+ private_data->main_h);
+ if (private_data->week_win)
+ gdk_window_move_resize (private_data->week_win,
+- allocation->width
++ widget->allocation.width
+ - private_data->week_width
+- - (xthickness + INNER_BORDER),
++ /*- (xthickness + INNER_BORDER)*/,
+ private_data->header_h + private_data->day_name_h
+- + (widget->style->ythickness + INNER_BORDER),
++ /*+ (widget->style->ythickness + INNER_BORDER)*/,
+ private_data->week_width,
+ private_data->main_h);
+ }
+ }
+ }
+
++
+ static gboolean
+ gtk_calendar_expose (GtkWidget *widget,
+ GdkEventExpose *event)
+@@ -1711,22 +1919,24 @@
+ if (GTK_WIDGET_DRAWABLE (widget))
+ {
+ if (event->window == private_data->main_win)
+- gtk_calendar_paint_main (widget);
++ gtk_calendar_paint_main (widget);
+
+ if (event->window == private_data->header_win)
+- gtk_calendar_paint_header (widget);
+-
+- if (event->window == private_data->day_name_win)
+- gtk_calendar_paint_day_names (widget);
+-
+- if (event->window == private_data->week_win)
+- gtk_calendar_paint_week_numbers (widget);
+- if (event->window == widget->window)
++ gtk_calendar_paint_header (widget);
++ if (event->window == private_data->footer_win)
++ gtk_calendar_paint_footer(widget);
++
++ if (event->window == private_data->day_name_win)
++ gtk_calendar_paint_day_names (widget);
++
++ if (event->window == private_data->week_win)
++ gtk_calendar_paint_week_numbers (widget);
++/* if (event->window == widget->window)
+ {
+ gtk_paint_shadow (widget->style, widget->window, GTK_WIDGET_STATE (widget),
+ GTK_SHADOW_IN, NULL, widget, "calendar",
+ 0, 0, widget->allocation.width, widget->allocation.height);
+- }
++ }*/
+ }
+
+ return FALSE;
+@@ -1740,12 +1950,12 @@
+ char buffer[255];
+ int x, y;
+ gint header_width, cal_height;
+- gint max_month_width;
++/* gint max_month_width;*/
+ gint max_year_width;
+ GtkCalendarPrivateData *private_data;
+ PangoLayout *layout;
+ PangoRectangle logical_rect;
+- gboolean year_left;
++/* gboolean year_left;*/
+
+ calendar = GTK_CALENDAR (widget);
+ private_data = GTK_CALENDAR_PRIVATE_DATA (widget);
+@@ -1755,29 +1965,29 @@
+ private_data->dirty_header = 1;
+ return;
+ }
+-
++/*
+ if (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_LTR)
+ year_left = private_data->year_before;
+ else
+ year_left = !private_data->year_before;
+-
++*/
+ private_data->dirty_header = 0;
+ gc = calendar->gc;
+
+ /* Clear window */
+ gdk_window_clear (private_data->header_win);
+
+- header_width = widget->allocation.width - 2 * widget->style->xthickness;
++ header_width = widget->allocation.width /*- 2 * widget->style->xthickness*/;
+ cal_height = widget->allocation.height;
+
+- max_month_width = private_data->max_month_width;
++ /*max_month_width = private_data->max_month_width;*/
+ max_year_width = private_data->max_year_width;
+
+- gdk_gc_set_foreground (gc, BACKGROUND_COLOR (GTK_WIDGET (calendar)));
+- gtk_paint_shadow (widget->style, private_data->header_win,
++/* gdk_gc_set_foreground (gc, BACKGROUND_COLOR (GTK_WIDGET (calendar)));*/
++ /*gtk_paint_shadow (widget->style, private_data->header_win,
+ GTK_STATE_NORMAL, GTK_SHADOW_OUT,
+ NULL, widget, "calendar",
+- 0, 0, header_width, private_data->header_h);
++ 0, 0, header_width, private_data->header_h);*/
+
+
+ g_snprintf (buffer, sizeof (buffer), "%d", calendar->year);
+@@ -1785,55 +1995,118 @@
+ pango_layout_get_pixel_extents (layout, NULL, &logical_rect);
+
+ /* Draw title */
+- y = (private_data->header_h - logical_rect.height) / 2;
+-
++ y = (HILDON_ARROW_HEIGHT /*private_data->header_h*/ - logical_rect.height) / 2;
++ x = (widget->allocation.width - logical_rect.width) / 2;
++
+ /* Draw year and its arrows */
+-
++#if 0
+ if (calendar->display_flags & GTK_CALENDAR_NO_MONTH_CHANGE)
+- if (year_left)
+- x = 3 + (max_year_width - logical_rect.width)/2;
+- else
++/* if (year_left) */
++ x = /*3+*/(widget->allocation.width - logical_rect.width)/2;
++/* else
+ x = header_width - (3 + max_year_width
+- - (max_year_width - logical_rect.width)/2);
++ - (max_year_width - logical_rect.width)/2);*/
+ else
+- if (year_left)
+- x = 3 + private_data->arrow_width + (max_year_width - logical_rect.width)/2;
+- else
++/* if (year_left)*/
++ x = 3 + HILDON_ARROW_WIDTH /*private_data->arrow_width*/ + (max_year_width - logical_rect.width)/2;
++ /* else
+ x = header_width - (3 + private_data->arrow_width + max_year_width
+ - (max_year_width - logical_rect.width)/2);
++ */
++ #endif
++ gdk_gc_set_foreground (gc, HEADER_FG_COLOR (GTK_WIDGET (calendar)));
++ gdk_draw_layout (private_data->header_win, gc, x, y, layout);
++
++ gtk_calendar_paint_arrow (widget, ARROW_YEAR_LEFT);
++ gtk_calendar_paint_arrow (widget, ARROW_YEAR_RIGHT);
++
++ g_object_unref (layout);
++}
++
++static void
++gtk_calendar_paint_footer (GtkWidget *widget)
++{
++GtkCalendar *calendar;
++ GdkGC *gc;
++ char buffer[255];
++ int x, y;
++ gint header_width, cal_height;
++/* gint max_month_width;
++ gint max_year_width;*/
++ GtkCalendarPrivateData *private_data;
++ PangoLayout *layout;
++ PangoRectangle logical_rect;
++/* gboolean year_left;*/
++
++ calendar = GTK_CALENDAR (widget);
++ private_data = GTK_CALENDAR_PRIVATE_DATA (widget);
++
++ if (private_data->freeze_count)
++ {
++ private_data->dirty_header = 1;
++ return;
++ }
++/*
++ if (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_LTR)
++ year_left = private_data->year_before;
++ else
++ year_left = !private_data->year_before;
++*/
++ private_data->dirty_header = 0;
++ gc = calendar->gc;
+
++ /* Clear window */
++ gdk_window_clear (private_data->footer_win);
++
++ header_width = widget->allocation.width - 2 * widget->style->xthickness;
++ cal_height = widget->allocation.height;
++
++ /*max_month_width = private_data->max_month_width;*/
++ /*max_year_width = private_data->max_year_width;*/
++
++ /*gdk_gc_set_foreground (gc, BACKGROUND_COLOR (GTK_WIDGET (calendar)));*/
++ /*gtk_paint_shadow (widget->style, private_data->footer_win,
++ GTK_STATE_NORMAL, GTK_SHADOW_OUT,
++ NULL, widget, "calendar",
++ 0, 0, header_width, private_data->header_h);*/
+
+- gdk_gc_set_foreground (gc, HEADER_FG_COLOR (GTK_WIDGET (calendar)));
+- gdk_draw_layout (private_data->header_win, gc, x, y, layout);
+
++ /*g_snprintf (buffer, sizeof (buffer), "%d", calendar->year);*/
++
++/* pango_layout_get_pixel_extents (layout, NULL, &logical_rect);*/
++
++ /* Draw title */
++
++
+ /* Draw month */
+ g_snprintf (buffer, sizeof (buffer), "%s", default_monthname[calendar->month]);
+- pango_layout_set_text (layout, buffer, -1);
++ layout = gtk_widget_create_pango_layout (widget, buffer);
+ pango_layout_get_pixel_extents (layout, NULL, &logical_rect);
+-
++#if 0
+ if (calendar->display_flags & GTK_CALENDAR_NO_MONTH_CHANGE)
+- if (year_left)
++/* if (year_left)*/
+ x = header_width - (3 + max_month_width
+ - (max_month_width - logical_rect.width)/2);
+- else
+- x = 3 + (max_month_width - logical_rect.width) / 2;
++ /* else
++ x = 3 + (max_month_width - logical_rect.width) / 2;*/
+ else
+- if (year_left)
+- x = header_width - (3 + private_data->arrow_width + max_month_width
++/* if (year_left)*/
++ x = header_width - (3 + HILDON_ARROW_WIDTH /*private_data->arrow_width*/ + max_month_width
+ - (max_month_width - logical_rect.width)/2);
+- else
++/* else
+ x = 3 + private_data->arrow_width + (max_month_width - logical_rect.width)/2;
++*/
++#endif
++ x = (widget->allocation.width - logical_rect.width) / 2;
++ y = (HILDON_ARROW_HEIGHT - logical_rect.height) / 2;
++
++ gdk_gc_set_foreground (gc, HEADER_FG_COLOR(GTK_WIDGET (calendar)));
++ gdk_draw_layout (private_data->footer_win, gc, x, y, layout);
+
+- gdk_draw_layout (private_data->header_win, gc, x, y, layout);
+-
+- gdk_gc_set_foreground (gc, BACKGROUND_COLOR (GTK_WIDGET (calendar)));
+-
+ gtk_calendar_paint_arrow (widget, ARROW_MONTH_LEFT);
+ gtk_calendar_paint_arrow (widget, ARROW_MONTH_RIGHT);
+- gtk_calendar_paint_arrow (widget, ARROW_YEAR_LEFT);
+- gtk_calendar_paint_arrow (widget, ARROW_YEAR_RIGHT);
+
+- g_object_unref (layout);
++ g_object_unref(layout);
+ }
+
+ static void
+@@ -1851,15 +2124,17 @@
+ GtkCalendarPrivateData *private_data;
+ gint focus_padding;
+ gint focus_width;
++ gboolean hildonlike;
+
+ g_return_if_fail (GTK_IS_CALENDAR (widget));
+ calendar = GTK_CALENDAR (widget);
+ private_data = GTK_CALENDAR_PRIVATE_DATA (widget);
+ gc = calendar->gc;
+-
++
+ gtk_widget_style_get (GTK_WIDGET (widget),
+ "focus-line-width", &focus_width,
+ "focus-padding", &focus_padding,
++ "hildonlike", &hildonlike,
+ NULL);
+ /*
+ * Handle freeze/thaw functionality
+@@ -1887,18 +2162,22 @@
+ * Draw rectangles as inverted background for the labels.
+ */
+
+- gdk_gc_set_foreground (gc, SELECTED_BG_COLOR (widget));
+- gdk_draw_rectangle (private_data->day_name_win, gc, TRUE,
+- CALENDAR_MARGIN, CALENDAR_MARGIN,
+- cal_width-CALENDAR_MARGIN * 2,
+- private_data->day_name_h - CALENDAR_MARGIN);
+-
+- if (calendar->display_flags & GTK_CALENDAR_SHOW_WEEK_NUMBERS)
+- gdk_draw_rectangle (private_data->day_name_win, gc, TRUE,
+- CALENDAR_MARGIN,
+- private_data->day_name_h - CALENDAR_YSEP,
+- private_data->week_width - CALENDAR_YSEP - CALENDAR_MARGIN,
+- CALENDAR_YSEP);
++ /* Hildon: don't paint dayname window */
++ if (!hildonlike)
++ {
++ gdk_gc_set_foreground (gc, SELECTED_BG_COLOR (widget));
++ gdk_draw_rectangle (private_data->day_name_win, gc, TRUE,
++ CALENDAR_MARGIN, CALENDAR_MARGIN,
++ cal_width-CALENDAR_MARGIN * 2,
++ private_data->day_name_h - CALENDAR_MARGIN);
++
++ if (calendar->display_flags & GTK_CALENDAR_SHOW_WEEK_NUMBERS)
++ gdk_draw_rectangle (private_data->day_name_win, gc, TRUE,
++ CALENDAR_MARGIN,
++ private_data->day_name_h - CALENDAR_YSEP,
++ private_data->week_width - CALENDAR_YSEP - CALENDAR_MARGIN,
++ CALENDAR_YSEP);
++ }
+
+ /*
+ * Write the labels
+@@ -1908,28 +2187,43 @@
+
+ gdk_gc_set_foreground (gc, SELECTED_FG_COLOR (widget));
+ for (i = 0; i < 7; i++)
+- {
++ {
+ if (gtk_widget_get_direction (GTK_WIDGET (calendar)) == GTK_TEXT_DIR_RTL)
+- day = 6 - i;
++ day = 6 - i;
+ else
+- day = i;
+- day = (day + private_data->week_start) % 7;
+- g_snprintf (buffer, sizeof (buffer), "%s", default_abbreviated_dayname[day]);
++ day = i;
++ day = (day + private_data->week_start) % 7;
++ g_snprintf (buffer, sizeof (buffer), "%s", default_abbreviated_dayname[day]);
++
++ pango_layout_set_text (layout, buffer, -1);
++ pango_layout_get_pixel_extents (layout, NULL, &logical_rect);
+
+- pango_layout_set_text (layout, buffer, -1);
+- pango_layout_get_pixel_extents (layout, NULL, &logical_rect);
++ /* Hildon: draw passive focus for day name */
++ if (hildonlike && calendar->focus_col == i)
++ {
++ guint x = left_x_for_column (calendar, calendar->focus_col);
+
+- gdk_draw_layout (private_data->day_name_win, gc,
+- (CALENDAR_MARGIN +
+- + (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_LTR ?
+- (private_data->week_width + (private_data->week_width ? CALENDAR_XSEP : 0))
+- : 0)
+- + day_wid_sep * i
+- + (day_width - logical_rect.width)/2),
+- CALENDAR_MARGIN + focus_width + focus_padding + logical_rect.y,
+- layout);
++ gtk_paint_box( GTK_WIDGET (calendar)->style,
++ private_data->day_name_win,
++ GTK_STATE_NORMAL,
++ GTK_SHADOW_OUT, NULL,
++ GTK_WIDGET (calendar), "passive-focus",
++ (x + 4) + HILDON_DAY_WIDTH, 0,
++ day_wid_sep + 2,
++ HILDON_DAY_HEIGHT);
++ }
++ gdk_draw_layout (private_data->day_name_win, gc,
++ (CALENDAR_MARGIN +
++ + (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_LTR ?
++ (private_data->week_width + (private_data->week_width ? CALENDAR_XSEP : 0))
++ : 0)
++ + day_wid_sep * i
++ + (day_width - logical_rect.width)/2),
++ CALENDAR_MARGIN + focus_width + focus_padding + logical_rect.y,
++ layout);
++
++
+ }
+-
+ g_object_unref (layout);
+ }
+
+@@ -1940,14 +2234,15 @@
+ GdkGC *gc;
+ gint row, week = 0, year;
+ gint x_loc;
+- char buffer[3];
+- gint y_loc, day_height;
++ char buffer[10];
++ gint y_loc /*, day_height*/;
+ GtkCalendarPrivateData *private_data;
+ PangoLayout *layout;
+ PangoRectangle logical_rect;
+ gint focus_padding;
+ gint focus_width;
+-
++ gboolean hildonlike;
++
+ g_return_if_fail (GTK_IS_CALENDAR (widget));
+ g_return_if_fail (widget->window != NULL);
+ calendar = GTK_CALENDAR (widget);
+@@ -1968,6 +2263,7 @@
+ gtk_widget_style_get (GTK_WIDGET (widget),
+ "focus-line-width", &focus_width,
+ "focus-padding", &focus_padding,
++ "hildonlike", &hildonlike,
+ NULL);
+
+ /*
+@@ -1981,18 +2277,23 @@
+ */
+
+ gdk_gc_set_foreground (gc, SELECTED_BG_COLOR (widget));
+- if (private_data->day_name_win)
+- gdk_draw_rectangle (private_data->week_win, gc, TRUE,
+- CALENDAR_MARGIN,
+- 0,
+- private_data->week_width - CALENDAR_MARGIN,
+- private_data->main_h - CALENDAR_MARGIN);
+- else
+- gdk_draw_rectangle (private_data->week_win, gc, TRUE,
+- CALENDAR_MARGIN,
+- CALENDAR_MARGIN,
+- private_data->week_width - CALENDAR_MARGIN,
+- private_data->main_h - 2 * CALENDAR_MARGIN);
++
++ /* Hildon: don't paint background for weekday window */
++ if (!hildonlike)
++ {
++ if (private_data->day_name_win)
++ gdk_draw_rectangle (private_data->week_win, gc, TRUE,
++ CALENDAR_MARGIN,
++ 0,
++ private_data->week_width - CALENDAR_MARGIN,
++ private_data->main_h + private_data->day_name_h- CALENDAR_MARGIN);
++ else
++ gdk_draw_rectangle (private_data->week_win, gc, TRUE,
++ CALENDAR_MARGIN,
++ CALENDAR_MARGIN,
++ private_data->week_width - CALENDAR_MARGIN,
++ private_data->main_h - 2 * CALENDAR_MARGIN);
++ }
+
+ /*
+ * Write the labels
+@@ -2001,10 +2302,13 @@
+ layout = gtk_widget_create_pango_layout (widget, NULL);
+
+ gdk_gc_set_foreground (gc, SELECTED_FG_COLOR (widget));
+- day_height = row_height (calendar);
++ gdk_draw_line(private_data->week_win, gc,
++ HILDON_DAY_WIDTH - 1, 0, HILDON_DAY_WIDTH - 1, private_data->main_h + private_data->day_name_h);
++
++ /*day_height = row_height (calendar)*/;
+ for (row = 0; row < 6; row++)
+ {
+- year = calendar->year;
++ year = calendar->year;
+ if (calendar->day[row][6] < 15 && row > 3 && calendar->month == 11)
+ year++;
+
+@@ -2012,15 +2316,30 @@
+ ((calendar->day[row][6] < 15 && row > 3 ? 1 : 0)
+ + calendar->month) % 12 + 1, calendar->day[row][6]));
+
+- g_snprintf (buffer, sizeof (buffer), "%d", week);
+- pango_layout_set_text (layout, buffer, -1);
+- pango_layout_get_pixel_extents (layout, NULL, &logical_rect);
+-
+- y_loc = top_y_for_row (calendar, row) + (day_height - logical_rect.height) / 2;
+-
+- x_loc = (private_data->week_width
++ g_snprintf (buffer, sizeof (buffer), "%d", week);
++ pango_layout_set_text (layout, buffer, -1);
++ pango_layout_get_pixel_extents (layout, NULL, &logical_rect);
++
++ /* Hildon: draw passive focus for week */
++ if (hildonlike && calendar->focus_row == row)
++ {
++ guint y = top_y_for_row (calendar, calendar->focus_row + 1);
++
++ gtk_paint_box( GTK_WIDGET (calendar)->style,
++ private_data->week_win,
++ GTK_STATE_NORMAL,
++ GTK_SHADOW_OUT, NULL,
++ GTK_WIDGET (calendar), "passive-focus",
++ 0, y,
++ private_data->week_width - 4,
++ HILDON_DAY_HEIGHT);
++ }
++
++ y_loc = private_data->day_name_h + top_y_for_row (calendar, row) + (HILDON_DAY_HEIGHT - logical_rect.height) / 2;
++ x_loc = (HILDON_DAY_WIDTH - logical_rect.width) / 2;
++ /*(private_data->week_width
+ - logical_rect.width
+- - CALENDAR_XSEP - focus_padding - focus_width);
++ - CALENDAR_XSEP - focus_padding - focus_width);*/
+
+ gdk_draw_layout (private_data->week_win, gc, x_loc, y_loc, layout);
+ }
+@@ -2034,11 +2353,13 @@
+ {
+ GtkCalendar *calendar;
+ gint r, c, row, col;
+-
++ GtkCalendarPrivateData *private_data;
+ g_return_if_fail (GTK_IS_CALENDAR (widget));
+
+ calendar = GTK_CALENDAR (widget);
+-
++
++ private_data = GTK_CALENDAR_PRIVATE_DATA (widget);
++
+ row = -1;
+ col = -1;
+ for (r = 0; r < 6; r++)
+@@ -2054,6 +2375,7 @@
+ g_return_if_fail (col != -1);
+
+ gtk_calendar_paint_day (widget, row, col);
++
+ }
+
+ static void
+@@ -2065,13 +2387,14 @@
+ GdkGC *gc;
+ gchar buffer[255];
+ gint day;
+- gint day_height;
++ /*gint day_height;*/
+ gint x_left;
+ gint x_loc;
+ gint y_top;
+ gint y_loc;
+- gint day_xspace;
++ /*gint day_xspace;*/
+ gint focus_width;
++ gboolean hildonlike;
+
+ GtkCalendarPrivateData *private_data;
+ PangoLayout *layout;
+@@ -2083,6 +2406,8 @@
+ calendar = GTK_CALENDAR (widget);
+ private_data = GTK_CALENDAR_PRIVATE_DATA (widget);
+
++ if (private_data->main_win == NULL) return;
++
+ /*
+ * Handle freeze/thaw functionality
+ */
+@@ -2092,25 +2417,25 @@
+ private_data->dirty_main = 1;
+ return;
+ }
+-
+- gtk_widget_style_get (widget, "focus-line-width", &focus_width, NULL);
+
+- day_height = row_height (calendar);
+-
+- day_xspace = private_data->day_width - private_data->max_day_char_width*2;
++ gtk_widget_style_get (widget, "focus-line-width", &focus_width,
++ "hildonlike", &hildonlike, NULL);
++
++ /*day_height = row_height (calendar)*/;
++ /*day_xspace = HILDON_DAY_WIDTH private_data->day_width - private_data->max_day_char_width*2*/;
+
+ day = calendar->day[row][col];
+-
++
+ x_left = left_x_for_column (calendar, col);
+- x_loc = x_left + private_data->day_width / 2 + private_data->max_day_char_width;
++ /*x_loc = x_left + private_data->day_width / 2 + private_data->max_day_char_width;*/
+
+ y_top = top_y_for_row (calendar, row);
+
+ gdk_window_clear_area (private_data->main_win, x_left, y_top,
+- private_data->day_width, day_height);
++ HILDON_DAY_WIDTH, HILDON_DAY_HEIGHT);
+
+ gc = calendar->gc;
+-
++
+ if (calendar->day_month[row][col] == MONTH_PREV)
+ {
+ gdk_gc_set_foreground (gc, PREV_MONTH_COLOR (GTK_WIDGET (calendar)));
+@@ -2123,44 +2448,43 @@
+ {
+ /*
+ if (calendar->highlight_row == row && calendar->highlight_col == col)
+- {
+- gdk_gc_set_foreground (gc, HIGHLIGHT_BACK_COLOR (GTK_WIDGET (calendar)));
+- gdk_draw_rectangle (private_data->main_win, gc, TRUE, x_left, y_top,
++ {
++ gdk_gc_set_foreground (gc, HIGHLIGHT_BACK_COLOR (GTK_WIDGET (calendar)));
++ gdk_draw_rectangle (private_data->main_win, gc, TRUE, x_left, y_top,
+ private_data->day_width, day_height);
+- }
++ }
+ */
+ if (calendar->selected_day == day)
+- {
+- gdk_gc_set_foreground (gc, SELECTED_BG_COLOR (GTK_WIDGET (calendar)));
+- gdk_draw_rectangle (private_data->main_win, gc, TRUE, x_left, y_top,
+- private_data->day_width, day_height);
+- }
+-
++ {
++ /* Hildon: use custom graphics */
++ if (hildonlike)
++ {
++ gtk_paint_box( GTK_WIDGET (calendar)->style,
++ private_data->main_win,
++ GTK_STATE_NORMAL,
++ GTK_SHADOW_NONE, NULL,
++ GTK_WIDGET (calendar), "active-day",
++ x_left, y_top,
++ HILDON_DAY_WIDTH,
++ HILDON_DAY_HEIGHT);
++ }
++ else
++ {
++ gdk_gc_set_foreground (gc, SELECTED_BG_COLOR (GTK_WIDGET (calendar)));
++ gdk_draw_rectangle (private_data->main_win, gc, TRUE, x_left, y_top,
++ HILDON_DAY_WIDTH, HILDON_DAY_HEIGHT);
++ }
++ }
+ if (calendar->marked_date[day-1])
+- gdk_gc_set_foreground (gc, MARKED_COLOR (GTK_WIDGET (calendar)));
++ gdk_gc_set_foreground (gc, MARKED_COLOR (GTK_WIDGET (calendar)));
+ else
+- gdk_gc_set_foreground (gc, NORMAL_DAY_COLOR (GTK_WIDGET (calendar)));
+-
++ gdk_gc_set_foreground (gc, NORMAL_DAY_COLOR (GTK_WIDGET (calendar)));
+ if (calendar->selected_day == day)
+- gdk_gc_set_foreground (gc, SELECTED_FG_COLOR (GTK_WIDGET (calendar)));
++ gdk_gc_set_foreground (gc, SELECTED_FG_COLOR (GTK_WIDGET (calendar)));
+ else
+- gdk_gc_set_foreground (gc, & (GTK_WIDGET (calendar)->style->fg[GTK_WIDGET_STATE (calendar)]));
+- }
+-
+-
+- g_snprintf (buffer, sizeof (buffer), "%d", day);
+- layout = gtk_widget_create_pango_layout (widget, buffer);
+- pango_layout_get_pixel_extents (layout, NULL, &logical_rect);
++ gdk_gc_set_foreground (gc, & (GTK_WIDGET (calendar)->style->fg[GTK_WIDGET_STATE (calendar)]));
+
+- x_loc -= logical_rect.width;
+-
+- y_loc = y_top + (day_height - logical_rect.height) / 2;
+- gdk_draw_layout (private_data->main_win, gc,
+- x_loc, y_loc, layout);
+- if (calendar->marked_date[day-1]
+- && calendar->day_month[row][col] == MONTH_CURRENT)
+- gdk_draw_layout (private_data->main_win, gc,
+- x_loc-1, y_loc, layout);
++ }
+
+ if (GTK_WIDGET_HAS_FOCUS (calendar)
+ && calendar->focus_row == row && calendar->focus_col == col)
+@@ -2168,9 +2492,9 @@
+ GtkStateType state;
+
+ if (calendar->selected_day == day)
+- state = GTK_WIDGET_HAS_FOCUS (widget) ? GTK_STATE_SELECTED : GTK_STATE_ACTIVE;
++ state = GTK_WIDGET_HAS_FOCUS (widget) ? GTK_STATE_SELECTED : GTK_STATE_ACTIVE;
+ else
+- state = GTK_STATE_NORMAL;
++ state = GTK_STATE_NORMAL;
+
+ gtk_paint_focus (widget->style,
+ private_data->main_win,
+@@ -2178,10 +2502,29 @@
+ ? GTK_STATE_SELECTED : GTK_STATE_NORMAL,
+ NULL, widget, "calendar-day",
+ x_left, y_top,
+- private_data->day_width,
+- day_height);
++ HILDON_DAY_WIDTH,
++ HILDON_DAY_HEIGHT);
+ }
+
++ /* Hildon: paint green indicator for current day */
++ if (hildonlike && (day == private_data->current_day && calendar->selected_day !=
++ private_data->current_day) && (calendar->day_month[row][col] == MONTH_CURRENT))
++ gtk_calendar_check_current_date (calendar, x_left, y_top);
++
++ g_snprintf (buffer, sizeof (buffer), "%d", day);
++ layout = gtk_widget_create_pango_layout (widget, buffer);
++ pango_layout_get_pixel_extents (layout, NULL, &logical_rect);
++
++ x_loc = x_left + (HILDON_DAY_WIDTH - logical_rect.width) / 2;
++ y_loc = y_top + (HILDON_DAY_HEIGHT - logical_rect.height) / 2;
++
++ gdk_draw_layout (private_data->main_win, gc,
++ x_loc, y_loc, layout);
++ if (calendar->marked_date[day-1]
++ && calendar->day_month[row][col] == MONTH_CURRENT)
++ gdk_draw_layout (private_data->main_win, gc,
++ x_loc-1, y_loc, layout);
++
+ g_object_unref (layout);
+ }
+
+@@ -2195,7 +2538,7 @@
+
+ g_return_if_fail (GTK_IS_CALENDAR (widget));
+ g_return_if_fail (widget->window != NULL);
+-
++
+ calendar = GTK_CALENDAR (widget);
+ private_data = GTK_CALENDAR_PRIVATE_DATA (widget);
+
+@@ -2208,7 +2551,7 @@
+ gdk_window_clear (private_data->main_win);
+
+ /* gtk_calendar_compute_days (calendar); */ /* REMOVE later */
+-
++
+ for (col = 0; col < 7; col++)
+ for (row = 0; row < 6; row++)
+ gtk_calendar_paint_day (widget, row, col);
+@@ -2453,9 +2796,24 @@
+ guint month,
+ guint year)
+ {
++ gboolean hildonlike;
++ guint min_year, max_year;
++
+ g_return_val_if_fail (GTK_IS_CALENDAR (calendar), FALSE);
+ g_return_val_if_fail (month <= 11, FALSE);
+
++ gtk_widget_style_get(GTK_WIDGET (calendar), "hildonlike", &hildonlike,
++ "max-year", &max_year, "min-year",
++ &min_year, NULL);
++
++ if (hildonlike)
++ {
++ if (year >= max_year)
++ year = max_year;
++ else if (year <= min_year)
++ year = min_year;
++ }
++
+ calendar->month = month;
+ calendar->year = year;
+
+@@ -2478,12 +2836,30 @@
+ gtk_calendar_select_day (GtkCalendar *calendar,
+ guint day)
+ {
+- g_return_if_fail (GTK_IS_CALENDAR (calendar));
+- g_return_if_fail (day <= 31);
+-
+- /* gtk_calendar_compute_days (calendar); */
+-
+- /* Deselect the old day */
++ gint row, col;
++ GtkCalendarPrivateData *priv;
++ g_return_if_fail (GTK_IS_CALENDAR (calendar));
++ g_return_if_fail (day <= 31);
++ priv = GTK_CALENDAR_PRIVATE_DATA (calendar);
++
++ for (row = 0; row < 6; row ++)
++ for (col = 0; col < 7; col++)
++ {
++ if (calendar->day_month[row][col] == MONTH_CURRENT
++ && calendar->day[row][col] == day)
++ {
++ calendar->focus_row = row;
++ calendar->focus_col = col;
++ }
++ }
++
++ /* gtk_calendar_compute_days (calendar); */
++
++ if (calendar->month != priv->current_month ||
++ calendar->year != priv->current_year)
++ gtk_calendar_unmark_day (calendar, priv->current_day);
++
++ /* Deselect the old day */
+ if (calendar->selected_day > 0)
+ {
+ gint selected_day;
+@@ -2491,20 +2867,25 @@
+ selected_day = calendar->selected_day;
+ calendar->selected_day = 0;
+ if (GTK_WIDGET_DRAWABLE (GTK_WIDGET (calendar)))
+- gtk_calendar_paint_day_num (GTK_WIDGET (calendar), selected_day);
++ {
++ gtk_calendar_paint_day_num (GTK_WIDGET (calendar), selected_day);
++ }
+ }
+
+ calendar->selected_day = day;
+
++ /*printf("Selected day = %d\n", day);*/
++
+ /* Select the new day */
+ if (day != 0)
+ {
+ if (GTK_WIDGET_DRAWABLE (GTK_WIDGET (calendar)))
+- gtk_calendar_paint_day_num (GTK_WIDGET (calendar), day);
++ {
++ gtk_calendar_paint_day_num (GTK_WIDGET (calendar), day);
++ }
+ }
+-
++
+ g_object_notify (G_OBJECT (calendar), "day");
+-
+ g_signal_emit (calendar,
+ gtk_calendar_signals[DAY_SELECTED_SIGNAL],
+ 0);
+@@ -2560,17 +2941,16 @@
+ gtk_calendar_mark_day (GtkCalendar *calendar,
+ guint day)
+ {
+- g_return_val_if_fail (GTK_IS_CALENDAR (calendar), FALSE);
+-
+- if (day >= 1 && day <= 31 && calendar->marked_date[day-1] == FALSE)
+- {
+- calendar->marked_date[day - 1] = TRUE;
+- calendar->num_marked_dates++;
+- }
+- if (GTK_WIDGET_DRAWABLE (GTK_WIDGET (calendar)))
+- {
+- gtk_calendar_paint_main (GTK_WIDGET (calendar));
+- }
++ g_return_val_if_fail (GTK_IS_CALENDAR (calendar), FALSE);
++ if (day >= 1 && day <= 31 && calendar->marked_date[day-1] == FALSE)
++ {
++ calendar->marked_date[day - 1] = TRUE;
++ calendar->num_marked_dates++;
++ }
++ if (GTK_WIDGET_DRAWABLE (GTK_WIDGET (calendar)))
++ {
++ gtk_calendar_paint_main (GTK_WIDGET (calendar));
++ }
+
+ return TRUE;
+ }
+@@ -2629,14 +3009,15 @@
+ gtk_calendar_set_year_next (calendar);
+ break;
+ case ARROW_MONTH_LEFT:
+- gtk_calendar_set_month_prev (calendar);
+- break;
++ gtk_calendar_set_month_prev (calendar);
++ break;
+ case ARROW_MONTH_RIGHT:
+ gtk_calendar_set_month_next (calendar);
+ break;
+ default:;
+ /* do nothing */
+ }
++ gtk_calendar_select_and_focus_day(calendar, calendar->selected_day);
+ }
+
+ static gboolean
+@@ -2645,6 +3026,11 @@
+ GtkCalendar *calendar = data;
+ GtkCalendarPrivateData *private_data = GTK_CALENDAR_PRIVATE_DATA (calendar);
+ gboolean retval = FALSE;
++ GtkSettings *settings;
++ guint timeout;
++
++ settings = gtk_settings_get_default ();
++ g_object_get (settings, "gtk-update-timeout", &timeout, NULL);
+
+ GDK_THREADS_ENTER ();
+
+@@ -2655,7 +3041,7 @@
+ if (private_data->need_timer)
+ {
+ private_data->need_timer = FALSE;
+- private_data->timer = g_timeout_add (CALENDAR_TIMER_DELAY,
++ private_data->timer = g_timeout_add (/*CALENDAR_TIMER_DELAY*/timeout,
+ (GSourceFunc) calendar_timer,
+ (gpointer) calendar);
+ }
+@@ -2673,13 +3059,18 @@
+ gint click_child)
+ {
+ GtkCalendarPrivateData *private_data = GTK_CALENDAR_PRIVATE_DATA (widget);
++ GtkSettings *settings;
++ guint timeout;
+
++ settings = gtk_settings_get_default ();
++ g_object_get (settings, "gtk-initial-timeout", &timeout, NULL);
++
+ private_data->click_child = click_child;
+
+ if (!private_data->timer)
+ {
+ private_data->need_timer = TRUE;
+- private_data->timer = g_timeout_add (CALENDAR_INITIAL_TIMER_DELAY,
++ private_data->timer = g_timeout_add (/*CALENDAR_INITIAL_TIMER_DELAY*/timeout,
+ calendar_timer,
+ (gpointer) widget);
+ }
+@@ -2738,12 +3129,38 @@
+ GtkCalendar *calendar;
+ GtkCalendarPrivateData *private_data;
+ gint arrow = -1;
+-
++ gboolean hildonlike;
++ gint min_year, max_year;
++
+ calendar = GTK_CALENDAR (widget);
+ private_data = GTK_CALENDAR_PRIVATE_DATA (widget);
++
++ gtk_widget_style_get(widget, "hildonlike", &hildonlike,
++ "min-year", &min_year, "max-year", &max_year, NULL);
+
+- if (event->window == private_data->main_win)
+- gtk_calendar_main_button (widget, event);
++ if (!hildonlike)
++ {
++ if (event->window == private_data->main_win)
++ gtk_calendar_main_button (widget, event);
++ }
++ else if (hildonlike && (event->window == private_data->main_win))
++ {
++ gint x = (gint) (event->x);
++ gint y = (gint) (event->y);
++ gint row = row_from_y (calendar, y);
++ gint col = column_from_x (calendar, x);
++ private_data->pressed_day = calendar->day[row][col];
++
++ if ((calendar->year == min_year && calendar->month == 0 && calendar->day_month[row][col] == MONTH_PREV) ||
++ (calendar->year == max_year && calendar->month == 11 && calendar->day_month[row][col] == MONTH_NEXT))
++ {}
++ else if (calendar->day_month[row][col] == MONTH_CURRENT)
++ gtk_calendar_select_and_focus_day (calendar, private_data->pressed_day);
++
++ /* Remember month where button was pressed */
++ private_data->pressed_month = calendar->month;
++ private_data->slide_stylus = TRUE;
++ }
+
+ if (!GTK_WIDGET_HAS_FOCUS (widget))
+ gtk_widget_grab_focus (widget);
+@@ -2766,7 +3183,7 @@
+ }
+ }
+
+- return FALSE;
++ return TRUE;
+ }
+
+ static gboolean
+@@ -2775,16 +3192,45 @@
+ {
+ GtkCalendar *calendar;
+ GtkCalendarPrivateData *private_data;
++ gboolean hildonlike;
+
+ calendar = GTK_CALENDAR (widget);
+ private_data = GTK_CALENDAR_PRIVATE_DATA (widget);
+
++ gtk_widget_style_get(widget, "hildonlike", &hildonlike,
++ NULL);
++
++ if (hildonlike && (event->window == private_data->main_win))
++ {
++ gtk_calendar_main_button (widget, event);
++ gint x = (gint) (event->x);
++ gint y = (gint) (event->y);
++ gint row = row_from_y (calendar, y);
++ gint col = column_from_x (calendar, x);
++ private_data->prev_col = -1;
++ private_data->prev_row = -1;
++
++ if ((private_data->pressed_day == calendar->day[row][col]) &&
++ (private_data->pressed_month == calendar->month))
++ {
++ if (!private_data->is_bad_day)
++ {
++ g_signal_emit (calendar, gtk_calendar_signals[SELECTED_DATE_SIGNAL], 0);
++ }
++ else
++ {
++ private_data->is_bad_day = FALSE;
++ }
++ }
++ private_data->slide_stylus = FALSE;
++ }
++
+ if (event->button == 1)
+ {
+ stop_spinning (widget);
+
+ if (private_data->in_drag)
+- private_data->in_drag = 0;
++ private_data->in_drag = 0;
+ }
+
+ return TRUE;
+@@ -2799,15 +3245,42 @@
+ gint event_x, event_y;
+ gint row, col;
+ gint old_row, old_col;
++ gboolean hildonlike;
+
+ calendar = GTK_CALENDAR (widget);
+ private_data = GTK_CALENDAR_PRIVATE_DATA (widget);
+ event_x = (gint) (event->x);
+ event_y = (gint) (event->y);
+-
++
++ gtk_widget_style_get(widget, "hildonlike", &hildonlike,
++ NULL);
++
+ if (event->window == private_data->main_win)
+ {
+-
++ if (hildonlike)
++ {
++ /* Hildon: make active day to move, when stylus is slided */
++ if (private_data->slide_stylus)
++ {
++ gint c_row = row_from_y (calendar, event_y);
++ gint c_col = column_from_x (calendar, event_x);
++
++ if (calendar->day_month[c_row][c_col] == MONTH_PREV ||
++ calendar->day_month[c_row][c_col] == MONTH_NEXT)
++ { }
++ else if ((private_data->prev_row != c_row || private_data->prev_col != c_col) &&
++ (calendar->highlight_row != -1 && calendar->highlight_col != -1))
++ {
++ gtk_calendar_select_and_focus_day (calendar,
++ calendar->day[c_row][c_col]);
++ /* Update passive focus indicators work weekday number and name */
++ gtk_calendar_paint_week_numbers (GTK_WIDGET (calendar));
++ gtk_calendar_paint_day_names (GTK_WIDGET (calendar));
++ }
++ private_data->prev_col = c_col;
++ private_data->prev_row = c_row;
++ }
++ }
+ if (private_data->in_drag)
+ {
+ if (gtk_drag_check_threshold (widget,
+@@ -2847,7 +3320,7 @@
+ calendar->highlight_col = col;
+
+ if (row > -1 && col > -1)
+- gtk_calendar_paint_day (widget, row, col);
++ gtk_calendar_paint_day (widget, row, col);
+ }
+ }
+ }
+@@ -2863,7 +3336,7 @@
+
+ calendar = GTK_CALENDAR (widget);
+ private_data = GTK_CALENDAR_PRIVATE_DATA (widget);
+-
++
+ if (event->window == private_data->arrow_win[ARROW_MONTH_LEFT])
+ {
+ private_data->arrow_state[ARROW_MONTH_LEFT] = GTK_STATE_PRELIGHT;
+@@ -2902,7 +3375,7 @@
+
+ calendar = GTK_CALENDAR (widget);
+ private_data = GTK_CALENDAR_PRIVATE_DATA (widget);
+-
++
+ if (event->window == private_data->main_win)
+ {
+ row = calendar->highlight_row;
+@@ -2910,7 +3383,7 @@
+ calendar->highlight_row = -1;
+ calendar->highlight_col = -1;
+ if (row > -1 && col > -1)
+- gtk_calendar_paint_day (widget, row, col);
++ gtk_calendar_paint_day (widget, row, col);
+ }
+
+ if (event->window == private_data->arrow_win[ARROW_MONTH_LEFT])
+@@ -2949,10 +3422,14 @@
+ GdkGC *gc;
+ GtkCalendar *calendar;
+ gint state;
+- gint width, height;
++ gint max_year, min_year;
++ gboolean hildonlike;
++/* gint width, height;*/
+
+ calendar = GTK_CALENDAR (widget);
+ private_data = GTK_CALENDAR_PRIVATE_DATA (widget);
++ gtk_widget_style_get (widget, "hildonlike", &hildonlike, "max-year",
++ &max_year, "min-year", &min_year, NULL);
+
+ if (private_data->freeze_count)
+ {
+@@ -2965,23 +3442,81 @@
+ state = private_data->arrow_state[arrow];
+ gc = calendar->gc;
+
+- gdk_window_clear (window);
++/* gdk_window_clear (window);*/
+ gdk_window_set_background (window, &(widget)->style->bg[state]);
+- gdk_drawable_get_size (window, &width, &height);
+- gdk_window_clear_area (window,
++/* gdk_drawable_get_size (window, &width, &height);*/
++/* gdk_window_clear_area (window,
+ 0,0,
+- width,height);
+- if (arrow == ARROW_MONTH_LEFT || arrow == ARROW_YEAR_LEFT)
+- gtk_paint_arrow (widget->style, window, state,
++ width,height);*/
++
++ gdk_window_clear(window);
++
++ /* Hildon: added support for dimmed arrows */
++ if (hildonlike && (calendar->year <= min_year || calendar->year >= max_year))
++ {
++ if (calendar->year <= min_year)
++ {
++ if (arrow == ARROW_YEAR_LEFT)
++ gtk_paint_arrow (widget->style, window, GTK_STATE_INSENSITIVE,
++ GTK_SHADOW_OUT, NULL, widget, "calendar",
++ GTK_ARROW_LEFT, TRUE,
++ 0, 0, HILDON_ARROW_WIDTH, HILDON_ARROW_HEIGHT);
++ else if (arrow == ARROW_YEAR_RIGHT || arrow == ARROW_MONTH_RIGHT)
++ gtk_paint_arrow (widget->style, window, state,
++ GTK_SHADOW_OUT, NULL, widget, "calendar",
++ GTK_ARROW_RIGHT, TRUE,
++ 0, 0, HILDON_ARROW_WIDTH, HILDON_ARROW_HEIGHT);
++ else if (arrow == ARROW_MONTH_LEFT && calendar->month != 0)
++ gtk_paint_arrow (widget->style, window, state,
++ GTK_SHADOW_OUT, NULL, widget, "calendar",
++ GTK_ARROW_LEFT, TRUE,
++ 0, 0, HILDON_ARROW_WIDTH, HILDON_ARROW_HEIGHT);
++ else if (arrow == ARROW_MONTH_LEFT && !calendar->month)
++ gtk_paint_arrow (widget->style, window, GTK_STATE_INSENSITIVE,
++ GTK_SHADOW_OUT, NULL, widget, "calendar",
++ GTK_ARROW_LEFT, TRUE,
++ 0, 0, HILDON_ARROW_WIDTH, HILDON_ARROW_HEIGHT);
++ }
++ else if (calendar->year >= max_year)
++ {
++ if (arrow == ARROW_YEAR_RIGHT)
++ gtk_paint_arrow (widget->style, window, GTK_STATE_INSENSITIVE,
++ GTK_SHADOW_OUT, NULL, widget, "calendar",
++ GTK_ARROW_RIGHT, TRUE,
++ 0, 0, HILDON_ARROW_WIDTH, HILDON_ARROW_HEIGHT);
++ else if (arrow == ARROW_YEAR_LEFT || arrow == ARROW_MONTH_LEFT)
++ gtk_paint_arrow (widget->style, window, state,
+ GTK_SHADOW_OUT, NULL, widget, "calendar",
+ GTK_ARROW_LEFT, TRUE,
+- width/2 - 3, height/2 - 4, 8, 8);
+- else
+- gtk_paint_arrow (widget->style, window, state,
++ 0, 0, HILDON_ARROW_WIDTH, HILDON_ARROW_HEIGHT);
++ else if (arrow == ARROW_MONTH_RIGHT && calendar->month != 11)
++ gtk_paint_arrow (widget->style, window, state,
++ GTK_SHADOW_OUT, NULL, widget, "calendar",
++ GTK_ARROW_RIGHT, TRUE,
++ 0, 0, HILDON_ARROW_WIDTH, HILDON_ARROW_HEIGHT);
++ else if (arrow == ARROW_MONTH_RIGHT && calendar->month == 11)
++ gtk_paint_arrow (widget->style, window, GTK_STATE_INSENSITIVE,
++ GTK_SHADOW_OUT, NULL, widget, "calendar",
++ GTK_ARROW_RIGHT, TRUE,
++ 0, 0, HILDON_ARROW_WIDTH, HILDON_ARROW_HEIGHT);
++ }
++ }
++ else
++ {
++ if (arrow == ARROW_MONTH_LEFT || arrow == ARROW_YEAR_LEFT)
++ gtk_paint_arrow (widget->style, window, state,
++ GTK_SHADOW_OUT, NULL, widget, "calendar",
++ GTK_ARROW_LEFT, TRUE,
++ /* width/2 - 3, height/2 - 4, 8, 8);*/
++ 0, 0, HILDON_ARROW_WIDTH, HILDON_ARROW_HEIGHT);
++ else
++ gtk_paint_arrow (widget->style, window, state,
+ GTK_SHADOW_OUT, NULL, widget, "calendar",
+ GTK_ARROW_RIGHT, TRUE,
+- width/2 - 2, height/2 - 4, 8, 8);
+- }
++ /* width/2 - 2, height/2 - 4, 8, 8);*/
++ 0, 0, HILDON_ARROW_WIDTH, HILDON_ARROW_HEIGHT);
++ }
++ }
+ }
+
+ void
+@@ -3159,17 +3694,26 @@
+ GdkEventKey *event)
+ {
+ GtkCalendar *calendar;
++ GtkSettings *settings;
+ gint return_val;
+ gint old_focus_row;
+ gint old_focus_col;
+ gint row, col, day;
+-
++ gint min_year, max_year;
++ gboolean knav;
++
+ calendar = GTK_CALENDAR (widget);
+ return_val = FALSE;
+
+ old_focus_row = calendar->focus_row;
+ old_focus_col = calendar->focus_col;
+
++ gtk_widget_style_get (widget, "max-year", &max_year,
++ "min-year", &min_year, NULL);
++
++ settings = gtk_settings_get_default ();
++ g_object_get (settings, "hildon-keyboard-navigation", &knav, NULL);
++
+ switch (event->keyval)
+ {
+ case GDK_KP_Left:
+@@ -3179,10 +3723,41 @@
+ gtk_calendar_set_month_prev (calendar);
+ else
+ {
+- move_focus (calendar, -1);
+- gtk_calendar_paint_day (widget, old_focus_row, old_focus_col);
+- gtk_calendar_paint_day (widget, calendar->focus_row,
+- calendar->focus_col);
++ /* if we are at the first allowed day of the minimum year/month then do nothing */
++ if (calendar->year == min_year && calendar->month == 0 && calendar->day_month[old_focus_row][old_focus_col-1] == MONTH_PREV)
++ {
++ g_signal_emit (calendar, gtk_calendar_signals[ERRONEOUS_DATE_SIGNAL], 0);
++ return TRUE;
++ }
++ else /* else normal */
++ {
++ move_focus (calendar, -1);
++ if (!knav)
++ {
++ gtk_calendar_paint_day (widget, old_focus_row, old_focus_col);
++ gtk_calendar_paint_day (widget, calendar->focus_row,
++ calendar->focus_col);
++ }
++ else if (knav)
++ {
++ gint day_month = calendar->day_month[calendar->focus_row][calendar->focus_col];
++ if (day_month == MONTH_CURRENT && calendar->selected_day != 1)
++ {
++ gtk_calendar_select_day(calendar, calendar->selected_day - 1);
++ }
++ else
++ {
++ if (calendar->month != 0) {
++ calendar->selected_day = month_length[leap (calendar->year)][calendar->month];
++ } else {
++ calendar->selected_day = month_length[leap (calendar->year -1)][12];
++ }
++ gtk_calendar_set_month_prev (calendar);
++ }
++ gtk_calendar_paint_week_numbers (GTK_WIDGET (calendar));
++ gtk_calendar_paint_day_names (GTK_WIDGET (calendar));
++ }
++ }
+ }
+ break;
+ case GDK_KP_Right:
+@@ -3192,10 +3767,36 @@
+ gtk_calendar_set_month_next (calendar);
+ else
+ {
+- move_focus (calendar, 1);
+- gtk_calendar_paint_day (widget, old_focus_row, old_focus_col);
+- gtk_calendar_paint_day (widget, calendar->focus_row,
+- calendar->focus_col);
++ if (calendar->year == max_year && calendar->month == 11 && calendar->day_month[old_focus_row][old_focus_col+1] == MONTH_NEXT)
++ {
++ g_signal_emit (calendar, gtk_calendar_signals[ERRONEOUS_DATE_SIGNAL], 0);
++ return TRUE;
++ }
++ else
++ {
++ move_focus (calendar, 1);
++ if (!knav)
++ {
++ gtk_calendar_paint_day (widget, old_focus_row, old_focus_col);
++ gtk_calendar_paint_day (widget, calendar->focus_row,
++ calendar->focus_col);
++ }
++ else if (knav)
++ {
++ gint day_month = calendar->day_month[calendar->focus_row][calendar->focus_col];
++ if (day_month == MONTH_CURRENT)
++ {
++ gtk_calendar_select_day (calendar, calendar->selected_day + 1);
++ }
++ else
++ {
++ calendar->selected_day = 1;
++ gtk_calendar_set_month_next (calendar);
++ }
++ gtk_calendar_paint_week_numbers (GTK_WIDGET (calendar));
++ gtk_calendar_paint_day_names (GTK_WIDGET (calendar));
++ }
++ }
+ }
+ break;
+ case GDK_KP_Up:
+@@ -3205,11 +3806,48 @@
+ gtk_calendar_set_year_prev (calendar);
+ else
+ {
+- if (calendar->focus_row > 0)
+- calendar->focus_row--;
+- gtk_calendar_paint_day (widget, old_focus_row, old_focus_col);
+- gtk_calendar_paint_day (widget, calendar->focus_row,
+- calendar->focus_col);
++ if (calendar->year == min_year && calendar->month == 0 && calendar->day_month[old_focus_row-1][old_focus_col] == MONTH_PREV)
++ {
++ g_signal_emit (calendar, gtk_calendar_signals[ERRONEOUS_DATE_SIGNAL], 0);
++ return TRUE;
++ }
++ else
++ {
++ if (calendar->focus_row > 0)
++ calendar->focus_row--;
++ if (!knav)
++ {
++ gtk_calendar_paint_day (widget, old_focus_row, old_focus_col);
++ gtk_calendar_paint_day (widget, calendar->focus_row,
++ calendar->focus_col);
++ }
++ else if (knav)
++ {
++ gint day_month = calendar->day_month[calendar->focus_row][calendar->focus_col];
++ if (day_month == MONTH_CURRENT)
++ {
++ if ((calendar->selected_day - 7) <= 0)
++ {
++ if (calendar->month != 0)
++ calendar->selected_day = month_length[leap (calendar->year)][calendar->month];
++ else
++ calendar->selected_day = month_length[leap (calendar->year - 1)][12];
++ gtk_calendar_set_month_prev (calendar);
++ }
++ else
++ {
++ gtk_calendar_select_day (calendar, calendar->selected_day - 7);
++ }
++ }
++ else
++ {
++ calendar->selected_day = calendar->day[calendar->focus_row][calendar->focus_col];
++ gtk_calendar_set_month_prev (calendar);
++ }
++ gtk_calendar_paint_week_numbers (GTK_WIDGET (calendar));
++ gtk_calendar_paint_day_names (GTK_WIDGET (calendar));
++ }
++ }
+ }
+ break;
+ case GDK_KP_Down:
+@@ -3219,12 +3857,49 @@
+ gtk_calendar_set_year_next (calendar);
+ else
+ {
+- if (calendar->focus_row < 5)
+- calendar->focus_row++;
+- gtk_calendar_paint_day (widget, old_focus_row, old_focus_col);
+- gtk_calendar_paint_day (widget, calendar->focus_row,
+- calendar->focus_col);
++ if (calendar->year == max_year && calendar->month == 11 && calendar->day_month[old_focus_row+1][old_focus_col] == MONTH_NEXT)
++ {
++ g_signal_emit (calendar, gtk_calendar_signals[ERRONEOUS_DATE_SIGNAL], 0);
++ return TRUE;
++ }
++ else
++ {
++
++ if (calendar->focus_row < 5)
++ calendar->focus_row++;
++ if (!knav)
++ {
++ gtk_calendar_paint_day (widget, old_focus_row, old_focus_col);
++ gtk_calendar_paint_day (widget, calendar->focus_row,
++ calendar->focus_col);
++ }
++ else if (knav)
++ {
++ gint day_month = calendar->day_month[calendar->focus_row][calendar->focus_col];
++ if (day_month == MONTH_CURRENT)
++ {
++ if ((calendar->selected_day + 7) >
++ month_length[leap (calendar->year)][calendar->month + 1])
++ {
++ calendar->selected_day = 1;
++ gtk_calendar_set_month_next (calendar);
++ }
++ else
++ {
++ gtk_calendar_select_day (calendar, calendar->selected_day + 7);
++ }
++ }
++ else
++ {
++ calendar->selected_day = calendar->day[calendar->focus_row][calendar->focus_col];
++ gtk_calendar_set_month_next (calendar);
++ }
++ gtk_calendar_paint_week_numbers (GTK_WIDGET (calendar));
++ gtk_calendar_paint_day_names (GTK_WIDGET (calendar));
++ }
++ }
+ }
++
+ break;
+ case GDK_KP_Space:
+ case GDK_space:
+@@ -3545,3 +4220,27 @@
+ gtk_calendar_select_day (calendar, day);
+ g_object_thaw_notify (G_OBJECT (calendar));
+ }
++
++/* This function return TRUE if we should mark date and FALSE
++ * otherwise
++ */
++static void
++gtk_calendar_check_current_date (GtkCalendar *calendar, gint x, gint y)
++{
++ GtkCalendarPrivateData *private_data;
++
++ private_data = GTK_CALENDAR_PRIVATE_DATA (calendar);
++
++ if (calendar->month == private_data->current_month &&
++ calendar->year == private_data->current_year)
++ {
++ gtk_paint_box( GTK_WIDGET (calendar)->style,
++ private_data->main_win,
++ GTK_STATE_NORMAL,
++ GTK_SHADOW_NONE, NULL,
++ GTK_WIDGET (calendar), "current-day",
++ x, y,
++ HILDON_DAY_WIDTH,
++ HILDON_DAY_HEIGHT);
++ }
++}
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcalendar.h.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcalendar.h.diff
index e69de29bb2..185d27e8a2 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcalendar.h.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcalendar.h.diff
@@ -0,0 +1,12 @@
+--- gtk+-2.6.4/gtk/gtkcalendar.h 2003-05-08 03:25:48.000000000 +0300
++++ gtk+-2.6.4/gtk/gtkcalendar.h 2005-04-06 16:19:36.267024936 +0300
+@@ -111,6 +111,9 @@
+ void (* next_month) (GtkCalendar *calendar);
+ void (* prev_year) (GtkCalendar *calendar);
+ void (* next_year) (GtkCalendar *calendar);
++ /* Hildon signals */
++ void (* erroneous_date) (GtkCalendar *calendar);
++ void (* selected_date) (GtkCalendar *calendar);
+
+ };
+
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellrenderertext.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellrenderertext.c.diff
index e69de29bb2..b24c26120a 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellrenderertext.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellrenderertext.c.diff
@@ -0,0 +1,66 @@
+--- gtk+-2.6.4/gtk/gtkcellrenderertext.c 2005-01-09 19:32:25.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkcellrenderertext.c 2005-04-06 16:19:36.274023872 +0300
+@@ -182,8 +182,8 @@
+
+ GTK_CELL_RENDERER (celltext)->xalign = 0.0;
+ GTK_CELL_RENDERER (celltext)->yalign = 0.5;
+- GTK_CELL_RENDERER (celltext)->xpad = 2;
+- GTK_CELL_RENDERER (celltext)->ypad = 2;
++ GTK_CELL_RENDERER (celltext)->xpad = 0;
++ GTK_CELL_RENDERER (celltext)->ypad = 0;
+ celltext->fixed_height_rows = -1;
+ celltext->font = pango_font_description_new ();
+
+@@ -1429,7 +1429,7 @@
+ /* The minimum size for ellipsized labels is ~ 3 chars */
+ if (width)
+ {
+- if (priv->ellipsize || priv->width_chars > 0)
++ /*if (priv->ellipsize || priv->width_chars > 0)
+ {
+ PangoContext *context;
+ PangoFontMetrics *metrics;
+@@ -1444,9 +1444,9 @@
+ *width += (PANGO_PIXELS (char_width) * MAX (priv->width_chars, 3));
+ }
+ else
+- {
++ {*/
+ *width = GTK_CELL_RENDERER (celltext)->xpad * 2 + rect.width;
+- }
++ /*} */
+ }
+
+ if (cell_area)
+@@ -1501,6 +1501,7 @@
+ gint x_offset;
+ gint y_offset;
+ GtkCellRendererTextPrivate *priv;
++ PangoRectangle logical_rect;
+
+ priv = GTK_CELL_RENDERER_TEXT_GET_PRIVATE (cell);
+
+@@ -1521,7 +1522,7 @@
+ else if ((flags & GTK_CELL_RENDERER_PRELIT) == GTK_CELL_RENDERER_PRELIT &&
+ GTK_WIDGET_STATE (widget) == GTK_STATE_PRELIGHT)
+ {
+- state = GTK_STATE_PRELIGHT;
++ state = GTK_STATE_NORMAL;
+ }
+ else
+ {
+@@ -1559,6 +1560,14 @@
+ g_object_unref (gc);
+ }
+
++ /* Dirty Hildon hack to force ellipsation */
++ pango_layout_get_extents (layout, NULL, &logical_rect);
++ if (PANGO_PIXELS (logical_rect.width) > MIN (background_area->width, expose_area->width))
++ {
++ priv->ellipsize = PANGO_ELLIPSIZE_END;
++ priv->ellipsize_set = TRUE;
++ }
++
+ if (priv->ellipsize)
+ pango_layout_set_width (layout,
+ (cell_area->width - x_offset - 2 * cell->xpad) * PANGO_SCALE);
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellrenderertoggle.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellrenderertoggle.c.diff
index e69de29bb2..f6d47f2174 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellrenderertoggle.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellrenderertoggle.c.diff
@@ -0,0 +1,11 @@
+--- gtk+-2.6.4/gtk/gtkcellrenderertoggle.c 2004-08-09 19:59:51.000000000 +0300
++++ gtk+-2.6.4/gtk/gtkcellrenderertoggle.c 2005-04-06 16:19:36.274023872 +0300
+@@ -71,7 +71,7 @@
+ PROP_INCONSISTENT
+ };
+
+-#define TOGGLE_WIDTH 12
++#define TOGGLE_WIDTH 26
+
+ static guint toggle_cell_signals[LAST_SIGNAL] = { 0 };
+
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellview.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellview.c.diff
index e69de29bb2..a6dbfc6a4a 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellview.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellview.c.diff
@@ -0,0 +1,19 @@
+--- gtk+-2.6.4/gtk/gtkcellview.c 2004-12-15 18:27:30.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkcellview.c 2005-04-06 16:19:36.275023720 +0300
+@@ -82,7 +82,6 @@
+ GValue *value);
+ static GtkCellViewCellInfo *gtk_cell_view_get_cell_info (GtkCellView *cellview,
+ GtkCellRenderer *renderer);
+-static void gtk_cell_view_set_cell_data (GtkCellView *cell_view);
+
+
+ static void gtk_cell_view_cell_layout_pack_start (GtkCellLayout *layout,
+@@ -536,7 +535,7 @@
+ return NULL;
+ }
+
+-static void
++void
+ gtk_cell_view_set_cell_data (GtkCellView *cell_view)
+ {
+ GList *i;
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellview.h.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellview.h.diff
index e69de29bb2..eb46720a90 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellview.h.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellview.h.diff
@@ -0,0 +1,10 @@
+--- gtk+-2.6.4/gtk/gtkcellview.h 2004-12-15 18:27:30.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkcellview.h 2005-04-06 16:19:36.317017336 +0300
+@@ -67,6 +67,7 @@
+
+ void gtk_cell_view_set_background_color (GtkCellView *cell_view,
+ const GdkColor *color);
++void gtk_cell_view_set_cell_data (GtkCellView *cellview);
+ GList *gtk_cell_view_get_cell_renderers (GtkCellView *cell_view);
+
+ G_END_DECLS
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcheckbutton.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcheckbutton.c.diff
index e69de29bb2..c6922ddc16 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcheckbutton.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcheckbutton.c.diff
@@ -0,0 +1,520 @@
+--- gtk+-2.6.4/gtk/gtkcheckbutton.c 2004-08-09 19:59:51.000000000 +0300
++++ gtk+-2.6.4/gtk/gtkcheckbutton.c 2005-04-06 16:19:36.317017336 +0300
+@@ -31,27 +31,44 @@
+ #include "gtklabel.h"
+
+
+-#define INDICATOR_SIZE 13
++#define INDICATOR_SIZE 24
+ #define INDICATOR_SPACING 2
+
++/* maJiK numbers for indicator */
++#define INDICATOR_SIDE_PADDING 5
++#define FOCUS_TOP_PADDING 7
++#define FOCUS_DOWN_PADDING 1
++
++/* spacing to take account of the 1 pixel
++ transparency of the widgetfocus.png
++*/
++#define HILDON_SPACING 1
++
++#define TOGGLE_ON_CLICK "toggle-on-click"
+
+-static void gtk_check_button_class_init (GtkCheckButtonClass *klass);
+-static void gtk_check_button_init (GtkCheckButton *check_button);
+-static void gtk_check_button_size_request (GtkWidget *widget,
+- GtkRequisition *requisition);
+-static void gtk_check_button_size_allocate (GtkWidget *widget,
+- GtkAllocation *allocation);
+-static gint gtk_check_button_expose (GtkWidget *widget,
+- GdkEventExpose *event);
+-static void gtk_check_button_paint (GtkWidget *widget,
+- GdkRectangle *area);
+-static void gtk_check_button_draw_indicator (GtkCheckButton *check_button,
+- GdkRectangle *area);
+-static void gtk_real_check_button_draw_indicator (GtkCheckButton *check_button,
+- GdkRectangle *area);
++static void gtk_check_button_class_init (GtkCheckButtonClass *klass);
++static void gtk_check_button_init (GtkCheckButton *check_button);
++static void gtk_check_button_size_request (GtkWidget *widget,
++ GtkRequisition *requisition);
++static void gtk_check_button_size_allocate (GtkWidget *widget,
++ GtkAllocation *allocation);
++static gint gtk_check_button_expose (GtkWidget *widget,
++ GdkEventExpose *event);
++static void gtk_check_button_paint (GtkWidget *widget,
++ GdkRectangle *area);
++static void gtk_check_button_draw_indicator (GtkCheckButton *check_button,
++ GdkRectangle *area);
++static void gtk_real_check_button_draw_indicator
++ (GtkCheckButton *check_button,
++ GdkRectangle *area);
+
+-static GtkToggleButtonClass *parent_class = NULL;
++static void gtk_check_button_calc_indicator_size( GtkCheckButton *button,
++ GdkRectangle *rect );
++
++static void gtk_check_button_clicked (GtkButton *button);
++static void gtk_check_button_update_state (GtkButton *button);
+
++static GtkToggleButtonClass *parent_class = NULL;
+
+ GType
+ gtk_check_button_get_type (void)
+@@ -85,32 +102,36 @@
+ gtk_check_button_class_init (GtkCheckButtonClass *class)
+ {
+ GtkWidgetClass *widget_class;
+-
++ GtkButtonClass *button_class;
++
+ widget_class = (GtkWidgetClass*) class;
++ button_class = (GtkButtonClass*) class;
+ parent_class = g_type_class_peek_parent (class);
+
+ widget_class->size_request = gtk_check_button_size_request;
+ widget_class->size_allocate = gtk_check_button_size_allocate;
+ widget_class->expose_event = gtk_check_button_expose;
+
++ button_class->clicked = gtk_check_button_clicked;
++
+ class->draw_indicator = gtk_real_check_button_draw_indicator;
+
+ gtk_widget_class_install_style_property (widget_class,
+ g_param_spec_int ("indicator_size",
+- P_("Indicator Size"),
+- P_("Size of check or radio indicator"),
+- 0,
+- G_MAXINT,
+- INDICATOR_SIZE,
+- G_PARAM_READABLE));
++ P_("Indicator Size"),
++ P_("Size of check or radio indicator"),
++ 0,
++ G_MAXINT,
++ INDICATOR_SIZE,
++ G_PARAM_READABLE));
+ gtk_widget_class_install_style_property (widget_class,
+ g_param_spec_int ("indicator_spacing",
+- P_("Indicator Spacing"),
+- P_("Spacing around check or radio indicator"),
+- 0,
+- G_MAXINT,
+- INDICATOR_SPACING,
+- G_PARAM_READABLE));
++ P_("Indicator Spacing"),
++ P_("Spacing around check or radio indicator"),
++ 0,
++ G_MAXINT,
++ INDICATOR_SPACING,
++ G_PARAM_READABLE));
+ }
+
+ static void
+@@ -148,7 +169,8 @@
+ GtkWidget*
+ gtk_check_button_new_with_mnemonic (const gchar *label)
+ {
+- return g_object_new (GTK_TYPE_CHECK_BUTTON, "label", label, "use_underline", TRUE, NULL);
++ return g_object_new (GTK_TYPE_CHECK_BUTTON, "label", label,
++ "use_underline", TRUE, NULL);
+ }
+
+
+@@ -163,39 +185,70 @@
+
+ if (GTK_WIDGET_DRAWABLE (widget))
+ {
+- gint border_width;
+- gint interior_focus;
+- gint focus_width;
+- gint focus_pad;
+-
++ gint border_width = 0;
++ gint interior_focus = 0;
++ gint focus_width = 0;
++ gint focus_pad = 0;
++ gint indicator_size = 0;
++ gint indicator_spacing = 0;
++
+ gtk_widget_style_get (widget,
+ "interior-focus", &interior_focus,
+ "focus-line-width", &focus_width,
+ "focus-padding", &focus_pad,
++ "indicator-size", &indicator_size,
++ "indicator-spacing", &indicator_spacing,
+ NULL);
+-
+- gtk_check_button_draw_indicator (check_button, area);
+
+ border_width = GTK_CONTAINER (widget)->border_width;
++
++ /* Hildon: change the focus so that it draws around the entire
++ * widget - including both the indicator *and* the label
++ */
+ if (GTK_WIDGET_HAS_FOCUS (widget))
+ {
+ GtkWidget *child = GTK_BIN (widget)->child;
+
++ int w = indicator_size + 2 * indicator_spacing +
++ 2 * (focus_width + focus_pad);
++ int h = indicator_size + 2 * indicator_spacing +
++ 2 * (focus_width + focus_pad) + 2 * HILDON_SPACING
++ - FOCUS_TOP_PADDING;
++ int x = widget->allocation.x;
++ int y = widget->allocation.y + (widget->allocation.height - h)/2
++ + FOCUS_DOWN_PADDING;
++
++ if (gtk_widget_get_direction(widget) == GTK_TEXT_DIR_RTL)
++ x = widget->allocation.x + widget->allocation.width -
++ (2 * HILDON_SPACING) - (indicator_size + 2) -
++ (indicator_spacing + 2);
++
+ if (interior_focus && child && GTK_WIDGET_VISIBLE (child))
+- gtk_paint_focus (widget->style, widget->window, GTK_WIDGET_STATE (widget),
+- NULL, widget, "checkbutton",
+- child->allocation.x - focus_width - focus_pad,
+- child->allocation.y - focus_width - focus_pad,
+- child->allocation.width + 2 * (focus_width + focus_pad),
+- child->allocation.height + 2 * (focus_width + focus_pad));
++ {
++ if (gtk_widget_get_direction(widget) == GTK_TEXT_DIR_RTL)
++ {
++ /* Move the "x" to the left, and enlarge the width,
++ both accounting for the child
++ */
++ x += - child->allocation.width - HILDON_SPACING -
++ (widget->style->xthickness);
++ w += child->allocation.width + HILDON_SPACING +
++ (widget->style->xthickness);
++ } else {
++ w = child->allocation.x + child->allocation.width +
++ 2 * widget->style->xthickness - x;
++ }
++
++ gtk_paint_focus (widget->style, widget->window,
++ GTK_WIDGET_STATE (widget),
++ NULL, widget, "checkbutton", x, y, w, h);
++ }
+ else
+- gtk_paint_focus (widget->style, widget->window, GTK_WIDGET_STATE (widget),
+- NULL, widget, "checkbutton",
+- border_width + widget->allocation.x,
+- border_width + widget->allocation.y,
+- widget->allocation.width - 2 * border_width,
+- widget->allocation.height - 2 * border_width);
++ gtk_paint_focus (widget->style, widget->window,
++ GTK_WIDGET_STATE (widget),
++ NULL, widget, "checkbutton", x, y, w, h);
+ }
++ gtk_check_button_draw_indicator (check_button, area);
+ }
+ }
+
+@@ -205,10 +258,10 @@
+ gint *indicator_spacing)
+ {
+ GtkWidget *widget = GTK_WIDGET (check_button);
+-
++
+ if (indicator_size)
+ gtk_widget_style_get (widget, "indicator_size", indicator_size, NULL);
+-
++
+ if (indicator_spacing)
+ gtk_widget_style_get (widget, "indicator_spacing", indicator_spacing, NULL);
+ }
+@@ -233,7 +286,7 @@
+ "focus-line-width", &focus_width,
+ "focus-padding", &focus_pad,
+ NULL);
+-
++
+ requisition->width = border_width * 2;
+ requisition->height = border_width * 2;
+
+@@ -246,15 +299,19 @@
+ GtkRequisition child_requisition;
+
+ gtk_widget_size_request (child, &child_requisition);
+-
+- requisition->width += child_requisition.width + indicator_spacing;
++
++ requisition->width += child_requisition.width +
++ 2 * widget->style->xthickness;
+ requisition->height += child_requisition.height;
++ requisition->width += 2 * widget->style->xthickness;
+ }
+
+- requisition->width += (indicator_size + indicator_spacing * 2 + 2 * (focus_width + focus_pad));
++ requisition->width += (indicator_size + indicator_spacing * 2 +
++ 2 * (focus_width + focus_pad));
+
+ temp = indicator_size + indicator_spacing * 2;
+- requisition->height = MAX (requisition->height, temp) + 2 * (focus_width + focus_pad);
++ requisition->height = MAX (requisition->height, temp) +
++ 2 * (focus_width + focus_pad);
+ }
+ else
+ (* GTK_WIDGET_CLASS (parent_class)->size_request) (widget, requisition);
+@@ -280,45 +337,59 @@
+ gint focus_width;
+ gint focus_pad;
+
+- _gtk_check_button_get_props (check_button, &indicator_size, &indicator_spacing);
++ _gtk_check_button_get_props (check_button,
++ &indicator_size, &indicator_spacing);
+ gtk_widget_style_get (widget,
+ "focus-line-width", &focus_width,
+ "focus-padding", &focus_pad,
+ NULL);
+-
++
+ widget->allocation = *allocation;
+ if (GTK_WIDGET_REALIZED (widget))
+ gdk_window_move_resize (button->event_window,
+ allocation->x, allocation->y,
+ allocation->width, allocation->height);
+
+- if (GTK_BIN (button)->child && GTK_WIDGET_VISIBLE (GTK_BIN (button)->child))
++ if (GTK_BIN (button)->child &&
++ GTK_WIDGET_VISIBLE (GTK_BIN (button)->child))
+ {
+ GtkRequisition child_requisition;
+ gint border_width = GTK_CONTAINER (widget)->border_width;
+-
+- gtk_widget_get_child_requisition (GTK_BIN (button)->child, &child_requisition);
++
++ gtk_widget_get_child_requisition (GTK_BIN (button)->child,
++ &child_requisition);
+
+- child_allocation.width = MIN (child_requisition.width,
++ child_allocation.width = MIN (
++ child_requisition.width,
+ allocation->width -
+- ((border_width + focus_width + focus_pad) * 2
+- + indicator_size + indicator_spacing * 3));
+- child_allocation.width = MAX (child_allocation.width, 1);
++ ((border_width + focus_width +
++ focus_pad) * 2
++ - 2 * widget->style->xthickness +
++ indicator_size +
++ indicator_spacing * 2 ) );
+
++ child_allocation.width = MAX (child_allocation.width, 1);
++
+ child_allocation.height = MIN (child_requisition.height,
+- allocation->height - (border_width + focus_width + focus_pad) * 2);
++ allocation->height -
++ (border_width + focus_width +
++ focus_pad) * 2);
+ child_allocation.height = MAX (child_allocation.height, 1);
+
+- child_allocation.x = (border_width + indicator_size + indicator_spacing * 3 +
+- widget->allocation.x + focus_width + focus_pad);
++ child_allocation.x = (border_width + indicator_size +
++ indicator_spacing * 2 +
++ widget->style->xthickness +
++ widget->allocation.x +
++ focus_width + focus_pad);
+ child_allocation.y = widget->allocation.y +
+- (allocation->height - child_allocation.height) / 2;
+-
++ (allocation->height - child_allocation.height) / 2;
++
+ if (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL)
+- child_allocation.x = allocation->x + allocation->width
+- - (child_allocation.x - allocation->x + child_allocation.width);
++ child_allocation.x = allocation->x + allocation->width -
++ (child_allocation.x - allocation->x + child_allocation.width);
+
+- gtk_widget_size_allocate (GTK_BIN (button)->child, &child_allocation);
++ gtk_widget_size_allocate (GTK_BIN (button)->child,
++ &child_allocation);
+ }
+ }
+ else
+@@ -375,45 +446,33 @@
+ GdkRectangle *area)
+ {
+ GtkWidget *widget;
+- GtkWidget *child;
+ GtkButton *button;
+ GtkToggleButton *toggle_button;
+ GtkStateType state_type;
+ GtkShadowType shadow_type;
+- gint x, y;
+- gint indicator_size;
+- gint indicator_spacing;
+- gint focus_width;
+- gint focus_pad;
+- gboolean interior_focus;
++
++ GdkRectangle indicator = {0, 0, 0, 0};
+
+ if (GTK_WIDGET_DRAWABLE (check_button))
+ {
+ widget = GTK_WIDGET (check_button);
+ button = GTK_BUTTON (check_button);
+ toggle_button = GTK_TOGGLE_BUTTON (check_button);
+-
+- gtk_widget_style_get (widget, "interior_focus", &interior_focus,
+- "focus-line-width", &focus_width,
+- "focus-padding", &focus_pad, NULL);
+-
+- _gtk_check_button_get_props (check_button, &indicator_size, &indicator_spacing);
+-
+- x = widget->allocation.x + indicator_spacing + GTK_CONTAINER (widget)->border_width;
+- y = widget->allocation.y + (widget->allocation.height - indicator_size) / 2;
+-
+- child = GTK_BIN (check_button)->child;
+- if (!interior_focus || !(child && GTK_WIDGET_VISIBLE (child)))
+- x += focus_width + focus_pad;
+-
++ gtk_check_button_calc_indicator_size( check_button, &indicator );
++
++ /* move indicator to root coordinates */
++ indicator.x += widget->allocation.x;
++ indicator.y += widget->allocation.y;
++
+ if (toggle_button->inconsistent)
+ shadow_type = GTK_SHADOW_ETCHED_IN;
+ else if (toggle_button->active)
+ shadow_type = GTK_SHADOW_IN;
+ else
+ shadow_type = GTK_SHADOW_OUT;
+-
+- if (button->activate_timeout || (button->button_down && button->in_button))
++
++ if (button->activate_timeout ||
++ (button->button_down && button->in_button))
+ state_type = GTK_STATE_ACTIVE;
+ else if (button->in_button)
+ state_type = GTK_STATE_PRELIGHT;
+@@ -422,32 +481,107 @@
+ else
+ state_type = GTK_STATE_NORMAL;
+
+- if (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL)
+- x = widget->allocation.x + widget->allocation.width - (indicator_size + x - widget->allocation.x);
++ /* Hildon change. We want to draw active image always when we have
++ * focus. */
++ if (GTK_WIDGET_HAS_FOCUS (widget))
++ state_type = GTK_STATE_ACTIVE;
+
+- if (GTK_WIDGET_STATE (toggle_button) == GTK_STATE_PRELIGHT)
++ if (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL)
+ {
+- GdkRectangle restrict_area;
+- GdkRectangle new_area;
+-
+- restrict_area.x = widget->allocation.x + GTK_CONTAINER (widget)->border_width;
+- restrict_area.y = widget->allocation.y + GTK_CONTAINER (widget)->border_width;
+- restrict_area.width = widget->allocation.width - (2 * GTK_CONTAINER (widget)->border_width);
+- restrict_area.height = widget->allocation.height - (2 * GTK_CONTAINER (widget)->border_width);
++ indicator.x = widget->allocation.x + widget->allocation.width
++ - (indicator.width + indicator.x - widget->allocation.x);
+
+- if (gdk_rectangle_intersect (area, &restrict_area, &new_area))
+- {
+- gtk_paint_flat_box (widget->style, widget->window, GTK_STATE_PRELIGHT,
+- GTK_SHADOW_ETCHED_OUT,
+- area, widget, "checkbutton",
+- new_area.x, new_area.y,
+- new_area.width, new_area.height);
+- }
+ }
+
+ gtk_paint_check (widget->style, widget->window,
+ state_type, shadow_type,
+ area, widget, "checkbutton",
+- x, y, indicator_size, indicator_size);
++ indicator.x, indicator.y,
++ indicator.width, indicator.height);
++ }
++}
++
++
++/* calculates the size and position of the indicator
++ * relative to the origin of the check button.
++ */
++static void gtk_check_button_calc_indicator_size( GtkCheckButton *button,
++ GdkRectangle *rect )
++{
++ gint indicator_size;
++ gint indicator_spacing;
++ gint focus_width;
++ gint focus_pad;
++ gboolean interior_focus;
++ GtkWidget *child;
++ GtkWidget *widget = GTK_WIDGET(button);
++
++
++ gtk_widget_style_get (widget, "interior_focus", &interior_focus,
++ "focus-line-width", &focus_width,
++ "focus-padding", &focus_pad,
++ "indicator-size", &indicator_size,
++ "indicator-spacing", &indicator_spacing,
++ NULL
++ );
++
++
++ /* HILDON: We want the indicator to be positioned according to the spec.
++ *
++ * NOTE: INDICATOR_SIDE_PADDING and INDICATOR_TOP_PADDING
++ * are maJiKal numbers that make the indicator to be drawn
++ * to correct coordinates, 1337 \o/
++ */
++ rect->x = INDICATOR_SIDE_PADDING;
++ rect->y = ( widget->allocation.height - indicator_size ) / 2;
++
++ /* Hildon: we always add space for the focus */
++ rect->x += focus_width + focus_pad;
++
++ child = GTK_BIN (widget)->child;
++ if (interior_focus && child && GTK_WIDGET_VISIBLE (child))
++ {
++ rect->y += HILDON_SPACING;
+ }
++
++ rect->width = indicator_size;
++ rect->height = indicator_size;
+ }
++
++static void
++gtk_check_button_clicked (GtkButton *button)
++{
++ GtkToggleButton *toggle_button = GTK_TOGGLE_BUTTON (button);
++
++ toggle_button->active = !toggle_button->active;
++ gtk_toggle_button_toggled (toggle_button);
++
++ gtk_check_button_update_state (button);
++
++ g_object_notify (G_OBJECT (toggle_button), "active");
++}
++
++static void
++gtk_check_button_update_state (GtkButton *button)
++{
++ GtkToggleButton *toggle_button = GTK_TOGGLE_BUTTON (button);
++ gboolean depressed;
++ GtkStateType new_state;
++
++ if (toggle_button->inconsistent)
++ depressed = FALSE;
++ else if (button->in_button && button->button_down)
++ depressed = TRUE;
++ else
++ depressed = toggle_button->active;
++
++ if (button->in_button &&
++ (!button->button_down || toggle_button->draw_indicator))
++ new_state = GTK_STATE_PRELIGHT;
++ else
++ new_state = depressed ? GTK_STATE_ACTIVE : GTK_STATE_NORMAL;
++
++ _gtk_button_set_depressed (button, depressed);
++ gtk_widget_set_state (GTK_WIDGET (toggle_button), new_state);
++}
++
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcombobox.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcombobox.c.diff
index e69de29bb2..2376beaeaa 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcombobox.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcombobox.c.diff
@@ -0,0 +1,950 @@
+--- gtk+-2.6.4/gtk/gtkcombobox.c 2005-02-25 21:11:08.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkcombobox.c 2005-04-06 16:19:36.406003808 +0300
+@@ -17,6 +17,10 @@
+ * Boston, MA 02111-1307, USA.
+ */
+
++/*
++ * Modified for Nokia Oyj during 2002-2004.
++ */
++
+ #include <config.h>
+ #include "gtkalias.h"
+ #include "gtkcombobox.h"
+@@ -39,6 +43,8 @@
+ #include "gtktreeselection.h"
+ #include "gtkvseparator.h"
+ #include "gtkwindow.h"
++#include "gtkcomboboxentry.h"
++#include "gtktoolbar.h"
+
+ #include <gdk/gdkkeysyms.h>
+
+@@ -52,6 +58,13 @@
+
+ #include "gtktreeprivate.h"
+
++#define HILDON_MAX_WIDTH 406
++#define HILDON_MAX_HEIGHT 305
++#define HILDON_MAX_ITEMS 8
++/* this is also defined in gtkmenu.c and should be replaced with
++ a style property */
++#define MENU_SCROLL_ARROW_HEIGHT 20
++
+ /* WELCOME, to THE house of evil code */
+
+ typedef struct _ComboCellInfo ComboCellInfo;
+@@ -119,6 +132,9 @@
+ GtkTreeViewRowSeparatorFunc row_separator_func;
+ gpointer row_separator_data;
+ GtkDestroyNotify row_separator_destroy;
++
++ /* Hildon hack: state of our style property */
++ gboolean autodimmed_button;
+ };
+
+ /* While debugging this evil code, I have learned that
+@@ -201,6 +217,7 @@
+
+ #define BONUS_PADDING 4
+ #define SCROLL_TIME 100
++#define HILDON_PADDING 25
+
+ /* common */
+ static void gtk_combo_box_class_init (GtkComboBoxClass *klass);
+@@ -273,6 +290,14 @@
+ gboolean include_internals,
+ GtkCallback callback,
+ gpointer callback_data);
++static gboolean gtk_combo_box_focus_in (GtkWidget *widget,
++ GdkEventFocus *event);
++static gint gtk_combo_box_focus (GtkWidget *widget,
++ GtkDirectionType dir);
++static void gtk_combo_box_child_focus_in (GtkWidget *widget,
++ GdkEventFocus *event);
++static void gtk_combo_box_child_focus_out (GtkWidget *widget,
++ GdkEventFocus *event);
+ static gboolean gtk_combo_box_expose_event (GtkWidget *widget,
+ GdkEventExpose *event);
+ static gboolean gtk_combo_box_scroll_event (GtkWidget *widget,
+@@ -285,6 +310,12 @@
+
+ static void gtk_combo_box_check_appearance (GtkComboBox *combo_box);
+
++/* <Hildon addition> */
++extern void gtk_grab_combo_box_entry_focus (GtkComboBoxEntry *entry_box);
++
++static void gtk_combo_box_grab_focus (GtkWidget *focus_widget);
++/* </hildon addition> */
++
+ /* listening to the model */
+ static void gtk_combo_box_model_row_inserted (GtkTreeModel *model,
+ GtkTreePath *path,
+@@ -424,6 +455,9 @@
+ static void gtk_combo_box_start_editing (GtkCellEditable *cell_editable,
+ GdkEvent *event);
+
++static void gtk_combo_box_menu_position_above (GtkMenu *menu, gint *x,
++ gint *y, gboolean *push_in,
++ gpointer user_data);
+
+ GType
+ gtk_combo_box_get_type (void)
+@@ -479,6 +513,25 @@
+ return combo_box_type;
+ }
+
++/* Hildon addition: Check if the button needs to be dimmed */
++static void hildon_check_autodim(GtkComboBox *combo_box)
++{
++ GtkWidget *widget;
++ GtkTreeModel *model;
++ GtkTreeIter iter;
++
++ widget = combo_box->priv->button;
++ model = combo_box->priv->model;
++
++ if (combo_box->priv->autodimmed_button && widget != NULL)
++ {
++ if (model && gtk_tree_model_get_iter_first(model, &iter))
++ gtk_widget_set_sensitive(widget, TRUE);
++ else
++ gtk_widget_set_sensitive(widget, FALSE);
++ }
++}
++
+ /* common */
+ static void
+ gtk_combo_box_class_init (GtkComboBoxClass *klass)
+@@ -504,6 +557,11 @@
+ widget_class->mnemonic_activate = gtk_combo_box_mnemonic_activate;
+ widget_class->style_set = gtk_combo_box_style_set;
+ widget_class->state_changed = gtk_combo_box_state_changed;
++
++ /* Hildon addition */
++ widget_class->grab_focus = gtk_combo_box_grab_focus;
++ widget_class->focus_in_event = gtk_combo_box_focus_in;
++ widget_class->focus = gtk_combo_box_focus;
+
+ gtk_object_class = (GtkObjectClass *)klass;
+ gtk_object_class->destroy = gtk_combo_box_destroy;
+@@ -687,6 +745,41 @@
+ FALSE,
+ G_PARAM_READABLE));
+
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_boolean ("hildonlike",
++ _("Size request"),
++ _("Size allocate"),
++ FALSE,
++ G_PARAM_READABLE));
++
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("arrow-height",
++ P_("Arrow height for option menu"),
++ P_("Sets arrow height"),
++ 0,
++ G_MAXINT,
++ 28,
++ G_PARAM_READWRITE));
++
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("arrow-width",
++ P_("Arrow width for option menu"),
++ P_("Sets arrow width"),
++ 0,
++ G_MAXINT,
++ 26,
++ G_PARAM_READWRITE));
++
++
++ /* Hildon hack: style property for enabling the autodimming hack */
++ gtk_widget_class_install_style_property (
++ widget_class,
++ g_param_spec_boolean ("autodimmed_button",
++ _("Autodimmed button"),
++ _("Automatically dims the button if the list is empty"),
++ FALSE,
++ G_PARAM_READABLE));
++
+ g_type_class_add_private (object_class, sizeof (GtkComboBoxPrivate));
+ }
+
+@@ -731,6 +824,11 @@
+ combo_box->priv->editing_canceled = FALSE;
+ combo_box->priv->auto_scroll = FALSE;
+ combo_box->priv->focus_on_click = TRUE;
++
++ /* Hildon hack: default value for our style property if it is queried before
++ * the style is set */
++ combo_box->priv->autodimmed_button = FALSE;
++ GTK_WIDGET_SET_FLAGS ( combo_box, GTK_CAN_FOCUS );
+ }
+
+ static void
+@@ -911,7 +1009,19 @@
+ {
+ GtkComboBox *combo_box = GTK_COMBO_BOX (widget);
+
++ /* Hildon hack: read the state of our style property */
++ gtk_widget_style_get (GTK_WIDGET(combo_box),
++ "autodimmed_button", &(combo_box->priv->autodimmed_button), NULL);
++
+ gtk_combo_box_check_appearance (combo_box);
++
++ /* Hildon hack: handle the dimmed state of the button in regards whether
++ * the list is empty or not. This has to be done here because
++ * in the callback functions of GtkTreeModel the button widget
++ * may have not yet been set. However, we repeat this stuff in
++ * those functions, because later the button will be set and
++ * we want to update our state. */
++ hildon_check_autodim(combo_box);
+
+ if (combo_box->priv->tree_view && combo_box->priv->cell_view)
+ gtk_cell_view_set_background_color (GTK_CELL_VIEW (combo_box->priv->cell_view),
+@@ -922,10 +1032,17 @@
+ gtk_combo_box_button_toggled (GtkWidget *widget,
+ gpointer data)
+ {
++ gboolean hildonlike;
+ GtkComboBox *combo_box = GTK_COMBO_BOX (data);
++
++ gtk_widget_style_get (GTK_WIDGET (combo_box), "hildonlike", &hildonlike, NULL);
+
+ if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (widget)))
+ {
++ if (hildonlike) {
++ gtk_combo_box_grab_focus(GTK_WIDGET(combo_box));
++ }
++
+ if (!combo_box->priv->popup_in_progress)
+ gtk_combo_box_popup (combo_box);
+ }
+@@ -1103,7 +1220,7 @@
+ {
+ gtk_container_remove (GTK_CONTAINER (combo_box->priv->popup_frame),
+ combo_box->priv->popup_widget);
+- g_object_unref (combo_box->priv->popup_widget);
++ g_object_unref (G_OBJECT (combo_box->priv->popup_widget));
+ combo_box->priv->popup_widget = NULL;
+ }
+
+@@ -1175,7 +1292,7 @@
+ popup);
+
+ gtk_widget_show (popup);
+- g_object_ref (popup);
++ g_object_ref (G_OBJECT (popup));
+ combo_box->priv->popup_widget = popup;
+ }
+ }
+@@ -1250,9 +1367,13 @@
+ GtkRequisition requisition;
+ GList *children;
+ gint screen_width;
++ gint screen_height;
+ gint menu_xpos;
+ gint menu_ypos;
+- gint menu_width;
++ gint menu_width, menu_height;
++ gint counter = 0;
++ gint scroll_offset = 0;
++ gint max_items = 0;
+
+ g_return_if_fail (GTK_IS_COMBO_BOX (user_data));
+
+@@ -1261,6 +1382,7 @@
+
+ gtk_widget_get_child_requisition (GTK_WIDGET (menu), &requisition);
+ menu_width = requisition.width;
++ menu_height = requisition.height;
+
+ active = gtk_menu_get_active (GTK_MENU (combo_box->priv->popup_widget));
+ gdk_window_get_origin (widget->window, &menu_xpos, &menu_ypos);
+@@ -1275,6 +1397,11 @@
+ }
+
+ children = GTK_MENU_SHELL (combo_box->priv->popup_widget)->children;
++ child = children->data;
++ gtk_widget_get_child_requisition (child, &requisition);
++ max_items = (HILDON_MAX_HEIGHT-2*MENU_SCROLL_ARROW_HEIGHT)/requisition.height;
++ max_items -= 1;
++
+ while (children)
+ {
+ child = children->data;
+@@ -1284,27 +1411,119 @@
+
+ if (GTK_WIDGET_VISIBLE (child))
+ {
+- gtk_widget_get_child_requisition (child, &requisition);
+- menu_ypos -= requisition.height;
++ if (counter < max_items - 2)
++ menu_ypos -= requisition.height;
++ if (counter > max_items - 3)
++ scroll_offset += requisition.height;
+ }
+-
++
++ counter++;
+ children = children->next;
+ }
++ gtk_widget_get_child_requisition (GTK_WIDGET(menu), &requisition);
+
++ if ( requisition.height >= HILDON_MAX_HEIGHT )
++ menu_ypos -= MENU_SCROLL_ARROW_HEIGHT;
++
+ if (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL)
+ menu_xpos = menu_xpos + widget->allocation.width - menu_width;
+
++ {
++ gint menu_xpad, menu_ypad;
++ gtk_widget_style_get (GTK_WIDGET (menu),
++ "horizontal-padding", &menu_xpad,
++ "vertical-padding", &menu_ypad,
++ NULL);
++ menu_xpos -= menu_xpad - 3;
++ menu_ypos -= menu_ypad - 1;
++ }
++
+ /* Clamp the position on screen */
+ screen_width = gdk_screen_get_width (gtk_widget_get_screen (widget));
++ screen_height = gdk_screen_get_height (gtk_widget_get_screen (widget));
+
+ if (menu_xpos < 0)
+ menu_xpos = 0;
+ else if ((menu_xpos + menu_width) > screen_width)
+ menu_xpos -= ((menu_xpos + menu_width) - screen_width);
+
++ if (menu_ypos + menu_height > screen_height)
++ {
++ menu_ypos = screen_height - menu_height;
++ }
++ if (menu_ypos < 0)
++ {
++ menu_ypos = 0;
++ }
++
++ GTK_MENU(combo_box->priv->popup_widget)->scroll_offset = scroll_offset;
++
+ *x = menu_xpos;
+ *y = menu_ypos;
+
++ *push_in = FALSE;
++}
++
++static void
++gtk_combo_box_menu_position_above (GtkMenu *menu,
++ gint *x,
++ gint *y,
++ gboolean *push_in,
++ gpointer user_data)
++{
++ /*
++ * This function positiones the menu above widgets.
++ * This is a modified version of the position function
++ * gtk_combo_box_position_over.
++ * NB: This is only used when gtkcombobox is in toolbar!
++ */
++
++ GtkWidget *child;
++ GtkRequisition requisition;
++ GList *children;
++ gint screen_width;
++ gint menu_xpos;
++ gint menu_ypos;
++ gint gx,gy;
++ gint menu_width;
++ GtkWidget *widget;
++
++ widget = GTK_WIDGET(user_data);
++
++ gtk_widget_get_child_requisition (GTK_WIDGET (menu), &requisition);
++ menu_width = requisition.width;
++
++ gdk_window_get_position(GDK_WINDOW(widget->window), &gx, &gy);
++ gtk_widget_translate_coordinates (widget, gtk_widget_get_toplevel(widget),
++ gx, gy, &menu_xpos, &menu_ypos);
++
++ menu_ypos -= GTK_WIDGET(menu)->style->ythickness * 2;
++ menu_ypos -= GTK_WIDGET(widget)->style->ythickness * 2;
++
++ menu_ypos -= widget->allocation.height;
++
++ children = GTK_MENU_SHELL (menu)->children;
++ while (children) {
++ child = children->data;
++ if (GTK_WIDGET_VISIBLE (child)){
++ gtk_widget_get_child_requisition (child, &requisition);
++ menu_ypos -= requisition.height;
++ }
++ children = children->next;
++ }
++
++ if (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL)
++ menu_xpos = menu_xpos + widget->allocation.width - menu_width;
++
++ screen_width = gdk_screen_get_width (gtk_widget_get_screen (widget));
++
++ if (menu_xpos < 0)
++ menu_xpos = 0;
++ else if ((menu_xpos + menu_width) > screen_width)
++ menu_xpos -= ((menu_xpos + menu_width) - screen_width);
++
++ *x = menu_xpos;
++ *y = menu_ypos;
+ *push_in = TRUE;
+ }
+
+@@ -1318,21 +1537,44 @@
+ GtkComboBox *combo_box;
+ GtkWidget *menu_item;
+
++ gboolean hildonlike;
++
+ combo_box = GTK_COMBO_BOX (user_data);
+
+- if (combo_box->priv->wrap_width > 0 || combo_box->priv->cell_view == NULL)
+- gtk_combo_box_menu_position_below (menu, x, y, push_in, user_data);
+- else
++ gtk_widget_style_get (GTK_WIDGET (combo_box), "hildonlike", &hildonlike, NULL);
++
++ if (!(combo_box->priv->wrap_width > 0 || combo_box->priv->cell_view == NULL))
+ {
+ /* FIXME handle nested menus better */
+ menu_item = gtk_menu_get_active (GTK_MENU (combo_box->priv->popup_widget));
+ if (menu_item)
+ gtk_menu_shell_select_item (GTK_MENU_SHELL (combo_box->priv->popup_widget),
+ menu_item);
++ }
+
+- gtk_combo_box_menu_position_over (menu, x, y, push_in, user_data);
++ if (hildonlike)
++ {
++ /* HILDON: we check if combobox is in a toolbar */
++ gboolean in_toolbar = gtk_widget_get_ancestor(GTK_WIDGET(combo_box), GTK_TYPE_TOOLBAR) != NULL;
++ if (in_toolbar)
++ {
++ /*due to limits in combo's sizes we use position_over here also*/
++ gtk_combo_box_menu_position_over (menu, x, y, push_in, user_data);
++ return;
++ }
+ }
+
++ if (combo_box->priv->wrap_width > 0 || combo_box->priv->cell_view == NULL)
++/*
++ * Changed because we always want the combo box position to be over
++ * the combo box, unless it's in toolbar.
++ *
++ gtk_combo_box_menu_position_below (menu, x, y, push_in, user_data);
++*/
++ gtk_combo_box_menu_position_over (menu, x, y, push_in, user_data);
++ else
++ gtk_combo_box_menu_position_over (menu, x, y, push_in, user_data);
++
+ }
+
+ static void
+@@ -1430,7 +1672,7 @@
+ list = cells;
+ while (list)
+ {
+- g_object_get (list->data, "sensitive", &sensitive, NULL);
++ g_object_get (G_OBJECT (list->data), "sensitive", &sensitive, NULL);
+
+ if (sensitive)
+ break;
+@@ -1469,7 +1711,7 @@
+ list = cells;
+ while (list)
+ {
+- g_object_get (list->data, "sensitive", &sensitive, NULL);
++ g_object_get (G_OBJECT (list->data), "sensitive", &sensitive, NULL);
+
+ if (sensitive)
+ break;
+@@ -1516,8 +1758,8 @@
+ if (menu != combo_box->priv->popup_widget && child == children)
+ {
+ separator = GTK_WIDGET (child->next->data);
+- g_object_set (item, "visible", sensitive, NULL);
+- g_object_set (separator, "visible", sensitive, NULL);
++ g_object_set (G_OBJECT (item), "visible", sensitive, NULL);
++ g_object_set (G_OBJECT (separator), "visible", sensitive, NULL);
+ }
+ else
+ gtk_widget_set_sensitive (item, sensitive);
+@@ -1543,16 +1785,19 @@
+ if (gtk_tree_row_reference_valid (combo_box->priv->active_row))
+ {
+ path = gtk_tree_row_reference_get_path (combo_box->priv->active_row);
+- active_item = gtk_tree_path_get_indices (path)[0];
+- gtk_tree_path_free (path);
+-
+- if (combo_box->priv->add_tearoffs)
+- active_item++;
++ if (path)
++ {
++ active_item = gtk_tree_path_get_indices (path)[0];
++ gtk_tree_path_free (path);
++
++ if (combo_box->priv->add_tearoffs)
++ active_item++;
++ }
+ }
+
+ /* FIXME handle nested menus better */
+- gtk_menu_set_active (GTK_MENU (combo_box->priv->popup_widget), active_item);
+-
++ gtk_menu_set_active (GTK_MENU (combo_box->priv->popup_widget), active_item);
++
+ if (combo_box->priv->wrap_width == 0)
+ {
+ width = GTK_WIDGET (combo_box)->allocation.width;
+@@ -1684,6 +1929,7 @@
+ {
+ gint padding;
+ GtkRequisition req;
++ gboolean hildonlike;
+
+ if (combo_box->priv->cell_view)
+ gtk_widget_style_get (combo_box->priv->cell_view,
+@@ -1691,9 +1937,17 @@
+ NULL);
+ else
+ padding = 0;
++
++ gtk_widget_style_get (GTK_WIDGET (combo_box), "hildonlike", &hildonlike,
++ NULL);
+
+ /* add some pixels for good measure */
+- padding += BONUS_PADDING;
++ /* Hildon: we need more padding because our theming
++ * Not elegent way to do it anyway ... */
++ if (hildonlike)
++ padding += HILDON_PADDING;
++ else
++ padding += BONUS_PADDING;
+
+ if (combo_box->priv->cell_view)
+ gtk_cell_view_get_size_of_row (GTK_CELL_VIEW (combo_box->priv->cell_view),
+@@ -1709,6 +1963,7 @@
+ {
+ GtkTreeIter iter;
+ GtkTreePath *path;
++ gboolean hildonlike;
+
+ if (!combo_box->priv->model ||
+ !gtk_tree_model_get_iter_first (combo_box->priv->model, &iter))
+@@ -1717,6 +1972,7 @@
+ combo_box->priv->width = 0;
+
+ path = gtk_tree_path_new_from_indices (0, -1);
++ gtk_widget_style_get (GTK_WIDGET (combo_box), "hildonlike", &hildonlike, NULL);
+
+ do
+ {
+@@ -1727,8 +1983,11 @@
+ path, &req);
+ else
+ req.width = 0;
++ /* Hildon: we need more padding because our theming
++ * Not elegent way to do it anyway ... */
+
+- combo_box->priv->width = MAX (combo_box->priv->width, req.width);
++ combo_box->priv->width = MAX (combo_box->priv->width,
++ req.width + (hildonlike == 1) ? HILDON_PADDING : 0 );
+
+ gtk_tree_path_next (path);
+ }
+@@ -1744,10 +2003,19 @@
+ gint width, height;
+ gint focus_width, focus_pad;
+ GtkRequisition bin_req;
++ gboolean hildonlike;
++ gint arrow_width;
++ gint arrow_height;
+
+ GtkComboBox *combo_box = GTK_COMBO_BOX (widget);
+
+ gtk_combo_box_check_appearance (combo_box);
++
++ /* get hildonlike style property */
++ gtk_widget_style_get (widget, "hildonlike",
++ &hildonlike, "arrow-width",
++ &arrow_width, "arrow-height",
++ &arrow_height, NULL);
+
+ /* common */
+ gtk_widget_size_request (GTK_BIN (widget)->child, &bin_req);
+@@ -1829,6 +2097,13 @@
+ requisition->height = MAX (requisition->height, button_req.height);
+ requisition->width += button_req.width;
+ }
++
++ requisition->width = MIN (requisition->width, HILDON_MAX_WIDTH);
++
++ /* HILDON quick fix: height forced to be 28px as specified by Hildon specs. */
++ if (hildonlike)
++ if (requisition->height > arrow_height)
++ requisition->height = arrow_height;
+ }
+
+ static void
+@@ -1839,17 +2114,32 @@
+ gint focus_width, focus_pad;
+ GtkAllocation child;
+ GtkRequisition req;
++ GtkRequisition child_req;
+ gboolean is_rtl = gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL;
++ gboolean hildonlike;
++ gint arrow_width;
++ gint arrow_height;
+
+ gtk_combo_box_check_appearance (combo_box);
+
+- widget->allocation = *allocation;
+-
+ gtk_widget_style_get (GTK_WIDGET (widget),
+ "focus-line-width", &focus_width,
+ "focus-padding", &focus_pad,
++ "hildonlike", &hildonlike,
++ "arrow-width", &arrow_width,
++ "arrow-height", &arrow_height,
+ NULL);
+
++ /* HILDON: set height to fixed value */
++ if (hildonlike)
++ if (allocation->height > arrow_height)
++ {
++ allocation->y += (allocation->height - arrow_height) / 2;
++ allocation->height = arrow_height;
++ }
++
++ widget->allocation = *allocation;
++
+ if (!combo_box->priv->tree_view)
+ {
+ if (combo_box->priv->cell_view)
+@@ -1909,7 +2199,16 @@
+ child.width = child.x;
+ child.x = allocation->x
+ + border_width + xthickness + focus_width + focus_pad;
+- child.width -= child.x;
++ child.width -= child.x + xthickness;
++ }
++
++ if (hildonlike)
++ {
++ gtk_widget_size_request(GTK_BIN(widget)->child, &child_req);
++ child.y += (child.height - child_req.height) / 2;
++ child.height = child_req.height;
++ gtk_widget_hide(combo_box->priv->separator);
++ gtk_widget_hide(combo_box->priv->arrow);
+ }
+
+ child.width = MAX (1, child.width);
+@@ -1928,6 +2227,11 @@
+ child.height = allocation->height;
+ child.width = MAX (1, child.width);
+ child.height = MAX (1, child.height);
++
++ /* HILDON quick fix */
++ if (hildonlike)
++ child.width = arrow_width;
++
+ gtk_widget_size_allocate (combo_box->priv->button, &child);
+
+ if (is_rtl)
+@@ -1938,6 +2242,13 @@
+ child.width = allocation->width - req.width;
+ child.width = MAX (1, child.width);
+ child.height = MAX (1, child.height);
++
++ if (hildonlike)
++ {
++ gtk_widget_size_request(GTK_BIN(widget)->child, &child_req);
++ child.y += (child.height - child_req.height) / 2;
++ child.height = child_req.height;
++ }
+ gtk_widget_size_allocate (GTK_BIN (widget)->child, &child);
+ }
+ }
+@@ -1990,6 +2301,11 @@
+ GTK_WIDGET (combo_box->priv->cell_view_frame)->style->ythickness);
+ }
+ }
++
++ gtk_widget_size_request(GTK_BIN(widget)->child, &child_req);
++
++ child.y += (child.height - child_req.height) / 2;
++ child.height = child_req.height;
+
+ child.width = MAX (1, child.width);
+ child.height = MAX (1, child.height);
+@@ -2036,6 +2352,8 @@
+ gtk_cell_view_set_displayed_row (GTK_CELL_VIEW (combo_box->priv->cell_view), NULL);
+ }
+
++
++
+ static void
+ gtk_combo_box_forall (GtkContainer *container,
+ gboolean include_internals,
+@@ -2057,6 +2375,46 @@
+ }
+
+ static gboolean
++gtk_combo_box_focus_in (GtkWidget *widget,
++ GdkEventFocus *event)
++{
++ g_return_val_if_fail( widget, FALSE );
++
++ if ( !GTK_CONTAINER( widget )->focus_child )
++ {
++ gtk_combo_box_grab_focus ( GTK_WIDGET(widget) );
++ return TRUE;
++ }
++ return FALSE;
++}
++
++static gint
++gtk_combo_box_focus (GtkWidget *widget,
++ GtkDirectionType dir)
++{
++ g_return_val_if_fail (widget, FALSE);
++ if (GTK_WIDGET_HAS_FOCUS(widget)||GTK_CONTAINER(widget)->focus_child)
++ return FALSE;
++
++ gtk_widget_grab_focus (widget);
++ return TRUE;
++}
++
++static void
++gtk_combo_box_child_focus_in (GtkWidget * widget,
++ GdkEventFocus *event)
++{
++ gtk_widget_event( widget, (GdkEvent*)event );
++}
++
++static void
++gtk_combo_box_child_focus_out (GtkWidget * widget,
++ GdkEventFocus *event)
++{
++ gtk_widget_event( widget, (GdkEvent*)event );
++}
++
++static gboolean
+ gtk_combo_box_expose_event (GtkWidget *widget,
+ GdkEventExpose *event)
+ {
+@@ -2357,11 +2715,13 @@
+ gboolean add_children)
+ {
+ GtkWidget *menu;
++ gboolean hildonlike;
++
++ gtk_widget_style_get (GTK_WIDGET (combo_box), "hildonlike", &hildonlike, NULL);
+
+ if (combo_box->priv->cell_view)
+ {
+ combo_box->priv->button = gtk_toggle_button_new ();
+-
+ g_signal_connect (combo_box->priv->button, "toggled",
+ G_CALLBACK (gtk_combo_box_button_toggled), combo_box);
+ g_signal_connect_after (combo_box->priv->button,
+@@ -2400,6 +2760,9 @@
+ gtk_widget_show_all (combo_box->priv->button);
+ }
+
++ g_signal_connect_swapped (combo_box->priv->button, "focus_in_event", G_CALLBACK (gtk_combo_box_child_focus_in), combo_box);
++ g_signal_connect_swapped (combo_box->priv->button, "focus_out_event", G_CALLBACK (gtk_combo_box_child_focus_out), combo_box);
++
+ g_signal_connect (combo_box->priv->button, "button_press_event",
+ G_CALLBACK (gtk_combo_box_menu_button_press),
+ combo_box);
+@@ -2749,6 +3112,9 @@
+ {
+ GtkComboBox *combo_box = GTK_COMBO_BOX (user_data);
+
++ /* Hildon hack: sets the popup button sensitive if we have items in the list */
++ hildon_check_autodim(combo_box);
++
+ gtk_tree_row_reference_inserted (G_OBJECT (user_data), path);
+
+ if (combo_box->priv->tree_view)
+@@ -2783,7 +3149,10 @@
+ if (combo_box->priv->tree_view)
+ gtk_combo_box_list_popup_resize (combo_box);
+ else
+- gtk_combo_box_menu_row_deleted (model, path, user_data);
++ gtk_combo_box_menu_row_deleted (model, path, user_data);
++
++ /* Hildon hack: dim the popup button in case item count reaches 0 */
++ hildon_check_autodim(combo_box);
+ }
+
+ static void
+@@ -3458,10 +3827,46 @@
+ gboolean found;
+ GtkTreeIter iter;
+ GtkTreeIter new_iter;
++ gboolean hildonlike;
++ gint index = gtk_combo_box_get_active (combo_box);
++ gint new_index;
++ gint items = 0;
+
+ if (combo_box->priv->model == NULL)
+ return FALSE;
+
++ items = gtk_tree_model_iter_n_children (combo_box->priv->model, NULL);
++
++ gtk_widget_style_get (GTK_WIDGET (combo_box), "hildonlike",
++ &hildonlike, NULL);
++
++ /* Hildon select key */
++ if (hildonlike)
++ {
++ if (event->keyval == GDK_KP_Enter || event->keyval == GDK_Return)
++ {
++ gtk_combo_box_popup (combo_box);
++ return TRUE;
++ }
++ else if (event->keyval == GDK_Left && items != 0)
++ {
++ new_index = (index == 0) ? items - 1 : index - 1;
++ gtk_combo_box_set_active (combo_box, new_index);
++ return TRUE;
++ }
++ else if (event->keyval == GDK_Right && items != 0)
++ {
++ new_index = (index == items - 1) ? 0 : index + 1;
++ gtk_combo_box_set_active (combo_box, new_index);
++ return TRUE;
++ }
++ else if ((event->keyval == GDK_Down || event->keyval == GDK_KP_Down)
++ || (event->keyval == GDK_Up || event->keyval == GDK_KP_Up))
++ {
++ return FALSE;
++ }
++ }
++
+ if ((event->keyval == GDK_Down || event->keyval == GDK_KP_Down) &&
+ state == GDK_MOD1_MASK)
+ {
+@@ -3714,7 +4119,7 @@
+
+ combo_box = GTK_COMBO_BOX (layout);
+
+- g_object_ref (cell);
++ g_object_ref (G_OBJECT (cell));
+ gtk_object_sink (GTK_OBJECT (cell));
+
+ info = g_new0 (ComboCellInfo, 1);
+@@ -3771,7 +4176,7 @@
+
+ combo_box = GTK_COMBO_BOX (layout);
+
+- g_object_ref (cell);
++ g_object_ref (G_OBJECT (cell));
+ gtk_object_sink (GTK_OBJECT (cell));
+
+ info = g_new0 (ComboCellInfo, 1);
+@@ -3833,7 +4238,7 @@
+ ComboCellInfo *info = (ComboCellInfo *)i->data;
+
+ gtk_combo_box_cell_layout_clear_attributes (layout, info->cell);
+- g_object_unref (info->cell);
++ g_object_unref (G_OBJECT (info->cell));
+ g_free (info);
+ i->data = NULL;
+ }
+@@ -3922,7 +4327,7 @@
+
+ if (GTK_IS_MENU_ITEM (parent) &&
+ gtk_menu_item_get_submenu (GTK_MENU_ITEM (parent)))
+- g_object_set (cell, "sensitive", TRUE, NULL);
++ g_object_set (G_OBJECT (cell), "sensitive", TRUE, NULL);
+ }
+
+
+@@ -4137,7 +4542,7 @@
+ GtkWidget *
+ gtk_combo_box_new (void)
+ {
+- return g_object_new (GTK_TYPE_COMBO_BOX, NULL);
++ return GTK_WIDGET (g_object_new (GTK_TYPE_COMBO_BOX, NULL));
+ }
+
+ /**
+@@ -4157,7 +4562,9 @@
+
+ g_return_val_if_fail (GTK_IS_TREE_MODEL (model), NULL);
+
+- combo_box = g_object_new (GTK_TYPE_COMBO_BOX, "model", model, NULL);
++ combo_box = GTK_COMBO_BOX (g_object_new (GTK_TYPE_COMBO_BOX,
++ "model", model,
++ NULL));
+
+ return GTK_WIDGET (combo_box);
+ }
+@@ -4512,6 +4919,7 @@
+ if (!model)
+ {
+ gtk_combo_box_unset_model (combo_box);
++ hildon_check_autodim(combo_box);
+ return;
+ }
+
+@@ -4524,7 +4932,7 @@
+ gtk_combo_box_unset_model (combo_box);
+
+ combo_box->priv->model = model;
+- g_object_ref (combo_box->priv->model);
++ g_object_ref (G_OBJECT (combo_box->priv->model));
+
+ combo_box->priv->inserted_id =
+ g_signal_connect (combo_box->priv->model, "row_inserted",
+@@ -4561,6 +4969,8 @@
+ if (combo_box->priv->cell_view)
+ gtk_cell_view_set_model (GTK_CELL_VIEW (combo_box->priv->cell_view),
+ combo_box->priv->model);
++
++ hildon_check_autodim(combo_box);
+ }
+
+ /**
+@@ -5140,3 +5550,33 @@
+
+ return combo->priv->focus_on_click;
+ }
++/* Hildon addition:
++ * This is added, because we need to be able grab focus for our widget.
++ * Focus grabbing can happen it two ways: If we are using combobox entry
++ * we grab entry widget focus, otherwise togglebutton focus
++ */
++static void gtk_combo_box_grab_focus (GtkWidget *focus_widget)
++{
++ GtkComboBox *combo_box;
++ GtkComboBoxEntry *combo_entry;
++ gboolean hildonlike;
++
++ combo_box = GTK_COMBO_BOX (focus_widget);
++
++ gtk_widget_style_get (focus_widget, "hildonlike",
++ &hildonlike, NULL);
++
++ if (hildonlike)
++ {
++ /* Are we in entry mode ? */
++ if ( GTK_IS_COMBO_BOX_ENTRY(combo_box))
++ {
++ combo_entry = GTK_COMBO_BOX_ENTRY (combo_box);
++ gtk_grab_combo_box_entry_focus (combo_entry);
++ }
++ else
++ {
++ gtk_widget_grab_focus (combo_box->priv->button);
++ }
++ }
++}
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcomboboxentry.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcomboboxentry.c.diff
index e69de29bb2..43a861abd6 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcomboboxentry.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcomboboxentry.c.diff
@@ -0,0 +1,24 @@
+--- gtk+-2.6.4/gtk/gtkcomboboxentry.c 2004-11-20 01:18:37.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkcomboboxentry.c 2005-04-06 16:19:36.407003656 +0300
+@@ -55,6 +55,8 @@
+ gpointer user_data);
+ static gboolean gtk_combo_box_entry_mnemonic_activate (GtkWidget *entry,
+ gboolean group_cycling);
++/*static void gtk_grab_combo_box_entry_focus (GtkComboBoxEntry *entry_box);*/
++
+ static void has_frame_changed (GtkComboBoxEntry *entry_box,
+ GParamSpec *pspec,
+ gpointer data);
+@@ -382,3 +384,12 @@
+
+ return entry_box;
+ }
++
++/* Hildon: this is added because we need to grab focus from caption control
++ * to ComboBox entry.
++ */
++void
++gtk_grab_combo_box_entry_focus (GtkComboBoxEntry *entry_box)
++{
++ gtk_widget_grab_focus (entry_box->priv->entry);
++}
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcontainer.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcontainer.c.diff
index e69de29bb2..abd251bdcb 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcontainer.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcontainer.c.diff
@@ -0,0 +1,284 @@
+--- gtk+-2.6.4/gtk/gtkcontainer.c 2005-03-01 08:28:55.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkcontainer.c 2005-04-06 16:19:36.410003200 +0300
+@@ -37,10 +37,13 @@
+ #include "gtkwindow.h"
+ #include "gtkintl.h"
+ #include "gtktoolbar.h"
++#include "gtkmenu.h"
++#include "gtkentry.h"
++#include "gtktextview.h"
++#include "gtkwidget.h"
+ #include <gobject/gobjectnotifyqueue.c>
+ #include <gobject/gvaluecollector.h>
+
+-
+ enum {
+ ADD,
+ REMOVE,
+@@ -56,6 +59,19 @@
+ PROP_CHILD
+ };
+
++enum {
++ FOCUS_MOVE_OK,
++ FOCUS_MOVE_OK_NO_MOVE,
++ FOCUS_MOVE_FAIL_NO_TEXT
++};
++
++typedef struct
++{
++ GtkWidget *menu;
++ void *func;
++ GtkWidgetTapAndHoldFlags flags;
++} GtkContainerTAH;
++
+ #define PARAM_SPEC_PARAM_ID(pspec) ((pspec)->param_id)
+ #define PARAM_SPEC_SET_PARAM_ID(pspec, id) ((pspec)->param_id = (id))
+
+@@ -87,6 +103,9 @@
+ static gboolean gtk_container_focus_move (GtkContainer *container,
+ GList *children,
+ GtkDirectionType direction);
++static gint gtk_container_focus_move_with_tab (GtkContainer *container,
++ GtkDirectionType direction,
++ GtkWidget **fallback);
+ static void gtk_container_children_callback (GtkWidget *widget,
+ gpointer client_data);
+ static void gtk_container_show_all (GtkWidget *widget);
+@@ -95,10 +114,14 @@
+ GdkEventExpose *event);
+ static void gtk_container_map (GtkWidget *widget);
+ static void gtk_container_unmap (GtkWidget *widget);
+-
++static void gtk_container_tap_and_hold_setup (GtkWidget *widget,
++ GtkWidget *menu, GtkCallback func, GtkWidgetTapAndHoldFlags flags);
+ static gchar* gtk_container_child_default_composite_name (GtkContainer *container,
+ GtkWidget *child);
++static void gtk_container_tap_and_hold_setup_forall( GtkWidget *widget,
++ GtkContainerTAH *tah );
+
++static void gtk_container_grab_focus( GtkWidget *focus_widget );
+
+ /* --- variables --- */
+ static const gchar vadjustment_key[] = "gtk-vadjustment";
+@@ -190,7 +213,9 @@
+ widget_class->map = gtk_container_map;
+ widget_class->unmap = gtk_container_unmap;
+ widget_class->focus = gtk_container_focus;
+-
++ widget_class->tap_and_hold_setup = gtk_container_tap_and_hold_setup;
++ widget_class->grab_focus = gtk_container_grab_focus;
++
+ class->add = gtk_container_add_unimplemented;
+ class->remove = gtk_container_remove_unimplemented;
+ class->check_resize = gtk_container_real_check_resize;
+@@ -2011,6 +2036,24 @@
+ GtkWidget *focus_child;
+ GtkWidget *child;
+
++ /*
++ * If there's an item focus already and tab was pressed, only go thru
++ * GtkEntries and GtkTextviews. Do _not_ jump from last widget to the first
++ * one and vice verca.
++ */
++ if ((direction == GTK_DIR_TAB_FORWARD || direction == GTK_DIR_TAB_BACKWARD) &&
++ container->focus_child != NULL)
++ {
++ GtkWidget *fallback;
++ fallback = NULL;
++ if (gtk_container_focus_move_with_tab (container, direction, &fallback)
++ != FOCUS_MOVE_FAIL_NO_TEXT)
++ return TRUE;
++
++ if (fallback && gtk_widget_child_focus (fallback, direction))
++ return TRUE;
++ }
++
+ focus_child = container->focus_child;
+
+ while (children)
+@@ -2019,7 +2062,7 @@
+ children = children->next;
+
+ if (!child)
+- continue;
++ continue;
+
+ if (focus_child)
+ {
+@@ -2027,8 +2070,8 @@
+ {
+ focus_child = NULL;
+
+- if (gtk_widget_child_focus (child, direction))
+- return TRUE;
++ if (gtk_widget_child_focus (child, direction))
++ return TRUE;
+ }
+ }
+ else if (GTK_WIDGET_DRAWABLE (child) &&
+@@ -2042,6 +2085,105 @@
+ return FALSE;
+ }
+
++static gint
++gtk_container_focus_move_with_tab (GtkContainer *container,
++ GtkDirectionType direction,
++ GtkWidget **fallback)
++{
++ GList *children, *sorted_children;
++ GtkWidget *child;
++ GtkWidget *focus_child;
++ gboolean found_text;
++ gint ret;
++
++ found_text = FALSE;
++ focus_child = container->focus_child;
++
++ /* This part is copied from gtk_container_focus() */
++ if (container->has_focus_chain)
++ children = g_list_copy (get_focus_chain (container));
++ else
++ children = gtk_container_get_all_children (container);
++
++ if (container->has_focus_chain &&
++ (direction == GTK_DIR_TAB_FORWARD ||
++ direction == GTK_DIR_TAB_BACKWARD))
++ {
++ sorted_children = g_list_copy (children);
++
++ if (direction == GTK_DIR_TAB_BACKWARD)
++ sorted_children = g_list_reverse (sorted_children);
++ }
++ else
++ sorted_children = _gtk_container_focus_sort (container, children,
++ direction, NULL);
++ g_list_free(children);
++ children = sorted_children;
++
++ while (children)
++ {
++ child = children->data;
++ children = children->next;
++
++ if (!child)
++ continue;
++
++ if (GTK_IS_ENTRY (child) || GTK_IS_TEXT_VIEW (child))
++ found_text = TRUE;
++
++ if (focus_child)
++ {
++ if (child == focus_child)
++ {
++ focus_child = NULL;
++ if (GTK_IS_CONTAINER (child))
++ {
++ ret = gtk_container_focus_move_with_tab (GTK_CONTAINER (child),
++ direction,
++ fallback);
++ if (ret == FOCUS_MOVE_OK)
++ {
++ g_list_free (sorted_children);
++ return FOCUS_MOVE_OK;
++ }
++ else if (ret == FOCUS_MOVE_OK_NO_MOVE)
++ found_text = TRUE;
++ }
++ }
++ }
++ else if (GTK_WIDGET_DRAWABLE (child) &&
++ gtk_widget_is_ancestor (child, GTK_WIDGET (container)))
++ {
++ if (GTK_IS_ENTRY (child) || GTK_IS_TEXT_VIEW (child))
++ {
++ if (gtk_widget_child_focus (child, direction))
++ {
++ g_list_free (sorted_children);
++ return FOCUS_MOVE_OK;
++ }
++ }
++ else if (GTK_IS_CONTAINER (child))
++ {
++ ret = gtk_container_focus_move_with_tab (GTK_CONTAINER (child),
++ direction,
++ fallback);
++ if (ret == FOCUS_MOVE_OK)
++ {
++ g_list_free (sorted_children);
++ return FOCUS_MOVE_OK;
++ }
++ else if (ret == FOCUS_MOVE_OK_NO_MOVE)
++ found_text = TRUE;
++ }
++ if (GTK_WIDGET_CAN_FOCUS (child) && *fallback == NULL)
++ *fallback = child;
++ }
++ }
++
++ g_list_free (sorted_children);
++
++ return found_text ? FOCUS_MOVE_OK_NO_MOVE : FOCUS_MOVE_FAIL_NO_TEXT;
++}
+
+ static void
+ gtk_container_children_callback (GtkWidget *widget,
+@@ -2463,3 +2605,58 @@
+ gdk_event_free (child_event);
+ }
+ }
++
++static void gtk_container_tap_and_hold_setup_forall( GtkWidget *widget,
++ GtkContainerTAH *tah )
++{
++ gtk_widget_tap_and_hold_setup( widget, tah->menu, tah->func,
++ tah->flags );
++}
++
++static void gtk_container_tap_and_hold_setup( GtkWidget *widget,
++ GtkWidget *menu, GtkCallback func, GtkWidgetTapAndHoldFlags flags )
++{
++ GtkContainerTAH tah;
++ g_return_if_fail( GTK_IS_WIDGET(widget));
++ g_return_if_fail( menu == NULL || GTK_IS_MENU(menu) );
++ tah.menu = menu;
++ tah.func = func;
++ tah.flags = flags;
++ if (flags & GTK_TAP_AND_HOLD_NO_INTERNALS)
++ gtk_container_foreach( GTK_CONTAINER(widget),
++ (GtkCallback)gtk_container_tap_and_hold_setup_forall, &tah );
++ else
++ gtk_container_forall( GTK_CONTAINER(widget),
++ (GtkCallback)gtk_container_tap_and_hold_setup_forall, &tah );
++ parent_class->tap_and_hold_setup (widget, menu, func, flags);
++}
++
++static void gtk_container_grab_focus( GtkWidget *focus_widget )
++{
++ if( GTK_WIDGET_CAN_FOCUS(focus_widget) )
++ parent_class->grab_focus( focus_widget );
++ else
++ {
++ GList *first = NULL;
++ GList *children = NULL;
++ GtkWidget *old_focus = NULL;
++ GtkWidget *toplevel = NULL;
++
++ toplevel = gtk_widget_get_toplevel( focus_widget );
++ if( !GTK_IS_WINDOW(toplevel) )
++ return;
++
++ old_focus = GTK_WINDOW(toplevel)->focus_widget;
++ first = gtk_container_get_all_children(
++ GTK_CONTAINER(focus_widget) );
++ children = g_list_last( first );
++
++ while( children && GTK_WINDOW(toplevel)->focus_widget == old_focus )
++ {
++ gtk_widget_grab_focus( GTK_WIDGET(children->data) );
++ children = children->prev;
++ }
++ g_list_free( first );
++ }
++}
++
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkdialog.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkdialog.c.diff
index e69de29bb2..39ecdf209b 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkdialog.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkdialog.c.diff
@@ -0,0 +1,451 @@
+--- gtk+-2.6.4/gtk/gtkdialog.c 2005-01-20 21:52:15.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkdialog.c 2005-04-06 16:19:36.416002288 +0300
+@@ -24,6 +24,9 @@
+ * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
+ */
+
++/* Modified for Nokia Oyj during 2002-2003. See CHANGES file for list
++ * of changes.
++ */
+ #include <config.h>
+ #include "gtkalias.h"
+ #include "gtkbutton.h"
+@@ -37,11 +40,14 @@
+ #include "gtkmain.h"
+ #include "gtkintl.h"
+ #include "gtkbindings.h"
++#include "gtkalignment.h"
+
+ #define GET_PRIVATE(obj) (G_TYPE_INSTANCE_GET_PRIVATE ((obj), GTK_TYPE_DIALOG, GtkDialogPrivate))
+
+ typedef struct {
+ guint ignore_separator : 1;
++ GtkWidget *first;
++ GtkWidget *last;
+ } GtkDialogPrivate;
+
+ typedef struct _ResponseData ResponseData;
+@@ -77,7 +83,18 @@
+ static void gtk_dialog_close (GtkDialog *dialog);
+
+ static ResponseData* get_response_data (GtkWidget *widget,
+- gboolean create);
++ gboolean create);
++
++static gboolean gtk_dialog_handle_focus (GtkWidget *widget,
++ GtkDirectionType dir,
++ gpointer user_data);
++
++static gboolean gtk_dialog_move_to_next_active_button (GList *iter,
++ gboolean forward);
++
++static GtkWidget *gtk_dialog_get_first_sensitive (GList *list);
++static GtkWidget *gtk_dialog_get_last_sensitive (GList *list);
++
+
+ enum {
+ PROP_0,
+@@ -195,6 +212,23 @@
+ 5,
+ G_PARAM_READABLE));
+
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("extended_left_border",
++ _("Content area extra left border"),
++ _("Width of extra left border around the main dialog area"),
++ 0,
++ G_MAXINT,
++ 0,
++ G_PARAM_READABLE));
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("extended_right_border",
++ _("Content area extra right border"),
++ _("Width of extra right border around the main dialog area"),
++ 0,
++ G_MAXINT,
++ 0,
++ G_PARAM_READABLE));
++
+ binding_set = gtk_binding_set_by_class (class);
+
+ gtk_binding_entry_add_signal (binding_set, GDK_Escape, 0,
+@@ -205,9 +239,15 @@
+ update_spacings (GtkDialog *dialog)
+ {
+ GtkWidget *widget;
++ GtkWidget *hbox;
++ GtkWidget *left_padding;
++ GtkWidget *right_padding;
+ gint content_area_border;
+ gint button_spacing;
+ gint action_area_border;
++
++ gint extended_left_border;
++ gint extended_right_border;
+
+ widget = GTK_WIDGET (dialog);
+
+@@ -218,6 +258,10 @@
+ &button_spacing,
+ "action_area_border",
+ &action_area_border,
++ "extended_left_border",
++ &extended_left_border,
++ "extended_right_border",
++ &extended_right_border,
+ NULL);
+
+ gtk_container_set_border_width (GTK_CONTAINER (dialog->vbox),
+@@ -226,12 +270,36 @@
+ button_spacing);
+ gtk_container_set_border_width (GTK_CONTAINER (dialog->action_area),
+ action_area_border);
++
++ if ((extended_left_border == 0) && (extended_right_border == 0))
++ /* no extended borders, so we are done */
++ return;
++
++ /* extended borders are in use, so reconstruct dialog */
++ hbox = gtk_hbox_new(FALSE, 0);
++ left_padding = gtk_alignment_new(0.0, 0.0, 0.0, 0.0);
++ right_padding = gtk_alignment_new(0.0, 0.0, 0.0, 0.0);
++ gtk_widget_set_size_request(left_padding, extended_left_border, 0);
++ gtk_widget_set_size_request(right_padding, extended_right_border, 0);
++
++ gtk_widget_ref(dialog->vbox);
++ gtk_container_remove(GTK_CONTAINER(dialog), dialog->vbox);
++ gtk_container_add(GTK_CONTAINER(hbox), left_padding);
++ gtk_container_add(GTK_CONTAINER(hbox), dialog->vbox);
++ gtk_container_add(GTK_CONTAINER(hbox), right_padding);
++ gtk_container_add(GTK_CONTAINER(dialog), hbox);
++ gtk_widget_unref(dialog->vbox);
++
++ gtk_widget_show(left_padding);
++ gtk_widget_show(right_padding);
++ gtk_widget_show(hbox);
+ }
+
+ static void
+ gtk_dialog_init (GtkDialog *dialog)
+ {
+ GtkDialogPrivate *priv;
++ GtkWidget *alignment;
+
+ priv = GET_PRIVATE (dialog);
+ priv->ignore_separator = FALSE;
+@@ -250,14 +318,23 @@
+ gtk_container_add (GTK_CONTAINER (dialog), dialog->vbox);
+ gtk_widget_show (dialog->vbox);
+
++ /* Hildon : Here we add an alignment widget to gtk because
++ * we want that the dialog buttons are all centered. */
++ alignment = gtk_alignment_new (0.5, 0.5, 0, 0);
++ gtk_box_pack_end (GTK_BOX (dialog->vbox), alignment, FALSE, TRUE, 0);
++
+ dialog->action_area = gtk_hbutton_box_new ();
+
+ gtk_button_box_set_layout (GTK_BUTTON_BOX (dialog->action_area),
+ GTK_BUTTONBOX_END);
+
+- gtk_box_pack_end (GTK_BOX (dialog->vbox), dialog->action_area,
+- FALSE, TRUE, 0);
++ /* we need add-signal to allocate correct area for childs */
++ gtk_container_add (GTK_CONTAINER (alignment), dialog->action_area);
++ /* gtk_box_pack_end (GTK_BOX (dialog->vbox), dialog->action_area,
++ FALSE, TRUE, 0); */
++
+ gtk_widget_show (dialog->action_area);
++ gtk_widget_show (alignment);
+
+ dialog->separator = gtk_hseparator_new ();
+ gtk_box_pack_end (GTK_BOX (dialog->vbox), dialog->separator, FALSE, TRUE, 0);
+@@ -616,9 +693,15 @@
+ else
+ g_warning ("Only 'activatable' widgets can be packed into the action area of a GtkDialog");
+
++ gtk_container_add(GTK_CONTAINER(dialog->action_area), child);
++/*
+ gtk_box_pack_end (GTK_BOX (dialog->action_area),
+ child,
+ FALSE, TRUE, 0);
++*/
++
++ g_signal_connect (child, "focus",
++ (GCallback)gtk_dialog_handle_focus, (gpointer)dialog);
+
+ if (response_id == GTK_RESPONSE_HELP)
+ gtk_button_box_set_child_secondary (GTK_BUTTON_BOX (dialog->action_area), child, TRUE);
+@@ -637,7 +720,7 @@
+ * you don't need it.
+ *
+ * Return value: the button widget that was added
+- **/
++ **/ /*ROK*/
+ GtkWidget*
+ gtk_dialog_add_button (GtkDialog *dialog,
+ const gchar *button_text,
+@@ -653,7 +736,10 @@
+ GTK_WIDGET_SET_FLAGS (button, GTK_CAN_DEFAULT);
+
+ gtk_widget_show (button);
+-
++
++ g_signal_connect (button, "focus",
++ (GCallback)gtk_dialog_handle_focus,
++ (gpointer)dialog);
+ gtk_dialog_add_action_widget (dialog,
+ button,
+ response_id);
+@@ -990,6 +1076,8 @@
+ gulong unmap_handler;
+ gulong destroy_handler;
+ gulong delete_handler;
++ GtkDialogPrivate *priv;
++ GList *list = NULL;
+
+ g_return_val_if_fail (GTK_IS_DIALOG (dialog), -1);
+
+@@ -1001,6 +1089,27 @@
+
+ if (!GTK_WIDGET_VISIBLE (dialog))
+ gtk_widget_show (GTK_WIDGET (dialog));
++
++ priv = GET_PRIVATE (dialog);
++ list = gtk_container_get_children (GTK_CONTAINER (dialog->vbox));
++ priv->first = gtk_dialog_get_first_sensitive (list);
++ priv->last = gtk_dialog_get_last_sensitive (list);
++
++ if (priv->first)
++ {
++ g_signal_connect (priv->first, "focus",
++ (GCallback)gtk_dialog_handle_focus,
++ (gpointer)dialog);
++ }
++
++ if (priv->last)
++ {
++ g_signal_connect (priv->last, "focus",
++ (GCallback)gtk_dialog_handle_focus,
++ (gpointer)dialog);
++ }
++
++ g_list_free (list);
+
+ response_handler =
+ g_signal_connect (dialog,
+@@ -1236,4 +1345,215 @@
+ gtk_box_reorder_child (GTK_BOX (dialog->action_area), child, position);
+ }
+ }
++static gboolean
++gtk_dialog_handle_focus (GtkWidget *widget,
++ GtkDirectionType dir,
++ gpointer user_data)
++ {
++ GtkDialog *dialog = NULL;
++ GList *list = NULL;
++ GList *iter = NULL;
++ gint i = 0;
++ gint list_length = 0;
++ gboolean ret_val = FALSE;
++ GtkDialogPrivate *priv;
++
++ dialog = GTK_DIALOG(user_data);
++ list = gtk_container_get_children (GTK_CONTAINER(
++ GTK_DIALOG(user_data)->action_area));
++ iter = list;
++ priv = GET_PRIVATE (dialog);
++
++ if (GTK_WIDGET_HAS_FOCUS (widget))
++ if (widget == priv->first)
++ {
++ if (dir == GTK_DIR_UP)
++ {
++ ret_val = gtk_dialog_move_to_next_active_button (g_list_last (list),
++ FALSE);
++ }
++ else if (dir == GTK_DIR_DOWN && priv->first == priv->last)
++ ret_val = gtk_dialog_move_to_next_active_button (list, TRUE);
++ else if (dir == GTK_DIR_DOWN)
++ {
++ }
++ }
++ else if (widget == priv->last)
++ {
++ if (dir == GTK_DIR_DOWN)
++ {
++ ret_val = gtk_dialog_move_to_next_active_button (list, TRUE);
++ }
++ else if (dir == GTK_DIR_UP)
++ {
++ }
++ }
++ else
++ {
++ list_length = g_list_length(list);
++ while (iter != NULL)
++ {
++ ++i;
++ if (iter->data == widget)
++ {
++ switch (dir) {
++ case GTK_DIR_UP:
++ /* If in the first item -> the default works like it should */
++
++ if (i > 1)
++ {
++ /* If not in the first button, but in the first active
++ * button, the default should do, else handle movement
++ * by yourself
++ */
++ ret_val = gtk_dialog_move_to_next_active_button (
++ g_list_previous (iter),
++ FALSE);
++ }
++ else
++ {
++ /* gtk_widget_grab_focus (priv->last);*/
++ g_signal_emit_by_name (dialog, "move-focus",
++ GTK_DIR_TAB_BACKWARD);
++ ret_val = TRUE;
++ }
++ break;
++
++ /* If in the last item:jump to top, else select previous button */
++ case GTK_DIR_DOWN:
++ if (i < list_length)
++ {
++ ret_val = gtk_dialog_move_to_next_active_button (
++ g_list_next (iter),
++ TRUE);
++ if (!ret_val)
++ {
++ g_signal_emit_by_name (dialog, "move-focus",
++ GTK_DIR_TAB_FORWARD);
++ ret_val = TRUE;
++ }
++ }
++ else
++ {
++ g_signal_emit_by_name (dialog, "move-focus",
++ GTK_DIR_TAB_FORWARD);
++ ret_val = TRUE;
++ }
++ break;
++
++ case GTK_DIR_TAB_BACKWARD:
++ case GTK_DIR_TAB_FORWARD:
++ case GTK_DIR_LEFT:
++ case GTK_DIR_RIGHT:
++ default:
++ break;
++ }
++ break;
++ }
++ iter = g_list_next(iter);
++ }
++ }
++
++ g_list_free (list);
++
++ return ret_val;
++ }
++static gboolean
++gtk_dialog_move_to_next_active_button (GList *iter, gboolean forward)
++{
++ gboolean active;
++ gboolean visible;
++
++ while (iter)
++ {
++ g_object_get (G_OBJECT (iter->data), "sensitive", &active, NULL);
++ g_object_get (G_OBJECT (iter->data), "visible", &visible, NULL);
++ if (active && visible)
++ {
++ gtk_widget_grab_focus (GTK_WIDGET (iter->data));
++ return TRUE;
++ }
++
++ if (forward)
++ iter = g_list_next (iter);
++ else
++ iter = g_list_previous (iter);
++ }
++
++ return FALSE;
++}
++static GtkWidget*
++gtk_dialog_get_first_sensitive (GList *list)
++{
++ GList *sublist = NULL;
++ GList *iter = NULL;
++ GtkWidget *widget = NULL;
++ gboolean active;
++ gboolean visible;
++ while (list)
++ {
++ widget = GTK_WIDGET (list->data);
++ if (GTK_IS_CONTAINER (widget))
++ {
++ sublist = gtk_container_get_children (GTK_CONTAINER(widget));
++ widget = gtk_dialog_get_first_sensitive (sublist);
++ g_list_free (sublist);
++ sublist = NULL;
++
++ if (widget)
++ return widget;
++ }
++ else
++ {
++ g_object_get (G_OBJECT (widget), "sensitive", &active, NULL);
++ g_object_get (G_OBJECT (widget), "visible", &visible, NULL);
++ if (active && visible && GTK_WIDGET_CAN_FOCUS (widget))
++ return widget;
++ }
++
++ list = g_list_next (list);
++ }
++
++ return NULL;
++}
++
++static GtkWidget*
++gtk_dialog_get_last_sensitive (GList *list)
++{
++ GList *sublist = NULL;
++ GtkWidget *widget = NULL;
++ gboolean active;
++ gboolean visible;
++
++ list = g_list_last (list);
++ if (list && list->prev != NULL)
++ list = g_list_previous (list);
++
++ while (list)
++ {
++ widget = GTK_WIDGET (list->data);
++ if (GTK_IS_CONTAINER (widget))
++ {
++ sublist = gtk_container_get_children (GTK_CONTAINER(widget));
++ widget = gtk_dialog_get_last_sensitive (sublist);
++ g_list_free (sublist);
++ sublist = NULL;
++
++ if (widget)
++ return widget;
++ }
++ else
++ {
++ g_object_get (G_OBJECT (widget), "sensitive", &active, NULL);
++ g_object_get (G_OBJECT (widget), "visible", &visible, NULL);
++ if (active && visible && GTK_WIDGET_CAN_FOCUS (widget))
++ return widget;
++ }
++
++ list = g_list_previous (list);
++ }
++
++ return NULL;
++}
++
+
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkdnd.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkdnd.c.diff
index e69de29bb2..247d3f9b46 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkdnd.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkdnd.c.diff
@@ -0,0 +1,12 @@
+--- gtk+-2.6.4/gtk/gtkdnd.c 2005-02-01 20:07:40.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkdnd.c 2005-04-06 16:19:36.432999704 +0300
+@@ -2145,6 +2145,9 @@
+ g_signal_connect (widget, "button_press_event",
+ G_CALLBACK (gtk_drag_source_event_cb),
+ site);
++ g_signal_connect (widget, "button_release_event",
++ G_CALLBACK (gtk_drag_source_event_cb),
++ site);
+ g_signal_connect (widget, "motion_notify_event",
+ G_CALLBACK (gtk_drag_source_event_cb),
+ site);
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkentry.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkentry.c.diff
index e69de29bb2..fae911305c 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkentry.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkentry.c.diff
@@ -0,0 +1,1308 @@
+--- gtk+-2.6.4/gtk/gtkentry.c 2005-02-04 17:36:02.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkentry.c 2005-04-06 16:19:36.466994536 +0300
+@@ -24,6 +24,10 @@
+ * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
+ */
+
++ /* Modified for Nokia Oyj during 2002-2003. See CHANGES file for list
++ * of changes.
++ */
++
+ #include <config.h>
+ #include <string.h>
+
+@@ -53,6 +57,7 @@
+ #include "gtktreeselection.h"
+ #include "gtkentryprivate.h"
+ #include "gtkcelllayout.h"
++#include "gtkscrolledwindow.h"
+
+ #define GTK_ENTRY_COMPLETION_KEY "gtk-entry-completion-key"
+
+@@ -60,6 +65,8 @@
+ #define DRAW_TIMEOUT 20
+ #define INNER_BORDER 2
+ #define COMPLETION_TIMEOUT 300
++#define HILDON_EDITED_CHARACTER_MAX 8
++#define HILDON_EDITED_CHARACTER_MS 600 /* 0.6 seconds */
+
+ /* Initial size of buffer, in bytes */
+ #define MIN_SIZE 16
+@@ -75,6 +82,18 @@
+ {
+ gfloat xalign;
+ gint insert_pos;
++ /* Hildon additions:
++ * following variables are needed
++ * for Hildon password 'preview'
++ * functionality; last inputted character
++ * is showed for defined period, before it is
++ * rendered to '*'
++ */
++ gchar hildon_edited_character[HILDON_EDITED_CHARACTER_MAX];
++ gboolean hildon_edited_character_timeout;
++ gint hildon_edited_character_length;
++ gboolean keep_focus;
++ gboolean menu_popped;
+ };
+
+ enum {
+@@ -104,7 +123,9 @@
+ PROP_WIDTH_CHARS,
+ PROP_SCROLL_OFFSET,
+ PROP_TEXT,
+- PROP_XALIGN
++ PROP_XALIGN,
++ PROP_AUTOCAP,
++ PROP_INPUT_MODE
+ };
+
+ static guint signals[LAST_SIGNAL] = { 0 };
+@@ -324,6 +345,23 @@
+ gint *y,
+ gint *width,
+ gint *height);
++static void gtk_entry_update_scrolled_window (GtkEntry *entry);
++static void gtk_entry_set_autocap (GtkEntry *entry,
++ gboolean autocap);
++static gboolean gtk_entry_get_autocap (GtkEntry *entry);
++static void gtk_entry_set_input_mode (GtkEntry *entry,
++ gboolean mode);
++static gint gtk_entry_get_input_mode (GtkEntry *entry);
++
++/*Change for Hildon
++ *returns an iterator to the character at position x,y of the
++ *layout
++ *returns NULL if no iterator was found at that position
++ *Caller must call pango_layout_free_iter on the returned iterator
++ */
++static PangoLayoutIter *get_char_at_pos( PangoLayout *layout, gint x, gint y );
++
++static gboolean hildon_remove_visible_character( gpointer data );
+
+ /* Completion */
+ static gint gtk_entry_completion_timeout (gpointer data);
+@@ -523,7 +561,25 @@
+ P_("FALSE displays the \"invisible char\" instead of the actual text (password mode)"),
+ TRUE,
+ G_PARAM_READABLE | G_PARAM_WRITABLE));
+-
++
++ g_object_class_install_property (gobject_class,
++ PROP_AUTOCAP,
++ g_param_spec_boolean ("autocap",
++ P_("auto capitalization"),
++ P_("Enable autocap support"),
++ TRUE,
++ G_PARAM_READABLE | G_PARAM_WRITABLE));
++
++ g_object_class_install_property (gobject_class,
++ PROP_INPUT_MODE,
++ g_param_spec_int ("input_mode",
++ P_("input mode"),
++ P_("Define widget's input mode"),
++ 0,
++ 9, /* keep me updated */
++ 0,
++ G_PARAM_READABLE | G_PARAM_WRITABLE));
++
+ g_object_class_install_property (gobject_class,
+ PROP_HAS_FRAME,
+ g_param_spec_boolean ("has_frame",
+@@ -593,6 +649,40 @@
+ 0.0,
+ G_PARAM_READABLE | G_PARAM_WRITABLE));
+
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("horizontal-border",
++ P_("Horizontal borders for entry"),
++ P_("Set left/right borders"),
++ 0,
++ G_MAXINT,
++ INNER_BORDER,
++ G_PARAM_READWRITE));
++
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("vertical-border",
++ P_("Vertical borders for entry"),
++ P_("Set top/bottom borders"),
++ 0,
++ G_MAXINT,
++ INNER_BORDER,
++ G_PARAM_READWRITE));
++
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("icon-width",
++ P_("Icon Width"),
++ P_("Size of the purpose icon."),
++ 0,
++ G_MAXINT,
++ 0,
++ G_PARAM_READWRITE));
++
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_boolean ("show-last-char",
++ P_("Show last char in invisible mode for a while"),
++ P_("Last char is shown before it is rendered to asterisk"),
++ FALSE,
++ G_PARAM_READABLE | G_PARAM_WRITABLE));
++
+ signals[POPULATE_POPUP] =
+ g_signal_new ("populate_popup",
+ G_OBJECT_CLASS_TYPE (gobject_class),
+@@ -853,6 +943,22 @@
+ iface->start_editing = gtk_entry_start_editing;
+ }
+
++/* HILDON: Timed function to hide the most recently inputted character in password mode
++*/
++static gboolean
++ hildon_remove_visible_character( gpointer data )
++{
++ g_return_val_if_fail (GTK_IS_WIDGET (data), FALSE);
++
++ GtkEntry * entry = GTK_ENTRY( data );
++
++ /* Force the string to redrawn, but now without a visible character */
++ gtk_entry_recompute( entry );
++
++ /* Return false so this timeout is not called again and destroyed */
++ return FALSE;
++}
++
+ static void
+ gtk_entry_set_property (GObject *object,
+ guint prop_id,
+@@ -867,9 +973,10 @@
+ {
+ gboolean new_value = g_value_get_boolean (value);
+
++ gtk_widget_set_sensitive( GTK_WIDGET( entry ), entry->editable );
+ if (new_value != entry->editable)
+ {
+- if (!new_value)
++ if (!new_value)
+ {
+ gtk_entry_reset_im_context (entry);
+ if (GTK_WIDGET_HAS_FOCUS (entry))
+@@ -896,6 +1003,14 @@
+ case PROP_VISIBILITY:
+ gtk_entry_set_visibility (entry, g_value_get_boolean (value));
+ break;
++
++ case PROP_AUTOCAP:
++ gtk_entry_set_autocap (entry, g_value_get_boolean (value));
++ break;
++
++ case PROP_INPUT_MODE:
++ gtk_entry_set_input_mode (entry, g_value_get_int (value));
++ break;
+
+ case PROP_HAS_FRAME:
+ gtk_entry_set_has_frame (entry, g_value_get_boolean (value));
+@@ -954,6 +1069,12 @@
+ case PROP_VISIBILITY:
+ g_value_set_boolean (value, entry->visible);
+ break;
++ case PROP_AUTOCAP:
++ g_value_set_boolean (value, gtk_entry_get_autocap (entry));
++ break;
++ case PROP_INPUT_MODE:
++ g_value_set_int (value, gtk_entry_get_input_mode (entry));
++ break;
+ case PROP_HAS_FRAME:
+ g_value_set_boolean (value, entry->has_frame);
+ break;
+@@ -1000,7 +1121,20 @@
+ entry->width_chars = -1;
+ entry->is_cell_renderer = FALSE;
+ entry->editing_canceled = FALSE;
+- entry->has_frame = TRUE;
++#ifdef HILDON_SINGLE_LINE_EDITOR
++ entry->has_frame = FALSE;
++#else
++ entry->has_frame = TRUE;
++#endif
++
++ /* Hildon */
++ memset( &priv->hildon_edited_character, 0x00, HILDON_EDITED_CHARACTER_MAX );
++ priv->hildon_edited_character_length = 0;
++ priv->hildon_edited_character_timeout = FALSE;
++
++ priv->keep_focus = FALSE;
++ priv->menu_popped = FALSE;
++
+ priv->xalign = 0.0;
+
+ gtk_drag_dest_set (GTK_WIDGET (entry),
+@@ -1013,6 +1147,10 @@
+ * to it; so we create it here and destroy it in finalize().
+ */
+ entry->im_context = gtk_im_multicontext_new ();
++ /* Set default stuff. */
++ gtk_entry_set_autocap (entry, TRUE);
++ gtk_entry_set_input_mode (entry, 0); /* alpha-numeric-special */
++ g_object_set (G_OBJECT (entry->im_context), "use-show-hide", TRUE, NULL);
+
+ g_signal_connect (entry->im_context, "commit",
+ G_CALLBACK (gtk_entry_commit_cb), entry);
+@@ -1058,7 +1196,8 @@
+ gtk_entry_finalize (GObject *object)
+ {
+ GtkEntry *entry = GTK_ENTRY (object);
+-
++ GtkEntryPrivate *priv = GTK_ENTRY_GET_PRIVATE (GTK_WIDGET (entry));
++
+ gtk_entry_set_completion (entry, NULL);
+
+ if (entry->cached_layout)
+@@ -1072,6 +1211,9 @@
+ if (entry->recompute_idle)
+ g_source_remove (entry->recompute_idle);
+
++ if (priv->hildon_edited_character_timeout)
++ g_source_remove (priv->hildon_edited_character_timeout);
++
+ entry->text_size = 0;
+
+ if (entry->text)
+@@ -1213,7 +1355,14 @@
+ PangoFontMetrics *metrics;
+ gint xborder, yborder;
+ PangoContext *context;
+-
++ gint border_x, border_y;
++ gint icon_width;
++
++ gtk_widget_style_get (widget,
++ "horizontal-border", &border_x,
++ "vertical-border", &border_y,
++ "icon-width", &icon_width, NULL);
++
+ gtk_widget_ensure_style (widget);
+ context = gtk_widget_get_pango_context (widget);
+ metrics = pango_context_get_metrics (context,
+@@ -1225,21 +1374,22 @@
+
+ _gtk_entry_get_borders (entry, &xborder, &yborder);
+
+- xborder += INNER_BORDER;
+- yborder += INNER_BORDER;
++ xborder += border_x<<1;
++ yborder += border_y<<1;
+
+ if (entry->width_chars < 0)
+- requisition->width = MIN_ENTRY_WIDTH + xborder * 2;
++ requisition->width = MIN_ENTRY_WIDTH + xborder;
+ else
+ {
+ gint char_width = pango_font_metrics_get_approximate_char_width (metrics);
+ gint digit_width = pango_font_metrics_get_approximate_digit_width (metrics);
+ gint char_pixels = (MAX (char_width, digit_width) + PANGO_SCALE - 1) / PANGO_SCALE;
+
+- requisition->width = char_pixels * entry->width_chars + xborder * 2;
++ requisition->width = char_pixels * entry->width_chars + xborder;
+ }
+-
+- requisition->height = PANGO_PIXELS (entry->ascent + entry->descent) + yborder * 2;
++
++ requisition->width += icon_width;
++ requisition->height = PANGO_PIXELS (entry->ascent + entry->descent) + yborder;
+
+ pango_font_metrics_unref (metrics);
+ }
+@@ -1253,23 +1403,39 @@
+ {
+ gint xborder, yborder;
+ GtkRequisition requisition;
++ gint icon_width;
+ GtkWidget *widget = GTK_WIDGET (entry);
+
++ gtk_widget_style_get (widget, "icon-width", &icon_width, NULL);
++
+ gtk_widget_get_child_requisition (widget, &requisition);
+
+ _gtk_entry_get_borders (entry, &xborder, &yborder);
+
+ if (x)
+- *x = xborder;
++ *x = xborder + icon_width;
+
+ if (y)
++ {
+ *y = yborder;
++ if( widget->allocation.height < requisition.height )
++ *y += ((widget->allocation.height - requisition.height) / 2);
++ if( *y < yborder )
++ *y = yborder;
++ }
+
+ if (width)
+- *width = GTK_WIDGET (entry)->allocation.width - xborder * 2;
++ *width = GTK_WIDGET (entry)->allocation.width - xborder * 2 - icon_width;
+
+ if (height)
+- *height = requisition.height - yborder * 2;
++ {
++ if( widget->allocation.height < requisition.height )
++ *height = widget->allocation.height - yborder * 2;
++ else
++ *height = widget->requisition.height - yborder * 2;
++ if( *height <=0 )
++ *height = 1;
++ }
+ }
+
+ static void
+@@ -1289,10 +1455,9 @@
+
+ if (y)
+ {
+- if (entry->is_cell_renderer)
+- *y = widget->allocation.y;
+- else
+- *y = widget->allocation.y + (widget->allocation.height - requisition.height) / 2;
++ *y = widget->allocation.y;
++ if( widget->allocation.height > requisition.height )
++ *y += ((widget->allocation.height - requisition.height) / 2);
+ }
+
+ if (width)
+@@ -1300,10 +1465,10 @@
+
+ if (height)
+ {
+- if (entry->is_cell_renderer)
+- *height = widget->allocation.height;
+- else
++ if( widget->allocation.height > requisition.height )
+ *height = requisition.height;
++ else
++ *height = widget->allocation.height;
+ }
+ }
+
+@@ -1383,20 +1548,19 @@
+ GdkEventExpose *event)
+ {
+ GtkEntry *entry = GTK_ENTRY (widget);
++ gint area_width, area_height;
++
++ get_widget_window_size (entry, NULL, NULL, &area_width, &area_height);
+
+ if (widget->window == event->window)
+- gtk_entry_draw_frame (widget);
++ {
++ gtk_paint_box (widget->style, widget->window,
++ GTK_WIDGET_STATE (widget), GTK_SHADOW_NONE,
++ NULL, widget, "entry_frame",
++ 0, 0, area_width, area_height);
++ }
+ else if (entry->text_area == event->window)
+ {
+- gint area_width, area_height;
+-
+- get_text_area_size (entry, NULL, NULL, &area_width, &area_height);
+-
+- gtk_paint_flat_box (widget->style, entry->text_area,
+- GTK_WIDGET_STATE(widget), GTK_SHADOW_NONE,
+- NULL, widget, "entry_bg",
+- 0, 0, area_width, area_height);
+-
+ if ((entry->visible || entry->invisible_char != 0) &&
+ GTK_WIDGET_HAS_FOCUS (widget) &&
+ entry->selection_bound == entry->current_pos && entry->cursor_visible)
+@@ -1490,16 +1654,19 @@
+ return FALSE;
+
+ entry->button = event->button;
+-
++
+ if (!GTK_WIDGET_HAS_FOCUS (widget))
+ {
+ entry->in_click = TRUE;
+ gtk_widget_grab_focus (widget);
+ entry->in_click = FALSE;
+ }
+-
++
++ /* Hildon: we need to reset IM context so pre-edit string can be committed */
++ gtk_entry_reset_im_context (entry);
++
+ tmp_pos = gtk_entry_find_position (entry, event->x + entry->scroll_offset);
+-
++
+ if (event->button == 1)
+ {
+ gboolean have_selection = gtk_editable_get_selection_bounds (editable, &sel_start, &sel_end);
+@@ -1509,8 +1676,6 @@
+
+ if (event->state & GDK_SHIFT_MASK)
+ {
+- gtk_entry_reset_im_context (entry);
+-
+ if (!have_selection) /* select from the current position to the clicked position */
+ sel_start = sel_end = entry->current_pos;
+
+@@ -1575,9 +1740,20 @@
+ entry->drag_start_x = event->x + entry->scroll_offset;
+ entry->drag_start_y = event->y + entry->scroll_offset;
+ }
+- else
+- gtk_editable_set_position (editable, tmp_pos);
+- break;
++ else {
++ /* HILDON: do not move the cursor inside the textarea if invisible
++ * as per the specifications */
++ if (!entry->visible)
++ if(tmp_pos == strlen(gtk_entry_get_text(entry))){
++ gtk_editable_set_position( editable, entry->text_length);
++ } else {
++ gtk_editable_select_region (editable, 0, -1);
++ }
++ else
++ gtk_editable_set_position (editable, tmp_pos);
++ }
++
++ break;
+
+ case GDK_2BUTTON_PRESS:
+ /* We ALWAYS receive a GDK_BUTTON_PRESS immediately before
+@@ -1614,8 +1790,16 @@
+ }
+ else if (event->button == 3 && event->type == GDK_BUTTON_PRESS)
+ {
++ /* Hildon: if we are in password mode selection and Cut & Copy should
++ be disabled. */
++ if (!entry->visible)
++ {
++ gtk_editable_set_position (GTK_EDITABLE(entry), 0);
++ }
++
+ gtk_entry_do_popup (entry, event);
+ entry->button = 0; /* Don't wait for release, since the menu will gtk_grab_add */
++ priv->keep_focus = TRUE;
+
+ return TRUE;
+ }
+@@ -1632,11 +1816,23 @@
+ if (event->window != entry->text_area || entry->button != event->button)
+ return FALSE;
+
++ if (entry->editable)
++ gtk_im_context_show (entry->im_context);
++
+ if (entry->in_drag)
+ {
+ gint tmp_pos = gtk_entry_find_position (entry, entry->drag_start_x);
+
+- gtk_editable_set_position (GTK_EDITABLE (entry), tmp_pos);
++ /* HILDON: If not visible, do not allow cursor to be positioned inside the string */
++ if (!entry->visible){
++ if(tmp_pos == strlen(gtk_entry_get_text(entry))){
++ gtk_editable_set_position( GTK_EDITABLE(entry), entry->text_length);
++ } else {
++ gtk_editable_select_region (GTK_EDITABLE (entry), 0, -1);
++ }
++ } else {
++ gtk_editable_set_position (GTK_EDITABLE (entry), tmp_pos);
++ }
+
+ entry->in_drag = 0;
+ }
+@@ -1822,6 +2018,13 @@
+ }
+ }
+
++ if (event->keyval == GDK_Return)
++ return FALSE;
++ if (event->keyval == GDK_KP_Enter)
++ g_signal_emit_by_name (G_OBJECT(gtk_widget_get_ancestor (widget,
++ GTK_TYPE_WINDOW)), "move-focus",
++ GTK_DIR_TAB_FORWARD);
++
+ if (GTK_WIDGET_CLASS (parent_class)->key_press_event (widget, event))
+ /* Activate key bindings
+ */
+@@ -1835,6 +2038,8 @@
+ GdkEventKey *event)
+ {
+ GtkEntry *entry = GTK_ENTRY (widget);
++
++ gtk_entry_update_scrolled_window( entry );
+
+ if (entry->editable)
+ {
+@@ -1853,7 +2058,35 @@
+ GdkEventFocus *event)
+ {
+ GtkEntry *entry = GTK_ENTRY (widget);
+-
++ GtkEntryPrivate *priv;
++
++ priv = GTK_ENTRY_GET_PRIVATE (widget);
++ /* Hildon : If the text doesn't fit the entry, upon focusing
++ * to an text field, move the caret to the end of the entry.
++ * Force the entry to recompute, otherwise it doesn't update
++ * if the cursor is currently at the end*/
++ /* hildon : If the text has no selection and focus returned with
++ other means than pointer click, set cursor before first
++ character of the text, otherwise behave normally */
++
++ if (!entry->in_click)
++ {
++ /*gboolean has_selection;
++ has_selection = gtk_editable_get_selection_bounds (GTK_EDITABLE (entry), NULL, NULL);
++ if (!has_selection)
++ {
++ gtk_editable_set_position (GTK_EDITABLE (entry), -1);
++ }*//*FIXME need a better hack here*/
++ /* Hildon: If in SecretEditor mode highlight selection if entry got focus
++ * otherways than mouse/stylus */
++ if (!entry->visible && priv->keep_focus)
++ {
++ gtk_editable_select_region (GTK_EDITABLE (entry), 0, -1);
++ }
++ }
++
++ gtk_entry_recompute (GTK_ENTRY (entry));
++
+ gtk_widget_queue_draw (widget);
+
+ if (entry->editable)
+@@ -1876,6 +2109,8 @@
+ GdkEventFocus *event)
+ {
+ GtkEntry *entry = GTK_ENTRY (widget);
++ GtkEntryPrivate *priv = GTK_ENTRY_GET_PRIVATE (widget);
++ guint tmp_pos;
+ GtkEntryCompletion *completion;
+
+ gtk_widget_queue_draw (widget);
+@@ -1886,6 +2121,20 @@
+ gtk_im_context_focus_out (entry->im_context);
+ }
+
++ tmp_pos = gtk_editable_get_position (GTK_EDITABLE (widget));
++ if (priv->keep_focus){
++ if (!entry->visible)
++ gtk_editable_set_position (GTK_EDITABLE (widget), tmp_pos);
++ priv->keep_focus = FALSE;
++ }
++ else {
++ if (priv->menu_popped)
++ priv->menu_popped = FALSE;
++ else gtk_editable_set_position (GTK_EDITABLE (widget), tmp_pos);
++ }
++
++ gtk_widget_queue_draw(widget);
++
+ gtk_entry_check_cursor_blink (entry);
+
+ g_signal_handlers_disconnect_by_func (gdk_keymap_get_for_display (gtk_widget_get_display (widget)),
+@@ -1902,7 +2151,6 @@
+ static void
+ gtk_entry_grab_focus (GtkWidget *widget)
+ {
+- GtkEntry *entry = GTK_ENTRY (widget);
+ gboolean select_on_focus;
+
+ GTK_WIDGET_CLASS (parent_class)->grab_focus (widget);
+@@ -1912,8 +2160,8 @@
+ &select_on_focus,
+ NULL);
+
+- if (select_on_focus && entry->editable && !entry->in_click)
+- gtk_editable_select_region (GTK_EDITABLE (widget), 0, -1);
++/* Hildon : When focusing to an entry, it shouldn't become
++ * highlighted. */
+ }
+
+ static void
+@@ -1987,7 +2235,7 @@
+
+ if (new_text_length > 63)
+ g_free (text);
+-
++ gtk_entry_update_scrolled_window( entry );
+ g_object_unref (editable);
+ }
+
+@@ -2074,7 +2322,7 @@
+ if (end < 0)
+ end = entry->text_length;
+
+- gtk_entry_reset_im_context (entry);
++ /*gtk_entry_reset_im_context (entry);*//*FIXME tmp kludge, might break something*/
+
+ gtk_entry_set_positions (entry,
+ MIN (end, entry->text_length),
+@@ -2168,13 +2416,19 @@
+ {
+ gint index;
+ gint n_chars;
++ gboolean show_last_char = FALSE;
+
+ GtkEntry *entry = GTK_ENTRY (editable);
+-
++ GtkEntryPrivate *priv = GTK_ENTRY_GET_PRIVATE (GTK_WIDGET (entry));
+ if (new_text_length < 0)
+ new_text_length = strlen (new_text);
+
+ n_chars = g_utf8_strlen (new_text, new_text_length);
++
++
++ gtk_widget_style_get (GTK_WIDGET (entry), "show-last-char",
++ &show_last_char, NULL);
++
+ if (entry->text_max_length > 0 && n_chars + entry->text_length > entry->text_max_length)
+ {
+ gdk_display_beep (gtk_widget_get_display (GTK_WIDGET (entry)));
+@@ -2238,6 +2492,14 @@
+
+ if (entry->selection_bound > *position)
+ entry->selection_bound += n_chars;
++
++ /* Hildon: store this addition IF it was only 1 char (user inputted) and we are currently in secret mode (invisible) */
++
++ if (show_last_char && n_chars == 1 && !entry->visible && (new_text_length < HILDON_EDITED_CHARACTER_MAX)) {
++ memset( &priv->hildon_edited_character, 0x00, HILDON_EDITED_CHARACTER_MAX );
++ priv->hildon_edited_character_length = new_text_length;
++ memcpy( &priv->hildon_edited_character, new_text, new_text_length ); /* Guaranteed to be < total length */
++ }
+
+ *position += n_chars;
+
+@@ -2339,6 +2601,11 @@
+
+ gtk_entry_reset_im_context (entry);
+
++ /* Hildon, if not visible set the position to the end */
++ /* New SecretEditor specs say that with cursor should move
++ * With left/right arrows
++ */
++
+ if (entry->current_pos != entry->selection_bound && !extend_selection)
+ {
+ /* If we have a current selection and aren't extending it, move to the
+@@ -2445,7 +2712,7 @@
+ gint start_pos = entry->current_pos;
+ gint end_pos = entry->current_pos;
+
+- gtk_entry_reset_im_context (entry);
++ /* Hildon: code removed - backspace should not clear the word completion */
+
+ if (!entry->editable)
+ return;
+@@ -2515,7 +2782,8 @@
+ GtkEditable *editable = GTK_EDITABLE (entry);
+ gint prev_pos;
+
+- gtk_entry_reset_im_context (entry);
++/* gtk_entry_reset_im_context (entry); */ /*backspace should not clear
++ the word completion*/
+
+ if (!entry->editable || !entry->text)
+ return;
+@@ -2883,21 +3151,28 @@
+ ++i;
+ }
+ }
+-
++
++#define HILDON_EDITED_CHARACTER_MS 600 /* 0.6 seconds */
++
+ static PangoLayout *
+ gtk_entry_create_layout (GtkEntry *entry,
+ gboolean include_preedit)
+ {
+ GtkWidget *widget = GTK_WIDGET (entry);
++ GtkEntryPrivate *priv = GTK_ENTRY_GET_PRIVATE (entry);
+ PangoLayout *layout = gtk_widget_create_pango_layout (widget, NULL);
+ PangoAttrList *tmp_attrs = pango_attr_list_new ();
+
+ gchar *preedit_string = NULL;
+ gint preedit_length = 0;
+ PangoAttrList *preedit_attrs = NULL;
++ gboolean show_last_char = FALSE;
+
+ pango_layout_set_single_paragraph_mode (layout, TRUE);
+
++ gtk_widget_style_get (widget, "show-last-char",
++ &show_last_char, NULL);
++
+ if (include_preedit)
+ {
+ gtk_im_context_get_preedit_string (entry->im_context,
+@@ -3003,7 +3278,49 @@
+ else
+ invisible_char = ' '; /* just pick a char */
+
+- append_char (str, invisible_char, entry->text_length);
++ if (!show_last_char)
++ append_char (str, invisible_char, entry->text_length);
++ else if (show_last_char)
++ {
++ /* Hildon */
++ if (priv->hildon_edited_character_length > 0)
++ {
++
++ /* If we have an outstanding timeout, remove it, because the character it is set to hide
++ * is already hidden now. We do this first to prevent possible race conditions if the timout
++ * were to trigger while in here
++ */
++
++ if (priv->hildon_edited_character_timeout)
++ {
++ g_source_remove( priv->hildon_edited_character_timeout );
++ priv->hildon_edited_character_timeout = FALSE;
++ }
++
++ /* Draw the secret character length-1 times, because the last char will be visible */
++ append_char (str, invisible_char, entry->text_length > 1 ? entry->text_length - 1 : 0);
++
++ /* Add our visible char, the most recently inputted one */
++ g_string_append_len (str, (char *)&priv->hildon_edited_character, priv->hildon_edited_character_length);
++
++ /* Now remove this last inputted character, don't need it anymore */
++
++ memset( priv->hildon_edited_character, 0x00, HILDON_EDITED_CHARACTER_MAX );
++ priv->hildon_edited_character_length = 0;
++
++ priv->hildon_edited_character_timeout = g_timeout_add( HILDON_EDITED_CHARACTER_MS, (GSourceFunc)
++ hildon_remove_visible_character, entry );
++
++ }
++ else
++ {
++ /* No last character known. This could be for example because the application has filled
++ * in the password already. In that case we of course don't want to view it
++ */
++ append_char (str, invisible_char, entry->text_length);
++ }
++ }
++
+ pango_layout_set_text (layout, str->str, str->len);
+ g_string_free (str, TRUE);
+ }
+@@ -3048,12 +3365,17 @@
+ gint area_width, area_height;
+ gint y_pos;
+ PangoLayoutLine *line;
+-
++ gint border_x, border_y;
++
++ gtk_widget_style_get (GTK_WIDGET (entry), "horizontal-border", &border_x,
++ "vertical-border", &border_y,
++ NULL);
++
+ layout = gtk_entry_ensure_layout (entry, TRUE);
+
+ get_text_area_size (entry, NULL, NULL, &area_width, &area_height);
+
+- area_height = PANGO_SCALE * (area_height - 2 * INNER_BORDER);
++ area_height = PANGO_SCALE * (area_height - 2 * border_y);
+
+ line = pango_layout_get_lines (layout)->data;
+ pango_layout_line_get_extents (line, NULL, &logical_rect);
+@@ -3070,10 +3392,10 @@
+ else if (y_pos + logical_rect.height > area_height)
+ y_pos = area_height - logical_rect.height;
+
+- y_pos = INNER_BORDER + y_pos / PANGO_SCALE;
++ y_pos = border_y + y_pos / PANGO_SCALE;
+
+ if (x)
+- *x = INNER_BORDER - entry->scroll_offset;
++ *x = border_x - entry->scroll_offset;
+
+ if (y)
+ *y = y_pos;
+@@ -3083,6 +3405,10 @@
+ gtk_entry_draw_text (GtkEntry *entry)
+ {
+ GtkWidget *widget;
++ gint border_y, border_x;
++
++ gtk_widget_style_get (GTK_WIDGET (entry), "horizontal-border", &border_x,
++ "vertical-border", &border_y, NULL);
+
+ if (!entry->visible && entry->invisible_char == 0)
+ return;
+@@ -3092,14 +3418,76 @@
+ PangoLayout *layout = gtk_entry_ensure_layout (entry, TRUE);
+ gint x, y;
+ gint start_pos, end_pos;
++ GdkRectangle clip_rect;
+
+ widget = GTK_WIDGET (entry);
+
+ get_layout_position (entry, &x, &y);
+
++ /* Use a clipping rectangle so that we always get enough empty space around
++ * the text.
++ */
++ clip_rect.x = border_x;
++ clip_rect.y = 0;
++
++ gdk_drawable_get_size (entry->text_area, &clip_rect.width, &clip_rect.height);
++ clip_rect.width -= border_x * 2;
++
++ /*changes for Hildon
++ *Reduce the size of the clip rect, so that only full characters are displayed
++ */
++
++ /* NOTE: Commented out because it does not work with bidi text where
++the indexes are in random
++ * left-right or right-left order. Code causes Pango assert aborts. Because gtkentry itself
++ * is broken with regard to bidi anyway (bug #478) we ignore this requirement of the spec
++ * until gtkentry itself is fixed. (bug #477)
++ */
++
++ /* Better yet, let's enable this only when not in RTL mode */
++
++ /* Note: BUG #857. patched gtkentry crashed when pasting scalable fonts. This is pango problem
++ * and we tested patched gtkentry with pango version 1.3.2 and it appears to be fixed. Section is commented
++ out until we upgrade to new version of pango
++ if (gtk_widget_get_direction( entry ) != GTK_TEXT_DIR_RTL)
++ {
++ PangoRectangle char_rect; // used for getting character's onscreen pos
++ PangoLayoutIter *iter; // used to iterate over the text
++
++ // get the position of the character currently at the clip border
++ iter = get_char_at_pos( layout, (clip_rect.x + clip_rect.width + entry->scroll_offset), 0 );
++ if ( iter )
++ {
++ // get the position of that character on the screen
++ pango_layout_iter_get_char_extents( iter, &char_rect );
++ char_rect.x /= PANGO_SCALE;
++ char_rect.x -= entry->scroll_offset;
++ char_rect.width /= PANGO_SCALE;
++
++ // if the ending position is > the clip rectangle, then the
++ // character is only partially visible, and we should
++ // clip the entire character.
++
++ if ( char_rect.x + char_rect.width > clip_rect.x + clip_rect.width )
++ {
++ clip_rect.width = char_rect.x;
++ }
++
++ pango_layout_iter_free( iter );
++ }
++
++ }
++ */
++ /******************************************************************/
++
++ gdk_gc_set_clip_rectangle (widget->style->text_gc [widget->state], &clip_rect);
++
+ gdk_draw_layout (entry->text_area, widget->style->text_gc [widget->state],
+ x, y,
+ layout);
++
++ gdk_gc_set_clip_rectangle (widget->style->text_gc [widget->state], NULL);
++
+
+ if (gtk_editable_get_selection_bounds (GTK_EDITABLE (entry), &start_pos, &end_pos))
+ {
+@@ -3128,7 +3516,7 @@
+ {
+ GdkRectangle rect;
+
+- rect.x = INNER_BORDER - entry->scroll_offset + ranges[2 * i];
++ rect.x = border_x - entry->scroll_offset + ranges[2 * i];
+ rect.y = y;
+ rect.width = ranges[2 * i + 1];
+ rect.height = logical_rect.height;
+@@ -3177,14 +3565,18 @@
+ {
+ GdkKeymap *keymap = gdk_keymap_get_for_display (gtk_widget_get_display (GTK_WIDGET (entry)));
+ PangoDirection keymap_direction = gdk_keymap_get_direction (keymap);
++ gint border_x, border_y;
+
++ gtk_widget_style_get (GTK_WIDGET (entry), "horizontal-border", &border_x,
++ "vertical-border", &border_y,
++ NULL);
+ if (GTK_WIDGET_DRAWABLE (entry))
+ {
+ GtkWidget *widget = GTK_WIDGET (entry);
+ GdkRectangle cursor_location;
+ gboolean split_cursor;
+
+- gint xoffset = INNER_BORDER - entry->scroll_offset;
++ gint xoffset = border_x - entry->scroll_offset;
+ gint strong_x, weak_x;
+ gint text_area_height;
+ PangoDirection dir1 = PANGO_DIRECTION_NEUTRAL;
+@@ -3221,9 +3613,9 @@
+ }
+
+ cursor_location.x = xoffset + x1;
+- cursor_location.y = INNER_BORDER;
++ cursor_location.y = border_y;
+ cursor_location.width = 0;
+- cursor_location.height = text_area_height - 2 * INNER_BORDER ;
++ cursor_location.height = text_area_height - 2 * border_y;
+
+ draw_insertion_cursor (entry,
+ &cursor_location, TRUE, dir1,
+@@ -3249,11 +3641,8 @@
+ static void
+ gtk_entry_reset_im_context (GtkEntry *entry)
+ {
+- if (entry->need_im_reset)
+- {
+- entry->need_im_reset = 0;
+- gtk_im_context_reset (entry->im_context);
+- }
++ /* Hildon: We want reset to be sent more often */
++ gtk_im_context_reset (entry->im_context);
+ }
+
+ static gint
+@@ -3266,8 +3655,12 @@
+ gint pos;
+ gboolean trailing;
+ const gchar *text;
+- gint cursor_index;
+-
++ gint border_x, cursor_index;
++
++ gtk_widget_style_get (GTK_WIDGET (entry), "horizontal-border", &border_x,
++ NULL);
++ x -= border_x;
++
+ layout = gtk_entry_ensure_layout (entry, TRUE);
+ text = pango_layout_get_text (layout);
+ cursor_index = g_utf8_offset_to_pointer (text, entry->current_pos) - text;
+@@ -3355,12 +3748,17 @@
+ PangoLayout *layout;
+ PangoLayoutLine *line;
+ PangoRectangle logical_rect;
++ gint border_x, border_y;
++
++ gtk_widget_style_get (GTK_WIDGET (entry), "horizontal-border", &border_x,
++ "vertical-border", &border_y,
++ NULL);
+
+ if (!GTK_WIDGET_REALIZED (entry))
+ return;
+
+ gdk_drawable_get_size (entry->text_area, &text_area_width, NULL);
+- text_area_width -= 2 * INNER_BORDER;
++ text_area_width -= 2 * border_x;
+
+ layout = gtk_entry_ensure_layout (entry, TRUE);
+ line = pango_layout_get_lines (layout)->data;
+@@ -3390,13 +3788,13 @@
+ entry->scroll_offset = CLAMP (entry->scroll_offset, min_offset, max_offset);
+
+ /* And make sure cursors are on screen. Note that the cursor is
+- * actually drawn one pixel into the INNER_BORDER space on
++ * actually drawn one pixel into the border_x space on
+ * the right, when the scroll is at the utmost right. This
+ * looks better to to me than confining the cursor inside the
+ * border entirely, though it means that the cursor gets one
+ * pixel closer to the edge of the widget on the right than
+ * on the left. This might need changing if one changed
+- * INNER_BORDER from 2 to 1, as one would do on a
++ * border_x from 2 to 1, as one would do on a
+ * small-screen-real-estate display.
+ *
+ * We always make sure that the strong cursor is on screen, and
+@@ -3430,6 +3828,52 @@
+ entry->scroll_offset += weak_xoffset - text_area_width;
+ }
+
++ /*Changes for Hildon
++ * now we make it so that if a character is partially visible,
++ * then we also scroll that off the screen.
++ */
++
++ /* NOTE: Commented out because it does not work with bidi text where the indexes are in random
++ * left-right or right-left order. Code causes Pango assert aborts. Because gtkentry itself
++ * is broken with regard to bidi anyway (bug #478) we ignore this requirement of the spec
++ * until gtkentry itself is fixed. (bug #477)
++ */
++
++ /* Better yet, let's disable this (for now) only when using RTL text */
++
++/*Note: BUG #857. patched gtkentry crashed when pasting scalable fonts. This is pango problem
++ * and we tested patched gtkentry with pango version 1.3.2 and it appears to be fixed. Section is comment ed out until we upgrade to new version of pango
++ if (gtk_widget_get_direction( entry ) != GTK_TEXT_DIR_RTL)
++ {
++ PangoLayoutIter *iter = get_char_at_pos( layout, entry->scroll_offset, 0 );
++ // if we found the char we were looking for
++ if ( iter )
++ {
++ PangoRectangle char_rect; // used for getting character's onscreen pos
++
++ // get the position of that character on the screen
++ pango_layout_iter_get_char_extents( iter, &char_rect );
++ char_rect.x /= PANGO_SCALE;
++
++ // if the starting position is < the current scroll offset, then the
++ // character is only partially visible, and we should scroll to the
++ // start of the next character instead
++
++ if ( char_rect.x < entry->scroll_offset )
++ {
++ if ( pango_layout_iter_next_char( iter ) )
++ {
++ pango_layout_iter_get_char_extents( iter, &char_rect);
++ entry->scroll_offset = char_rect.x / PANGO_SCALE;
++ }
++ }
++
++ pango_layout_iter_free( iter );
++ }
++
++
++ }*/
++
+ g_object_notify (G_OBJECT (entry), "scroll_offset");
+ }
+
+@@ -3552,8 +3996,9 @@
+ pango_layout_get_log_attrs (layout, &log_attrs, &n_attrs);
+
+ /* Find the next word end */
++ /*Hildon: cursor should seek to the start of the next word*/
+ new_pos++;
+- while (new_pos < n_attrs && !log_attrs[new_pos].is_word_end)
++ while (new_pos < n_attrs && !log_attrs[new_pos].is_word_start)
+ new_pos++;
+
+ g_free (log_attrs);
+@@ -3648,14 +4093,9 @@
+
+ if (entry->visible)
+ return gtk_editable_get_chars (GTK_EDITABLE (entry), start, end);
+- else if (!entry->invisible_char)
++ /*Hildon: when not visible, no chars are public*/
++ else
+ return g_strdup ("");
+- else
+- {
+- GString *str = g_string_new (NULL);
+- append_char (str, entry->invisible_char, end - start);
+- return g_string_free (str, FALSE);
+- }
+ }
+
+ static void
+@@ -3678,9 +4118,12 @@
+
+ if (text)
+ {
+- gint pos, start, end;
++ gint pos, start, end, index;
+ GtkEntryCompletion *completion = gtk_entry_get_completion (entry);
+
++ /* when pasting multiline text, ignore everything but the first line */
++ for (index = 0; text[index] != 0 && text[index] != '\n'; index++);
++
+ if (completion)
+ {
+ g_signal_handler_block (entry, completion->priv->changed_id);
+@@ -3692,7 +4135,7 @@
+ gtk_editable_delete_text (editable, start, end);
+
+ pos = entry->current_pos;
+- gtk_editable_insert_text (editable, text, -1, &pos);
++ gtk_editable_insert_text (editable, text, index, &pos);
+ gtk_editable_set_position (editable, pos);
+
+ if (completion)
+@@ -3888,6 +4331,7 @@
+ {
+ g_return_if_fail (GTK_IS_ENTRY (entry));
+
++ g_object_set(G_OBJECT(entry->im_context), "visibility", visible, NULL);
+ entry->visible = visible ? TRUE : FALSE;
+ g_object_notify (G_OBJECT (entry), "visibility");
+ gtk_entry_recompute (entry);
+@@ -4569,6 +5013,7 @@
+ GdkEventButton *event)
+ {
+ PopupInfo *info = g_new (PopupInfo, 1);
++ GtkEntryPrivate *priv;
+
+ /* In order to know what entries we should make sensitive, we
+ * ask for the current targets of the clipboard, and when
+@@ -4576,6 +5021,8 @@
+ */
+ info->entry = g_object_ref (entry);
+
++ priv = GTK_ENTRY_GET_PRIVATE (entry);
++
+ if (event)
+ {
+ info->button = event->button;
+@@ -4591,6 +5038,8 @@
+ gdk_atom_intern ("TARGETS", FALSE),
+ popup_targets_received,
+ info);
++
++ priv->menu_popped = TRUE;
+ }
+
+ static gboolean
+@@ -5389,3 +5838,156 @@
+
+ return completion;
+ }
++
++static PangoLayoutIter *get_char_at_pos( PangoLayout *layout, gint x, gint y )
++{
++ gint index = 0; /*the index of the first character */
++ gint trailing = 0; /*not used*/
++ PangoLayoutIter *iter; /*used to iterate over the text*/
++ gboolean valid_char = TRUE;
++
++ /*get the position of the character currently at the scroll offset*/
++ pango_layout_xy_to_index( layout, x * PANGO_SCALE, y * PANGO_SCALE, &index, &trailing );
++ iter = pango_layout_get_iter( layout );
++
++ /*iterate until we get to the character at the same index*/
++ while ( valid_char && pango_layout_iter_get_index( iter ) != index )
++ {
++ valid_char = pango_layout_iter_next_char( iter );
++ }
++
++ if ( valid_char == FALSE )
++ iter = NULL;
++
++ return iter;
++}
++
++static void gtk_entry_update_scrolled_window( GtkEntry *entry)
++{
++ GtkWidget *parent;
++ GtkWidget *widget;
++ GtkWidget *direct_parent = NULL;
++ GtkScrolledWindow *sw = NULL;
++ gboolean need_update = FALSE;
++ GtkAdjustment *vadjustment;
++ gdouble value;
++
++ widget = parent = GTK_WIDGET(entry);
++ if(parent->parent != NULL)
++ direct_parent = parent->parent;
++ while(parent && !GTK_WIDGET_TOPLEVEL(parent))
++ {
++ if(GTK_IS_SCROLLED_WINDOW(parent))
++ {
++ need_update = TRUE;
++ sw = GTK_SCROLLED_WINDOW(parent);
++ break;
++ }
++ parent = parent->parent;
++ }
++
++ if(need_update)
++ {
++ gint x=0, y=0;
++ vadjustment = gtk_scrolled_window_get_vadjustment(sw);
++ value = gtk_adjustment_get_value(vadjustment);
++
++ if(direct_parent != NULL)
++ gtk_widget_translate_coordinates( direct_parent, parent,
++ widget->allocation.x, widget->allocation.y, &x, &y );
++
++ if( (gdouble) y < 0 )
++ {
++ value = value + (gdouble) y;
++ if (value < vadjustment->lower)
++ value = vadjustment->lower;
++ }
++ else if( (gdouble )y + widget->allocation.height > vadjustment->page_size)
++ {
++ value = value + (gdouble)y + widget->allocation.height
++ - vadjustment->page_size;
++ if(value > vadjustment->upper - vadjustment->page_size)
++ value = vadjustment->upper - vadjustment->page_size;
++ }
++ gtk_adjustment_set_value(vadjustment, value);
++ gtk_scrolled_window_set_vadjustment(sw, GTK_ADJUSTMENT(vadjustment));
++ }
++}
++
++/*
++ * gtk_entry_set_autocap:
++ * @entry: a #GtkEntry
++ * @autocap: autocap
++ *
++ * Sets autocapitalization of the widget.
++ */
++static void
++gtk_entry_set_autocap (GtkEntry *entry,
++ gboolean autocap)
++{
++ g_return_if_fail (GTK_IS_ENTRY (entry));
++
++ if (gtk_entry_get_autocap (entry) != autocap)
++ {
++ g_object_set (G_OBJECT (entry->im_context), "autocap", autocap, NULL);
++ g_object_notify (G_OBJECT (entry), "autocap");
++ }
++}
++
++/*
++ * gtk_entry_get_autocap:
++ * @entry: a #GtkEntry
++ *
++ * Gets autocapitalization state of the widget.
++ *
++ * Return value: a state
++ */
++static gboolean
++gtk_entry_get_autocap (GtkEntry *entry)
++{
++ gboolean autocap;
++ g_return_val_if_fail (GTK_IS_ENTRY (entry), FALSE);
++
++ g_object_get (G_OBJECT (entry->im_context), "autocap", &autocap, NULL);
++
++ return autocap;
++}
++
++/*
++ * gtk_entry_set_input_mode:
++ * @entry: a #GtkEntry
++ * @autocap: input mode
++ *
++ * Sets autocapitalization of the widget.
++ */
++static void
++gtk_entry_set_input_mode (GtkEntry *entry,
++ gint mode)
++{
++ g_return_if_fail (GTK_IS_ENTRY (entry));
++
++ if (gtk_entry_get_input_mode (entry) != mode)
++ {
++ g_object_set (G_OBJECT (entry->im_context), "input_mode", mode, NULL);
++ g_object_notify (G_OBJECT (entry), "input_mode");
++ }
++}
++
++/*
++ * gtk_entry_get_input_mode:
++ * @entry: a #GtkEntry
++ *
++ * Gets input mode of the widget.
++ *
++ * Return value: input mode
++ */
++static gint
++gtk_entry_get_input_mode (GtkEntry *entry)
++{
++ gint mode;
++ g_return_val_if_fail (GTK_IS_ENTRY (entry), FALSE);
++
++ g_object_get (G_OBJECT (entry->im_context), "input_mode", &mode, NULL);
++
++ return mode;
++}
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkenums.h.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkenums.h.diff
index e69de29bb2..5978100c97 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkenums.h.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkenums.h.diff
@@ -0,0 +1,15 @@
+--- gtk+-2.6.4/gtk/gtkenums.h 2003-07-18 21:52:02.000000000 +0300
++++ gtk+-2.6.4/gtk/gtkenums.h 2005-04-06 16:19:36.500989368 +0300
+@@ -133,7 +133,11 @@
+ GTK_ICON_SIZE_LARGE_TOOLBAR,
+ GTK_ICON_SIZE_BUTTON,
+ GTK_ICON_SIZE_DND,
+- GTK_ICON_SIZE_DIALOG
++ GTK_ICON_SIZE_DIALOG,
++ HILDON_ICON_SIZE_26,
++ HILDON_ICON_SIZE_40,
++ HILDON_ICON_SIZE_50,
++ HILDON_ICON_SIZE_64
+ } GtkIconSize;
+
+ #ifndef GTK_DISABLE_DEPRECATED
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkfilesystem.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkfilesystem.c.diff
index e69de29bb2..87346c0260 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkfilesystem.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkfilesystem.c.diff
@@ -0,0 +1,12 @@
+--- gtk+-2.6.4/gtk/gtkfilesystem.c 2004-09-13 19:00:00.000000000 +0300
++++ gtk+-2.6.4/gtk/gtkfilesystem.c 2005-04-06 16:19:36.518986632 +0300
+@@ -1147,4 +1147,9 @@
+ return fs;
+ }
+
++/* In Hildon we need to publish the previous symbol */
++GtkFileSystem *hildon_gtk_file_system_create(const char *file_system_name)
++{
++ return _gtk_file_system_create (file_system_name);
++}
+
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkfilesystem.h.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkfilesystem.h.diff
index e69de29bb2..a555ca230b 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkfilesystem.h.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkfilesystem.h.diff
@@ -0,0 +1,12 @@
+--- gtk+-2.6.4/gtk/gtkfilesystem.h 2005-01-03 01:15:21.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkfilesystem.h 2005-04-06 16:19:36.518986632 +0300
+@@ -364,6 +364,9 @@
+
+ GtkFileSystem *_gtk_file_system_create (const char *file_system_name);
+
++/* In Hildon we need to publish the previous symbol */
++GtkFileSystem *hildon_gtk_file_system_create(const char *file_system_name);
++
+ G_END_DECLS
+
+ #endif /* __GTK_FILE_SYSTEM_H__ */
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkframe.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkframe.c.diff
index e69de29bb2..6ca54c0c99 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkframe.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkframe.c.diff
@@ -0,0 +1,82 @@
+--- gtk+-2.6.4/gtk/gtkframe.c 2004-08-17 22:10:24.000000000 +0300
++++ gtk+-2.6.4/gtk/gtkframe.c 2005-04-06 16:19:36.583976752 +0300
+@@ -24,6 +24,10 @@
+ * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
+ */
+
++/* Modified for Nokia Oyj during 2002-2003. See CHANGES file for list
++ * of changes.
++ */
++
+ #include <config.h>
+ #include <string.h>
+ #include "gtkalias.h"
+@@ -33,6 +37,7 @@
+
+ #define LABEL_PAD 1
+ #define LABEL_SIDE_PAD 2
++#define FRAME_BORDER_WIDTH 3
+
+ enum {
+ PROP_0,
+@@ -172,6 +177,14 @@
+ P_("A widget to display in place of the usual frame label"),
+ GTK_TYPE_WIDGET,
+ G_PARAM_READABLE | G_PARAM_WRITABLE));
++
++ /* draw hildonlike frame */
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_boolean ("hildonlike",
++ _("hildonlike looks"),
++ _("Draw frame, 1/0"),
++ FALSE,
++ G_PARAM_READABLE));
+
+ widget_class->expose_event = gtk_frame_expose;
+ widget_class->size_request = gtk_frame_size_request;
+@@ -276,7 +289,7 @@
+ GtkWidget*
+ gtk_frame_new (const gchar *label)
+ {
+- return g_object_new (GTK_TYPE_FRAME, "label", label, NULL);
++ return g_object_new (GTK_TYPE_FRAME, "label", label, "border-width", FRAME_BORDER_WIDTH, NULL);
+ }
+
+ static void
+@@ -533,6 +546,9 @@
+ {
+ GtkFrame *frame;
+ gint x, y, width, height;
++ gboolean hildonlike;
++
++ gtk_widget_style_get ( widget, "hildonlike", &hildonlike, NULL );
+
+ if (GTK_WIDGET_DRAWABLE (widget))
+ {
+@@ -543,7 +559,16 @@
+ width = frame->child_allocation.width + 2 * widget->style->xthickness;
+ height = frame->child_allocation.height + 2 * widget->style->ythickness;
+
+- if (frame->label_widget)
++ if (hildonlike) {
++ /* draw hildon application borders */
++ gtk_paint_box (widget->style,
++ widget->window,
++ GTK_WIDGET_STATE( widget ),
++ GTK_SHADOW_OUT,
++ NULL, widget, "frame",
++ x, y, width, height);
++ }
++ else if (frame->label_widget)
+ {
+ GtkRequisition child_requisition;
+ gfloat xalign;
+@@ -586,7 +611,7 @@
+ {
+ if (GTK_WIDGET_DRAWABLE (widget))
+ {
+- gtk_frame_paint (widget, &event->area);
++ gtk_frame_paint (widget, &event->area);
+
+ (* GTK_WIDGET_CLASS (parent_class)->expose_event) (widget, event);
+ }
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhashtable.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhashtable.c.diff
index e69de29bb2..fc6e15810b 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhashtable.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhashtable.c.diff
@@ -0,0 +1,102 @@
+--- gtk+-2.6.4/gtk/gtkhashtable.c 1970-01-01 02:00:00.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkhashtable.c 2005-04-06 16:19:36.596974776 +0300
+@@ -0,0 +1,99 @@
++/* GTK - The GIMP Toolkit
++ * Copyright (C) 2005 Nokia
++ * Author: Jorn Baayen <jbaayen@gnome.org>
++ *
++ * This library is free software; you can redistribute it and/or
++ * modify it under the terms of the GNU Lesser General Public
++ * License as published by the Free Software Foundation; either
++ * version 2 of the License, or (at your option) any later version.
++ *
++ * This library is distributed in the hope that it will be useful,
++ * but WITHOUT ANY WARRANTY; without even the implied warranty of
++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ * Lesser General Public License for more details.
++ *
++ * You should have received a copy of the GNU Lesser General Public
++ * License along with this library; if not, write to the
++ * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
++ * Boston, MA 02111-1307, USA.
++ */
++
++#include <config.h>
++#include "gtkhashtable.h"
++
++static gpointer parent_class = NULL;
++
++static void _gtk_hash_table_init (GtkHashTable *hash_table);
++static void _gtk_hash_table_class_init (GtkHashTableClass *klass);
++static void _gtk_hash_table_finalize (GObject *object);
++
++GType
++_gtk_hash_table_get_type (void)
++{
++ static GType hash_table_type = 0;
++
++ if (!hash_table_type)
++ {
++ static const GTypeInfo hash_table_info =
++ {
++ sizeof (GtkHashTableClass),
++ NULL, /* base_init */
++ NULL, /* base_finalize */
++ (GClassInitFunc) _gtk_hash_table_class_init,
++ NULL, /* class_finalize */
++ NULL, /* class_data */
++ sizeof (GtkHashTable),
++ 0, /* n_preallocs */
++ (GInstanceInitFunc) _gtk_hash_table_init,
++ };
++
++ hash_table_type =
++ g_type_register_static (G_TYPE_OBJECT, "GtkHashTable",
++ &hash_table_info, 0);
++ }
++
++ return hash_table_type;
++}
++
++static void
++_gtk_hash_table_init (GtkHashTable *hash_table)
++{
++ hash_table->hash = g_hash_table_new_full (g_str_hash, g_str_equal,
++ g_free, g_free);
++}
++
++static void
++_gtk_hash_table_class_init (GtkHashTableClass *klass)
++{
++ GObjectClass *object_class = G_OBJECT_CLASS (klass);
++
++ parent_class = g_type_class_peek_parent (klass);
++
++ object_class->finalize = _gtk_hash_table_finalize;
++}
++
++static void
++_gtk_hash_table_finalize (GObject *object)
++{
++ GtkHashTable *hash_table = GTK_HASH_TABLE (object);
++
++ g_hash_table_destroy (hash_table->hash);
++
++ G_OBJECT_CLASS (parent_class)->finalize (object);
++}
++
++/**
++ * _gtk_hash_table_new:
++ *
++ * Creates a new #GtkHashTable. This is a #GHashTable wrapped in a GObject,
++ * thereby supporting refcounting.
++ *
++ * Return value: a new #GtkHashTable
++ **/
++GtkHashTable*
++_gtk_hash_table_new (void)
++{
++ return g_object_new (GTK_TYPE_HASH_TABLE, NULL);
++}
++
++
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhashtable.h.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhashtable.h.diff
index e69de29bb2..733d68c35a 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhashtable.h.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhashtable.h.diff
@@ -0,0 +1,64 @@
+--- gtk+-2.6.4/gtk/gtkhashtable.h 1970-01-01 02:00:00.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkhashtable.h 2005-04-06 16:19:36.606973256 +0300
+@@ -0,0 +1,61 @@
++/* GTK - The GIMP Toolkit
++ * Copyright (C) 2005 Nokia
++ * Author: Jorn Baayen <jbaayen@gnome.org>
++ *
++ * This library is free software; you can redistribute it and/or
++ * modify it under the terms of the GNU Lesser General Public
++ * License as published by the Free Software Foundation; either
++ * version 2 of the License, or (at your option) any later version.
++ *
++ * This library is distributed in the hope that it will be useful,
++ * but WITHOUT ANY WARRANTY; without even the implied warranty of
++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ * Lesser General Public License for more details.
++ *
++ * You should have received a copy of the GNU Lesser General Public
++ * License along with this library; if not, write to the
++ * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
++ * Boston, MA 02111-1307, USA.
++ */
++
++#ifndef __GTK_HASH_TABLE_H__
++#define __GTK_HASH_TABLE_H__
++
++#include <glib-object.h>
++
++#ifdef __cplusplus
++extern "C" {
++#endif /* __cplusplus */
++
++typedef struct _GtkHashTable GtkHashTable;
++typedef struct _GtkHashTableClass GtkHashTableClass;
++
++#define GTK_TYPE_HASH_TABLE (_gtk_hash_table_get_type ())
++#define GTK_HASH_TABLE(object) (G_TYPE_CHECK_INSTANCE_CAST ((object), GTK_TYPE_HASH_TABLE, GtkHashTable))
++#define GTK_HASH_TABLE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GTK_TYPE_HASH_TABLE, GtkHashTableClass))
++#define GTK_IS_HASH_TABLE(object) (G_TYPE_CHECK_INSTANCE_TYPE ((object), GTK_TYPE_HASH_TABLE))
++#define GTK_IS_HASH_TABLE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GTK_TYPE_HASH_TABLE))
++#define GTK_HASH_TABLE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GTK_TYPE_HASH_TABLE, GtkHashTableClass))
++
++struct _GtkHashTable
++{
++ GObject parent_instance;
++
++ GHashTable *hash;
++};
++
++struct _GtkHashTableClass
++{
++ GObjectClass parent_class;
++};
++
++GType _gtk_hash_table_get_type (void) G_GNUC_CONST;
++GtkHashTable* _gtk_hash_table_new (void);
++
++#ifdef __cplusplus
++}
++#endif /* __cplusplus */
++
++#endif /* __GTK_HASH_TABLE_H__ */
++
++
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhbbox.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhbbox.c.diff
index e69de29bb2..e43db37f5c 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhbbox.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhbbox.c.diff
@@ -0,0 +1,344 @@
+--- gtk+-2.6.4/gtk/gtkhbbox.c 2004-08-09 19:59:52.000000000 +0300
++++ gtk+-2.6.4/gtk/gtkhbbox.c 2005-04-06 16:19:36.644967480 +0300
+@@ -24,10 +24,20 @@
+ * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
+ */
+
++/* Modified for Nokia Oyj during 2002-2005. See CHANGES file for list
++ * of changes.
++ */
++
++/* Hildon : Button spacing according to the spec. */
++#define HILDON_BUTTON_SPACING 5
++/* Selecting hetefogenous mode for a childlayout */
++#define GTK_BUTTONBOX_HETEROGENOUS 6
++
+ #include <config.h>
+ #include "gtkalias.h"
+ #include "gtkhbbox.h"
+-
++/* Hildon : We need this to mess with buttons graphics. */
++#include "gtkbutton.h"
+
+ static void gtk_hbutton_box_class_init (GtkHButtonBoxClass *klass);
+ static void gtk_hbutton_box_init (GtkHButtonBox *box);
+@@ -36,6 +46,15 @@
+ static void gtk_hbutton_box_size_allocate (GtkWidget *widget,
+ GtkAllocation *allocation);
+
++static void osso_gtk_hbutton_child_showhide_handler (GtkWidget *widget,
++ gpointer user_data);
++static void osso_gtk_hbutton_box_remove_child_signal_handlers (GtkHButtonBox *hbbox,
++ GtkWidget *removed_widget,
++ gpointer data);
++static void osso_gtk_hbutton_box_find_button_detail (GtkHButtonBox *hbbox,
++ GtkWidget *addremovewidget,
++ gpointer data);
++
+ static gint default_spacing = 30;
+ static gint default_layout_style = GTK_BUTTONBOX_EDGE;
+
+@@ -76,12 +95,23 @@
+
+ widget_class->size_request = gtk_hbutton_box_size_request;
+ widget_class->size_allocate = gtk_hbutton_box_size_allocate;
++
++ /* HILDON:
++ * Name buttons only if hildon like style property is set
++ */
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_boolean
++ ( "hildonlike",
++ "hildonlike looks",
++ "Name buttons, 1/0",
++ FALSE,
++ G_PARAM_READABLE) );
+ }
+
+ static void
+ gtk_hbutton_box_init (GtkHButtonBox *hbutton_box)
+ {
+- /* button_box_init has done everything allready */
++ /* button_box_init has done everything allready */
+ }
+
+ GtkWidget*
+@@ -91,6 +121,24 @@
+
+ hbutton_box = g_object_new (GTK_TYPE_HBUTTON_BOX, NULL);
+
++ /* Attach signal handler for 'hildonizing' buttons.
++ * gtk_hbutton_box_hildonize_buttons will check the name
++ * and if it is something we're interested in i.e.
++ *
++ * hildon_dialogbuttons
++ * hildon_viewbuttons
++ *
++ * it will do the hildonizing
++ */
++ g_signal_connect_after (G_OBJECT (hbutton_box), "remove",
++ G_CALLBACK (osso_gtk_hbutton_box_remove_child_signal_handlers),
++ NULL);
++ g_signal_connect_after( G_OBJECT( hbutton_box ), "add",
++ G_CALLBACK( osso_gtk_hbutton_box_find_button_detail ),
++ NULL );
++ g_signal_connect_after( G_OBJECT( hbutton_box ), "remove",
++ G_CALLBACK( osso_gtk_hbutton_box_find_button_detail ),
++ NULL );
+ return GTK_WIDGET (hbutton_box);
+ }
+
+@@ -145,6 +193,11 @@
+ gint child_height;
+ gint spacing;
+ GtkButtonBoxStyle layout;
++ gint child_xpad=0;
++ GtkBoxChild *child_req;
++ GList *children_req;
++ GtkRequisition treq;
++
+
+ box = GTK_BOX (widget);
+ bbox = GTK_BUTTON_BOX (widget);
+@@ -159,6 +212,12 @@
+ &child_width,
+ &child_height);
+
++ /* should GTK_BUTTONBOX_HETEROGENOUS add into the GtkButtonBoxStyle
++ enum struct
++ */
++ if( !box->homogeneous )
++ layout = GTK_BUTTONBOX_HETEROGENOUS;
++
+ if (nvis_children == 0)
+ {
+ requisition->width = 0;
+@@ -177,11 +236,36 @@
+ case GTK_BUTTONBOX_END:
+ requisition->width = nvis_children*child_width + ((nvis_children-1)*spacing);
+ break;
++ case GTK_BUTTONBOX_HETEROGENOUS:
++ children_req = GTK_BOX (box)->children;
++ child_req = children_req->data;
++ requisition->width = 0;
++
++ while (children_req)
++ {
++ child_req = children_req->data;
++ children_req = children_req->next;
++
++ if (GTK_WIDGET_VISIBLE (child_req->widget))
++ {
++ gtk_widget_get_child_requisition( child_req->widget,
++ &(treq) );
++ requisition->width += treq.width;
++
++ gtk_widget_style_get(widget,
++ "child-internal-pad-x",
++ &(child_xpad), NULL);
++ requisition->width += (child_xpad*2);
++ }
++ }
++ requisition->width += ((nvis_children-1)*spacing);
++
++ break;
+ default:
+ g_assert_not_reached();
+ break;
+ }
+-
++
+ requisition->height = child_height;
+ }
+
+@@ -227,6 +311,10 @@
+ &child_height);
+ widget->allocation = *allocation;
+ width = allocation->width - GTK_CONTAINER (box)->border_width*2;
++
++ if( !base_box->homogeneous )
++ layout = GTK_BUTTONBOX_HETEROGENOUS;
++
+ switch (layout)
+ {
+ case GTK_BUTTONBOX_SPREAD:
+@@ -264,6 +352,39 @@
+ - GTK_CONTAINER (box)->border_width;
+ secondary_x = allocation->x + GTK_CONTAINER (box)->border_width;
+ break;
++ case GTK_BUTTONBOX_HETEROGENOUS:
++ {
++ gint sumwidth = 0;
++ GtkBoxChild *child_h;
++ GList *children_h = GTK_BOX (box)->children;
++ /* heterogenous sized childs onto center */
++ childspacing = spacing;
++ child_h = children_h->data;
++
++ while (children_h )
++ {
++ if ( g_list_length (children_h) == 0 ) break;
++
++ child_h = children_h->data;
++ children_h = children_h->next;
++
++ if (GTK_WIDGET_VISIBLE (child_h->widget))
++ {
++ gint child_xpad = 0;
++ GtkRequisition treq;
++ gtk_widget_get_child_requisition( child_h->widget, &(treq) );
++ sumwidth += treq.width;
++
++ gtk_widget_style_get(widget,
++ "child-internal-pad-x",
++ &(child_xpad), NULL);
++ sumwidth += (child_xpad*2);
++ }
++ }
++ x = secondary_x = allocation->x +
++ ( (allocation->width - sumwidth - (spacing * (nvis_children - 1)))/2 );
++ break;
++ }
+ default:
+ g_assert_not_reached();
+ break;
+@@ -282,10 +403,33 @@
+
+ if (GTK_WIDGET_VISIBLE (child->widget))
+ {
+- child_allocation.width = child_width;
+ child_allocation.height = child_height;
+ child_allocation.y = y;
+
++ if(layout != GTK_BUTTONBOX_HETEROGENOUS)
++ {
++ child_allocation.width = child_width;
++ }
++ else /* if layout will be hetergenous */
++ {
++ gint child_hwidth = 0;
++ GtkRequisition treq;
++ gint child_xpad = 0;
++
++ gtk_widget_get_child_requisition( child->widget, &(treq) );
++ child_hwidth += treq.width;
++
++ gtk_widget_style_get(widget,
++ "child-internal-pad-x",
++ &child_xpad, NULL);
++ child_hwidth += (child_xpad*2);
++
++ child_allocation.width = child_hwidth;
++ childspace = child_hwidth + childspacing;
++
++ }
++
++ /* calculate the horizontal location */
+ if (child->is_secondary)
+ {
+ child_allocation.x = secondary_x;
+@@ -304,4 +448,104 @@
+ }
+ }
+ }
++
++/* Function to wrap "hide" and "show" signals to call
++ * osso_gtk_hbutton_box_find_button_detail -function.*/
++static void osso_gtk_hbutton_child_showhide_handler (GtkWidget *widget,
++ gpointer user_data)
++{
++ osso_gtk_hbutton_box_find_button_detail (widget, GTK_WIDGET (user_data), NULL);
++}
+
++/* Function to remove "show"&"hide" signal handlers
++ * from a child when it's removed. */
++static void osso_gtk_hbutton_box_remove_child_signal_handlers (GtkHButtonBox *hbbox,
++ GtkWidget *removed_widget,
++ gpointer data)
++{
++ g_signal_handlers_disconnect_by_func (G_OBJECT (removed_widget), osso_gtk_hbutton_box_find_button_detail, hbbox);
++}
++
++/* Signal handler called when we have to set
++ * painting detail values for buttons in this
++ * gtk_horizontal_button_box.
++ */
++static void osso_gtk_hbutton_box_find_button_detail (GtkHButtonBox *hbbox,
++ GtkWidget *addremovewidget,
++ gpointer data)
++{
++ GList *child;
++ gint visible_buttons = 0;
++ gint secondary_buttons = 0;
++ GtkWidget *leftmost_button = NULL;
++ GtkWidget *rightmost_button = NULL;
++
++ for( child = GTK_BOX (hbbox)->children ; child ; child = child->next )
++ {
++ GtkBoxChild *box_child = child->data;
++ GtkWidget *child_widget = box_child->widget;
++ gulong signal_handler = g_signal_handler_find ( G_OBJECT( child_widget ),
++ G_SIGNAL_MATCH_FUNC,
++ 0, 0, NULL,
++ G_CALLBACK (osso_gtk_hbutton_child_showhide_handler),
++ NULL);
++
++ if (signal_handler == 0)
++ {
++ g_signal_connect_object ( G_OBJECT( child_widget ),
++ "hide",
++ G_CALLBACK ( osso_gtk_hbutton_child_showhide_handler ),
++ hbbox, G_CONNECT_SWAPPED);
++ g_signal_connect_object ( G_OBJECT( child_widget ),
++ "show",
++ G_CALLBACK ( osso_gtk_hbutton_child_showhide_handler ),
++ hbbox, G_CONNECT_SWAPPED);
++ }
++
++ if ((GTK_WIDGET_VISIBLE (child_widget)) &&
++ (GTK_IS_BUTTON (child_widget)))
++ visible_buttons++;
++ else
++ continue;
++
++ if (leftmost_button == NULL)
++ leftmost_button = child_widget;
++
++ if (secondary_buttons == 0)
++ rightmost_button = child_widget;
++ else
++ if (box_child->is_secondary)
++ {
++ rightmost_button = child_widget;
++ secondary_buttons++;
++ }
++
++ if (box_child->is_secondary)
++ rightmost_button = child_widget;
++ }
++
++ if (visible_buttons == 0)
++ return;
++
++ for( child = GTK_BOX (hbbox)->children ; child ; child = child->next )
++ {
++ GtkBoxChild *box_child = child->data;
++ GtkWidget *child_widget = box_child->widget;
++ OssoGtkButtonAttachFlags attachflags = OSSO_GTK_BUTTON_ATTACH_NORTH | OSSO_GTK_BUTTON_ATTACH_SOUTH;
++ gboolean automatic_detail;
++
++ if (!((GTK_WIDGET_VISIBLE (child_widget)) &&
++ (GTK_IS_BUTTON (child_widget))))
++ continue;
++
++ if (child_widget == leftmost_button)
++ attachflags |= OSSO_GTK_BUTTON_ATTACH_WEST;
++
++ if (child_widget == rightmost_button)
++ attachflags |= OSSO_GTK_BUTTON_ATTACH_EAST;
++
++ g_object_get (G_OBJECT (child_widget), "automatic_detail", &automatic_detail, NULL);
++ if (automatic_detail == TRUE)
++ g_object_set (G_OBJECT (child_widget), "detail", osso_gtk_button_attach_details[attachflags], NULL);
++ }
++}
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhseparator.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhseparator.c.diff
index e69de29bb2..814c6ae5c7 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhseparator.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhseparator.c.diff
@@ -0,0 +1,40 @@
+--- gtk+-2.6.4/gtk/gtkhseparator.c 2004-08-09 19:59:52.000000000 +0300
++++ gtk+-2.6.4/gtk/gtkhseparator.c 2005-04-06 16:19:36.667963984 +0300
+@@ -91,13 +91,29 @@
+ gtk_hseparator_expose (GtkWidget *widget,
+ GdkEventExpose *event)
+ {
+- if (GTK_WIDGET_DRAWABLE (widget))
+- gtk_paint_hline (widget->style, widget->window, GTK_WIDGET_STATE (widget),
+- &event->area, widget, "hseparator",
+- widget->allocation.x,
+- widget->allocation.x + widget->allocation.width - 1,
+- widget->allocation.y + (widget->allocation.height -
+- widget->style->ythickness) / 2);
++ gboolean hildonlike_drawing = FALSE;
++ gtk_widget_style_get ( widget, "hildonlike-drawing", &hildonlike_drawing, NULL );
+
+- return FALSE;
++ if (GTK_WIDGET_DRAWABLE (widget))
++ {
++ if(hildonlike_drawing)
++ gtk_paint_box (widget->style, widget->window, GTK_STATE_NORMAL,
++ GTK_SHADOW_NONE, &event->area, widget, "hseparator",
++ widget->allocation.x,
++ widget->allocation.y + (widget->allocation.height -
++ widget->style->ythickness) / 2,
++ widget->allocation.width - 1,
++ widget->style->ythickness);
++ else
++ gtk_paint_hline (widget->style, widget->window, GTK_STATE_NORMAL,
++ &event->area, widget, "hseparator",
++ widget->allocation.x,
++ widget->allocation.x + widget->allocation.width - 1,
++ widget->allocation.y + (widget->allocation.height -
++ widget->style->ythickness) / 2);
++ }
++
++
++
++ return FALSE;
+ }
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkiconfactory.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkiconfactory.c.diff
index e69de29bb2..91874b9ce4 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkiconfactory.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkiconfactory.c.diff
@@ -0,0 +1,69 @@
+--- gtk+-2.6.4/gtk/gtkiconfactory.c 2005-01-03 16:44:33.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkiconfactory.c 2005-04-06 16:19:36.804943160 +0300
+@@ -813,7 +813,7 @@
+ {
+ if (icon_sizes == NULL)
+ {
+-#define NUM_BUILTIN_SIZES 7
++#define NUM_BUILTIN_SIZES 11
+ gint i;
+
+ icon_aliases = g_hash_table_new (g_str_hash, g_str_equal);
+@@ -863,7 +863,27 @@
+ icon_sizes[GTK_ICON_SIZE_DIALOG].width = 48;
+ icon_sizes[GTK_ICON_SIZE_DIALOG].height = 48;
+
+- g_assert ((GTK_ICON_SIZE_DIALOG + 1) == NUM_BUILTIN_SIZES);
++ icon_sizes[HILDON_ICON_SIZE_26].size = HILDON_ICON_SIZE_26;
++ icon_sizes[HILDON_ICON_SIZE_26].name = "hildon-26";
++ icon_sizes[HILDON_ICON_SIZE_26].width = 26;
++ icon_sizes[HILDON_ICON_SIZE_26].height = 26;
++
++ icon_sizes[HILDON_ICON_SIZE_40].size = HILDON_ICON_SIZE_40;
++ icon_sizes[HILDON_ICON_SIZE_40].name = "hildon-40";
++ icon_sizes[HILDON_ICON_SIZE_40].width = 40;
++ icon_sizes[HILDON_ICON_SIZE_40].height = 40;
++
++ icon_sizes[HILDON_ICON_SIZE_50].size = HILDON_ICON_SIZE_50;
++ icon_sizes[HILDON_ICON_SIZE_50].name = "hildon-50";
++ icon_sizes[HILDON_ICON_SIZE_50].width = 50;
++ icon_sizes[HILDON_ICON_SIZE_50].height = 50;
++
++ icon_sizes[HILDON_ICON_SIZE_64].size = HILDON_ICON_SIZE_64;
++ icon_sizes[HILDON_ICON_SIZE_64].name = "hildon-64";
++ icon_sizes[HILDON_ICON_SIZE_64].width = 54;
++ icon_sizes[HILDON_ICON_SIZE_64].height = 64;
++
++ g_assert ((HILDON_ICON_SIZE_64 + 1) == NUM_BUILTIN_SIZES);
+
+ /* Alias everything to itself. */
+ i = 1; /* skip invalid size */
+@@ -1658,7 +1678,7 @@
+ gint width, height, pixel_size;
+ gint *sizes, *s, dist;
+ GError *error = NULL;
+-
++
+ if (widget && gtk_widget_has_screen (widget))
+ screen = gtk_widget_get_screen (widget);
+ else if (style && style->colormap)
+@@ -1734,8 +1754,10 @@
+ tmp_source.type = GTK_ICON_SOURCE_PIXBUF;
+ tmp_source.source.pixbuf = tmp_pixbuf;
+
++ /* Hildon: no scaling allowed for Hildon icons */
+ pixbuf = gtk_style_render_icon (style, &tmp_source,
+- direction, state, -1,
++ direction, state,
++ (size < HILDON_ICON_SIZE_26) ? -1 : size,
+ widget, detail);
+
+ if (!pixbuf)
+@@ -1818,7 +1840,6 @@
+ {
+ /* This icon can be used for any direction/state/size */
+ static GtkIconSource fallback_source = GTK_ICON_SOURCE_INIT (TRUE, TRUE, TRUE);
+-
+ if (fallback_source.type == GTK_ICON_SOURCE_EMPTY)
+ {
+ GdkPixbuf *pixbuf = gdk_pixbuf_new_from_inline (-1, stock_missing_image_24, FALSE, NULL);
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkicontheme.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkicontheme.c.diff
index e69de29bb2..ff9cf71096 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkicontheme.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkicontheme.c.diff
@@ -0,0 +1,48 @@
+--- gtk+-2.6.4/gtk/gtkicontheme.c 2005-03-01 17:24:48.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkicontheme.c 2005-04-06 16:19:36.807942704 +0300
+@@ -64,7 +64,8 @@
+ ICON_SUFFIX_XPM = 1 << 0,
+ ICON_SUFFIX_SVG = 1 << 1,
+ ICON_SUFFIX_PNG = 1 << 2,
+- HAS_ICON_FILE = 1 << 3
++ HAS_ICON_FILE = 1 << 3,
++ ICON_SUFFIX_ANI = 1 << 4
+ } IconSuffix;
+
+
+@@ -1743,6 +1744,8 @@
+ return ".svg";
+ case ICON_SUFFIX_PNG:
+ return ".png";
++ case ICON_SUFFIX_ANI:
++ return ".ani";
+ default:
+ g_assert_not_reached();
+ }
+@@ -1760,6 +1763,8 @@
+ retval = ICON_SUFFIX_SVG;
+ else if (g_str_has_suffix (name, ".xpm"))
+ retval = ICON_SUFFIX_XPM;
++ else if (g_str_has_suffix (name, ".ani"))
++ retval = ICON_SUFFIX_ANI;
+ else
+ retval = ICON_SUFFIX_NONE;
+
+@@ -1776,6 +1781,8 @@
+ return ICON_SUFFIX_SVG;
+ else if ((suffix & ICON_SUFFIX_XPM) != 0)
+ return ICON_SUFFIX_XPM;
++ else if ((suffix & ICON_SUFFIX_ANI) != 0)
++ return ICON_SUFFIX_ANI;
+ else
+ return ICON_SUFFIX_NONE;
+ }
+@@ -2558,7 +2565,7 @@
+ icon_info->pixbuf = gdk_pixbuf_scale_simple (source_pixbuf,
+ 0.5 + image_width * icon_info->scale,
+ 0.5 + image_height * icon_info->scale,
+- GDK_INTERP_BILINEAR);
++ GDK_INTERP_NEAREST);
+ g_object_unref (source_pixbuf);
+ }
+
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkimcontext.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkimcontext.c.diff
index e69de29bb2..03d990c6dd 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkimcontext.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkimcontext.c.diff
@@ -0,0 +1,52 @@
+--- gtk+-2.6.4/gtk/gtkimcontext.c 2004-09-26 07:23:56.000000000 +0300
++++ gtk+-2.6.4/gtk/gtkimcontext.c 2005-04-06 16:19:36.814941640 +0300
+@@ -360,6 +360,44 @@
+ }
+
+ /**
++ * gtk_im_context_show:
++ * @context: a #GtkIMContext
++ *
++ * Notify the input method that widget thinks the actual
++ * input method show be opened.
++ **/
++void
++gtk_im_context_show (GtkIMContext *context)
++{
++ GtkIMContextClass *klass;
++
++ g_return_if_fail (GTK_IS_IM_CONTEXT (context));
++
++ klass = GTK_IM_CONTEXT_GET_CLASS (context);
++ if (klass->show)
++ klass->show (context);
++}
++
++/**
++ * gtk_im_context_hide:
++ * @context: a #GtkIMContext
++ *
++ * Notify the input method that widget thinks the actual
++ * input method show be closed.
++ **/
++void
++gtk_im_context_hide (GtkIMContext *context)
++{
++ GtkIMContextClass *klass;
++
++ g_return_if_fail (GTK_IS_IM_CONTEXT (context));
++
++ klass = GTK_IM_CONTEXT_GET_CLASS (context);
++ if (klass->hide)
++ klass->hide (context);
++}
++
++/**
+ * gtk_im_context_reset:
+ * @context: a #GtkIMContext
+ *
+@@ -553,4 +591,3 @@
+
+ return result;
+ }
+-
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkimcontext.h.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkimcontext.h.diff
index e69de29bb2..068d18a7d3 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkimcontext.h.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkimcontext.h.diff
@@ -0,0 +1,29 @@
+--- gtk+-2.6.4/gtk/gtkimcontext.h 2002-10-11 01:18:36.000000000 +0300
++++ gtk+-2.6.4/gtk/gtkimcontext.h 2005-04-06 16:19:36.815941488 +0300
+@@ -85,14 +85,15 @@
+ gboolean (*get_surrounding) (GtkIMContext *context,
+ gchar **text,
+ gint *cursor_index);
++ void (*show) (GtkIMContext *context);
++ void (*hide) (GtkIMContext *context);
++
+
+ /* Padding for future expansion */
+ void (*_gtk_reserved1) (void);
+ void (*_gtk_reserved2) (void);
+ void (*_gtk_reserved3) (void);
+ void (*_gtk_reserved4) (void);
+- void (*_gtk_reserved5) (void);
+- void (*_gtk_reserved6) (void);
+ };
+
+ GType gtk_im_context_get_type (void) G_GNUC_CONST;
+@@ -122,6 +123,8 @@
+ gboolean gtk_im_context_delete_surrounding (GtkIMContext *context,
+ gint offset,
+ gint n_chars);
++void gtk_im_context_show (GtkIMContext *context);
++void gtk_im_context_hide (GtkIMContext *context);
+
+ #ifdef __cplusplus
+ }
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkimmulticontext.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkimmulticontext.c.diff
index e69de29bb2..4332a9c318 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkimmulticontext.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkimmulticontext.c.diff
@@ -0,0 +1,155 @@
+--- gtk+-2.6.4/gtk/gtkimmulticontext.c 2004-08-09 19:59:52.000000000 +0300
++++ gtk+-2.6.4/gtk/gtkimmulticontext.c 2005-04-06 16:19:36.818941032 +0300
+@@ -59,6 +59,8 @@
+ static void gtk_im_multicontext_focus_in (GtkIMContext *context);
+ static void gtk_im_multicontext_focus_out (GtkIMContext *context);
+ static void gtk_im_multicontext_reset (GtkIMContext *context);
++static void gtk_im_multicontext_show (GtkIMContext *context);
++static void gtk_im_multicontext_hide (GtkIMContext *context);
+ static void gtk_im_multicontext_set_cursor_location (GtkIMContext *context,
+ GdkRectangle *area);
+ static void gtk_im_multicontext_set_use_preedit (GtkIMContext *context,
+@@ -118,6 +120,67 @@
+ return im_multicontext_type;
+ }
+
++static GtkIMContext *
++gtk_im_multicontext_get_slave (GtkIMMulticontext *multicontext);
++
++enum {
++ PROP_INPUT_MODE = 1,
++ PROP_AUTOCAP,
++ PROP_VISIBILITY,
++ PROP_USE_SHOW_HIDE
++};
++
++static void gtk_im_multicontext_set_property(GObject * object,
++ guint property_id,
++ const GValue * value,
++ GParamSpec * pspec)
++{
++ GtkIMContext *slave = gtk_im_multicontext_get_slave (GTK_IM_MULTICONTEXT(object));
++
++ GParamSpec *param_spec = g_object_class_find_property
++ (G_OBJECT_GET_CLASS(slave),
++ pspec->name);
++
++ if(param_spec != NULL)
++ g_object_set_property(G_OBJECT(slave), pspec->name, value);
++}
++
++static void gtk_im_multicontext_get_property(GObject * object,
++ guint property_id,
++ GValue * value,
++ GParamSpec * pspec)
++{
++ GtkIMContext *slave = gtk_im_multicontext_get_slave (GTK_IM_MULTICONTEXT(object));
++ GParamSpec *param_spec = g_object_class_find_property
++ (G_OBJECT_GET_CLASS(slave),
++ pspec->name);
++
++ if(param_spec != NULL)
++ g_object_get_property(G_OBJECT(slave), pspec->name, value);
++ else
++ {
++ switch (property_id)
++ {
++ case PROP_INPUT_MODE:
++ /* return 0 */
++ g_value_set_int(value, 0);
++ break;
++ case PROP_AUTOCAP:
++ /* return FALSE */
++ g_value_set_boolean(value, FALSE);
++ break;
++ case PROP_VISIBILITY:
++ /* return TRUE */
++ g_value_set_boolean(value, TRUE);
++ break;
++ case PROP_USE_SHOW_HIDE:
++ default:
++ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
++ break;
++ }
++ }
++}
++
+ static void
+ gtk_im_multicontext_class_init (GtkIMMulticontextClass *class)
+ {
+@@ -132,12 +195,38 @@
+ im_context_class->focus_in = gtk_im_multicontext_focus_in;
+ im_context_class->focus_out = gtk_im_multicontext_focus_out;
+ im_context_class->reset = gtk_im_multicontext_reset;
++ im_context_class->show = gtk_im_multicontext_show;
++ im_context_class->hide = gtk_im_multicontext_hide;
+ im_context_class->set_cursor_location = gtk_im_multicontext_set_cursor_location;
+ im_context_class->set_use_preedit = gtk_im_multicontext_set_use_preedit;
+ im_context_class->set_surrounding = gtk_im_multicontext_set_surrounding;
+ im_context_class->get_surrounding = gtk_im_multicontext_get_surrounding;
+
+ gobject_class->finalize = gtk_im_multicontext_finalize;
++
++ gobject_class->set_property = gtk_im_multicontext_set_property;
++ gobject_class->get_property = gtk_im_multicontext_get_property;
++
++ g_object_class_install_property(gobject_class, PROP_INPUT_MODE,
++ g_param_spec_int("input-mode", "Input mode",
++ "Specifies the set of allowed characters",
++ 0, 9, 0, /* We don't move symbolic definitions here. See hildon-input-mode.h */
++ G_PARAM_READWRITE));
++
++ g_object_class_install_property(gobject_class, PROP_AUTOCAP,
++ g_param_spec_boolean("autocap", "Autocap",
++ "Whether the client wants the first character in a sentense to be automatic upper case",
++ FALSE, G_PARAM_READWRITE));
++
++ g_object_class_install_property(gobject_class, PROP_VISIBILITY,
++ g_param_spec_boolean("visibility", "Visibility",
++ "FALSE displays the \"invisible char\"instead of the actual text (password mode)",
++ TRUE, G_PARAM_READABLE | G_PARAM_WRITABLE));
++
++ g_object_class_install_property(gobject_class, PROP_VISIBILITY,
++ g_param_spec_boolean("use-show-hide", "Use show/hide functions",
++ "Use show/hide functions to show/hide IM instead of focus_in/focus_out",
++ FALSE, G_PARAM_READABLE | G_PARAM_WRITABLE));
+ }
+
+ static void
+@@ -567,3 +656,36 @@
+ g_free (contexts);
+ }
+
++static void
++gtk_im_multicontext_show (GtkIMContext *context)
++{
++ GtkIMMulticontext *multicontext = GTK_IM_MULTICONTEXT (context);
++ GtkIMContext *slave;
++
++ /* If the global context type is different from the context we were
++ * using before, get rid of the old slave and create a new one
++ * for the new global context type.
++ */
++ if (!multicontext->context_id ||
++ strcmp (global_context_id, multicontext->context_id) != 0)
++ gtk_im_multicontext_set_slave (multicontext, NULL, FALSE);
++
++ slave = gtk_im_multicontext_get_slave (multicontext);
++
++ multicontext->priv->focus_in = TRUE;
++
++ if (slave)
++ gtk_im_context_show (slave);
++}
++
++static void
++gtk_im_multicontext_hide (GtkIMContext *context)
++{
++ GtkIMMulticontext *multicontext = GTK_IM_MULTICONTEXT (context);
++ GtkIMContext *slave = gtk_im_multicontext_get_slave (multicontext);
++
++ multicontext->priv->focus_in = FALSE;
++
++ if (slave)
++ gtk_im_context_hide (slave);
++}
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel-resize-patch b/packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel-resize-patch
index e69de29bb2..df29656343 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel-resize-patch
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel-resize-patch
@@ -0,0 +1,10 @@
+--- 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
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel.c.diff
index e69de29bb2..e730b66b7f 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel.c.diff
@@ -0,0 +1,390 @@
+--- gtk+-2.6.4/gtk/gtklabel.c 2005-02-28 06:32:03.000000000 +0200
++++ gtk+-2.6.4/gtk/gtklabel.c 2005-04-06 16:19:36.878931912 +0300
+@@ -23,6 +23,11 @@
+ * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
+ */
+
++
++/* Modified for Nokia Oyj during 2004. See CHANGES file for list
++ * of changes.
++ */
++
+ #include <config.h>
+ #include <math.h>
+ #include <string.h>
+@@ -52,6 +57,7 @@
+ guint single_line_mode : 1;
+ guint have_transform : 1;
+ gdouble angle;
++ gboolean request_full_width;
+ }
+ GtkLabelPrivate;
+
+@@ -75,6 +81,9 @@
+ LAST_SIGNAL
+ };
+
++/* Hildon mod.
++ A property PROP_TRANSLATABLE has been added here. If new Gtk+
++ versions add items here, the compability will break. */
+ enum {
+ PROP_0,
+ PROP_LABEL,
+@@ -89,6 +98,7 @@
+ PROP_MNEMONIC_WIDGET,
+ PROP_CURSOR_POSITION,
+ PROP_SELECTION_BOUND,
++ PROP_TRANSLATABLE,
+ PROP_ELLIPSIZE,
+ PROP_WIDTH_CHARS,
+ PROP_SINGLE_LINE_MODE,
+@@ -96,6 +106,12 @@
+ PROP_MAX_WIDTH_CHARS
+ };
+
++/* Hildon mod. A few keys. These are used to store data for label
++ * without changing the private structures. */
++#define LABEL_KEY_TRANSLATABLE "label_translatable"
++#define LABEL_KEY_TRANSLATABLETEXT "label_translatabletext"
++#define LABEL_KEY_ORIGINAL_LAYOUT "label_original_layout"
++
+ static guint signals[LAST_SIGNAL] = { 0 };
+
+ static void gtk_label_class_init (GtkLabelClass *klass);
+@@ -149,7 +165,7 @@
+ static void gtk_label_set_uline_text_internal (GtkLabel *label,
+ const gchar *str);
+ static void gtk_label_set_pattern_internal (GtkLabel *label,
+- const gchar *pattern);
++ const gchar *pattern);
+ static void set_markup (GtkLabel *label,
+ const gchar *str,
+ gboolean with_uline);
+@@ -516,6 +532,24 @@
+ G_MAXINT,
+ -1,
+ G_PARAM_READWRITE));
++ /* Hildon mod. Add property for a widget - whether it supports run-time
++ + locale change. Please note that this functionality is not yet
++ + completed and may change. */
++ g_object_class_install_property (gobject_class,
++ PROP_TRANSLATABLE,
++ g_param_spec_boolean ("translatable",
++ _("Is translatable"),
++ _("Whether label should be translatable."),
++ FALSE,
++ G_PARAM_READWRITE));
++
++ /* Hildonlike class property */
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_boolean ("hildonlike",
++ _("hildonlike looks"),
++ _("Changes wrapping etc behaviour, 1/0"),
++ FALSE,
++ G_PARAM_READABLE));
+ /*
+ * Key bindings
+ */
+@@ -650,6 +684,10 @@
+ case PROP_MAX_WIDTH_CHARS:
+ gtk_label_set_max_width_chars (label, g_value_get_int (value));
+ break;
++/* Hildon add. */
++ case PROP_TRANSLATABLE:
++ gtk_label_set_translatable (label, g_value_get_boolean (value));
++ break;
+ default:
+ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
+ break;
+@@ -730,6 +768,10 @@
+ case PROP_MAX_WIDTH_CHARS:
+ g_value_set_int (value, gtk_label_get_max_width_chars (label));
+ break;
++/* Hildon mod. */
++ case PROP_TRANSLATABLE:
++ g_value_set_boolean (value, gtk_label_get_translatable (label));
++ break;
+
+ default:
+ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
+@@ -748,6 +790,7 @@
+ priv->width_chars = -1;
+ priv->angle = 0.0;
+ priv->max_width_chars = -1;
++ priv->request_full_width = FALSE;
+ label->label = NULL;
+
+ label->jtype = GTK_JUSTIFY_LEFT;
+@@ -766,6 +809,15 @@
+ label->mnemonic_window = NULL;
+
+ gtk_label_set_text (label, "");
++
++/* Hildon Addition. */
++
++ g_object_set_data (G_OBJECT (label), LABEL_KEY_TRANSLATABLE, FALSE);
++ g_object_set_data (G_OBJECT (label), LABEL_KEY_TRANSLATABLETEXT, NULL);
++ g_object_set_data (G_OBJECT (label), LABEL_KEY_ORIGINAL_LAYOUT, NULL);
++
++/* /Hildon Addition. */
++
+ }
+
+ /**
+@@ -822,7 +874,7 @@
+
+ if (str && *str)
+ gtk_label_set_text_with_mnemonic (label, str);
+-
++
+ return GTK_WIDGET (label);
+ }
+
+@@ -1257,7 +1309,7 @@
+ GError *error = NULL;
+ PangoAttrList *attrs = NULL;
+ gunichar accel_char = 0;
+-
++
+ if (!pango_parse_markup (str,
+ -1,
+ with_uline ? '_' : 0,
+@@ -1340,12 +1392,14 @@
+ g_return_if_fail (GTK_IS_LABEL (label));
+
+ last_keyval = label->mnemonic_keyval;
++
+ gtk_label_set_label_internal (label, g_strdup (str ? str : ""));
+ gtk_label_set_use_markup_internal (label, TRUE);
+ gtk_label_set_use_underline_internal (label, TRUE);
+-
+ gtk_label_recalculate (label);
++
+ gtk_label_setup_mnemonic (label, last_keyval);
++
+ }
+
+ /**
+@@ -1409,7 +1463,7 @@
+
+ static void
+ gtk_label_set_pattern_internal (GtkLabel *label,
+- const gchar *pattern)
++ const gchar *pattern)
+ {
+ PangoAttrList *attrs;
+ g_return_if_fail (GTK_IS_LABEL (label));
+@@ -1421,7 +1475,16 @@
+
+ if (label->effective_attrs)
+ pango_attr_list_unref (label->effective_attrs);
++/* Following will disable undercores from
++ keyboard shortcuts if DISABLE_KEYBOARD_SHORTCUTS
++ is enabled during compile time
++ */
++#ifndef DISABLE_KEYBOARD_SHORTCUTS
+ label->effective_attrs = attrs;
++#else
++ pango_attr_list_unref (attrs);
++#endif /* DISABLE_KEYBOARD_SHORTCUTS */
++
+ }
+
+ void
+@@ -1742,8 +1805,13 @@
+ {
+ PangoLayout *layout;
+ GtkStyle *style = GTK_WIDGET (label)->style;
+-
++
++ gboolean hildonlike;
+ LabelWrapWidth *wrap_width = g_object_get_data (G_OBJECT (style), "gtk-label-wrap-width");
++
++ /* Hildon: get hildonlike property */
++ gtk_widget_style_get (GTK_WIDGET (label), "hildonlike", &hildonlike, NULL);
++
+ if (!wrap_width)
+ {
+ wrap_width = g_new0 (LabelWrapWidth, 1);
+@@ -1763,7 +1831,12 @@
+ "This long string gives a good enough length for any line to have.");
+ pango_layout_get_size (layout, &wrap_width->width, NULL);
+ g_object_unref (layout);
+-
++ /* A hildon mod for "fixing line wrapping". Remember to remove this
++ when GtkLabel will implement width for height size negotiation.*/
++ if (hildonlike)
++ {
++ wrap_width->width = wrap_width->width * 1.25;
++ }
+ return wrap_width->width;
+ }
+
+@@ -1774,8 +1847,12 @@
+ PangoRectangle logical_rect;
+ gint rwidth, rheight;
+ gboolean rtl;
++ gboolean hildonlike;
+
+ widget = GTK_WIDGET (label);
++
++ /* Hildon: get hildonlike property */
++ gtk_widget_style_get (widget, "hildonlike", &hildonlike, NULL);
+
+ rtl = gtk_widget_get_direction(widget) == GTK_TEXT_DIR_RTL;
+ rwidth = label->misc.xpad * 2;
+@@ -1864,8 +1941,18 @@
+
+ wrap_width = get_label_wrap_width (label);
+ width = MIN (width, wrap_width);
+- width = MIN (width,
++
++ if (!hildonlike)
++ {
++ width = MIN (width,
+ PANGO_SCALE * (gdk_screen_get_width (screen) + 1) / 2);
++ }
++ else
++ {
++ width = MIN (width,
++ PANGO_SCALE * (gdk_screen_get_width (screen) + 1));
++ }
++
+
+ pango_layout_set_width (label->layout, width);
+ pango_layout_get_extents (label->layout, NULL, &logical_rect);
+@@ -1910,6 +1997,7 @@
+ else /* !label->wrap */
+ pango_layout_set_width (label->layout, -1);
+ }
++
+ }
+
+ /* Gets the bounds of a layout in device coordinates. Note cut-and-paste
+@@ -2017,7 +2105,8 @@
+ priv->width_chars > 0 || priv->max_width_chars > 0) &&
+ aux_info && aux_info->width > 0)
+ width += aux_info->width;
+- else if (label->ellipsize || priv->width_chars > 0 || priv->max_width_chars > 0)
++ else if ((label->ellipsize || priv->width_chars > 0 || priv->max_width_chars > 0) &&
++ !priv->request_full_width)
+ {
+ PangoContext *context;
+ PangoFontMetrics *metrics;
+@@ -2081,11 +2170,24 @@
+ GtkAllocation *allocation)
+ {
+ GtkLabel *label;
++ GtkRequisition req;
++ GtkLabelPrivate *priv;
+
+ label = GTK_LABEL (widget);
++ priv = GTK_LABEL_GET_PRIVATE (label);
+
+ (* GTK_WIDGET_CLASS (parent_class)->size_allocate) (widget, allocation);
+
++ gtk_widget_get_child_requisition (widget, &req);
++
++ if (allocation->width < req.width && !label->wrap)
++ {
++ gtk_label_set_ellipsize (label, PANGO_ELLIPSIZE_END);
++ priv->request_full_width = TRUE;
++ }
++ else
++ priv->request_full_width = FALSE;
++
+ if (label->ellipsize)
+ {
+ if (label->layout)
+@@ -2479,7 +2581,7 @@
+ }
+ *dest = 0;
+ *pattern_dest = 0;
+-
++
+ gtk_label_set_text_internal (label, new_str);
+ gtk_label_set_pattern_internal (label, pattern);
+
+@@ -2541,13 +2643,11 @@
+ last_keyval = label->mnemonic_keyval;
+
+ g_object_freeze_notify (G_OBJECT (label));
+-
+ gtk_label_set_label_internal (label, g_strdup (str ? str : ""));
+ gtk_label_set_use_markup_internal (label, FALSE);
+ gtk_label_set_use_underline_internal (label, TRUE);
+-
+- gtk_label_recalculate (label);
+
++ gtk_label_recalculate (label);
+ gtk_label_setup_mnemonic (label, last_keyval);
+
+ g_object_thaw_notify (G_OBJECT (label));
+@@ -3948,3 +4048,67 @@
+ popup_position_func, label,
+ 0, gtk_get_current_event_time ());
+ }
++
++/* Hildon mod.
++ * Functions for run-time locale changing. Beware though that this
++ functionality is not yet completed. Therefore it's suggested
++ that these functions shouldn't be used yet outside testing. */
++
++void gtk_label_set_translatable (GtkLabel *label, gboolean newstatus)
++{
++ if (newstatus == gtk_label_get_translatable (label)) return;
++
++ if (newstatus == TRUE)
++ {
++ if (g_object_get_data (G_OBJECT (label), LABEL_KEY_TRANSLATABLETEXT) != NULL)
++ g_free (g_object_get_data (G_OBJECT (label), LABEL_KEY_TRANSLATABLETEXT));
++ g_object_set_data (G_OBJECT (label), LABEL_KEY_TRANSLATABLETEXT, g_strdup (label->label));
++ g_object_set_data (G_OBJECT (label), LABEL_KEY_TRANSLATABLE, (void*) TRUE);
++ if (label->text != NULL)
++ g_free (label->text);
++ if (label->label != NULL)
++ g_free (label->label);
++ label->text = g_strdup(_(g_object_get_data (G_OBJECT (label), LABEL_KEY_TRANSLATABLETEXT)));
++ label->label = g_strdup(_(g_object_get_data (G_OBJECT (label), LABEL_KEY_TRANSLATABLETEXT)));
++ }
++ else
++ {
++ if (label->text != NULL)
++ g_free (label->text);
++ if (label->label != NULL)
++ g_free (label->label);
++ label->text = g_strdup (g_object_get_data (G_OBJECT (label), LABEL_KEY_TRANSLATABLETEXT));
++ label->label = g_strdup (g_object_get_data (G_OBJECT (label), LABEL_KEY_TRANSLATABLETEXT));
++ g_object_set_data (G_OBJECT (label), LABEL_KEY_TRANSLATABLE, FALSE);
++ if (g_object_get_data (G_OBJECT (label), LABEL_KEY_TRANSLATABLETEXT) != NULL)
++ g_free (g_object_get_data (G_OBJECT (label), LABEL_KEY_TRANSLATABLETEXT));
++ g_object_set_data (G_OBJECT (label), LABEL_KEY_TRANSLATABLETEXT, NULL);
++ }
++ gtk_label_recalculate (label);
++}
++
++gboolean gtk_label_get_translatable (GtkLabel *label)
++{
++ return (gboolean) (g_object_get_data (G_OBJECT (label), LABEL_KEY_TRANSLATABLE));
++}
++
++
++void gtk_label_retranslate (GtkLabel *label)
++{
++ g_object_freeze_notify (G_OBJECT (label));
++ if (gtk_label_get_translatable (label) == TRUE)
++ {
++ if (label->label != NULL)
++ g_free (label->label);
++ label->label = g_strdup(gettext(g_object_get_data (G_OBJECT (label), LABEL_KEY_TRANSLATABLETEXT)));
++ }
++ if (g_object_get_data (G_OBJECT (label), LABEL_KEY_ORIGINAL_LAYOUT)) g_object_unref (g_object_get_data (G_OBJECT (label), LABEL_KEY_ORIGINAL_LAYOUT));
++ g_object_set_data (G_OBJECT (label), LABEL_KEY_ORIGINAL_LAYOUT, NULL);
++ g_object_notify (G_OBJECT (label), "label");
++ gtk_label_recalculate (label);
++ g_object_thaw_notify (G_OBJECT (label));
++ gtk_label_set_text (label, label->label);
++}
++
++/* End of hildon mods for run-time locale change. */
++
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel.h.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel.h.diff
index e69de29bb2..5aef5e5a62 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel.h.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel.h.diff
@@ -0,0 +1,29 @@
+--- gtk+-2.6.4/gtk/gtklabel.h 2004-12-13 08:34:54.000000000 +0200
++++ gtk+-2.6.4/gtk/gtklabel.h 2005-04-06 16:19:36.889930240 +0300
+@@ -23,6 +23,10 @@
+ * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
+ */
+
++/* Modified for Nokia Oyj during 2004. See CHANGES file for list
++ * of changes.
++ */
++
+ #ifndef __GTK_LABEL_H__
+ #define __GTK_LABEL_H__
+
+@@ -165,6 +169,15 @@
+ gboolean single_line_mode);
+ gboolean gtk_label_get_single_line_mode (GtkLabel *label);
+
++/* Additional Hildon functions for run-time locale change */
++
++void gtk_label_set_translatable (GtkLabel *label, gboolean newstatus);
++gboolean gtk_label_get_translatable (GtkLabel *label);
++
++void gtk_label_retranslate (GtkLabel *label);
++
++/* ----- */
++
+ #ifndef GTK_DISABLE_DEPRECATED
+
+ #define gtk_label_set gtk_label_set_text
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmain.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmain.c.diff
index e69de29bb2..2132487bdf 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmain.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmain.c.diff
@@ -0,0 +1,35 @@
+--- gtk+-2.6.4/gtk/gtkmain.c 2004-12-27 07:25:15.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkmain.c 2005-04-06 16:19:36.897929024 +0300
+@@ -68,6 +68,7 @@
+ #include "gtkwindow.h"
+ #include "gtkprivate.h"
+ #include "gtkdebug.h"
++#include "gtkwidget.h"
+
+ /* Private type definitions
+ */
+@@ -1297,6 +1298,15 @@
+ {
+ grab_widget = event_widget;
+ }
++
++ /* Hildon: insensitive press handling is moved here */
++ if (event->type == GDK_BUTTON_PRESS)
++ {
++ if (!GTK_WIDGET_IS_SENSITIVE (event_widget))
++ {
++ gtk_widget_insensitive_press(event_widget);
++ }
++ }
+
+ /* Not all events get sent to the grabbing widget.
+ * The delete, destroy, expose, focus change and resize
+@@ -2090,7 +2100,7 @@
+ handled_event = FALSE;
+
+ g_object_ref (widget);
+-
++
+ if ((event->type == GDK_KEY_PRESS) ||
+ (event->type == GDK_KEY_RELEASE))
+ {
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshal.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshal.c.diff
index e69de29bb2..80c0618bf9 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshal.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshal.c.diff
@@ -0,0 +1,266 @@
+--- gtk+-2.6.4/gtk/gtkmarshal.c 2005-03-01 17:58:15.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkmarshal.c 2005-04-06 16:19:36.898928872 +0300
+@@ -48,7 +48,7 @@
+ #endif /* !G_ENABLE_DEBUG */
+
+
+-/* BOOL:NONE (./gtkmarshal.list:1) */
++/* BOOL:NONE (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:1) */
+ void
+ gtk_marshal_BOOLEAN__VOID (GClosure *closure,
+ GValue *return_value,
+@@ -85,7 +85,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOL:POINTER (./gtkmarshal.list:2) */
++/* BOOL:POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:2) */
+ void
+ gtk_marshal_BOOLEAN__POINTER (GClosure *closure,
+ GValue *return_value,
+@@ -124,7 +124,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOL:POINTER,POINTER,INT,INT (./gtkmarshal.list:3) */
++/* BOOL:POINTER,POINTER,INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:3) */
+ void
+ gtk_marshal_BOOLEAN__POINTER_POINTER_INT_INT (GClosure *closure,
+ GValue *return_value,
+@@ -169,7 +169,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOL:POINTER,INT,INT (./gtkmarshal.list:4) */
++/* BOOL:POINTER,INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:4) */
+ void
+ gtk_marshal_BOOLEAN__POINTER_INT_INT (GClosure *closure,
+ GValue *return_value,
+@@ -212,7 +212,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOL:POINTER,INT,INT,UINT (./gtkmarshal.list:5) */
++/* BOOL:POINTER,INT,INT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:5) */
+ void
+ gtk_marshal_BOOLEAN__POINTER_INT_INT_UINT (GClosure *closure,
+ GValue *return_value,
+@@ -257,7 +257,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOL:POINTER,STRING,STRING,POINTER (./gtkmarshal.list:6) */
++/* BOOL:POINTER,STRING,STRING,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:6) */
+ void
+ gtk_marshal_BOOLEAN__POINTER_STRING_STRING_POINTER (GClosure *closure,
+ GValue *return_value,
+@@ -302,7 +302,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* ENUM:ENUM (./gtkmarshal.list:7) */
++/* ENUM:ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:7) */
+ void
+ gtk_marshal_ENUM__ENUM (GClosure *closure,
+ GValue *return_value,
+@@ -341,7 +341,7 @@
+ g_value_set_enum (return_value, v_return);
+ }
+
+-/* INT:POINTER (./gtkmarshal.list:8) */
++/* INT:POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:8) */
+ void
+ gtk_marshal_INT__POINTER (GClosure *closure,
+ GValue *return_value,
+@@ -380,7 +380,7 @@
+ g_value_set_int (return_value, v_return);
+ }
+
+-/* INT:POINTER,CHAR,CHAR (./gtkmarshal.list:9) */
++/* INT:POINTER,CHAR,CHAR (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:9) */
+ void
+ gtk_marshal_INT__POINTER_CHAR_CHAR (GClosure *closure,
+ GValue *return_value,
+@@ -423,13 +423,13 @@
+ g_value_set_int (return_value, v_return);
+ }
+
+-/* NONE:BOOL (./gtkmarshal.list:10) */
++/* NONE:BOOL (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:10) */
+
+-/* NONE:BOXED (./gtkmarshal.list:11) */
++/* NONE:BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:11) */
+
+-/* NONE:ENUM (./gtkmarshal.list:12) */
++/* NONE:ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:12) */
+
+-/* NONE:ENUM,FLOAT (./gtkmarshal.list:13) */
++/* NONE:ENUM,FLOAT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:13) */
+ void
+ gtk_marshal_VOID__ENUM_FLOAT (GClosure *closure,
+ GValue *return_value,
+@@ -466,7 +466,7 @@
+ data2);
+ }
+
+-/* NONE:ENUM,FLOAT,BOOL (./gtkmarshal.list:14) */
++/* NONE:ENUM,FLOAT,BOOL (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:14) */
+ void
+ gtk_marshal_VOID__ENUM_FLOAT_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+@@ -505,9 +505,9 @@
+ data2);
+ }
+
+-/* NONE:INT (./gtkmarshal.list:15) */
++/* NONE:INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:15) */
+
+-/* NONE:INT,INT (./gtkmarshal.list:16) */
++/* NONE:INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:16) */
+ void
+ gtk_marshal_VOID__INT_INT (GClosure *closure,
+ GValue *return_value,
+@@ -544,7 +544,7 @@
+ data2);
+ }
+
+-/* NONE:INT,INT,POINTER (./gtkmarshal.list:17) */
++/* NONE:INT,INT,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:17) */
+ void
+ gtk_marshal_VOID__INT_INT_POINTER (GClosure *closure,
+ GValue *return_value,
+@@ -583,13 +583,13 @@
+ data2);
+ }
+
+-/* NONE:NONE (./gtkmarshal.list:18) */
++/* NONE:NONE (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:18) */
+
+-/* NONE:OBJECT (./gtkmarshal.list:19) */
++/* NONE:OBJECT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:19) */
+
+-/* NONE:POINTER (./gtkmarshal.list:20) */
++/* NONE:POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:20) */
+
+-/* NONE:POINTER,INT (./gtkmarshal.list:21) */
++/* NONE:POINTER,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:21) */
+ void
+ gtk_marshal_VOID__POINTER_INT (GClosure *closure,
+ GValue *return_value,
+@@ -626,7 +626,7 @@
+ data2);
+ }
+
+-/* NONE:POINTER,POINTER (./gtkmarshal.list:22) */
++/* NONE:POINTER,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:22) */
+ void
+ gtk_marshal_VOID__POINTER_POINTER (GClosure *closure,
+ GValue *return_value,
+@@ -663,7 +663,7 @@
+ data2);
+ }
+
+-/* NONE:POINTER,POINTER,POINTER (./gtkmarshal.list:23) */
++/* NONE:POINTER,POINTER,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:23) */
+ void
+ gtk_marshal_VOID__POINTER_POINTER_POINTER (GClosure *closure,
+ GValue *return_value,
+@@ -702,7 +702,7 @@
+ data2);
+ }
+
+-/* NONE:POINTER,STRING,STRING (./gtkmarshal.list:24) */
++/* NONE:POINTER,STRING,STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:24) */
+ void
+ gtk_marshal_VOID__POINTER_STRING_STRING (GClosure *closure,
+ GValue *return_value,
+@@ -741,7 +741,7 @@
+ data2);
+ }
+
+-/* NONE:POINTER,UINT (./gtkmarshal.list:25) */
++/* NONE:POINTER,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:25) */
+ void
+ gtk_marshal_VOID__POINTER_UINT (GClosure *closure,
+ GValue *return_value,
+@@ -778,7 +778,7 @@
+ data2);
+ }
+
+-/* NONE:POINTER,UINT,ENUM (./gtkmarshal.list:26) */
++/* NONE:POINTER,UINT,ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:26) */
+ void
+ gtk_marshal_VOID__POINTER_UINT_ENUM (GClosure *closure,
+ GValue *return_value,
+@@ -817,7 +817,7 @@
+ data2);
+ }
+
+-/* NONE:POINTER,POINTER,UINT,UINT (./gtkmarshal.list:27) */
++/* NONE:POINTER,POINTER,UINT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:27) */
+ void
+ gtk_marshal_VOID__POINTER_POINTER_UINT_UINT (GClosure *closure,
+ GValue *return_value,
+@@ -858,7 +858,7 @@
+ data2);
+ }
+
+-/* NONE:POINTER,INT,INT,POINTER,UINT,UINT (./gtkmarshal.list:28) */
++/* NONE:POINTER,INT,INT,POINTER,UINT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:28) */
+ void
+ gtk_marshal_VOID__POINTER_INT_INT_POINTER_UINT_UINT (GClosure *closure,
+ GValue *return_value,
+@@ -903,7 +903,7 @@
+ data2);
+ }
+
+-/* NONE:POINTER,UINT,UINT (./gtkmarshal.list:29) */
++/* NONE:POINTER,UINT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:29) */
+ void
+ gtk_marshal_VOID__POINTER_UINT_UINT (GClosure *closure,
+ GValue *return_value,
+@@ -942,11 +942,11 @@
+ data2);
+ }
+
+-/* NONE:POINTER,UINT,UINT (./gtkmarshal.list:30) */
++/* NONE:POINTER,UINT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:30) */
+
+-/* NONE:STRING (./gtkmarshal.list:31) */
++/* NONE:STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:31) */
+
+-/* NONE:STRING,INT,POINTER (./gtkmarshal.list:32) */
++/* NONE:STRING,INT,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:32) */
+ void
+ gtk_marshal_VOID__STRING_INT_POINTER (GClosure *closure,
+ GValue *return_value,
+@@ -985,9 +985,9 @@
+ data2);
+ }
+
+-/* NONE:UINT (./gtkmarshal.list:33) */
++/* NONE:UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:33) */
+
+-/* NONE:UINT,POINTER,UINT,ENUM,ENUM,POINTER (./gtkmarshal.list:34) */
++/* NONE:UINT,POINTER,UINT,ENUM,ENUM,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:34) */
+ void
+ gtk_marshal_VOID__UINT_POINTER_UINT_ENUM_ENUM_POINTER (GClosure *closure,
+ GValue *return_value,
+@@ -1032,7 +1032,7 @@
+ data2);
+ }
+
+-/* NONE:UINT,POINTER,UINT,UINT,ENUM (./gtkmarshal.list:35) */
++/* NONE:UINT,POINTER,UINT,UINT,ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:35) */
+ void
+ gtk_marshal_VOID__UINT_POINTER_UINT_UINT_ENUM (GClosure *closure,
+ GValue *return_value,
+@@ -1075,7 +1075,7 @@
+ data2);
+ }
+
+-/* NONE:UINT,STRING (./gtkmarshal.list:36) */
++/* NONE:UINT,STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:36) */
+ void
+ gtk_marshal_VOID__UINT_STRING (GClosure *closure,
+ GValue *return_value,
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshal.h.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshal.h.diff
index e69de29bb2..9740129005 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshal.h.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshal.h.diff
@@ -0,0 +1,284 @@
+--- gtk+-2.6.4/gtk/gtkmarshal.h 2005-03-01 17:58:16.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkmarshal.h 2005-04-06 16:19:36.899928720 +0300
+@@ -7,7 +7,7 @@
+
+ G_BEGIN_DECLS
+
+-/* BOOL:NONE (./gtkmarshal.list:1) */
++/* BOOL:NONE (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:1) */
+ extern void gtk_marshal_BOOLEAN__VOID (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -16,7 +16,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_BOOL__NONE gtk_marshal_BOOLEAN__VOID
+
+-/* BOOL:POINTER (./gtkmarshal.list:2) */
++/* BOOL:POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:2) */
+ extern void gtk_marshal_BOOLEAN__POINTER (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -25,7 +25,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_BOOL__POINTER gtk_marshal_BOOLEAN__POINTER
+
+-/* BOOL:POINTER,POINTER,INT,INT (./gtkmarshal.list:3) */
++/* BOOL:POINTER,POINTER,INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:3) */
+ extern void gtk_marshal_BOOLEAN__POINTER_POINTER_INT_INT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -34,7 +34,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_BOOL__POINTER_POINTER_INT_INT gtk_marshal_BOOLEAN__POINTER_POINTER_INT_INT
+
+-/* BOOL:POINTER,INT,INT (./gtkmarshal.list:4) */
++/* BOOL:POINTER,INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:4) */
+ extern void gtk_marshal_BOOLEAN__POINTER_INT_INT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -43,7 +43,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_BOOL__POINTER_INT_INT gtk_marshal_BOOLEAN__POINTER_INT_INT
+
+-/* BOOL:POINTER,INT,INT,UINT (./gtkmarshal.list:5) */
++/* BOOL:POINTER,INT,INT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:5) */
+ extern void gtk_marshal_BOOLEAN__POINTER_INT_INT_UINT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -52,7 +52,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_BOOL__POINTER_INT_INT_UINT gtk_marshal_BOOLEAN__POINTER_INT_INT_UINT
+
+-/* BOOL:POINTER,STRING,STRING,POINTER (./gtkmarshal.list:6) */
++/* BOOL:POINTER,STRING,STRING,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:6) */
+ extern void gtk_marshal_BOOLEAN__POINTER_STRING_STRING_POINTER (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -61,7 +61,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_BOOL__POINTER_STRING_STRING_POINTER gtk_marshal_BOOLEAN__POINTER_STRING_STRING_POINTER
+
+-/* ENUM:ENUM (./gtkmarshal.list:7) */
++/* ENUM:ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:7) */
+ extern void gtk_marshal_ENUM__ENUM (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -69,7 +69,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* INT:POINTER (./gtkmarshal.list:8) */
++/* INT:POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:8) */
+ extern void gtk_marshal_INT__POINTER (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -77,7 +77,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* INT:POINTER,CHAR,CHAR (./gtkmarshal.list:9) */
++/* INT:POINTER,CHAR,CHAR (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:9) */
+ extern void gtk_marshal_INT__POINTER_CHAR_CHAR (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -85,19 +85,19 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* NONE:BOOL (./gtkmarshal.list:10) */
++/* NONE:BOOL (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:10) */
+ #define gtk_marshal_VOID__BOOLEAN g_cclosure_marshal_VOID__BOOLEAN
+ #define gtk_marshal_NONE__BOOL gtk_marshal_VOID__BOOLEAN
+
+-/* NONE:BOXED (./gtkmarshal.list:11) */
++/* NONE:BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:11) */
+ #define gtk_marshal_VOID__BOXED g_cclosure_marshal_VOID__BOXED
+ #define gtk_marshal_NONE__BOXED gtk_marshal_VOID__BOXED
+
+-/* NONE:ENUM (./gtkmarshal.list:12) */
++/* NONE:ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:12) */
+ #define gtk_marshal_VOID__ENUM g_cclosure_marshal_VOID__ENUM
+ #define gtk_marshal_NONE__ENUM gtk_marshal_VOID__ENUM
+
+-/* NONE:ENUM,FLOAT (./gtkmarshal.list:13) */
++/* NONE:ENUM,FLOAT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:13) */
+ extern void gtk_marshal_VOID__ENUM_FLOAT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -106,7 +106,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_NONE__ENUM_FLOAT gtk_marshal_VOID__ENUM_FLOAT
+
+-/* NONE:ENUM,FLOAT,BOOL (./gtkmarshal.list:14) */
++/* NONE:ENUM,FLOAT,BOOL (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:14) */
+ extern void gtk_marshal_VOID__ENUM_FLOAT_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -115,11 +115,11 @@
+ gpointer marshal_data);
+ #define gtk_marshal_NONE__ENUM_FLOAT_BOOL gtk_marshal_VOID__ENUM_FLOAT_BOOLEAN
+
+-/* NONE:INT (./gtkmarshal.list:15) */
++/* NONE:INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:15) */
+ #define gtk_marshal_VOID__INT g_cclosure_marshal_VOID__INT
+ #define gtk_marshal_NONE__INT gtk_marshal_VOID__INT
+
+-/* NONE:INT,INT (./gtkmarshal.list:16) */
++/* NONE:INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:16) */
+ extern void gtk_marshal_VOID__INT_INT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -128,7 +128,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_NONE__INT_INT gtk_marshal_VOID__INT_INT
+
+-/* NONE:INT,INT,POINTER (./gtkmarshal.list:17) */
++/* NONE:INT,INT,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:17) */
+ extern void gtk_marshal_VOID__INT_INT_POINTER (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -137,19 +137,19 @@
+ gpointer marshal_data);
+ #define gtk_marshal_NONE__INT_INT_POINTER gtk_marshal_VOID__INT_INT_POINTER
+
+-/* NONE:NONE (./gtkmarshal.list:18) */
++/* NONE:NONE (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:18) */
+ #define gtk_marshal_VOID__VOID g_cclosure_marshal_VOID__VOID
+ #define gtk_marshal_NONE__NONE gtk_marshal_VOID__VOID
+
+-/* NONE:OBJECT (./gtkmarshal.list:19) */
++/* NONE:OBJECT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:19) */
+ #define gtk_marshal_VOID__OBJECT g_cclosure_marshal_VOID__OBJECT
+ #define gtk_marshal_NONE__OBJECT gtk_marshal_VOID__OBJECT
+
+-/* NONE:POINTER (./gtkmarshal.list:20) */
++/* NONE:POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:20) */
+ #define gtk_marshal_VOID__POINTER g_cclosure_marshal_VOID__POINTER
+ #define gtk_marshal_NONE__POINTER gtk_marshal_VOID__POINTER
+
+-/* NONE:POINTER,INT (./gtkmarshal.list:21) */
++/* NONE:POINTER,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:21) */
+ extern void gtk_marshal_VOID__POINTER_INT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -158,7 +158,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_NONE__POINTER_INT gtk_marshal_VOID__POINTER_INT
+
+-/* NONE:POINTER,POINTER (./gtkmarshal.list:22) */
++/* NONE:POINTER,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:22) */
+ extern void gtk_marshal_VOID__POINTER_POINTER (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -167,7 +167,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_NONE__POINTER_POINTER gtk_marshal_VOID__POINTER_POINTER
+
+-/* NONE:POINTER,POINTER,POINTER (./gtkmarshal.list:23) */
++/* NONE:POINTER,POINTER,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:23) */
+ extern void gtk_marshal_VOID__POINTER_POINTER_POINTER (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -176,7 +176,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_NONE__POINTER_POINTER_POINTER gtk_marshal_VOID__POINTER_POINTER_POINTER
+
+-/* NONE:POINTER,STRING,STRING (./gtkmarshal.list:24) */
++/* NONE:POINTER,STRING,STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:24) */
+ extern void gtk_marshal_VOID__POINTER_STRING_STRING (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -185,7 +185,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_NONE__POINTER_STRING_STRING gtk_marshal_VOID__POINTER_STRING_STRING
+
+-/* NONE:POINTER,UINT (./gtkmarshal.list:25) */
++/* NONE:POINTER,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:25) */
+ extern void gtk_marshal_VOID__POINTER_UINT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -194,7 +194,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_NONE__POINTER_UINT gtk_marshal_VOID__POINTER_UINT
+
+-/* NONE:POINTER,UINT,ENUM (./gtkmarshal.list:26) */
++/* NONE:POINTER,UINT,ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:26) */
+ extern void gtk_marshal_VOID__POINTER_UINT_ENUM (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -203,7 +203,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_NONE__POINTER_UINT_ENUM gtk_marshal_VOID__POINTER_UINT_ENUM
+
+-/* NONE:POINTER,POINTER,UINT,UINT (./gtkmarshal.list:27) */
++/* NONE:POINTER,POINTER,UINT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:27) */
+ extern void gtk_marshal_VOID__POINTER_POINTER_UINT_UINT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -212,7 +212,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_NONE__POINTER_POINTER_UINT_UINT gtk_marshal_VOID__POINTER_POINTER_UINT_UINT
+
+-/* NONE:POINTER,INT,INT,POINTER,UINT,UINT (./gtkmarshal.list:28) */
++/* NONE:POINTER,INT,INT,POINTER,UINT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:28) */
+ extern void gtk_marshal_VOID__POINTER_INT_INT_POINTER_UINT_UINT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -221,7 +221,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_NONE__POINTER_INT_INT_POINTER_UINT_UINT gtk_marshal_VOID__POINTER_INT_INT_POINTER_UINT_UINT
+
+-/* NONE:POINTER,UINT,UINT (./gtkmarshal.list:29) */
++/* NONE:POINTER,UINT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:29) */
+ extern void gtk_marshal_VOID__POINTER_UINT_UINT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -230,13 +230,13 @@
+ gpointer marshal_data);
+ #define gtk_marshal_NONE__POINTER_UINT_UINT gtk_marshal_VOID__POINTER_UINT_UINT
+
+-/* NONE:POINTER,UINT,UINT (./gtkmarshal.list:30) */
++/* NONE:POINTER,UINT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:30) */
+
+-/* NONE:STRING (./gtkmarshal.list:31) */
++/* NONE:STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:31) */
+ #define gtk_marshal_VOID__STRING g_cclosure_marshal_VOID__STRING
+ #define gtk_marshal_NONE__STRING gtk_marshal_VOID__STRING
+
+-/* NONE:STRING,INT,POINTER (./gtkmarshal.list:32) */
++/* NONE:STRING,INT,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:32) */
+ extern void gtk_marshal_VOID__STRING_INT_POINTER (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -245,11 +245,11 @@
+ gpointer marshal_data);
+ #define gtk_marshal_NONE__STRING_INT_POINTER gtk_marshal_VOID__STRING_INT_POINTER
+
+-/* NONE:UINT (./gtkmarshal.list:33) */
++/* NONE:UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:33) */
+ #define gtk_marshal_VOID__UINT g_cclosure_marshal_VOID__UINT
+ #define gtk_marshal_NONE__UINT gtk_marshal_VOID__UINT
+
+-/* NONE:UINT,POINTER,UINT,ENUM,ENUM,POINTER (./gtkmarshal.list:34) */
++/* NONE:UINT,POINTER,UINT,ENUM,ENUM,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:34) */
+ extern void gtk_marshal_VOID__UINT_POINTER_UINT_ENUM_ENUM_POINTER (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -258,7 +258,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_NONE__UINT_POINTER_UINT_ENUM_ENUM_POINTER gtk_marshal_VOID__UINT_POINTER_UINT_ENUM_ENUM_POINTER
+
+-/* NONE:UINT,POINTER,UINT,UINT,ENUM (./gtkmarshal.list:35) */
++/* NONE:UINT,POINTER,UINT,UINT,ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:35) */
+ extern void gtk_marshal_VOID__UINT_POINTER_UINT_UINT_ENUM (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -267,7 +267,7 @@
+ gpointer marshal_data);
+ #define gtk_marshal_NONE__UINT_POINTER_UINT_UINT_ENUM gtk_marshal_VOID__UINT_POINTER_UINT_UINT_ENUM
+
+-/* NONE:UINT,STRING (./gtkmarshal.list:36) */
++/* NONE:UINT,STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshal.list:36) */
+ extern void gtk_marshal_VOID__UINT_STRING (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshalers.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshalers.c.diff
index e69de29bb2..7f22a0e5d9 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshalers.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshalers.c.diff
@@ -0,0 +1,606 @@
+--- gtk+-2.6.4/gtk/gtkmarshalers.c 2005-03-01 17:58:15.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkmarshalers.c 2005-04-06 16:19:36.902928264 +0300
+@@ -48,7 +48,7 @@
+ #endif /* !G_ENABLE_DEBUG */
+
+
+-/* BOOLEAN:BOXED (./gtkmarshalers.list:24) */
++/* BOOLEAN:BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:24) */
+ void
+ _gtk_marshal_BOOLEAN__BOXED (GClosure *closure,
+ GValue *return_value,
+@@ -87,7 +87,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOLEAN:BOXED,BOXED (./gtkmarshalers.list:25) */
++/* BOOLEAN:BOXED,BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:25) */
+ void
+ _gtk_marshal_BOOLEAN__BOXED_BOXED (GClosure *closure,
+ GValue *return_value,
+@@ -128,7 +128,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOLEAN:ENUM (./gtkmarshalers.list:26) */
++/* BOOLEAN:ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:26) */
+ void
+ _gtk_marshal_BOOLEAN__ENUM (GClosure *closure,
+ GValue *return_value,
+@@ -167,7 +167,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOLEAN:ENUM,DOUBLE (./gtkmarshalers.list:27) */
++/* BOOLEAN:ENUM,DOUBLE (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:27) */
+ void
+ _gtk_marshal_BOOLEAN__ENUM_DOUBLE (GClosure *closure,
+ GValue *return_value,
+@@ -208,7 +208,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOLEAN:ENUM,INT (./gtkmarshalers.list:28) */
++/* BOOLEAN:ENUM,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:28) */
+ void
+ _gtk_marshal_BOOLEAN__ENUM_INT (GClosure *closure,
+ GValue *return_value,
+@@ -249,7 +249,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOLEAN:OBJECT,UINT,FLAGS (./gtkmarshalers.list:29) */
++/* BOOLEAN:OBJECT,UINT,FLAGS (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:29) */
+ void
+ _gtk_marshal_BOOLEAN__OBJECT_UINT_FLAGS (GClosure *closure,
+ GValue *return_value,
+@@ -292,7 +292,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOLEAN:OBJECT,INT,INT,UINT (./gtkmarshalers.list:30) */
++/* BOOLEAN:OBJECT,INT,INT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:30) */
+ void
+ _gtk_marshal_BOOLEAN__OBJECT_INT_INT_UINT (GClosure *closure,
+ GValue *return_value,
+@@ -337,7 +337,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOLEAN:OBJECT,STRING,STRING,BOXED (./gtkmarshalers.list:31) */
++/* BOOLEAN:OBJECT,STRING,STRING,BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:31) */
+ void
+ _gtk_marshal_BOOLEAN__OBJECT_STRING_STRING_BOXED (GClosure *closure,
+ GValue *return_value,
+@@ -382,7 +382,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOLEAN:OBJECT,BOXED (./gtkmarshalers.list:32) */
++/* BOOLEAN:OBJECT,BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:32) */
+ void
+ _gtk_marshal_BOOLEAN__OBJECT_BOXED (GClosure *closure,
+ GValue *return_value,
+@@ -423,7 +423,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOLEAN:OBJECT,BOXED,BOXED (./gtkmarshalers.list:33) */
++/* BOOLEAN:OBJECT,BOXED,BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:33) */
+ void
+ _gtk_marshal_BOOLEAN__OBJECT_BOXED_BOXED (GClosure *closure,
+ GValue *return_value,
+@@ -466,7 +466,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOLEAN:OBJECT,STRING,STRING (./gtkmarshalers.list:34) */
++/* BOOLEAN:OBJECT,STRING,STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:34) */
+ void
+ _gtk_marshal_BOOLEAN__OBJECT_STRING_STRING (GClosure *closure,
+ GValue *return_value,
+@@ -509,7 +509,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOLEAN:INT,INT (./gtkmarshalers.list:35) */
++/* BOOLEAN:INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:35) */
+ void
+ _gtk_marshal_BOOLEAN__INT_INT (GClosure *closure,
+ GValue *return_value,
+@@ -550,7 +550,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOLEAN:INT,INT,INT (./gtkmarshalers.list:36) */
++/* BOOLEAN:INT,INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:36) */
+ void
+ _gtk_marshal_BOOLEAN__INT_INT_INT (GClosure *closure,
+ GValue *return_value,
+@@ -593,7 +593,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOLEAN:UINT (./gtkmarshalers.list:37) */
++/* BOOLEAN:UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:37) */
+ void
+ _gtk_marshal_BOOLEAN__UINT (GClosure *closure,
+ GValue *return_value,
+@@ -632,7 +632,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOLEAN:VOID (./gtkmarshalers.list:38) */
++/* BOOLEAN:VOID (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:38) */
+ void
+ _gtk_marshal_BOOLEAN__VOID (GClosure *closure,
+ GValue *return_value,
+@@ -669,7 +669,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOLEAN:BOOLEAN (./gtkmarshalers.list:39) */
++/* BOOLEAN:BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:39) */
+ void
+ _gtk_marshal_BOOLEAN__BOOLEAN (GClosure *closure,
+ GValue *return_value,
+@@ -708,9 +708,9 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOLEAN:NONE (./gtkmarshalers.list:40) */
++/* BOOLEAN:NONE (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:40) */
+
+-/* BOOLEAN:BOOLEAN,BOOLEAN,BOOLEAN (./gtkmarshalers.list:41) */
++/* BOOLEAN:BOOLEAN,BOOLEAN,BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:41) */
+ void
+ _gtk_marshal_BOOLEAN__BOOLEAN_BOOLEAN_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+@@ -753,7 +753,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* BOOLEAN:STRING (./gtkmarshalers.list:42) */
++/* BOOLEAN:STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:42) */
+ void
+ _gtk_marshal_BOOLEAN__STRING (GClosure *closure,
+ GValue *return_value,
+@@ -792,7 +792,7 @@
+ g_value_set_boolean (return_value, v_return);
+ }
+
+-/* ENUM:ENUM (./gtkmarshalers.list:43) */
++/* ENUM:ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:43) */
+ void
+ _gtk_marshal_ENUM__ENUM (GClosure *closure,
+ GValue *return_value,
+@@ -831,7 +831,7 @@
+ g_value_set_enum (return_value, v_return);
+ }
+
+-/* INT:POINTER (./gtkmarshalers.list:44) */
++/* INT:POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:44) */
+ void
+ _gtk_marshal_INT__POINTER (GClosure *closure,
+ GValue *return_value,
+@@ -870,13 +870,13 @@
+ g_value_set_int (return_value, v_return);
+ }
+
+-/* NONE:BOOLEAN (./gtkmarshalers.list:45) */
++/* NONE:BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:45) */
+
+-/* NONE:ENUM (./gtkmarshalers.list:46) */
++/* NONE:ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:46) */
+
+-/* NONE:INT (./gtkmarshalers.list:47) */
++/* NONE:INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:47) */
+
+-/* NONE:INT,BOOL (./gtkmarshalers.list:48) */
++/* NONE:INT,BOOL (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:48) */
+ void
+ _gtk_marshal_VOID__INT_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+@@ -913,7 +913,7 @@
+ data2);
+ }
+
+-/* NONE:INT,INT (./gtkmarshalers.list:49) */
++/* NONE:INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:49) */
+ void
+ _gtk_marshal_VOID__INT_INT (GClosure *closure,
+ GValue *return_value,
+@@ -950,9 +950,9 @@
+ data2);
+ }
+
+-/* NONE:NONE (./gtkmarshalers.list:50) */
++/* NONE:NONE (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:50) */
+
+-/* NONE:STRING,INT,POINTER (./gtkmarshalers.list:51) */
++/* NONE:STRING,INT,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:51) */
+ void
+ _gtk_marshal_VOID__STRING_INT_POINTER (GClosure *closure,
+ GValue *return_value,
+@@ -991,7 +991,7 @@
+ data2);
+ }
+
+-/* STRING:DOUBLE (./gtkmarshalers.list:52) */
++/* STRING:DOUBLE (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:52) */
+ void
+ _gtk_marshal_STRING__DOUBLE (GClosure *closure,
+ GValue *return_value,
+@@ -1030,11 +1030,11 @@
+ g_value_take_string (return_value, v_return);
+ }
+
+-/* VOID:DOUBLE (./gtkmarshalers.list:53) */
++/* VOID:DOUBLE (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:53) */
+
+-/* VOID:BOOLEAN (./gtkmarshalers.list:54) */
++/* VOID:BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:54) */
+
+-/* VOID:BOOLEAN,BOOLEAN,BOOLEAN (./gtkmarshalers.list:55) */
++/* VOID:BOOLEAN,BOOLEAN,BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:55) */
+ void
+ _gtk_marshal_VOID__BOOLEAN_BOOLEAN_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+@@ -1073,9 +1073,9 @@
+ data2);
+ }
+
+-/* VOID:BOXED (./gtkmarshalers.list:56) */
++/* VOID:BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:56) */
+
+-/* VOID:BOXED,BOXED (./gtkmarshalers.list:57) */
++/* VOID:BOXED,BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:57) */
+ void
+ _gtk_marshal_VOID__BOXED_BOXED (GClosure *closure,
+ GValue *return_value,
+@@ -1112,7 +1112,7 @@
+ data2);
+ }
+
+-/* VOID:BOXED,BOXED,POINTER (./gtkmarshalers.list:58) */
++/* VOID:BOXED,BOXED,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:58) */
+ void
+ _gtk_marshal_VOID__BOXED_BOXED_POINTER (GClosure *closure,
+ GValue *return_value,
+@@ -1151,7 +1151,7 @@
+ data2);
+ }
+
+-/* VOID:BOXED,OBJECT (./gtkmarshalers.list:59) */
++/* VOID:BOXED,OBJECT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:59) */
+ void
+ _gtk_marshal_VOID__BOXED_OBJECT (GClosure *closure,
+ GValue *return_value,
+@@ -1188,7 +1188,7 @@
+ data2);
+ }
+
+-/* VOID:BOXED,STRING,INT (./gtkmarshalers.list:60) */
++/* VOID:BOXED,STRING,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:60) */
+ void
+ _gtk_marshal_VOID__BOXED_STRING_INT (GClosure *closure,
+ GValue *return_value,
+@@ -1227,7 +1227,7 @@
+ data2);
+ }
+
+-/* VOID:BOXED,UINT (./gtkmarshalers.list:61) */
++/* VOID:BOXED,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:61) */
+ void
+ _gtk_marshal_VOID__BOXED_UINT (GClosure *closure,
+ GValue *return_value,
+@@ -1264,7 +1264,7 @@
+ data2);
+ }
+
+-/* VOID:BOXED,UINT,FLAGS (./gtkmarshalers.list:62) */
++/* VOID:BOXED,UINT,FLAGS (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:62) */
+ void
+ _gtk_marshal_VOID__BOXED_UINT_FLAGS (GClosure *closure,
+ GValue *return_value,
+@@ -1303,7 +1303,7 @@
+ data2);
+ }
+
+-/* VOID:BOXED,UINT,UINT (./gtkmarshalers.list:63) */
++/* VOID:BOXED,UINT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:63) */
+ void
+ _gtk_marshal_VOID__BOXED_UINT_UINT (GClosure *closure,
+ GValue *return_value,
+@@ -1342,9 +1342,9 @@
+ data2);
+ }
+
+-/* VOID:ENUM (./gtkmarshalers.list:64) */
++/* VOID:ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:64) */
+
+-/* VOID:ENUM,BOOLEAN (./gtkmarshalers.list:65) */
++/* VOID:ENUM,BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:65) */
+ void
+ _gtk_marshal_VOID__ENUM_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+@@ -1381,7 +1381,7 @@
+ data2);
+ }
+
+-/* VOID:ENUM,ENUM (./gtkmarshalers.list:66) */
++/* VOID:ENUM,ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:66) */
+ void
+ _gtk_marshal_VOID__ENUM_ENUM (GClosure *closure,
+ GValue *return_value,
+@@ -1418,7 +1418,7 @@
+ data2);
+ }
+
+-/* VOID:ENUM,FLOAT (./gtkmarshalers.list:67) */
++/* VOID:ENUM,FLOAT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:67) */
+ void
+ _gtk_marshal_VOID__ENUM_FLOAT (GClosure *closure,
+ GValue *return_value,
+@@ -1455,7 +1455,7 @@
+ data2);
+ }
+
+-/* VOID:ENUM,FLOAT,BOOLEAN (./gtkmarshalers.list:68) */
++/* VOID:ENUM,FLOAT,BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:68) */
+ void
+ _gtk_marshal_VOID__ENUM_FLOAT_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+@@ -1494,7 +1494,7 @@
+ data2);
+ }
+
+-/* VOID:ENUM,INT (./gtkmarshalers.list:69) */
++/* VOID:ENUM,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:69) */
+ void
+ _gtk_marshal_VOID__ENUM_INT (GClosure *closure,
+ GValue *return_value,
+@@ -1531,7 +1531,7 @@
+ data2);
+ }
+
+-/* VOID:ENUM,INT,BOOLEAN (./gtkmarshalers.list:70) */
++/* VOID:ENUM,INT,BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:70) */
+ void
+ _gtk_marshal_VOID__ENUM_INT_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+@@ -1570,11 +1570,11 @@
+ data2);
+ }
+
+-/* VOID:INT (./gtkmarshalers.list:71) */
++/* VOID:INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:71) */
+
+-/* VOID:INT,INT (./gtkmarshalers.list:72) */
++/* VOID:INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:72) */
+
+-/* VOID:INT,INT,BOXED (./gtkmarshalers.list:73) */
++/* VOID:INT,INT,BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:73) */
+ void
+ _gtk_marshal_VOID__INT_INT_BOXED (GClosure *closure,
+ GValue *return_value,
+@@ -1613,7 +1613,7 @@
+ data2);
+ }
+
+-/* VOID:INT,INT,INT (./gtkmarshalers.list:74) */
++/* VOID:INT,INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:74) */
+ void
+ _gtk_marshal_VOID__INT_INT_INT (GClosure *closure,
+ GValue *return_value,
+@@ -1652,9 +1652,9 @@
+ data2);
+ }
+
+-/* VOID:OBJECT (./gtkmarshalers.list:75) */
++/* VOID:OBJECT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:75) */
+
+-/* VOID:OBJECT,BOOLEAN (./gtkmarshalers.list:76) */
++/* VOID:OBJECT,BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:76) */
+ void
+ _gtk_marshal_VOID__OBJECT_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+@@ -1691,7 +1691,7 @@
+ data2);
+ }
+
+-/* VOID:OBJECT,BOXED,BOXED (./gtkmarshalers.list:77) */
++/* VOID:OBJECT,BOXED,BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:77) */
+ void
+ _gtk_marshal_VOID__OBJECT_BOXED_BOXED (GClosure *closure,
+ GValue *return_value,
+@@ -1730,7 +1730,7 @@
+ data2);
+ }
+
+-/* VOID:OBJECT,BOXED,UINT,UINT (./gtkmarshalers.list:78) */
++/* VOID:OBJECT,BOXED,UINT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:78) */
+ void
+ _gtk_marshal_VOID__OBJECT_BOXED_UINT_UINT (GClosure *closure,
+ GValue *return_value,
+@@ -1771,7 +1771,7 @@
+ data2);
+ }
+
+-/* VOID:OBJECT,INT,INT (./gtkmarshalers.list:79) */
++/* VOID:OBJECT,INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:79) */
+ void
+ _gtk_marshal_VOID__OBJECT_INT_INT (GClosure *closure,
+ GValue *return_value,
+@@ -1810,7 +1810,7 @@
+ data2);
+ }
+
+-/* VOID:OBJECT,INT,INT,BOXED,UINT,UINT (./gtkmarshalers.list:80) */
++/* VOID:OBJECT,INT,INT,BOXED,UINT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:80) */
+ void
+ _gtk_marshal_VOID__OBJECT_INT_INT_BOXED_UINT_UINT (GClosure *closure,
+ GValue *return_value,
+@@ -1855,7 +1855,7 @@
+ data2);
+ }
+
+-/* VOID:OBJECT,OBJECT (./gtkmarshalers.list:81) */
++/* VOID:OBJECT,OBJECT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:81) */
+ void
+ _gtk_marshal_VOID__OBJECT_OBJECT (GClosure *closure,
+ GValue *return_value,
+@@ -1892,7 +1892,7 @@
+ data2);
+ }
+
+-/* VOID:OBJECT,STRING (./gtkmarshalers.list:82) */
++/* VOID:OBJECT,STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:82) */
+ void
+ _gtk_marshal_VOID__OBJECT_STRING (GClosure *closure,
+ GValue *return_value,
+@@ -1929,7 +1929,7 @@
+ data2);
+ }
+
+-/* VOID:OBJECT,STRING,STRING (./gtkmarshalers.list:83) */
++/* VOID:OBJECT,STRING,STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:83) */
+ void
+ _gtk_marshal_VOID__OBJECT_STRING_STRING (GClosure *closure,
+ GValue *return_value,
+@@ -1968,7 +1968,7 @@
+ data2);
+ }
+
+-/* VOID:OBJECT,UINT (./gtkmarshalers.list:84) */
++/* VOID:OBJECT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:84) */
+ void
+ _gtk_marshal_VOID__OBJECT_UINT (GClosure *closure,
+ GValue *return_value,
+@@ -2005,7 +2005,7 @@
+ data2);
+ }
+
+-/* VOID:OBJECT,UINT,FLAGS (./gtkmarshalers.list:85) */
++/* VOID:OBJECT,UINT,FLAGS (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:85) */
+ void
+ _gtk_marshal_VOID__OBJECT_UINT_FLAGS (GClosure *closure,
+ GValue *return_value,
+@@ -2044,11 +2044,11 @@
+ data2);
+ }
+
+-/* VOID:OBJECT,STRING (./gtkmarshalers.list:86) */
++/* VOID:OBJECT,STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:86) */
+
+-/* VOID:POINTER (./gtkmarshalers.list:87) */
++/* VOID:POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:87) */
+
+-/* VOID:POINTER,INT (./gtkmarshalers.list:88) */
++/* VOID:POINTER,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:88) */
+ void
+ _gtk_marshal_VOID__POINTER_INT (GClosure *closure,
+ GValue *return_value,
+@@ -2085,7 +2085,7 @@
+ data2);
+ }
+
+-/* VOID:POINTER,BOOLEAN (./gtkmarshalers.list:89) */
++/* VOID:POINTER,BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:89) */
+ void
+ _gtk_marshal_VOID__POINTER_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+@@ -2122,7 +2122,7 @@
+ data2);
+ }
+
+-/* VOID:POINTER,POINTER,POINTER (./gtkmarshalers.list:90) */
++/* VOID:POINTER,POINTER,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:90) */
+ void
+ _gtk_marshal_VOID__POINTER_POINTER_POINTER (GClosure *closure,
+ GValue *return_value,
+@@ -2161,7 +2161,7 @@
+ data2);
+ }
+
+-/* VOID:POINTER,UINT (./gtkmarshalers.list:91) */
++/* VOID:POINTER,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:91) */
+ void
+ _gtk_marshal_VOID__POINTER_UINT (GClosure *closure,
+ GValue *return_value,
+@@ -2198,9 +2198,9 @@
+ data2);
+ }
+
+-/* VOID:STRING (./gtkmarshalers.list:92) */
++/* VOID:STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:92) */
+
+-/* VOID:STRING,STRING (./gtkmarshalers.list:93) */
++/* VOID:STRING,STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:93) */
+ void
+ _gtk_marshal_VOID__STRING_STRING (GClosure *closure,
+ GValue *return_value,
+@@ -2237,9 +2237,9 @@
+ data2);
+ }
+
+-/* VOID:STRING,INT,POINTER (./gtkmarshalers.list:94) */
++/* VOID:STRING,INT,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:94) */
+
+-/* VOID:STRING,UINT,FLAGS (./gtkmarshalers.list:95) */
++/* VOID:STRING,UINT,FLAGS (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:95) */
+ void
+ _gtk_marshal_VOID__STRING_UINT_FLAGS (GClosure *closure,
+ GValue *return_value,
+@@ -2278,7 +2278,7 @@
+ data2);
+ }
+
+-/* VOID:UINT,FLAGS,BOXED (./gtkmarshalers.list:96) */
++/* VOID:UINT,FLAGS,BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:96) */
+ void
+ _gtk_marshal_VOID__UINT_FLAGS_BOXED (GClosure *closure,
+ GValue *return_value,
+@@ -2317,7 +2317,7 @@
+ data2);
+ }
+
+-/* VOID:UINT,UINT (./gtkmarshalers.list:97) */
++/* VOID:UINT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:97) */
+ void
+ _gtk_marshal_VOID__UINT_UINT (GClosure *closure,
+ GValue *return_value,
+@@ -2354,7 +2354,7 @@
+ data2);
+ }
+
+-/* VOID:UINT,STRING (./gtkmarshalers.list:98) */
++/* VOID:UINT,STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:98) */
+ void
+ _gtk_marshal_VOID__UINT_STRING (GClosure *closure,
+ GValue *return_value,
+@@ -2391,7 +2391,7 @@
+ data2);
+ }
+
+-/* VOID:UINT,BOXED,UINT,FLAGS,FLAGS (./gtkmarshalers.list:99) */
++/* VOID:UINT,BOXED,UINT,FLAGS,FLAGS (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:99) */
+ void
+ _gtk_marshal_VOID__UINT_BOXED_UINT_FLAGS_FLAGS (GClosure *closure,
+ GValue *return_value,
+@@ -2434,7 +2434,7 @@
+ data2);
+ }
+
+-/* VOID:UINT,OBJECT,UINT,FLAGS,FLAGS (./gtkmarshalers.list:100) */
++/* VOID:UINT,OBJECT,UINT,FLAGS,FLAGS (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:100) */
+ void
+ _gtk_marshal_VOID__UINT_OBJECT_UINT_FLAGS_FLAGS (GClosure *closure,
+ GValue *return_value,
+@@ -2477,5 +2477,5 @@
+ data2);
+ }
+
+-/* VOID:VOID (./gtkmarshalers.list:101) */
++/* VOID:VOID (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:101) */
+
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshalers.h.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshalers.h.diff
index e69de29bb2..e6941631e4 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshalers.h.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshalers.h.diff
@@ -0,0 +1,622 @@
+--- gtk+-2.6.4/gtk/gtkmarshalers.h 2005-03-01 17:58:15.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkmarshalers.h 2005-04-06 16:19:36.903928112 +0300
+@@ -6,7 +6,7 @@
+
+ G_BEGIN_DECLS
+
+-/* BOOLEAN:BOXED (./gtkmarshalers.list:24) */
++/* BOOLEAN:BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:24) */
+ extern void _gtk_marshal_BOOLEAN__BOXED (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -14,7 +14,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* BOOLEAN:BOXED,BOXED (./gtkmarshalers.list:25) */
++/* BOOLEAN:BOXED,BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:25) */
+ extern void _gtk_marshal_BOOLEAN__BOXED_BOXED (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -22,7 +22,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* BOOLEAN:ENUM (./gtkmarshalers.list:26) */
++/* BOOLEAN:ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:26) */
+ extern void _gtk_marshal_BOOLEAN__ENUM (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -30,7 +30,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* BOOLEAN:ENUM,DOUBLE (./gtkmarshalers.list:27) */
++/* BOOLEAN:ENUM,DOUBLE (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:27) */
+ extern void _gtk_marshal_BOOLEAN__ENUM_DOUBLE (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -38,7 +38,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* BOOLEAN:ENUM,INT (./gtkmarshalers.list:28) */
++/* BOOLEAN:ENUM,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:28) */
+ extern void _gtk_marshal_BOOLEAN__ENUM_INT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -46,7 +46,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* BOOLEAN:OBJECT,UINT,FLAGS (./gtkmarshalers.list:29) */
++/* BOOLEAN:OBJECT,UINT,FLAGS (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:29) */
+ extern void _gtk_marshal_BOOLEAN__OBJECT_UINT_FLAGS (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -54,7 +54,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* BOOLEAN:OBJECT,INT,INT,UINT (./gtkmarshalers.list:30) */
++/* BOOLEAN:OBJECT,INT,INT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:30) */
+ extern void _gtk_marshal_BOOLEAN__OBJECT_INT_INT_UINT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -62,7 +62,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* BOOLEAN:OBJECT,STRING,STRING,BOXED (./gtkmarshalers.list:31) */
++/* BOOLEAN:OBJECT,STRING,STRING,BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:31) */
+ extern void _gtk_marshal_BOOLEAN__OBJECT_STRING_STRING_BOXED (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -70,7 +70,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* BOOLEAN:OBJECT,BOXED (./gtkmarshalers.list:32) */
++/* BOOLEAN:OBJECT,BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:32) */
+ extern void _gtk_marshal_BOOLEAN__OBJECT_BOXED (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -78,7 +78,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* BOOLEAN:OBJECT,BOXED,BOXED (./gtkmarshalers.list:33) */
++/* BOOLEAN:OBJECT,BOXED,BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:33) */
+ extern void _gtk_marshal_BOOLEAN__OBJECT_BOXED_BOXED (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -86,7 +86,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* BOOLEAN:OBJECT,STRING,STRING (./gtkmarshalers.list:34) */
++/* BOOLEAN:OBJECT,STRING,STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:34) */
+ extern void _gtk_marshal_BOOLEAN__OBJECT_STRING_STRING (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -94,7 +94,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* BOOLEAN:INT,INT (./gtkmarshalers.list:35) */
++/* BOOLEAN:INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:35) */
+ extern void _gtk_marshal_BOOLEAN__INT_INT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -102,7 +102,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* BOOLEAN:INT,INT,INT (./gtkmarshalers.list:36) */
++/* BOOLEAN:INT,INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:36) */
+ extern void _gtk_marshal_BOOLEAN__INT_INT_INT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -110,7 +110,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* BOOLEAN:UINT (./gtkmarshalers.list:37) */
++/* BOOLEAN:UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:37) */
+ extern void _gtk_marshal_BOOLEAN__UINT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -118,7 +118,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* BOOLEAN:VOID (./gtkmarshalers.list:38) */
++/* BOOLEAN:VOID (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:38) */
+ extern void _gtk_marshal_BOOLEAN__VOID (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -126,7 +126,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* BOOLEAN:BOOLEAN (./gtkmarshalers.list:39) */
++/* BOOLEAN:BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:39) */
+ extern void _gtk_marshal_BOOLEAN__BOOLEAN (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -134,10 +134,10 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* BOOLEAN:NONE (./gtkmarshalers.list:40) */
++/* BOOLEAN:NONE (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:40) */
+ #define _gtk_marshal_BOOLEAN__NONE _gtk_marshal_BOOLEAN__VOID
+
+-/* BOOLEAN:BOOLEAN,BOOLEAN,BOOLEAN (./gtkmarshalers.list:41) */
++/* BOOLEAN:BOOLEAN,BOOLEAN,BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:41) */
+ extern void _gtk_marshal_BOOLEAN__BOOLEAN_BOOLEAN_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -145,7 +145,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* BOOLEAN:STRING (./gtkmarshalers.list:42) */
++/* BOOLEAN:STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:42) */
+ extern void _gtk_marshal_BOOLEAN__STRING (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -153,7 +153,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* ENUM:ENUM (./gtkmarshalers.list:43) */
++/* ENUM:ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:43) */
+ extern void _gtk_marshal_ENUM__ENUM (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -161,7 +161,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* INT:POINTER (./gtkmarshalers.list:44) */
++/* INT:POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:44) */
+ extern void _gtk_marshal_INT__POINTER (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -169,19 +169,19 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* NONE:BOOLEAN (./gtkmarshalers.list:45) */
++/* NONE:BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:45) */
+ #define _gtk_marshal_VOID__BOOLEAN g_cclosure_marshal_VOID__BOOLEAN
+ #define _gtk_marshal_NONE__BOOLEAN _gtk_marshal_VOID__BOOLEAN
+
+-/* NONE:ENUM (./gtkmarshalers.list:46) */
++/* NONE:ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:46) */
+ #define _gtk_marshal_VOID__ENUM g_cclosure_marshal_VOID__ENUM
+ #define _gtk_marshal_NONE__ENUM _gtk_marshal_VOID__ENUM
+
+-/* NONE:INT (./gtkmarshalers.list:47) */
++/* NONE:INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:47) */
+ #define _gtk_marshal_VOID__INT g_cclosure_marshal_VOID__INT
+ #define _gtk_marshal_NONE__INT _gtk_marshal_VOID__INT
+
+-/* NONE:INT,BOOL (./gtkmarshalers.list:48) */
++/* NONE:INT,BOOL (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:48) */
+ extern void _gtk_marshal_VOID__INT_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -190,7 +190,7 @@
+ gpointer marshal_data);
+ #define _gtk_marshal_NONE__INT_BOOL _gtk_marshal_VOID__INT_BOOLEAN
+
+-/* NONE:INT,INT (./gtkmarshalers.list:49) */
++/* NONE:INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:49) */
+ extern void _gtk_marshal_VOID__INT_INT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -199,11 +199,11 @@
+ gpointer marshal_data);
+ #define _gtk_marshal_NONE__INT_INT _gtk_marshal_VOID__INT_INT
+
+-/* NONE:NONE (./gtkmarshalers.list:50) */
++/* NONE:NONE (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:50) */
+ #define _gtk_marshal_VOID__VOID g_cclosure_marshal_VOID__VOID
+ #define _gtk_marshal_NONE__NONE _gtk_marshal_VOID__VOID
+
+-/* NONE:STRING,INT,POINTER (./gtkmarshalers.list:51) */
++/* NONE:STRING,INT,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:51) */
+ extern void _gtk_marshal_VOID__STRING_INT_POINTER (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -212,7 +212,7 @@
+ gpointer marshal_data);
+ #define _gtk_marshal_NONE__STRING_INT_POINTER _gtk_marshal_VOID__STRING_INT_POINTER
+
+-/* STRING:DOUBLE (./gtkmarshalers.list:52) */
++/* STRING:DOUBLE (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:52) */
+ extern void _gtk_marshal_STRING__DOUBLE (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -220,12 +220,12 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:DOUBLE (./gtkmarshalers.list:53) */
++/* VOID:DOUBLE (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:53) */
+ #define _gtk_marshal_VOID__DOUBLE g_cclosure_marshal_VOID__DOUBLE
+
+-/* VOID:BOOLEAN (./gtkmarshalers.list:54) */
++/* VOID:BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:54) */
+
+-/* VOID:BOOLEAN,BOOLEAN,BOOLEAN (./gtkmarshalers.list:55) */
++/* VOID:BOOLEAN,BOOLEAN,BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:55) */
+ extern void _gtk_marshal_VOID__BOOLEAN_BOOLEAN_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -233,10 +233,10 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:BOXED (./gtkmarshalers.list:56) */
++/* VOID:BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:56) */
+ #define _gtk_marshal_VOID__BOXED g_cclosure_marshal_VOID__BOXED
+
+-/* VOID:BOXED,BOXED (./gtkmarshalers.list:57) */
++/* VOID:BOXED,BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:57) */
+ extern void _gtk_marshal_VOID__BOXED_BOXED (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -244,7 +244,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:BOXED,BOXED,POINTER (./gtkmarshalers.list:58) */
++/* VOID:BOXED,BOXED,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:58) */
+ extern void _gtk_marshal_VOID__BOXED_BOXED_POINTER (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -252,7 +252,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:BOXED,OBJECT (./gtkmarshalers.list:59) */
++/* VOID:BOXED,OBJECT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:59) */
+ extern void _gtk_marshal_VOID__BOXED_OBJECT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -260,7 +260,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:BOXED,STRING,INT (./gtkmarshalers.list:60) */
++/* VOID:BOXED,STRING,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:60) */
+ extern void _gtk_marshal_VOID__BOXED_STRING_INT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -268,7 +268,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:BOXED,UINT (./gtkmarshalers.list:61) */
++/* VOID:BOXED,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:61) */
+ extern void _gtk_marshal_VOID__BOXED_UINT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -276,7 +276,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:BOXED,UINT,FLAGS (./gtkmarshalers.list:62) */
++/* VOID:BOXED,UINT,FLAGS (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:62) */
+ extern void _gtk_marshal_VOID__BOXED_UINT_FLAGS (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -284,7 +284,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:BOXED,UINT,UINT (./gtkmarshalers.list:63) */
++/* VOID:BOXED,UINT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:63) */
+ extern void _gtk_marshal_VOID__BOXED_UINT_UINT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -292,9 +292,9 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:ENUM (./gtkmarshalers.list:64) */
++/* VOID:ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:64) */
+
+-/* VOID:ENUM,BOOLEAN (./gtkmarshalers.list:65) */
++/* VOID:ENUM,BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:65) */
+ extern void _gtk_marshal_VOID__ENUM_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -302,7 +302,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:ENUM,ENUM (./gtkmarshalers.list:66) */
++/* VOID:ENUM,ENUM (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:66) */
+ extern void _gtk_marshal_VOID__ENUM_ENUM (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -310,7 +310,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:ENUM,FLOAT (./gtkmarshalers.list:67) */
++/* VOID:ENUM,FLOAT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:67) */
+ extern void _gtk_marshal_VOID__ENUM_FLOAT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -318,7 +318,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:ENUM,FLOAT,BOOLEAN (./gtkmarshalers.list:68) */
++/* VOID:ENUM,FLOAT,BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:68) */
+ extern void _gtk_marshal_VOID__ENUM_FLOAT_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -326,7 +326,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:ENUM,INT (./gtkmarshalers.list:69) */
++/* VOID:ENUM,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:69) */
+ extern void _gtk_marshal_VOID__ENUM_INT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -334,7 +334,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:ENUM,INT,BOOLEAN (./gtkmarshalers.list:70) */
++/* VOID:ENUM,INT,BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:70) */
+ extern void _gtk_marshal_VOID__ENUM_INT_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -342,11 +342,11 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:INT (./gtkmarshalers.list:71) */
++/* VOID:INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:71) */
+
+-/* VOID:INT,INT (./gtkmarshalers.list:72) */
++/* VOID:INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:72) */
+
+-/* VOID:INT,INT,BOXED (./gtkmarshalers.list:73) */
++/* VOID:INT,INT,BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:73) */
+ extern void _gtk_marshal_VOID__INT_INT_BOXED (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -354,7 +354,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:INT,INT,INT (./gtkmarshalers.list:74) */
++/* VOID:INT,INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:74) */
+ extern void _gtk_marshal_VOID__INT_INT_INT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -362,10 +362,10 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:OBJECT (./gtkmarshalers.list:75) */
++/* VOID:OBJECT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:75) */
+ #define _gtk_marshal_VOID__OBJECT g_cclosure_marshal_VOID__OBJECT
+
+-/* VOID:OBJECT,BOOLEAN (./gtkmarshalers.list:76) */
++/* VOID:OBJECT,BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:76) */
+ extern void _gtk_marshal_VOID__OBJECT_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -373,7 +373,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:OBJECT,BOXED,BOXED (./gtkmarshalers.list:77) */
++/* VOID:OBJECT,BOXED,BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:77) */
+ extern void _gtk_marshal_VOID__OBJECT_BOXED_BOXED (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -381,7 +381,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:OBJECT,BOXED,UINT,UINT (./gtkmarshalers.list:78) */
++/* VOID:OBJECT,BOXED,UINT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:78) */
+ extern void _gtk_marshal_VOID__OBJECT_BOXED_UINT_UINT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -389,7 +389,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:OBJECT,INT,INT (./gtkmarshalers.list:79) */
++/* VOID:OBJECT,INT,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:79) */
+ extern void _gtk_marshal_VOID__OBJECT_INT_INT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -397,7 +397,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:OBJECT,INT,INT,BOXED,UINT,UINT (./gtkmarshalers.list:80) */
++/* VOID:OBJECT,INT,INT,BOXED,UINT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:80) */
+ extern void _gtk_marshal_VOID__OBJECT_INT_INT_BOXED_UINT_UINT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -405,7 +405,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:OBJECT,OBJECT (./gtkmarshalers.list:81) */
++/* VOID:OBJECT,OBJECT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:81) */
+ extern void _gtk_marshal_VOID__OBJECT_OBJECT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -413,7 +413,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:OBJECT,STRING (./gtkmarshalers.list:82) */
++/* VOID:OBJECT,STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:82) */
+ extern void _gtk_marshal_VOID__OBJECT_STRING (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -421,7 +421,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:OBJECT,STRING,STRING (./gtkmarshalers.list:83) */
++/* VOID:OBJECT,STRING,STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:83) */
+ extern void _gtk_marshal_VOID__OBJECT_STRING_STRING (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -429,7 +429,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:OBJECT,UINT (./gtkmarshalers.list:84) */
++/* VOID:OBJECT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:84) */
+ extern void _gtk_marshal_VOID__OBJECT_UINT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -437,7 +437,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:OBJECT,UINT,FLAGS (./gtkmarshalers.list:85) */
++/* VOID:OBJECT,UINT,FLAGS (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:85) */
+ extern void _gtk_marshal_VOID__OBJECT_UINT_FLAGS (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -445,12 +445,12 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:OBJECT,STRING (./gtkmarshalers.list:86) */
++/* VOID:OBJECT,STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:86) */
+
+-/* VOID:POINTER (./gtkmarshalers.list:87) */
++/* VOID:POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:87) */
+ #define _gtk_marshal_VOID__POINTER g_cclosure_marshal_VOID__POINTER
+
+-/* VOID:POINTER,INT (./gtkmarshalers.list:88) */
++/* VOID:POINTER,INT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:88) */
+ extern void _gtk_marshal_VOID__POINTER_INT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -458,7 +458,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:POINTER,BOOLEAN (./gtkmarshalers.list:89) */
++/* VOID:POINTER,BOOLEAN (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:89) */
+ extern void _gtk_marshal_VOID__POINTER_BOOLEAN (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -466,7 +466,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:POINTER,POINTER,POINTER (./gtkmarshalers.list:90) */
++/* VOID:POINTER,POINTER,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:90) */
+ extern void _gtk_marshal_VOID__POINTER_POINTER_POINTER (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -474,7 +474,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:POINTER,UINT (./gtkmarshalers.list:91) */
++/* VOID:POINTER,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:91) */
+ extern void _gtk_marshal_VOID__POINTER_UINT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -482,10 +482,10 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:STRING (./gtkmarshalers.list:92) */
++/* VOID:STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:92) */
+ #define _gtk_marshal_VOID__STRING g_cclosure_marshal_VOID__STRING
+
+-/* VOID:STRING,STRING (./gtkmarshalers.list:93) */
++/* VOID:STRING,STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:93) */
+ extern void _gtk_marshal_VOID__STRING_STRING (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -493,9 +493,9 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:STRING,INT,POINTER (./gtkmarshalers.list:94) */
++/* VOID:STRING,INT,POINTER (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:94) */
+
+-/* VOID:STRING,UINT,FLAGS (./gtkmarshalers.list:95) */
++/* VOID:STRING,UINT,FLAGS (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:95) */
+ extern void _gtk_marshal_VOID__STRING_UINT_FLAGS (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -503,7 +503,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:UINT,FLAGS,BOXED (./gtkmarshalers.list:96) */
++/* VOID:UINT,FLAGS,BOXED (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:96) */
+ extern void _gtk_marshal_VOID__UINT_FLAGS_BOXED (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -511,7 +511,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:UINT,UINT (./gtkmarshalers.list:97) */
++/* VOID:UINT,UINT (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:97) */
+ extern void _gtk_marshal_VOID__UINT_UINT (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -519,7 +519,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:UINT,STRING (./gtkmarshalers.list:98) */
++/* VOID:UINT,STRING (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:98) */
+ extern void _gtk_marshal_VOID__UINT_STRING (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -527,7 +527,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:UINT,BOXED,UINT,FLAGS,FLAGS (./gtkmarshalers.list:99) */
++/* VOID:UINT,BOXED,UINT,FLAGS,FLAGS (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:99) */
+ extern void _gtk_marshal_VOID__UINT_BOXED_UINT_FLAGS_FLAGS (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -535,7 +535,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:UINT,OBJECT,UINT,FLAGS,FLAGS (./gtkmarshalers.list:100) */
++/* VOID:UINT,OBJECT,UINT,FLAGS,FLAGS (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:100) */
+ extern void _gtk_marshal_VOID__UINT_OBJECT_UINT_FLAGS_FLAGS (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+@@ -543,7 +543,7 @@
+ gpointer invocation_hint,
+ gpointer marshal_data);
+
+-/* VOID:VOID (./gtkmarshalers.list:101) */
++/* VOID:VOID (/home/jlehto/teema4/3rdparty/gtk+2.0-2.6/gtk/gtkmarshalers.list:101) */
+
+ G_END_DECLS
+
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenu.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenu.c.diff
index e69de29bb2..16fac1b155 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenu.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenu.c.diff
@@ -0,0 +1,1223 @@
+--- gtk+-2.6.4/gtk/gtkmenu.c 2005-03-01 08:28:56.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkmenu.c 2005-04-06 16:19:36.921925376 +0300
+@@ -24,10 +24,16 @@
+ * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
+ */
+
++/* Modified for Nokia Oyj during 2002-2005. See CHANGES file for list
++ * of changes.
++ */
++
+ #define GTK_MENU_INTERNALS
+
+ #include <config.h>
+ #include <string.h> /* memset */
++#include <math.h>
++#include <stdlib.h>
+ #include "gdk/gdkkeysyms.h"
+ #include "gtkalias.h"
+ #include "gtkaccellabel.h"
+@@ -44,7 +50,11 @@
+ #include "gtkvscrollbar.h"
+ #include "gtksettings.h"
+ #include "gtkintl.h"
++#include "gtkcombobox.h"
+
++/* Hildon : We need this to figure out if menu should have
++ * corners etc. */
++#include "gtkmenubar.h"
+
+ #define MENU_ITEM_CLASS(w) GTK_MENU_ITEM_GET_CLASS (w)
+
+@@ -55,16 +65,43 @@
+ * extends below the submenu
+ */
+
++/* HILDON:
++ * Urgh, nasty thing to hard-code things like these :p
++ * One should really do some rewriting here...
++ */
++
+ #define MENU_SCROLL_STEP1 8
+ #define MENU_SCROLL_STEP2 15
+-#define MENU_SCROLL_ARROW_HEIGHT 16
+-#define MENU_SCROLL_FAST_ZONE 8
++#define MENU_SCROLL_ARROW_HEIGHT 20 /* This used to be: 23; This hard-coding should be
++ * changed. Add arrow_height style property into
++ * commongtkrc and read it from there everywhere
++ * where a reference to MENU_SCROLL_ARROW_HEIGHT
++ * is made.
++ * If these changes are made, please modify also
++ * gtkcombobox.c.
++ */
++#define MENU_SCROLL_FAST_ZONE MENU_SCROLL_ARROW_HEIGHT /* Was originally 8 */
+ #define MENU_SCROLL_TIMEOUT1 50
+ #define MENU_SCROLL_TIMEOUT2 20
+
+ #define ATTACH_INFO_KEY "gtk-menu-child-attach-info-key"
+ #define ATTACHED_MENUS "gtk-attached-menus"
+
++/* HILDON: */
++#define HILDON_MENU_NAME_SHARP "menu_with_corners"
++
++/* needed to allow different themeing for first level menus */
++#define HILDON_MENU_NAME_ROUND_FIRST_LEVEL "menu_without_corners_first_level"
++#define HILDON_MENU_NAME_ROUND "menu_without_corners"
++#define HILDON_MENU_NAME_FORCE_SHARP "menu_force_with_corners"
++#define HILDON_MENU_NAME_FORCE_ROUND "menu_force_without_corners"
++
++/* maximum sizes for menus when attached to comboboxes */
++#define HILDON_MENU_COMBO_MAX_WIDTH 406
++#define HILDON_MENU_COMBO_MIN_WIDTH 66
++#define HILDON_MENU_COMBO_MAX_HEIGHT 305
++#define HILDON_MENU_COMBO_MIN_HEIGHT 70
++
+ typedef struct _GtkMenuAttachData GtkMenuAttachData;
+ typedef struct _GtkMenuPrivate GtkMenuPrivate;
+
+@@ -92,6 +129,15 @@
+ gboolean have_layout;
+ gint n_rows;
+ gint n_columns;
++
++ /* Arrow states */
++ GtkStateType lower_arrow_state;
++ GtkStateType upper_arrow_state;
++
++ /* For context menu behavior */
++ gboolean context_menu;
++ int popup_pointer_x;
++ int popup_pointer_y;
+ };
+
+ typedef struct
+@@ -108,6 +154,7 @@
+
+ enum {
+ MOVE_SCROLL,
++ CLOSE_CURRENT,
+ LAST_SIGNAL
+ };
+
+@@ -191,7 +238,8 @@
+ static void gtk_menu_handle_scrolling (GtkMenu *menu,
+ gint event_x,
+ gint event_y,
+- gboolean enter);
++ gboolean enter,
++ gboolean motion);
+ static void gtk_menu_set_tearoff_hints (GtkMenu *menu,
+ gint width);
+ static void gtk_menu_style_set (GtkWidget *widget,
+@@ -232,6 +280,9 @@
+ guint signal_id);
+ static void _gtk_menu_refresh_accel_paths (GtkMenu *menu,
+ gboolean group_changed);
++static gboolean gtk_menu_check_name (GtkWidget *widget);
++
++static void _gtk_menu_close_current (GtkMenu *menu);
+
+ static GtkMenuShellClass *parent_class = NULL;
+ static const gchar attach_data_key[] = "gtk-menu-attach-data";
+@@ -496,7 +547,6 @@
+ widget_class->hide_all = gtk_menu_hide_all;
+ widget_class->enter_notify_event = gtk_menu_enter_notify;
+ widget_class->leave_notify_event = gtk_menu_leave_notify;
+- widget_class->motion_notify_event = gtk_menu_motion_notify;
+ widget_class->style_set = gtk_menu_style_set;
+ widget_class->focus = gtk_menu_focus;
+ widget_class->can_activate_accel = gtk_menu_real_can_activate_accel;
+@@ -521,6 +571,15 @@
+ _gtk_marshal_VOID__ENUM,
+ G_TYPE_NONE, 1,
+ GTK_TYPE_SCROLL_TYPE);
++
++ menu_signals[CLOSE_CURRENT] =
++ _gtk_binding_signal_new ("close_current",
++ G_OBJECT_CLASS_TYPE (object_class),
++ G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION,
++ G_CALLBACK (_gtk_menu_close_current),
++ NULL, NULL,
++ _gtk_marshal_VOID__VOID,
++ G_TYPE_NONE, 0);
+
+ g_object_class_install_property (gobject_class,
+ PROP_TEAROFF_TITLE,
+@@ -606,6 +665,11 @@
+ G_PARAM_READWRITE));
+
+ binding_set = gtk_binding_set_by_class (class);
++ /* Hildon : We moved handling of escape-key here because we need it to
++ * work like closing a submenu, not closing all the menus. */
++ gtk_binding_entry_add_signal (binding_set,
++ GDK_Escape, 0,
++ "close_current", 0);
+ gtk_binding_entry_add_signal (binding_set,
+ GDK_Up, 0,
+ "move_current", 1,
+@@ -709,6 +773,25 @@
+ DEFAULT_POPDOWN_DELAY,
+ G_PARAM_READWRITE));
+
++ /* Hildon addition : border width was
++ replaced with horizontal-padding and
++ vertical-padding (which already is an style
++ property for GtkMenu). */
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("horizontal-padding",
++ P_("Horizontal Padding"),
++ P_("Extra space at the left and right edges of the menu"),
++ 0,
++ G_MAXINT,
++ 0, /* 1, */
++ G_PARAM_READABLE));
++
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_boolean ("double_arrows",
++ P_("Double Arrows"),
++ P_("When scrolling, always show both arrows."),
++ FALSE,
++ G_PARAM_READABLE));
+ }
+
+
+@@ -884,13 +967,14 @@
+ menu->toggle_size = 0;
+
+ menu->toplevel = g_object_connect (g_object_new (GTK_TYPE_WINDOW,
+- "type", GTK_WINDOW_POPUP,
+- "child", menu,
+- NULL),
++ "type", GTK_WINDOW_POPUP,
++ "child", menu,
++ NULL),
+ "signal::event", gtk_menu_window_event, menu,
+ "signal::size_request", gtk_menu_window_size_request, menu,
+ "signal::destroy", gtk_widget_destroyed, &menu->toplevel,
+ NULL);
++
+ gtk_window_set_resizable (GTK_WINDOW (menu->toplevel), FALSE);
+ gtk_window_set_mnemonic_modifier (GTK_WINDOW (menu->toplevel), 0);
+
+@@ -919,6 +1003,15 @@
+ menu->lower_arrow_visible = FALSE;
+ menu->upper_arrow_prelight = FALSE;
+ menu->lower_arrow_prelight = FALSE;
++
++ /* <Hildon> */
++ priv->upper_arrow_state = GTK_STATE_NORMAL;
++ priv->lower_arrow_state = GTK_STATE_NORMAL;
++
++ priv->context_menu = FALSE;
++ priv->popup_pointer_x = -1;
++ priv->popup_pointer_y = -1;
++ /* </hildon */
+
+ priv->have_layout = FALSE;
+ }
+@@ -1220,7 +1313,8 @@
+
+ static gboolean
+ popup_grab_on_window (GdkWindow *window,
+- guint32 activate_time)
++ guint32 activate_time,
++ gboolean grab_keyboard)
+ {
+ if ((gdk_pointer_grab (window, TRUE,
+ GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK |
+@@ -1228,7 +1322,8 @@
+ GDK_POINTER_MOTION_MASK,
+ NULL, NULL, activate_time) == 0))
+ {
+- if (gdk_keyboard_grab (window, TRUE,
++ if (!grab_keyboard ||
++ gdk_keyboard_grab (window, TRUE,
+ activate_time) == 0)
+ return TRUE;
+ else
+@@ -1282,6 +1377,7 @@
+ GtkWidget *parent;
+ GdkEvent *current_event;
+ GtkMenuShell *menu_shell;
++ gboolean grab_keyboard;
+ GtkMenuPrivate *priv = gtk_menu_get_private (menu);
+
+ g_return_if_fail (GTK_IS_MENU (menu));
+@@ -1333,10 +1429,28 @@
+ * probably could just leave the grab on the other window, with a
+ * little reorganization of the code in gtkmenu*).
+ */
++
++ grab_keyboard = gtk_menu_shell_get_take_focus (menu_shell);
++ gtk_window_set_accept_focus (GTK_WINDOW (menu->toplevel), grab_keyboard);
++
+ if (xgrab_shell && xgrab_shell != widget)
+ {
+- if (popup_grab_on_window (xgrab_shell->window, activate_time))
++ if (popup_grab_on_window (xgrab_shell->window, activate_time, grab_keyboard))
+ GTK_MENU_SHELL (xgrab_shell)->have_xgrab = TRUE;
++
++ /* HILDON:
++ * Check wheter parent is GtkMenuBar. If so,
++ * then we need sharp upper corners for this menu.
++ */
++ if (gtk_menu_check_name (widget))
++ {
++ if (GTK_IS_MENU_BAR (parent_menu_shell))
++ gtk_widget_set_name (widget, HILDON_MENU_NAME_SHARP);
++ else if (GTK_IS_MENU (parent_menu_shell))
++ gtk_widget_set_name( widget, HILDON_MENU_NAME_ROUND);
++ else
++ gtk_widget_set_name (widget, HILDON_MENU_NAME_ROUND_FIRST_LEVEL);
++ }
+ }
+ else
+ {
+@@ -1344,8 +1458,14 @@
+
+ xgrab_shell = widget;
+ transfer_window = menu_grab_transfer_window_get (menu);
+- if (popup_grab_on_window (transfer_window, activate_time))
++ if (popup_grab_on_window (transfer_window, activate_time, grab_keyboard))
+ GTK_MENU_SHELL (xgrab_shell)->have_xgrab = TRUE;
++
++ /* HILDON:
++ * We want this menu to have round corners (Used by default)
++ */
++ if (gtk_menu_check_name (widget))
++ gtk_widget_set_name (widget, HILDON_MENU_NAME_ROUND_FIRST_LEVEL);
+ }
+
+ if (!GTK_MENU_SHELL (xgrab_shell)->have_xgrab)
+@@ -1409,6 +1529,23 @@
+
+ /* Position the menu, possibly changing the size request
+ */
++ if (GTK_IS_COMBO_BOX (gtk_menu_get_attach_widget (menu)))
++ {
++ /* Hildon - limit the size if the menu is attached to a ComboBox */
++ GtkRequisition req;
++ gint width, height;
++
++ gtk_widget_set_size_request (widget, -1, -1);
++ gtk_widget_size_request (widget, &req);
++
++ width = MAX (MIN (req.width, HILDON_MENU_COMBO_MAX_WIDTH),
++ HILDON_MENU_COMBO_MIN_WIDTH);
++ height = MAX (MIN (req.height, HILDON_MENU_COMBO_MAX_HEIGHT),
++ HILDON_MENU_COMBO_MIN_HEIGHT);
++
++ gtk_widget_set_size_request (widget, width, height);
++ }
++
+ gtk_menu_position (menu);
+
+ /* Compute the size of the toplevel and realize it so we
+@@ -1430,13 +1567,29 @@
+
+ gtk_menu_scroll_to (menu, menu->scroll_offset);
+
++ if (priv->context_menu)
++ {
++ /* Save position of the pointer during popup */
++ /* currently not-multihead safe */
++ GdkScreen *screen;
++ GdkDisplay *display;
++
++ screen = gtk_widget_get_screen (widget);
++ display = gdk_screen_get_display (screen);
++
++ gdk_display_get_pointer (display, NULL,
++ &priv->popup_pointer_x,
++ &priv->popup_pointer_y,
++ NULL);
++ }
++
+ /* Once everything is set up correctly, map the toplevel window on
+ the screen.
+ */
+ gtk_widget_show (menu->toplevel);
+
+ if (xgrab_shell == widget)
+- popup_grab_on_window (widget->window, activate_time); /* Should always succeed */
++ popup_grab_on_window (widget->window, activate_time, grab_keyboard); /* Should always succeed */
+ gtk_grab_add (GTK_WIDGET (menu));
+ }
+
+@@ -1996,6 +2149,7 @@
+ GtkWidget *child;
+ GList *children;
+ guint vertical_padding;
++ guint horizontal_padding;
+
+ g_return_if_fail (GTK_IS_MENU (widget));
+
+@@ -2025,9 +2179,10 @@
+
+ gtk_widget_style_get (GTK_WIDGET (menu),
+ "vertical-padding", &vertical_padding,
++ "horizontal-padding", &horizontal_padding,
+ NULL);
+
+- attributes.x = border_width + widget->style->xthickness;
++ attributes.x = border_width + widget->style->xthickness + horizontal_padding;
+ attributes.y = border_width + widget->style->ythickness + vertical_padding;
+ attributes.width = MAX (1, widget->allocation.width - attributes.x * 2);
+ attributes.height = MAX (1, widget->allocation.height - attributes.y * 2);
+@@ -2040,11 +2195,14 @@
+ if (menu->lower_arrow_visible)
+ attributes.height -= MENU_SCROLL_ARROW_HEIGHT;
+
++ attributes.window_type = GDK_WINDOW_CHILD;
++
+ menu->view_window = gdk_window_new (widget->window, &attributes, attributes_mask);
+ gdk_window_set_user_data (menu->view_window, menu);
+
+ attributes.x = 0;
+ attributes.y = 0;
++ attributes.width = MAX (1, widget->requisition.width - (border_width + widget->style->xthickness + horizontal_padding) * 2);
+ attributes.height = MAX (1, widget->requisition.height - (border_width + widget->style->ythickness + vertical_padding) * 2);
+
+ menu->bin_window = gdk_window_new (menu->view_window, &attributes, attributes_mask);
+@@ -2164,6 +2322,10 @@
+ guint vertical_padding;
+ GtkRequisition child_requisition;
+ GtkMenuPrivate *priv;
++ guint horizontal_padding;
++ GdkScreen *screen;
++ GdkRectangle monitor;
++ gint monitor_num;
+
+ g_return_if_fail (GTK_IS_MENU (widget));
+ g_return_if_fail (requisition != NULL);
+@@ -2182,6 +2344,16 @@
+ priv->heights = g_new0 (guint, gtk_menu_get_n_rows (menu));
+ priv->heights_length = gtk_menu_get_n_rows (menu);
+
++/* Hildon addition to find out the monitor width */
++ screen = gtk_widget_get_screen (widget);
++ if (widget->window != NULL)
++ monitor_num = gdk_screen_get_monitor_at_window (screen, widget->window);
++ else
++ monitor_num = 0;
++ if (monitor_num < 0)
++ monitor_num = 0;
++ gdk_screen_get_monitor_geometry (screen, monitor_num, &monitor);
++
+ children = menu_shell->children;
+ while (children)
+ {
+@@ -2223,15 +2395,18 @@
+
+ requisition->width += max_toggle_size + max_accel_width;
+ requisition->width *= gtk_menu_get_n_columns (menu);
+- requisition->width += (GTK_CONTAINER (menu)->border_width +
+- widget->style->xthickness) * 2;
+
+ gtk_widget_style_get (GTK_WIDGET (menu),
++ "horizontal-padding", &horizontal_padding,
+ "vertical-padding", &vertical_padding,
+ NULL);
++ requisition->width += (GTK_CONTAINER (menu)->border_width + horizontal_padding +
++ widget->style->xthickness) * 2;
+ requisition->height += (GTK_CONTAINER (menu)->border_width + vertical_padding +
+ widget->style->ythickness) * 2;
+
++/* Hildon addition to not make the menu too wide for the screen. */
++ requisition->width = MIN (requisition->width, monitor.width);
+ menu->toggle_size = max_toggle_size;
+
+ /* Don't resize the tearoff if it is not active, because it won't redraw (it is only a background pixmap).
+@@ -2253,6 +2428,7 @@
+ GList *children;
+ gint x, y;
+ gint width, height;
++ guint horizontal_padding;
+ guint vertical_padding;
+
+ g_return_if_fail (GTK_IS_MENU (widget));
+@@ -2266,10 +2442,11 @@
+ gtk_widget_get_child_requisition (GTK_WIDGET (menu), &child_requisition);
+
+ gtk_widget_style_get (GTK_WIDGET (menu),
++ "horizontal-padding", &horizontal_padding,
+ "vertical-padding", &vertical_padding,
+ NULL);
+
+- x = GTK_CONTAINER (menu)->border_width + widget->style->xthickness;
++ x = GTK_CONTAINER (menu)->border_width + widget->style->xthickness + horizontal_padding;
+ y = GTK_CONTAINER (menu)->border_width + widget->style->ythickness + vertical_padding;
+
+ width = MAX (1, allocation->width - x * 2);
+@@ -2407,27 +2584,32 @@
+ GdkEventExpose *event)
+ {
+ GtkMenu *menu;
+- gint width, height;
+- gint border_x, border_y;
+- guint vertical_padding;
+
+ g_return_if_fail (GTK_IS_MENU (widget));
+
+ menu = GTK_MENU (widget);
+
+- gtk_widget_style_get (GTK_WIDGET (menu),
+- "vertical-padding", &vertical_padding,
+- NULL);
+-
+- border_x = GTK_CONTAINER (widget)->border_width + widget->style->xthickness;
+- border_y = GTK_CONTAINER (widget)->border_width + widget->style->ythickness + vertical_padding;
+- gdk_drawable_get_size (widget->window, &width, &height);
+-
+ if (event->window == widget->window)
+ {
++ gint width, height;
++ gint border_x, border_y;
++ guint vertical_padding;
++ guint horizontal_padding;
++ GtkMenuPrivate *priv;
+ gint arrow_space = MENU_SCROLL_ARROW_HEIGHT - 2 * widget->style->ythickness;
+ gint arrow_size = 0.7 * arrow_space;
+
++ priv = gtk_menu_get_private (menu);
++
++ gtk_widget_style_get (GTK_WIDGET (menu),
++ "vertical-padding", &vertical_padding,
++ "horizontal-padding", &horizontal_padding,
++ NULL);
++
++ border_x = GTK_CONTAINER (widget)->border_width + widget->style->xthickness + horizontal_padding;
++ border_y = GTK_CONTAINER (widget)->border_width + widget->style->ythickness + vertical_padding;
++ gdk_drawable_get_size (widget->window, &width, &height);
++
+ gtk_paint_box (widget->style,
+ widget->window,
+ GTK_STATE_NORMAL,
+@@ -2436,21 +2618,9 @@
+ 0, 0, -1, -1);
+ if (menu->upper_arrow_visible && !menu->tearoff_active)
+ {
+- gtk_paint_box (widget->style,
+- widget->window,
+- menu->upper_arrow_prelight ?
+- GTK_STATE_PRELIGHT : GTK_STATE_NORMAL,
+- GTK_SHADOW_OUT,
+- NULL, widget, "menu",
+- border_x,
+- border_y,
+- width - 2 * border_x,
+- MENU_SCROLL_ARROW_HEIGHT);
+-
+ gtk_paint_arrow (widget->style,
+ widget->window,
+- menu->upper_arrow_prelight ?
+- GTK_STATE_PRELIGHT : GTK_STATE_NORMAL,
++ priv->upper_arrow_state,
+ GTK_SHADOW_OUT,
+ NULL, widget, "menu_scroll_arrow_up",
+ GTK_ARROW_UP,
+@@ -2462,21 +2632,9 @@
+
+ if (menu->lower_arrow_visible && !menu->tearoff_active)
+ {
+- gtk_paint_box (widget->style,
+- widget->window,
+- menu->lower_arrow_prelight ?
+- GTK_STATE_PRELIGHT : GTK_STATE_NORMAL,
+- GTK_SHADOW_OUT,
+- NULL, widget, "menu",
+- border_x,
+- height - border_y - MENU_SCROLL_ARROW_HEIGHT,
+- width - 2*border_x,
+- MENU_SCROLL_ARROW_HEIGHT);
+-
+ gtk_paint_arrow (widget->style,
+ widget->window,
+- menu->lower_arrow_prelight ?
+- GTK_STATE_PRELIGHT : GTK_STATE_NORMAL,
++ priv->lower_arrow_state,
+ GTK_SHADOW_OUT,
+ NULL, widget, "menu_scroll_arrow_down",
+ GTK_ARROW_DOWN,
+@@ -2516,18 +2674,82 @@
+ GTK_WIDGET_CLASS (parent_class)->show (widget);
+ }
+
++static GtkWidget *
++find_active_menu_item (GdkEventButton *event)
++{
++ GtkWidget *menu_item;
++
++ menu_item = gtk_get_event_widget ((GdkEvent*) event);
++ while (menu_item && !GTK_IS_MENU_ITEM (menu_item))
++ menu_item = menu_item->parent;
++
++ return menu_item;
++}
++
++static gboolean
++pointer_in_menu_tree (GtkWidget *widget)
++{
++ GtkMenuShell *mshell;
++ int width, height, x, y;
++
++ mshell = GTK_MENU_SHELL (widget);
++
++ gdk_window_get_pointer (widget->window, &x, &y, NULL);
++ gdk_drawable_get_size (widget->window, &width, &height);
++
++ if ((x <= width) && (x >= 0) && (y <= height) && (y >= 0))
++ return TRUE;
++
++ if ((mshell->parent_menu_shell != NULL) &&
++ GTK_IS_MENU (mshell->parent_menu_shell))
++ return pointer_in_menu_tree (mshell->parent_menu_shell);
++
++ return FALSE;
++}
++
++static int
++distance_traveled (GtkWidget *widget)
++{
++ GtkMenuPrivate *priv;
++ GdkScreen *screen;
++ GdkDisplay *display;
++ int x, y, dx, dy;
++
++ priv = gtk_menu_get_private (GTK_MENU (widget));
++
++ screen = gtk_widget_get_screen (widget);
++ display = gdk_screen_get_display (screen);
++
++ gdk_display_get_pointer (display, NULL, &x, &y, NULL);
++
++ dx = (priv->popup_pointer_x - x);
++ dy = (priv->popup_pointer_y - y);
++
++ return abs ((int) sqrt ((double) (dx * dx + dy * dy)));
++}
++
+ static gboolean
+ gtk_menu_button_press (GtkWidget *widget,
+- GdkEventButton *event)
++ GdkEventButton *event)
+ {
+- /* Don't pop down the menu for releases over scroll arrows
+- */
+- if (GTK_IS_MENU (widget))
++ GtkWidget *menu_item;
++
++ menu_item = find_active_menu_item (event);
++ if (menu_item == NULL)
+ {
+ GtkMenu *menu = GTK_MENU (widget);
+
+- if (menu->upper_arrow_prelight || menu->lower_arrow_prelight)
+- return TRUE;
++ if (menu->upper_arrow_prelight || menu->lower_arrow_prelight)
++ {
++ gtk_menu_handle_scrolling (GTK_MENU (widget), event->x_root, event->y_root, TRUE, FALSE);
++
++ return TRUE;
++ }
++
++ /* Don't pass down to menu shell if a non-menuitem part
++ * of the menu was clicked. */
++ if (pointer_in_menu_tree (widget))
++ return TRUE;
+ }
+
+ return GTK_WIDGET_CLASS (parent_class)->button_press_event (widget, event);
+@@ -2537,14 +2759,44 @@
+ gtk_menu_button_release (GtkWidget *widget,
+ GdkEventButton *event)
+ {
+- /* Don't pop down the menu for releases over scroll arrows
+- */
+- if (GTK_IS_MENU (widget))
++ GtkMenuPrivate *priv;
++ GtkWidget *menu_item;
++
++ priv = gtk_menu_get_private (GTK_MENU (widget));
++
++ menu_item = find_active_menu_item (event);
++ if (menu_item == NULL)
+ {
+ GtkMenu *menu = GTK_MENU (widget);
+
+- if (menu->upper_arrow_prelight || menu->lower_arrow_prelight)
+- return TRUE;
++ if (menu->upper_arrow_prelight || menu->lower_arrow_prelight)
++ {
++ gtk_menu_handle_scrolling (GTK_MENU (widget), event->x_root, event->y_root, FALSE, FALSE);
++
++ return TRUE;
++ }
++
++ if (priv->context_menu &&
++ (priv->popup_pointer_x >= 0) &&
++ (priv->popup_pointer_y >= 0))
++ {
++ int distance;
++
++ distance = distance_traveled (widget);
++
++ priv->popup_pointer_x = -1;
++ priv->popup_pointer_y = -1;
++
++ /* Don't popdown if we traveled less than 20px since popup point,
++ * as per the specs. */
++ if (distance < 20)
++ return TRUE;
++ }
++
++ /* Don't pass down to menu shell if a non-menuitem part
++ * of the menu was clicked. */
++ if (pointer_in_menu_tree (widget))
++ return TRUE;
+ }
+
+ return GTK_WIDGET_CLASS (parent_class)->button_release_event (widget, event);
+@@ -2765,7 +3017,7 @@
+ gboolean need_enter;
+
+ if (GTK_IS_MENU (widget))
+- gtk_menu_handle_scrolling (GTK_MENU (widget), event->x_root, event->y_root, TRUE);
++ gtk_menu_handle_scrolling (GTK_MENU (widget), event->x_root, event->y_root, TRUE, TRUE);
+
+ /* We received the event for one of two reasons:
+ *
+@@ -2779,7 +3031,27 @@
+ menu_item = gtk_get_event_widget ((GdkEvent*) event);
+ if (!menu_item || !GTK_IS_MENU_ITEM (menu_item) ||
+ !GTK_IS_MENU (menu_item->parent))
+- return FALSE;
++ {
++ GtkMenuPrivate *priv;
++
++ priv = gtk_menu_get_private (GTK_MENU (widget));
++
++ if (priv->context_menu)
++ {
++ /* Context menu mode. If we dragged out of the menu,
++ * close the menu, as by the specs. */
++ if (!pointer_in_menu_tree (widget) &&
++ (distance_traveled (widget) >= 20) &&
++ (event->state & GDK_BUTTON1_MASK))
++ {
++ gtk_menu_deactivate (GTK_MENU_SHELL (widget));
++
++ return TRUE;
++ }
++ }
++
++ return FALSE;
++ }
+
+ menu_shell = GTK_MENU_SHELL (menu_item->parent);
+ menu = GTK_MENU (menu_shell);
+@@ -2795,6 +3067,11 @@
+ */
+ if (gtk_menu_navigating_submenu (menu, event->x_root, event->y_root))
+ return TRUE;
++/* HILDON MOD.
++ * Close the submenus that are two levels down from the currently selected.
++ * This ensures that the focus is correct all the time.*/
++ if (GTK_MENU_ITEM(menu_item)->submenu != NULL)
++ gtk_menu_shell_deselect (GTK_MENU_SHELL(&(GTK_MENU(GTK_MENU_ITEM(menu_item)->submenu)->menu_shell)));
+
+ /* Make sure we pop down if we enter a non-selectable menu item, so we
+ * don't show a submenu when the cursor is outside the stay-up triangle.
+@@ -2828,6 +3105,7 @@
+ send_event->crossing.y_root = event->y_root;
+ send_event->crossing.x = event->x;
+ send_event->crossing.y = event->y;
++ send_event->crossing.state = event->state;
+
+ /* We send the event to 'widget', the currently active menu,
+ * instead of 'menu', the menu that the pointer is in. This
+@@ -2852,17 +3130,24 @@
+ GtkWidget *widget;
+ gint offset;
+ gint view_width, view_height;
++ gboolean double_arrows;
+
+ widget = GTK_WIDGET (menu);
+ offset = menu->scroll_offset + step;
+
++ /* get double_arrows style property */
++ gtk_widget_style_get (widget,
++ "double_arrows", &double_arrows,
++ NULL);
++
+ /* If we scroll upward and the non-visible top part
+ * is smaller than the scroll arrow it would be
+ * pretty stupid to show the arrow and taking more
+ * screen space than just scrolling to the top.
+ */
+- if ((step < 0) && (offset < MENU_SCROLL_ARROW_HEIGHT))
+- offset = 0;
++ if (!double_arrows)
++ if ((step < 0) && (offset < MENU_SCROLL_ARROW_HEIGHT))
++ offset = 0;
+
+ /* Don't scroll over the top if we weren't before: */
+ if ((menu->scroll_offset >= 0) && (offset < 0))
+@@ -2874,6 +3159,12 @@
+ if (menu->scroll_offset > 0)
+ view_height -= MENU_SCROLL_ARROW_HEIGHT;
+
++ /* When both arrows are always shown, reduce
++ * view height even more.
++ */
++ if (double_arrows)
++ view_height -= MENU_SCROLL_ARROW_HEIGHT;
++
+ if ((menu->scroll_offset + view_height <= widget->requisition.height) &&
+ (offset + view_height > widget->requisition.height))
+ offset = widget->requisition.height - view_height;
+@@ -2922,18 +3213,21 @@
+ gtk_menu_handle_scrolling (GtkMenu *menu,
+ gint x,
+ gint y,
+- gboolean enter)
++ gboolean enter,
++ gboolean motion)
+ {
+ GtkMenuShell *menu_shell;
++ GtkMenuPrivate *priv;
+ gint width, height;
+ gint border;
+ GdkRectangle rect;
+- gboolean in_arrow;
+ gboolean scroll_fast = FALSE;
+ guint vertical_padding;
+ gint top_x, top_y;
+ gint win_x, win_y;
+
++ priv = gtk_menu_get_private (menu);
++
+ menu_shell = GTK_MENU_SHELL (menu);
+
+ gdk_drawable_get_size (GTK_WIDGET (menu)->window, &width, &height);
+@@ -2946,10 +3240,11 @@
+ GTK_WIDGET (menu)->style->ythickness + vertical_padding;
+
+ gdk_window_get_position (menu->toplevel->window, &top_x, &top_y);
++ x -= top_x;
++ y -= top_y;
++
+ gdk_window_get_position (GTK_WIDGET (menu)->window, &win_x, &win_y);
+- win_x += top_x;
+- win_y += top_y;
+-
++
+ if (menu->upper_arrow_visible && !menu->tearoff_active)
+ {
+ rect.x = win_x;
+@@ -2957,35 +3252,49 @@
+ rect.width = width;
+ rect.height = MENU_SCROLL_ARROW_HEIGHT + border;
+
+- in_arrow = FALSE;
++ menu->upper_arrow_prelight = FALSE;
+ if ((x >= rect.x) && (x < rect.x + rect.width) &&
+ (y >= rect.y) && (y < rect.y + rect.height))
+- {
+- in_arrow = TRUE;
+- scroll_fast = (y < rect.y + MENU_SCROLL_FAST_ZONE);
+- }
+-
+- if (enter && in_arrow &&
+- (!menu->upper_arrow_prelight || menu->scroll_fast != scroll_fast))
+- {
+- menu->upper_arrow_prelight = TRUE;
+- menu->scroll_fast = scroll_fast;
+- gdk_window_invalidate_rect (GTK_WIDGET (menu)->window, &rect, FALSE);
+-
+- /* Deselect the active item so that any submenus are poped down */
+- gtk_menu_shell_deselect (menu_shell);
++ menu->upper_arrow_prelight = TRUE;
+
+- gtk_menu_remove_scroll_timeout (menu);
+- menu->scroll_step = (scroll_fast) ? -MENU_SCROLL_STEP2 : -MENU_SCROLL_STEP1;
+- menu->timeout_id = g_timeout_add ((scroll_fast) ? MENU_SCROLL_TIMEOUT2 : MENU_SCROLL_TIMEOUT1,
+- gtk_menu_scroll_timeout,
+- menu);
+- }
+- else if (!enter && !in_arrow && menu->upper_arrow_prelight)
++ if (priv->upper_arrow_state != GTK_STATE_INSENSITIVE)
+ {
+- gdk_window_invalidate_rect (GTK_WIDGET (menu)->window, &rect, FALSE);
+-
+- gtk_menu_stop_scrolling (menu);
++ if (enter && menu->upper_arrow_prelight &&
++ (menu->timeout_id == 0 || menu->scroll_fast != scroll_fast))
++ {
++ menu->scroll_fast = scroll_fast;
++
++ /* Deselect the active item so that any submenus are poped down */
++ gtk_menu_shell_deselect (menu_shell);
++
++ gtk_menu_remove_scroll_timeout (menu);
++ menu->scroll_step = (scroll_fast) ? -MENU_SCROLL_STEP2 : -MENU_SCROLL_STEP1;
++
++ if (!motion)
++ {
++ /* Only do stuff on click. */
++ GtkSettings *settings;
++ guint timeout;
++
++ settings = gtk_settings_get_default ();
++ g_object_get (settings, "gtk-update-timeout", &timeout, NULL);
++
++ menu->timeout_id = g_timeout_add (timeout / 2, gtk_menu_scroll_timeout, menu);
++
++ priv->upper_arrow_state = GTK_STATE_ACTIVE;
++ }
++
++ gdk_window_invalidate_rect (GTK_WIDGET (menu)->window, &rect, FALSE);
++ }
++ else if (!enter)
++ {
++ gtk_menu_stop_scrolling (menu);
++
++ priv->upper_arrow_state = menu->upper_arrow_prelight ?
++ GTK_STATE_PRELIGHT : GTK_STATE_NORMAL;
++
++ gdk_window_invalidate_rect (GTK_WIDGET (menu)->window, &rect, FALSE);
++ }
+ }
+ }
+
+@@ -2996,36 +3305,50 @@
+ rect.width = width;
+ rect.height = MENU_SCROLL_ARROW_HEIGHT + border;
+
+- in_arrow = FALSE;
++ menu->lower_arrow_prelight = FALSE;
+ if ((x >= rect.x) && (x < rect.x + rect.width) &&
+ (y >= rect.y) && (y < rect.y + rect.height))
+- {
+- in_arrow = TRUE;
+- scroll_fast = (y > rect.y + rect.height - MENU_SCROLL_FAST_ZONE);
+- }
++ menu->lower_arrow_prelight = TRUE;
+
+- if (enter && in_arrow &&
+- (!menu->lower_arrow_prelight || menu->scroll_fast != scroll_fast))
++ if (priv->lower_arrow_state != GTK_STATE_INSENSITIVE)
+ {
+- menu->lower_arrow_prelight = TRUE;
+- menu->scroll_fast = scroll_fast;
+- gdk_window_invalidate_rect (GTK_WIDGET (menu)->window, &rect, FALSE);
++ if (enter && menu->lower_arrow_prelight &&
++ (menu->timeout_id == 0 || menu->scroll_fast != scroll_fast))
++ {
++ menu->scroll_fast = scroll_fast;
+
+- /* Deselect the active item so that any submenus are poped down */
+- gtk_menu_shell_deselect (menu_shell);
++ /* Deselect the active item so that any submenus are poped down */
++ gtk_menu_shell_deselect (menu_shell);
+
+- gtk_menu_remove_scroll_timeout (menu);
+- menu->scroll_step = (scroll_fast) ? MENU_SCROLL_STEP2 : MENU_SCROLL_STEP1;
+- menu->timeout_id = g_timeout_add ((scroll_fast) ? MENU_SCROLL_TIMEOUT2 : MENU_SCROLL_TIMEOUT1,
+- gtk_menu_scroll_timeout,
+- menu);
+- }
+- else if (!enter && !in_arrow && menu->lower_arrow_prelight)
+- {
+- gdk_window_invalidate_rect (GTK_WIDGET (menu)->window, &rect, FALSE);
+-
+- gtk_menu_stop_scrolling (menu);
+- }
++ gtk_menu_remove_scroll_timeout (menu);
++ menu->scroll_step = (scroll_fast) ? MENU_SCROLL_STEP2 : MENU_SCROLL_STEP1;
++
++ if (!motion)
++ {
++ /* Only do stuff on click. */
++ GtkSettings *settings;
++ guint timeout;
++
++ settings = gtk_settings_get_default ();
++ g_object_get (settings, "gtk-update-timeout", &timeout, NULL);
++
++ menu->timeout_id = g_timeout_add (timeout / 2, gtk_menu_scroll_timeout, menu);
++
++ priv->lower_arrow_state = GTK_STATE_ACTIVE;
++ }
++
++ gdk_window_invalidate_rect (GTK_WIDGET (menu)->window, &rect, FALSE);
++ }
++ else if (!enter)
++ {
++ gtk_menu_stop_scrolling (menu);
++
++ priv->lower_arrow_state = menu->lower_arrow_prelight ?
++ GTK_STATE_PRELIGHT : GTK_STATE_NORMAL;
++
++ gdk_window_invalidate_rect (GTK_WIDGET (menu)->window, &rect, FALSE);
++ }
++ }
+ }
+ }
+
+@@ -3041,7 +3364,7 @@
+ GtkMenuShell *menu_shell = GTK_MENU_SHELL (widget);
+
+ if (!menu_shell->ignore_enter)
+- gtk_menu_handle_scrolling (GTK_MENU (widget), event->x_root, event->y_root, TRUE);
++ gtk_menu_handle_scrolling (GTK_MENU (widget), event->x_root, event->y_root, TRUE, TRUE);
+ }
+
+ if (menu_item && GTK_IS_MENU_ITEM (menu_item))
+@@ -3106,7 +3429,7 @@
+ if (gtk_menu_navigating_submenu (menu, event->x_root, event->y_root))
+ return TRUE;
+
+- gtk_menu_handle_scrolling (menu, event->x_root, event->y_root, FALSE);
++ gtk_menu_handle_scrolling (menu, event->x_root, event->y_root, FALSE, TRUE);
+
+ event_widget = gtk_get_event_widget ((GdkEvent*) event);
+
+@@ -3611,7 +3934,13 @@
+ requisition.width, requisition.height);
+ }
+
+- menu->scroll_offset = scroll_offset;
++ /* Hildon hack for menu in comboboxes:
++ * in case the menu in attached to a ComboBox, the scroll_offset is
++ * calculated in the positioning function so we dont't overwrite it
++ * with the value calculated above (in this function) */
++ if ( !GTK_IS_COMBO_BOX(gtk_menu_get_attach_widget(menu)) )
++ menu->scroll_offset = scroll_offset;
++
+ }
+
+ static void
+@@ -3628,9 +3957,6 @@
+ gtk_menu_stop_scrolling (GtkMenu *menu)
+ {
+ gtk_menu_remove_scroll_timeout (menu);
+-
+- menu->upper_arrow_prelight = FALSE;
+- menu->lower_arrow_prelight = FALSE;
+ }
+
+ static void
+@@ -3644,6 +3970,8 @@
+ gboolean last_visible;
+ gint menu_height;
+ guint vertical_padding;
++ guint horizontal_padding;
++ gboolean double_arrows;
+
+ widget = GTK_WIDGET (menu);
+
+@@ -3663,19 +3991,93 @@
+
+ gtk_widget_style_get (GTK_WIDGET (menu),
+ "vertical-padding", &vertical_padding,
++ "horizontal-padding", &horizontal_padding,
++ "double_arrows", &double_arrows,
+ NULL);
+
+ border_width = GTK_CONTAINER (menu)->border_width;
+- view_width -= (border_width + widget->style->xthickness) * 2;
++ view_width -= (border_width + widget->style->xthickness + horizontal_padding) * 2;
+ view_height -= (border_width + widget->style->ythickness + vertical_padding) * 2;
+ menu_height = widget->requisition.height -
+ (border_width + widget->style->ythickness + vertical_padding) * 2;
+
+- x = border_width + widget->style->xthickness;
++ x = border_width + widget->style->xthickness + horizontal_padding;
+ y = border_width + widget->style->ythickness + vertical_padding;
+
++ if (double_arrows && !menu->tearoff_active && (view_height < menu_height))
++ {
++ GtkMenuPrivate *priv;
++ GtkStateType upper_arrow_previous_state, lower_arrow_previous_state;
++
++ priv = gtk_menu_get_private (menu);
++
++ upper_arrow_previous_state = priv->upper_arrow_state;
++ lower_arrow_previous_state = priv->lower_arrow_state;
++
++ if (!menu->upper_arrow_visible || !menu->lower_arrow_visible)
++ gtk_widget_queue_draw (GTK_WIDGET (menu));
++
++ view_height -= 2*MENU_SCROLL_ARROW_HEIGHT;
++ y += MENU_SCROLL_ARROW_HEIGHT;
++
++ menu->upper_arrow_visible = menu->lower_arrow_visible = TRUE;
++ if (priv->upper_arrow_state == GTK_STATE_INSENSITIVE)
++ {
++ priv->upper_arrow_state = menu->upper_arrow_prelight ?
++ GTK_STATE_PRELIGHT : GTK_STATE_NORMAL;
++ }
++ if (priv->lower_arrow_state == GTK_STATE_INSENSITIVE)
++ {
++ priv->lower_arrow_state = menu->lower_arrow_prelight ?
++ GTK_STATE_PRELIGHT : GTK_STATE_NORMAL;
++ }
++
++ if (offset <= 0)
++ {
++ offset = 0;
++ priv->upper_arrow_state = GTK_STATE_INSENSITIVE;
++ }
++ if (offset >= menu_height - view_height)
++ {
++ offset = menu_height - view_height;
++ priv->lower_arrow_state = GTK_STATE_INSENSITIVE;
++ }
++
++ if ((priv->upper_arrow_state != upper_arrow_previous_state) ||
++ (priv->lower_arrow_state != lower_arrow_previous_state))
++ gtk_widget_queue_draw (GTK_WIDGET (menu));
++
++ if (upper_arrow_previous_state != GTK_STATE_INSENSITIVE &&
++ priv->upper_arrow_state == GTK_STATE_INSENSITIVE)
++ {
++ /* If we hid the upper arrow, possibly remove timeout */
++ if (menu->scroll_step < 0)
++ {
++ gtk_menu_stop_scrolling (menu);
++ gtk_widget_queue_draw (GTK_WIDGET (menu));
++ }
++ }
++
++ if (lower_arrow_previous_state != GTK_STATE_INSENSITIVE &&
++ priv->lower_arrow_state == GTK_STATE_INSENSITIVE)
++ {
++ /* If we hid the lower arrow, possibly remove timeout */
++ if (menu->scroll_step > 0)
++ {
++ gtk_menu_stop_scrolling (menu);
++ gtk_widget_queue_draw (GTK_WIDGET (menu));
++ }
++ }
++ }
++ else
+ if (!menu->tearoff_active)
+ {
++ if (offset <= 0)
++ offset = 0;
++
++ if (offset >= menu_height - view_height)
++ offset = menu_height - view_height;
++
+ last_visible = menu->upper_arrow_visible;
+ menu->upper_arrow_visible = offset > 0;
+
+@@ -3685,8 +4087,6 @@
+ if ( (last_visible != menu->upper_arrow_visible) &&
+ !menu->upper_arrow_visible)
+ {
+- menu->upper_arrow_prelight = FALSE;
+-
+ /* If we hid the upper arrow, possibly remove timeout */
+ if (menu->scroll_step < 0)
+ {
+@@ -3704,8 +4104,6 @@
+ if ( (last_visible != menu->lower_arrow_visible) &&
+ !menu->lower_arrow_visible)
+ {
+- menu->lower_arrow_prelight = FALSE;
+-
+ /* If we hid the lower arrow, possibly remove timeout */
+ if (menu->scroll_step > 0)
+ {
+@@ -3792,12 +4190,14 @@
+ &child_offset, &child_height, &last_child))
+ {
+ guint vertical_padding;
++ gboolean double_arrows;
+
+ y = menu->scroll_offset;
+ gdk_drawable_get_size (GTK_WIDGET (menu)->window, &width, &height);
+
+ gtk_widget_style_get (GTK_WIDGET (menu),
+ "vertical-padding", &vertical_padding,
++ "double_arrows", &double_arrows,
+ NULL);
+
+ height -= 2*GTK_CONTAINER (menu)->border_width + 2*GTK_WIDGET (menu)->style->ythickness + 2*vertical_padding;
+@@ -3820,11 +4220,11 @@
+ if (child_offset + child_height > y + height - arrow_height)
+ {
+ arrow_height = 0;
+- if (!last_child && !menu->tearoff_active)
++ if ((!last_child && !menu->tearoff_active) || (double_arrows))
+ arrow_height += MENU_SCROLL_ARROW_HEIGHT;
+
+ y = child_offset + child_height - height + arrow_height;
+- if ((y > 0) && !menu->tearoff_active)
++ if (((y > 0) && !menu->tearoff_active) || (double_arrows))
+ {
+ /* Need upper arrow */
+ arrow_height += MENU_SCROLL_ARROW_HEIGHT;
+@@ -4374,3 +4774,60 @@
+ return list;
+ }
+
++/* Little help function for making some sanity tests on this menu.
++ * Checks that given widget really is a menu and that it has no name
++ * assigned to it yet.
++ * Names used to do hildon theming:
++ * HILDON_MENU_NAME_SHARP for menu with sharp upper corners
++ * HILDON_MENU_NAME_ROUND for menu with round corners
++ */
++static gboolean
++gtk_menu_check_name (GtkWidget *widget)
++{
++ gboolean legal_name = FALSE;
++ gchar **tmp = NULL;
++ const gchar *name = NULL;
++ static gchar *menu_names[] = { "GtkMenu",
++ HILDON_MENU_NAME_SHARP,
++ HILDON_MENU_NAME_ROUND,
++ HILDON_MENU_NAME_ROUND_FIRST_LEVEL,
++ NULL };
++ if (GTK_IS_MENU (widget) &&
++ (name = gtk_widget_get_name (widget)))
++ {
++ if (!g_ascii_strcasecmp (name, HILDON_MENU_NAME_FORCE_SHARP) || !g_ascii_strcasecmp (name, HILDON_MENU_NAME_FORCE_ROUND))
++ return FALSE;
++ for (tmp = menu_names; *tmp; tmp++)
++ if (!g_ascii_strcasecmp (name, *tmp ))
++ {
++ legal_name = TRUE;
++ break;
++ }
++ }
++
++ return legal_name;
++}
++
++/* A function called when esc-key is pressed. */
++static void
++_gtk_menu_close_current (GtkMenu * menu)
++{
++ GtkMenuShell * shell = GTK_MENU_SHELL (menu);
++
++ /* Check is a submenu of current menu item is visible.
++ * If it is, close that first. */
++ if (shell->active_menu_item && (GTK_MENU_ITEM (shell->active_menu_item)->submenu) && GTK_WIDGET_VISIBLE (GTK_MENU_ITEM (shell->active_menu_item)->submenu))
++ gtk_menu_popdown (GTK_MENU (GTK_MENU_ITEM (shell->active_menu_item)->submenu));
++ else
++ gtk_menu_popdown (menu);
++
++}
++
++/* Hildon function to make context menus behave according to spec */
++void
++_gtk_menu_enable_context_menu_behavior (GtkMenu *menu)
++{
++ GtkMenuPrivate *priv = gtk_menu_get_private (menu);
++
++ priv->context_menu = TRUE;
++}
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenu.h.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenu.h.diff
index e69de29bb2..fc29e7965e 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenu.h.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenu.h.diff
@@ -0,0 +1,12 @@
+--- gtk+-2.6.4/gtk/gtkmenu.h 2004-05-06 10:35:26.000000000 +0300
++++ gtk+-2.6.4/gtk/gtkmenu.h 2005-04-06 16:19:36.943922032 +0300
+@@ -200,6 +200,9 @@
+ gint monitor_num);
+ GList* gtk_menu_get_for_attach_widget (GtkWidget *widget);
+
++/* Private functions */
++void _gtk_menu_enable_context_menu_behavior (GtkMenu *menu);
++
+ #ifndef GTK_DISABLE_DEPRECATED
+ #define gtk_menu_append(menu,child) gtk_menu_shell_append ((GtkMenuShell *)(menu),(child))
+ #define gtk_menu_prepend(menu,child) gtk_menu_shell_prepend ((GtkMenuShell *)(menu),(child))
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenuitem.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenuitem.c.diff
index e69de29bb2..7d8133e891 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenuitem.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenuitem.c.diff
@@ -0,0 +1,457 @@
+--- gtk+-2.6.4/gtk/gtkmenuitem.c 2004-12-28 09:39:31.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkmenuitem.c 2005-04-06 16:19:36.973917472 +0300
+@@ -24,6 +24,10 @@
+ * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
+ */
+
++/* Modified for Nokia Oyj during 2002-2003. See CHANGES file for list
++ * of changes.
++ */
++
+ #define GTK_MENU_INTERNALS
+
+ #include <config.h>
+@@ -38,6 +42,9 @@
+ #include "gtkmenuitem.h"
+ #include "gtkseparatormenuitem.h"
+
++#define HILDON_HEIGHT_INCREMENT 1
++#define HILDON_ARROW_SPACE 6
++
+ #define MENU_ITEM_CLASS(w) GTK_MENU_ITEM_CLASS (GTK_OBJECT (w)->klass)
+
+ enum {
+@@ -95,6 +102,8 @@
+ guint signal_id);
+
+
++static void _gtk_menu_item_activate_submenus (GtkMenuItem *item);
++
+ static GtkItemClass *parent_class;
+ static guint menu_item_signals[LAST_SIGNAL] = { 0 };
+
+@@ -158,7 +167,9 @@
+ item_class->select = gtk_real_menu_item_select;
+ item_class->deselect = gtk_real_menu_item_deselect;
+
+- klass->activate = NULL;
++ /* Hildon addition : Added this to catch the
++ * activation of meuuitems with submenus. */
++ klass->activate = _gtk_menu_item_activate_submenus;
+ klass->activate_item = gtk_real_menu_item_activate_item;
+ klass->toggle_size_request = gtk_real_menu_item_toggle_size_request;
+ klass->toggle_size_allocate = gtk_real_menu_item_toggle_size_allocate;
+@@ -239,6 +250,16 @@
+ G_MAXINT,
+ 10,
+ G_PARAM_READABLE));
++
++ /* Hildon modification - allow themeing of separator height */
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("separator_height",
++ "Separator height",
++ "Draw a separator graphics with height of x pixels.",
++ 0,
++ G_MAXINT,
++ 5,
++ G_PARAM_READABLE));
+ }
+
+ static void
+@@ -415,6 +436,13 @@
+ g_return_if_fail (GTK_IS_MENU_ITEM (menu_item));
+
+ gtk_item_select (GTK_ITEM (menu_item));
++ /* HILDON MOD. This is required as changed focus isn't drawn automatically
++ * and drawing it must be requested. */
++ if ((GTK_WIDGET(menu_item)->parent) && GTK_IS_MENU (GTK_WIDGET(menu_item)->parent))
++ {
++ GtkMenu *menu = GTK_MENU (GTK_WIDGET(menu_item)->parent);
++ if (menu->parent_menu_item) gtk_widget_queue_draw(GTK_WIDGET(menu->parent_menu_item));
++ }
+ }
+
+ void
+@@ -423,6 +451,13 @@
+ g_return_if_fail (GTK_IS_MENU_ITEM (menu_item));
+
+ gtk_item_deselect (GTK_ITEM (menu_item));
++ /* HILDON MOD. This is required as changed focus isn't drawn automatically
++ * and drawing it must be requested. */
++ if ((GTK_WIDGET(menu_item)->parent) && GTK_IS_MENU (GTK_WIDGET(menu_item)->parent))
++ {
++ GtkMenu *menu = GTK_MENU (GTK_WIDGET(menu_item)->parent);
++ if (menu->parent_menu_item) gtk_widget_queue_draw(GTK_WIDGET(menu->parent_menu_item));
++ }
+ }
+
+ void
+@@ -531,7 +566,7 @@
+ "arrow_spacing", &arrow_spacing,
+ NULL);
+
+- requisition->width += child_requisition.height;
++ requisition->width += child_requisition.height + HILDON_ARROW_SPACE;
+ requisition->width += arrow_spacing;
+
+ requisition->width = MAX (requisition->width, get_minimum_width (widget));
+@@ -543,6 +578,12 @@
+ requisition->height += 4;
+ }
+
++ /* We get correct focus size if we make the widget a bit bigger.
++ * (If the increment would be big, we should probably adjust the text
++ * position aswell.)
++ */
++ requisition->height += HILDON_HEIGHT_INCREMENT;
++
+ accel_width = 0;
+ gtk_container_foreach (GTK_CONTAINER (menu_item),
+ gtk_menu_item_accel_width_foreach,
+@@ -596,7 +637,8 @@
+ {
+ if (direction == GTK_TEXT_DIR_RTL)
+ child_allocation.x += child_requisition.height;
+- child_allocation.width -= child_requisition.height;
++ /* HILDON Modification. */
++ child_allocation.width -= child_requisition.height + HILDON_ARROW_SPACE;
+ }
+
+ if (child_allocation.width < 1)
+@@ -688,6 +730,7 @@
+ GtkShadowType shadow_type, selected_shadow_type;
+ gint width, height;
+ gint x, y;
++
+ gint border_width = GTK_CONTAINER (widget)->border_width;
+
+ if (GTK_WIDGET_DRAWABLE (widget))
+@@ -704,10 +747,56 @@
+ if ((state_type == GTK_STATE_PRELIGHT) &&
+ (GTK_BIN (menu_item)->child))
+ {
++ gint focus_x = x;
++ gint focus_width = width;
+ gtk_widget_style_get (widget,
+ "selected_shadow_type", &selected_shadow_type,
+ NULL);
+- gtk_paint_box (widget->style,
++
++ if (menu_item->submenu && menu_item->show_submenu_indicator)
++ {
++ GtkRequisition child_requisition;
++ gint arrow_size;
++ /* gint arrow_extent; */
++ gtk_widget_get_child_requisition (GTK_BIN (menu_item)->child,
++ &child_requisition);
++
++ arrow_size = child_requisition.height - 2 * widget->style->ythickness;
++ if (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_LTR) {
++ focus_width = x + width - arrow_size - 2 - HILDON_ARROW_SPACE;
++ }
++ else {
++ focus_x = x + arrow_size + 2 + HILDON_ARROW_SPACE;
++ }
++ }
++
++ /*
++ * Hildon modification:
++ * This draws different focus depending on if it's the toplevel
++ * focused menu item. All items that have submenus that in turn
++ * have an item selected will be drawn with SELECTED - state focus.
++ * If this isn't the case, PRELIGHT - state focus is used. */
++ if (menu_item->submenu)
++ {
++ GtkMenuItem *msi;
++ msi = GTK_MENU_ITEM(GTK_MENU_SHELL(&((GTK_MENU(menu_item->submenu))->menu_shell))->active_menu_item);
++ if ((msi == NULL) || (GTK_WIDGET (msi)->state == 0))
++ gtk_paint_box (widget->style,
++ widget->window,
++ GTK_STATE_PRELIGHT,
++ selected_shadow_type,
++ area, widget, "menuitem",
++ focus_x, y, focus_width, height);
++ else
++ gtk_paint_box (widget->style,
++ widget->window,
++ GTK_STATE_SELECTED,
++ selected_shadow_type,
++ area, widget, "menuitem",
++ focus_x, y, focus_width, height);
++ }
++ else
++ gtk_paint_box (widget->style,
+ widget->window,
+ GTK_STATE_PRELIGHT,
+ selected_shadow_type,
+@@ -747,8 +836,12 @@
+ arrow_extent = arrow_size * 0.8;
+
+ shadow_type = GTK_SHADOW_OUT;
+- if (state_type == GTK_STATE_PRELIGHT)
+- shadow_type = GTK_SHADOW_IN;
++ /*Hildon: only show the pressed arrow if the submenu is visible*/
++ if (state_type == GTK_STATE_PRELIGHT
++ && GTK_WIDGET_VISIBLE( menu_item->submenu))
++ {
++ shadow_type = GTK_SHADOW_IN;
++ }
+
+ if (direction == GTK_TEXT_DIR_LTR)
+ {
+@@ -763,6 +856,9 @@
+
+ arrow_y = y + (height - arrow_extent) / 2;
+
++/* HILDON modification to correct focus drawing with submenu arrow */
++ arrow_x = arrow_x - 4;
++
+ gtk_paint_arrow (widget->style, widget->window,
+ state_type, shadow_type,
+ area, widget, "menuitem",
+@@ -772,18 +868,20 @@
+ }
+ else if (!GTK_BIN (menu_item)->child)
+ {
+- guint horizontal_padding;
++ guint horizontal_padding, separator_height;
+
+ gtk_widget_style_get (widget,
+ "horizontal_padding", &horizontal_padding,
++ "separator_height", &separator_height,
+ NULL);
+
+- gtk_paint_hline (widget->style, widget->window, GTK_STATE_NORMAL,
+- area, widget, "menuitem",
+- widget->allocation.x + horizontal_padding + widget->style->xthickness,
+- widget->allocation.x + widget->allocation.width - horizontal_padding - widget->style->xthickness - 1,
+- widget->allocation.y + (widget->allocation.height -
+- widget->style->ythickness) / 2);
++ /* themable menuitem for menu separators */
++ gtk_paint_box (widget->style, widget->window, GTK_STATE_NORMAL, GTK_SHADOW_NONE,
++ area, widget, "separator",
++ widget->allocation.x + horizontal_padding + widget->style->xthickness,
++ widget->allocation.y + (widget->allocation.height - widget->style->ythickness) / 2,
++ widget->allocation.x + widget->allocation.width - horizontal_padding - widget->style->xthickness - 1,
++ separator_height);
+ }
+ }
+ }
+@@ -839,6 +937,7 @@
+ (!GTK_WIDGET_MAPPED (menu_item->submenu) ||
+ GTK_MENU (menu_item->submenu)->tearoff_active))
+ {
++ GdkEvent *event = gtk_get_current_event ();
+ gint popup_delay;
+
+ if (menu_item->timer)
+@@ -851,26 +950,40 @@
+ popup_delay = get_popup_delay (menu_item);
+
+ if (popup_delay > 0)
+- {
+- GdkEvent *event = gtk_get_current_event ();
+-
+- menu_item->timer = g_timeout_add (popup_delay,
+- gtk_menu_item_select_timeout,
+- menu_item);
+- if (event &&
+- event->type != GDK_BUTTON_PRESS &&
+- event->type != GDK_ENTER_NOTIFY)
+- menu_item->timer_from_keypress = TRUE;
+- else
+- menu_item->timer_from_keypress = FALSE;
+-
+- if (event)
+- gdk_event_free (event);
+- }
++ {
++ /* OK, Here comes the contender for the 2003 Ugly Award
++ * The popup delay is set small enough to be unnoticable, but high enough to not
++ * notice the flickering which occurs when we close all the deepest menu's Gtk+ helpfully
++ * expands but are not needed
++ * This does not fix the mouse navigation yet (bug 18) but should take care of 442
++ * NOTE: test the delay factor on different CPU speeds
++ */
++ popup_delay = 3;
++ /* Hildon: Disabling the automatic opening of submenus. */
++
++ if (event &&
++ event->type != GDK_BUTTON_PRESS &&
++ event->type != GDK_ENTER_NOTIFY &&
++ event->type != GDK_MOTION_NOTIFY) /*hildon: for some reason, the event is sometimes this and not enter!*/
++ menu_item->timer_from_keypress = TRUE;
++ else if (event)
++ {
++ /* mouse/pen events */
++ /* here is a problem -- when a menu item with sub menus gets a mouse event,
++ another event is generated for the submenu (and further its submenu etc.)
++ This leads to a behaviour which does not comply to the hildon spec. */
++ menu_item->timer_from_keypress = FALSE;
++ }
++ else /* does this really happen? */
++ menu_item->timer_from_keypress = FALSE;
++ }
+ else
+- _gtk_menu_item_popup_submenu (GTK_WIDGET (menu_item));
++ _gtk_menu_item_popup_submenu (menu_item);
++
++ if (event)
++ gdk_event_free (event);
+ }
+-
++
+ gtk_widget_set_state (GTK_WIDGET (menu_item), GTK_STATE_PRELIGHT);
+ gtk_widget_queue_draw (GTK_WIDGET (menu_item));
+ }
+@@ -878,25 +991,16 @@
+ static void
+ gtk_real_menu_item_deselect (GtkItem *item)
+ {
+- GtkMenuItem *menu_item;
++ GtkWidget *menu_item;
+
+ g_return_if_fail (GTK_IS_MENU_ITEM (item));
+
+- menu_item = GTK_MENU_ITEM (item);
++ menu_item = GTK_WIDGET (item);
+
+- if (menu_item->submenu)
+- {
+- if (menu_item->timer)
+- {
+- g_source_remove (menu_item->timer);
+- menu_item->timer = 0;
+- }
+- else
+- gtk_menu_popdown (GTK_MENU (menu_item->submenu));
+- }
++ _gtk_menu_item_popdown_submenu (menu_item);
+
+- gtk_widget_set_state (GTK_WIDGET (menu_item), GTK_STATE_NORMAL);
+- gtk_widget_queue_draw (GTK_WIDGET (menu_item));
++ gtk_widget_set_state (menu_item, GTK_STATE_NORMAL);
++ gtk_widget_queue_draw (menu_item);
+ }
+
+ static gboolean
+@@ -941,10 +1045,7 @@
+ _gtk_menu_shell_activate (menu_shell);
+
+ gtk_menu_shell_select_item (GTK_MENU_SHELL (widget->parent), widget);
+- _gtk_menu_item_popup_submenu (widget);
+-
+- gtk_menu_shell_select_first (GTK_MENU_SHELL (menu_item->submenu), TRUE);
+- submenu = GTK_MENU_SHELL (menu_item->submenu);
++ /* Hildon mod: automatic submenu opening has been removed */
+ }
+ }
+ }
+@@ -983,7 +1084,7 @@
+ {
+ _gtk_menu_item_popup_submenu (GTK_WIDGET (menu_item));
+ if (menu_item->timer_from_keypress && menu_item->submenu)
+- GTK_MENU_SHELL (menu_item->submenu)->ignore_enter = TRUE;
++ GTK_MENU_SHELL (menu_item->submenu)->ignore_enter = TRUE;
+ }
+
+ GDK_THREADS_LEAVE ();
+@@ -1002,7 +1103,16 @@
+ g_source_remove (menu_item->timer);
+ menu_item->timer = 0;
+
++ /* HILDON MOD. This is required as changed submenu arrow isn't drawn automatically
++ * and drawing it must be requested. */
++ gtk_widget_queue_draw (widget);
++
+ if (GTK_WIDGET_IS_SENSITIVE (menu_item->submenu))
++ {
++ gboolean take_focus;
++ take_focus = gtk_menu_shell_get_take_focus (GTK_MENU_SHELL (widget->parent));
++ gtk_menu_shell_set_take_focus (GTK_MENU_SHELL (menu_item->submenu),take_focus);
++
+ gtk_menu_popup (GTK_MENU (menu_item->submenu),
+ widget->parent,
+ widget,
+@@ -1010,6 +1120,28 @@
+ menu_item,
+ GTK_MENU_SHELL (widget->parent)->button,
+ 0);
++ }
++}
++
++void
++_gtk_menu_item_popdown_submenu (GtkWidget *widget)
++{
++ GtkMenuItem *menu_item;
++
++ menu_item = GTK_MENU_ITEM (widget);
++
++ if (menu_item->submenu)
++ {
++ if (menu_item->timer)
++ {
++ g_source_remove (menu_item->timer);
++ menu_item->timer = 0;
++ }
++ else
++ gtk_menu_popdown (GTK_MENU (menu_item->submenu));
++ }
++
++ gtk_widget_queue_draw (widget);
+ }
+
+ static void
+@@ -1092,14 +1224,17 @@
+ tx += widget->allocation.width - twidth;
+ }
+
++/* HILDON modifications
++ * Here we make the submenu of an menubar appear under the menubar.
++ * The only exception is when the resulting menu would be under 100 pixels
++ * high. In that case, the menu is made 100 pixels high.
++ */
+ if ((ty + widget->allocation.height + theight) <= monitor.y + monitor.height)
+ ty += widget->allocation.height;
+- else if ((ty - theight) >= monitor.y)
+- ty -= theight;
+- else if (monitor.y + monitor.height - (ty + widget->allocation.height) > ty)
++ else if ((ty + widget->allocation.height) < monitor.y + monitor.height - 120)
+ ty += widget->allocation.height;
+ else
+- ty -= theight;
++ ty = monitor.y + monitor.height - 120;
+ break;
+
+ case GTK_LEFT_RIGHT:
+@@ -1404,3 +1539,30 @@
+
+ return TRUE;
+ }
++
++/* Hildon modification :
++ * This function exists only for opening submenus on
++ * activation. */
++static void
++_gtk_menu_item_activate_submenus (GtkMenuItem *item)
++{
++ GdkEvent *event;
++
++ g_return_if_fail (GTK_IS_MENU_ITEM (item));
++
++ if (!GTK_IS_MENU (item->submenu) ||
++ GTK_WIDGET_VISIBLE (item->submenu))
++ return;
++
++ event = gtk_get_current_event ();
++ _gtk_menu_item_popup_submenu (item);
++
++ /* We don't want to select first item if the submenu
++ * is opened with mouse release because the selection
++ * would move straigh back under the cursor. */
++ if ((event == NULL) || (event->type != GDK_BUTTON_RELEASE))
++ gtk_menu_shell_select_first (GTK_MENU_SHELL (item->submenu), TRUE);
++
++ if (event)
++ gdk_event_free (event);
++}
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenuitem.h.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenuitem.h.diff
index e69de29bb2..cece91e70c 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenuitem.h.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenuitem.h.diff
@@ -0,0 +1,10 @@
+--- gtk+-2.6.4/gtk/gtkmenuitem.h 2004-12-15 18:27:30.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkmenuitem.h 2005-04-06 16:19:36.983915952 +0300
+@@ -122,6 +122,7 @@
+ gboolean group_changed);
+ gboolean _gtk_menu_item_is_selectable (GtkWidget *menu_item);
+ void _gtk_menu_item_popup_submenu (GtkWidget *menu_item);
++void _gtk_menu_item_popdown_submenu (GtkWidget *menu_item);
+
+ #ifndef GTK_DISABLE_DEPRECATED
+ #define gtk_menu_item_right_justify(menu_item) gtk_menu_item_set_right_justified ((menu_item), TRUE)
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenushell.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenushell.c.diff
index e69de29bb2..3534b7716d 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenushell.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenushell.c.diff
@@ -0,0 +1,490 @@
+--- gtk+-2.6.4/gtk/gtkmenushell.c 2005-02-09 18:46:54.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkmenushell.c 2005-04-06 16:19:36.999913520 +0300
+@@ -39,6 +39,8 @@
+ #include "gtkmnemonichash.h"
+ #include "gtktearoffmenuitem.h"
+ #include "gtkwindow.h"
++#include "gtkprivate.h"
++#include "gtkintl.h"
+
+ #define MENU_SHELL_TIMEOUT 500
+
+@@ -52,6 +54,11 @@
+ LAST_SIGNAL
+ };
+
++enum {
++ PROP_0,
++ PROP_TAKE_FOCUS
++};
++
+ typedef void (*GtkMenuShellSignal1) (GtkObject *object,
+ GtkMenuDirectionType arg1,
+ gpointer data);
+@@ -122,10 +129,20 @@
+ {
+ GtkMnemonicHash *mnemonic_hash;
+ GtkKeyHash *key_hash;
++ gboolean activated_submenu;
++ gboolean take_focus;
+ };
+
+ static void gtk_menu_shell_class_init (GtkMenuShellClass *klass);
+ static void gtk_menu_shell_init (GtkMenuShell *menu_shell);
++static void gtk_menu_shell_set_property (GObject *object,
++ guint prop_id,
++ const GValue *value,
++ GParamSpec *pspec);
++static void gtk_menu_shell_get_property (GObject *object,
++ guint prop_id,
++ GValue *value,
++ GParamSpec *pspec);
+ static void gtk_menu_shell_realize (GtkWidget *widget);
+ static void gtk_menu_shell_finalize (GObject *object);
+ static gint gtk_menu_shell_button_press (GtkWidget *widget,
+@@ -176,7 +193,6 @@
+ static GtkContainerClass *parent_class = NULL;
+ static guint menu_shell_signals[LAST_SIGNAL] = { 0 };
+
+-
+ GType
+ gtk_menu_shell_get_type (void)
+ {
+@@ -220,6 +236,8 @@
+ container_class = (GtkContainerClass*) klass;
+
+ parent_class = g_type_class_peek_parent (klass);
++ object_class->set_property = gtk_menu_shell_set_property;
++ object_class->get_property = gtk_menu_shell_get_property;
+
+ object_class->finalize = gtk_menu_shell_finalize;
+
+@@ -299,9 +317,15 @@
+
+
+ binding_set = gtk_binding_set_by_class (klass);
++/* Hildon : The following binding is commented out
++ * because we want the Escape key to only exit the
++ * currently opened submenu. Therefore, the handling
++ * of esc-key will be moved to gtkmenuitem.c */
++/*
+ gtk_binding_entry_add_signal (binding_set,
+ GDK_Escape, 0,
+ "cancel", 0);
++*/
+ gtk_binding_entry_add_signal (binding_set,
+ GDK_Return, 0,
+ "activate_current", 1,
+@@ -330,7 +354,23 @@
+ GDK_F10, GDK_SHIFT_MASK,
+ "cycle_focus", 1,
+ GTK_TYPE_DIRECTION_TYPE, GTK_DIR_TAB_BACKWARD);
+-
++ /**
++ * GtkMenuShell:take-focus:
++ *
++ * A boolean that determines whether the menu and its submenus grab the
++ * keyboard focus. See gtk_menu_shell_set_take_focus() and
++ * gtk_menu_shell_get_take_focus().
++ *
++ * Since: 2.8
++ **/
++ g_object_class_install_property (object_class,
++ PROP_TAKE_FOCUS,
++ g_param_spec_boolean ("take-focus",
++ P_("Take Focus"),
++ P_("A boolean that determines whether the menu grabs the keyboard focus"),
++ TRUE,
++ G_PARAM_READWRITE));
++
+ g_type_class_add_private (object_class, sizeof (GtkMenuShellPrivate));
+ }
+
+@@ -356,6 +396,46 @@
+
+ priv->mnemonic_hash = NULL;
+ priv->key_hash = NULL;
++ priv->take_focus = TRUE;
++ priv->activated_submenu = FALSE;
++}
++
++static void
++gtk_menu_shell_set_property (GObject *object,
++ guint prop_id,
++ const GValue *value,
++ GParamSpec *pspec)
++{
++ GtkMenuShell *menu_shell = GTK_MENU_SHELL (object);
++
++ switch (prop_id)
++ {
++ case PROP_TAKE_FOCUS:
++ gtk_menu_shell_set_take_focus (menu_shell, g_value_get_boolean (value));
++ break;
++ default:
++ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
++ break;
++ }
++}
++
++static void
++gtk_menu_shell_get_property (GObject *object,
++ guint prop_id,
++ GValue *value,
++ GParamSpec *pspec)
++{
++ GtkMenuShell *menu_shell = GTK_MENU_SHELL (object);
++
++ switch (prop_id)
++ {
++ case PROP_TAKE_FOCUS:
++ g_value_set_boolean (value, gtk_menu_shell_get_take_focus (menu_shell));
++ break;
++ default:
++ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
++ break;
++ }
+ }
+
+ static void
+@@ -470,6 +550,7 @@
+ gtk_menu_shell_button_press (GtkWidget *widget,
+ GdkEventButton *event)
+ {
++ GtkMenuShellPrivate *priv;
+ GtkMenuShell *menu_shell;
+ GtkWidget *menu_item;
+
+@@ -479,7 +560,22 @@
+ if (event->type != GDK_BUTTON_PRESS)
+ return FALSE;
+
++ priv = GTK_MENU_SHELL_GET_PRIVATE (widget);
++
+ menu_shell = GTK_MENU_SHELL (widget);
++ menu_item = gtk_menu_shell_get_item (menu_shell, (GdkEvent*) event);
++
++ if (menu_shell->active && menu_item &&
++ (menu_shell->active_menu_item == menu_item) &&
++ _gtk_menu_item_is_selectable (menu_item) &&
++ GTK_MENU_ITEM (menu_item)->submenu != NULL &&
++ !GTK_WIDGET_VISIBLE (GTK_MENU_ITEM (menu_item)->submenu))
++ {
++ /* Hildon : We want to be able to activate submenu items. */
++ gtk_menu_shell_activate_item (menu_shell, menu_item, FALSE);
++
++ priv->activated_submenu = TRUE;
++ }
+
+ if (menu_shell->parent_menu_shell)
+ {
+@@ -491,30 +587,29 @@
+
+ menu_shell->button = event->button;
+
+- menu_item = gtk_menu_shell_get_item (menu_shell, (GdkEvent *)event);
+-
+ if (menu_item && _gtk_menu_item_is_selectable (menu_item))
+- {
+- if ((menu_item->parent == widget) &&
+- (menu_item != menu_shell->active_menu_item))
+- {
+- if (GTK_MENU_SHELL_GET_CLASS (menu_shell)->submenu_placement == GTK_TOP_BOTTOM)
+- {
+- menu_shell->activate_time = event->time;
+- }
++ {
++
++ if ((menu_item->parent == widget) &&
++ (menu_item != menu_shell->active_menu_item))
++ {
++ if (GTK_MENU_SHELL_GET_CLASS (menu_shell)->submenu_placement == GTK_TOP_BOTTOM)
++ {
++ menu_shell->activate_time = event->time;
++ }
+
+- gtk_menu_shell_select_item (menu_shell, menu_item);
+- }
+- }
++ gtk_menu_shell_select_item (menu_shell, menu_item);
++ }
++ }
+ }
+ else
+ {
+ widget = gtk_get_event_widget ((GdkEvent*) event);
+ if (widget == GTK_WIDGET (menu_shell))
+- {
+- gtk_menu_shell_deactivate (menu_shell);
+- g_signal_emit (menu_shell, menu_shell_signals[SELECTION_DONE], 0);
+- }
++ {
++ gtk_menu_shell_deactivate (menu_shell);
++ g_signal_emit (menu_shell, menu_shell_signals[SELECTION_DONE], 0);
++ }
+ }
+
+ return TRUE;
+@@ -524,13 +619,20 @@
+ gtk_menu_shell_button_release (GtkWidget *widget,
+ GdkEventButton *event)
+ {
++ GtkMenuShellPrivate *priv;
+ GtkMenuShell *menu_shell;
+ GtkWidget *menu_item;
+ gint deactivate;
++ gboolean activated_submenu;
+
+ g_return_val_if_fail (GTK_IS_MENU_SHELL (widget), FALSE);
+ g_return_val_if_fail (event != NULL, FALSE);
+
++ priv = GTK_MENU_SHELL_GET_PRIVATE (widget);
++
++ activated_submenu = priv->activated_submenu;
++ priv->activated_submenu = FALSE;
++
+ menu_shell = GTK_MENU_SHELL (widget);
+ if (menu_shell->active)
+ {
+@@ -556,11 +658,11 @@
+ gtk_menu_shell_activate_item (menu_shell, menu_item, TRUE);
+ return TRUE;
+ }
+- else if (GTK_MENU_SHELL_GET_CLASS (menu_shell)->submenu_placement != GTK_TOP_BOTTOM)
+- {
+- gtk_menu_item_select (GTK_MENU_ITEM (menu_item));
+- return TRUE;
+- }
++ else if (!activated_submenu)
++ {
++ /* popdown the submenu if we didn't pop it up in this click */
++ _gtk_menu_item_popdown_submenu (menu_item);
++ }
+ }
+ else if (menu_item &&
+ !_gtk_menu_item_is_selectable (menu_item) &&
+@@ -630,12 +732,14 @@
+ gtk_menu_shell_enter_notify (GtkWidget *widget,
+ GdkEventCrossing *event)
+ {
++ GtkMenuShellPrivate *priv;
+ GtkMenuShell *menu_shell;
+ GtkWidget *menu_item;
+
+ g_return_val_if_fail (GTK_IS_MENU_SHELL (widget), FALSE);
+ g_return_val_if_fail (event != NULL, FALSE);
+
++ priv = GTK_MENU_SHELL_GET_PRIVATE (widget);
+ menu_shell = GTK_MENU_SHELL (widget);
+
+ if (menu_shell->active)
+@@ -658,6 +762,17 @@
+ (GTK_WIDGET_STATE (menu_item) != GTK_STATE_PRELIGHT))
+ {
+ gtk_menu_shell_select_item (menu_shell, menu_item);
++
++ /* If the pen is down, and there is a submenu that is not
++ * yet visible, activate it */
++ if ((event->state & GDK_BUTTON1_MASK) &&
++ GTK_MENU_ITEM (menu_item)->submenu != NULL &&
++ !GTK_WIDGET_VISIBLE (GTK_MENU_ITEM (menu_item)->submenu))
++ {
++ gtk_menu_shell_activate_item (menu_shell, menu_item, FALSE);
++
++ priv->activated_submenu = TRUE;
++ }
+ }
+ }
+ else if (menu_shell->parent_menu_shell)
+@@ -887,8 +1002,14 @@
+ /* This allows the bizarre radio buttons-with-submenus-display-history
+ * behavior
+ */
++ /* Hildon modification. We probably won't have those
++ * bizarre radio buttons-with-submenus so we don't
++ * need this. Also, this functionality interferes with
++ * other functionality. */
++/*
+ if (GTK_MENU_ITEM (menu_shell->active_menu_item)->submenu)
+ gtk_widget_activate (menu_shell->active_menu_item);
++*/
+ }
+
+ void
+@@ -919,7 +1040,9 @@
+
+ g_object_ref (menu_shell);
+
+- if (deactivate)
++ /* We don't want to deactivate if we're activating
++ * a submenu item. */
++ if ((deactivate) && (GTK_MENU_ITEM (menu_item)->submenu == NULL))
+ {
+ GtkMenuShell *parent_menu_shell = menu_shell;
+
+@@ -965,29 +1088,30 @@
+
+ if (distance > 0)
+ {
++ /*Hildon: selection no longer wraps around at the
++ *bottom of the menu*/
++
+ node = node->next;
+- while (node != start_node &&
+- (!node || !_gtk_menu_item_is_selectable (node->data)))
++ while (node && node != start_node &&
++ !_gtk_menu_item_is_selectable (node->data))
+ {
+- if (!node)
+- node = menu_shell->children;
+- else
+ node = node->next;
+ }
+ }
+ else
+ {
++ /*Hildon: selection no longer wraps around at the top
++ *of the menu*/
++
+ node = node->prev;
+- while (node != start_node &&
+- (!node || !_gtk_menu_item_is_selectable (node->data)))
++ while (node && node != start_node &&
++ !_gtk_menu_item_is_selectable (node->data))
+ {
+- if (!node)
+- node = g_list_last (menu_shell->children);
+- else
+ node = node->prev;
+ }
+ }
+
++ /*note: gtk_menu_shell_select_item won't select non-selectable items*/
+ if (node)
+ gtk_menu_shell_select_item (menu_shell, node->data);
+ }
+@@ -1119,6 +1243,16 @@
+ switch (direction)
+ {
+ case GTK_MENU_DIR_PARENT:
++
++ if(!parent_menu_shell || GTK_IS_MENU_BAR(parent_menu_shell))
++ break;
++
++ /* hildon-modification - menu should be closed when returning from submenu.
++ * WARNING: This function is from GtkMenu, which normally
++ * shouldn't be called from GtkMenuShell, but currently
++ * there are no better alternatives. */
++ gtk_menu_popdown (GTK_MENU (menu_shell));
++
+ if (parent_menu_shell)
+ {
+ if (GTK_MENU_SHELL_GET_CLASS (parent_menu_shell)->submenu_placement ==
+@@ -1151,10 +1285,14 @@
+ _gtk_menu_item_is_selectable (menu_shell->active_menu_item) &&
+ GTK_MENU_ITEM (menu_shell->active_menu_item)->submenu)
+ {
++ /* Hildon-modification -- submenu is not opened automatically but needs to be explicitly opened*/
++ g_signal_emit (G_OBJECT (menu_shell), menu_shell_signals[ACTIVATE_CURRENT], 0, (gint) FALSE);
++
+ if (gtk_menu_shell_select_submenu_first (menu_shell))
+ break;
+ }
+
++#if 0
+ /* Try to find a menu running the opposite direction */
+ while (parent_menu_shell &&
+ (GTK_MENU_SHELL_GET_CLASS (parent_menu_shell)->submenu_placement ==
+@@ -1173,6 +1311,7 @@
+ gtk_menu_shell_move_selected (parent_menu_shell, 1);
+ gtk_menu_shell_select_submenu_first (parent_menu_shell);
+ }
++#endif
+ break;
+
+ case GTK_MENU_DIR_PREV:
+@@ -1197,8 +1336,8 @@
+ gtk_real_menu_shell_activate_current (GtkMenuShell *menu_shell,
+ gboolean force_hide)
+ {
+- if (menu_shell->active_menu_item &&
+- _gtk_menu_item_is_selectable (menu_shell->active_menu_item))
++ if (menu_shell->active_menu_item)/* &&
++ _gtk_menu_item_is_selectable (menu_shell->active_menu_item)) */
+ {
+
+ if (GTK_MENU_ITEM (menu_shell->active_menu_item)->submenu == NULL)
+@@ -1390,4 +1529,73 @@
+ keyval, target);
+ gtk_menu_shell_reset_key_hash (menu_shell);
+ }
++/**
++ * gtk_menu_shell_get_take_focus:
++ * @menu: a #GtkMenuShell
++ *
++ * @returns: %TRUE if the menu_shell will take the keyboard focus on popup.
++ *
++ * Since: 2.8
++ **/
++gboolean
++gtk_menu_shell_get_take_focus (GtkMenuShell *menu_shell)
++{
++ GtkMenuShellPrivate *priv;
++
++ g_return_val_if_fail (GTK_IS_MENU_SHELL (menu_shell), FALSE);
++
++ priv = GTK_MENU_SHELL_GET_PRIVATE (menu_shell);
++
++ return priv->take_focus;
++}
++
++/**
++ * gtk_menu_shell_set_take_focus:
++ * @menu: a #GtkMenuShell
++ * @take_focus: %TRUE if the menu_shell should take the keyboard focus on popup.
++ *
++ * If @take_focus is %TRUE (the default) the menu will take the keyboard focus
++ * so that it will receive all keyboard events which is needed to enable
++ * keyboard navigation in menus.
++ *
++ * Setting @take_focus to %FALSE is useful only for special applications
++ * like virtual keyboard implementations which should not take keyboard
++ * focus.
++ *
++ * The @take_focus state of a menu or menu bar is automatically propagated
++ * to submenus whenever a submenu is popped up, so you don't have to worry
++ * about recursively setting it for your entire menu hierarchy. Only when
++ * programmatically picking a submenu and popping it up manually, the
++ * @take_focus property of the submenu needs to be set explicitely.
++ *
++ * Note that setting it to %FALSE has side-effects:
++ *
++ * If the focus is in some other app, it keeps the focus and keynav in
++ * the menu doesn't work. Consequently, keynav on the menu will only
++ * work if the focus is on some toplevel owned by the onscreen keyboard.
++ *
++ * To avoid confusing the user, menus with @take_focus set to %FALSE
++ * should not display mnemonics or accelerators, since it cannot be
++ * guaranteed that they will work.
++ *
++ * See also gdk_keyboard_grab()
++ *
++ * Since: 2.8
++ **/
++void
++gtk_menu_shell_set_take_focus (GtkMenuShell *menu_shell,
++ gboolean take_focus)
++{
++ GtkMenuShellPrivate *priv;
++
++ g_return_if_fail (GTK_IS_MENU_SHELL (menu_shell));
++
++ priv = GTK_MENU_SHELL_GET_PRIVATE (menu_shell);
++
++ if (priv->take_focus != take_focus)
++ {
++ priv->take_focus = take_focus;
++ g_object_notify (G_OBJECT (menu_shell), "take-focus");
++ }
++}
+
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenushell.h.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenushell.h.diff
index e69de29bb2..4bd7fc547c 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenushell.h.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenushell.h.diff
@@ -0,0 +1,12 @@
+--- gtk+-2.6.4/gtk/gtkmenushell.h 2004-12-11 00:09:22.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkmenushell.h 2005-04-06 16:19:36.999913520 +0300
+@@ -124,6 +124,9 @@
+ void _gtk_menu_shell_remove_mnemonic (GtkMenuShell *menu_shell,
+ guint keyval,
+ GtkWidget *target);
++gboolean gtk_menu_shell_get_take_focus (GtkMenuShell *menu_shell);
++void gtk_menu_shell_set_take_focus (GtkMenuShell *menu_shell,
++ gboolean take_focus);
+
+ #ifdef __cplusplus
+ }
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtknotebook.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtknotebook.c.diff
index e69de29bb2..4f75106938 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtknotebook.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtknotebook.c.diff
@@ -0,0 +1,831 @@
+--- gtk+-2.6.4/gtk/gtknotebook.c 2004-09-27 06:43:55.000000000 +0300
++++ gtk+-2.6.4/gtk/gtknotebook.c 2005-04-06 16:19:37.033908352 +0300
+@@ -40,10 +40,10 @@
+
+ #define TAB_OVERLAP 2
+ #define TAB_CURVATURE 1
+-#define ARROW_SIZE 12
++#define ARROW_WIDTH 20
++#define ARROW_HEIGHT 27
+ #define ARROW_SPACING 0
+-#define NOTEBOOK_INIT_SCROLL_DELAY (200)
+-#define NOTEBOOK_SCROLL_DELAY (100)
++#define LABEL_PADDING 0
+
+
+ enum {
+@@ -57,7 +57,9 @@
+
+ enum {
+ STEP_PREV,
+- STEP_NEXT
++ STEP_NEXT,
++ STEP_PREV_CYCLE,
++ STEP_NEXT_CYCLE
+ };
+
+ typedef enum
+@@ -216,7 +218,7 @@
+ GList *list,
+ gboolean destroying);
+ static void gtk_notebook_update_labels (GtkNotebook *notebook);
+-static gint gtk_notebook_timer (GtkNotebook *notebook);
++static gint gtk_notebook_timer (GtkNotebook *notebook );
+ static gint gtk_notebook_page_compare (gconstpointer a,
+ gconstpointer b);
+ static GList* gtk_notebook_find_child (GtkNotebook *notebook,
+@@ -458,7 +460,7 @@
+ g_param_spec_boolean ("scrollable",
+ P_("Scrollable"),
+ P_("If TRUE, scroll arrows are added if there are too many tabs to fit"),
+- FALSE,
++ TRUE,
+ G_PARAM_READWRITE));
+ g_object_class_install_property (gobject_class,
+ PROP_ENABLE_POPUP,
+@@ -584,6 +586,75 @@
+
+ G_PARAM_READABLE));
+
++ /* Hildon: for adding paddings to the inner borders of the visible page */
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("inner_left_border",
++ _("Inner left border of the visible page"),
++ _("Width of inner left border of the visible page"),
++ 0,
++ G_MAXINT,
++ 0,
++ G_PARAM_READABLE));
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("inner_right_border",
++ _("Inner right border of the visible page"),
++ _("Width of inner right border of the visible page"),
++ 0,
++ G_MAXINT,
++ 0,
++ G_PARAM_READABLE));
++
++ /* Hildon: previously hardcoded constants ARROW_WIDTH, ARROW_HEIGHT,
++ ARROW_SPACING, TAB_OVERLAP and TAB_CURVATURE are now style properties */
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("arrow-width",
++ _("Arrow width"),
++ _("Scroll arrow width"),
++ 0,
++ G_MAXINT,
++ ARROW_WIDTH,
++ G_PARAM_READABLE));
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("arrow-height",
++ _("Arrow height"),
++ _("Scroll arrow height"),
++ 0,
++ G_MAXINT,
++ ARROW_HEIGHT,
++ G_PARAM_READABLE));
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("arrow-spacing",
++ _("Arrow spacing"),
++ _("Scroll arrow spacing"),
++ 0,
++ G_MAXINT,
++ ARROW_SPACING,
++ G_PARAM_READABLE));
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("tab-overlap",
++ _("Tab overlap"),
++ _("Tab overlap"),
++ 0,
++ G_MAXINT,
++ TAB_OVERLAP,
++ G_PARAM_READABLE));
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("tab-curvature",
++ _("Tab curvature"),
++ _("Tab curvature"),
++ 0,
++ G_MAXINT,
++ TAB_CURVATURE,
++ G_PARAM_READABLE));
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("label-padding",
++ _("Label padding"),
++ _("Label padding"),
++ 0,
++ G_MAXINT,
++ LABEL_PADDING,
++ G_PARAM_READABLE));
++
+ notebook_signals[SWITCH_PAGE] =
+ g_signal_new ("switch_page",
+ G_TYPE_FROM_CLASS (gobject_class),
+@@ -705,11 +776,10 @@
+ notebook->show_tabs = TRUE;
+ notebook->show_border = TRUE;
+ notebook->tab_pos = GTK_POS_TOP;
+- notebook->scrollable = FALSE;
++ notebook->scrollable = TRUE;
+ notebook->in_child = 0;
+ notebook->click_child = 0;
+ notebook->button = 0;
+- notebook->need_timer = 0;
+ notebook->child_has_focus = FALSE;
+ notebook->have_visible_child = FALSE;
+ notebook->focus_out = FALSE;
+@@ -1189,9 +1259,18 @@
+ GtkRequisition child_requisition;
+ gboolean switch_page = FALSE;
+ gint vis_pages;
+- gint focus_width;
++ gint focus_width, label_padding;
++ gint arrow_width, arrow_height, arrow_spacing, tab_overlap, tab_curvature;
+
+- gtk_widget_style_get (widget, "focus-line-width", &focus_width, NULL);
++ gtk_widget_style_get (widget,
++ "focus-line-width", &focus_width,
++ "arrow-width", &arrow_width,
++ "arrow-height", &arrow_height,
++ "arrow-spacing", &arrow_spacing,
++ "tab-overlap", &tab_overlap,
++ "tab-curvature", &tab_curvature,
++ "label-padding", &label_padding,
++ NULL);
+
+ widget->requisition.width = 0;
+ widget->requisition.height = 0;
+@@ -1229,6 +1308,22 @@
+ {
+ widget->requisition.width += widget->style->xthickness * 2;
+ widget->requisition.height += widget->style->ythickness * 2;
++
++ /* Hildon kludge: inner border paddings */
++ if (notebook->children && notebook->show_border)
++ {
++ gint inner_left_border, inner_right_border;
++
++ gtk_widget_style_get (widget,
++ "inner_left_border",
++ &inner_left_border,
++ "inner_right_border",
++ &inner_right_border,
++ NULL);
++
++ widget->requisition.width += inner_left_border + inner_right_border;
++ }
++
+
+ if (notebook->show_tabs)
+ {
+@@ -1249,6 +1344,7 @@
+
+ gtk_widget_size_request (page->tab_label,
+ &child_requisition);
++ child_requisition.width += 2 * label_padding;
+
+ page->requisition.width =
+ child_requisition.width +
+@@ -1292,10 +1388,10 @@
+
+ if (notebook->scrollable && vis_pages > 1 &&
+ widget->requisition.width < tab_width)
+- tab_height = MAX (tab_height, ARROW_SIZE);
++ tab_height = MAX (tab_height, arrow_height);
+
+- padding = 2 * (TAB_CURVATURE + focus_width +
+- notebook->tab_hborder) - TAB_OVERLAP;
++ padding = 2 * (tab_curvature + focus_width +
++ notebook->tab_hborder) - tab_overlap;
+ tab_max += padding;
+ while (children)
+ {
+@@ -1316,15 +1412,15 @@
+
+ if (notebook->scrollable && vis_pages > 1 &&
+ widget->requisition.width < tab_width)
+- tab_width = tab_max + 2 * (ARROW_SIZE + ARROW_SPACING);
++ tab_width = tab_max + 2 * (arrow_width + arrow_spacing);
+
+ if (notebook->homogeneous && !notebook->scrollable)
+ widget->requisition.width = MAX (widget->requisition.width,
+ vis_pages * tab_max +
+- TAB_OVERLAP);
++ tab_overlap);
+ else
+ widget->requisition.width = MAX (widget->requisition.width,
+- tab_width + TAB_OVERLAP);
++ tab_width + tab_overlap);
+
+ widget->requisition.height += tab_height;
+ break;
+@@ -1335,10 +1431,10 @@
+
+ if (notebook->scrollable && vis_pages > 1 &&
+ widget->requisition.height < tab_height)
+- tab_width = MAX (tab_width, ARROW_SPACING + 2 * ARROW_SIZE);
++ tab_width = MAX (tab_width, arrow_spacing + 2 * arrow_width);
+
+- padding = 2 * (TAB_CURVATURE + focus_width +
+- notebook->tab_vborder) - TAB_OVERLAP;
++ padding = 2 * (tab_curvature + focus_width +
++ notebook->tab_vborder) - tab_overlap;
+ tab_max += padding;
+
+ while (children)
+@@ -1361,24 +1457,24 @@
+
+ if (notebook->scrollable && vis_pages > 1 &&
+ widget->requisition.height < tab_height)
+- tab_height = tab_max + ARROW_SIZE + ARROW_SPACING;
++ tab_height = tab_max + arrow_height + arrow_spacing;
+
+ widget->requisition.width += tab_width;
+
+ if (notebook->homogeneous && !notebook->scrollable)
+ widget->requisition.height =
+ MAX (widget->requisition.height,
+- vis_pages * tab_max + TAB_OVERLAP);
++ vis_pages * tab_max + tab_overlap);
+ else
+ widget->requisition.height =
+ MAX (widget->requisition.height,
+- tab_height + TAB_OVERLAP);
++ tab_height + tab_overlap);
+
+ if (!notebook->homogeneous || notebook->scrollable)
+ vis_pages = 1;
+ widget->requisition.height = MAX (widget->requisition.height,
+ vis_pages * tab_max +
+- TAB_OVERLAP);
++ tab_overlap);
+ break;
+ }
+ }
+@@ -1499,7 +1595,26 @@
+ }
+ }
+
++ /* Hildon kludge: inner border paddings */
++ if (notebook->show_border)
++ {
++ gint inner_left_border, inner_right_border;
++
++ gtk_widget_style_get (widget,
++ "inner_left_border",
++ &inner_left_border,
++ "inner_right_border",
++ &inner_right_border,
++ NULL);
++
++ child_allocation.x += inner_left_border;
++ child_allocation.width -= inner_left_border + inner_right_border;
++ if (child_allocation.width < 0)
++ child_allocation.width = 0;
++ }
++
+ children = notebook->children;
++
+ while (children)
+ {
+ page = children->data;
+@@ -1580,11 +1695,18 @@
+ GdkRectangle event_window_pos;
+ gboolean before = ARROW_IS_BEFORE (arrow);
+ gboolean left = ARROW_IS_LEFT (arrow);
++ gint arrow_width, arrow_height, arrow_spacing;
++
++ gtk_widget_style_get (GTK_WIDGET(notebook),
++ "arrow-width", &arrow_width,
++ "arrow-height", &arrow_height,
++ "arrow-spacing", &arrow_spacing,
++ NULL);
+
+ if (gtk_notebook_get_event_window_position (notebook, &event_window_pos))
+ {
+- rectangle->width = ARROW_SIZE;
+- rectangle->height = ARROW_SIZE;
++ rectangle->width = arrow_width;
++ rectangle->height = arrow_height;
+
+ switch (notebook->tab_pos)
+ {
+@@ -1602,6 +1724,8 @@
+ rectangle->y += event_window_pos.height - rectangle->height;
+ break;
+ case GTK_POS_TOP:
++ arrow_spacing = - arrow_spacing;
++ /* Fall through */
+ case GTK_POS_BOTTOM:
+ if (before)
+ {
+@@ -1617,7 +1741,11 @@
+ else
+ rectangle->x = event_window_pos.x + event_window_pos.width - 2 * rectangle->width;
+ }
+- rectangle->y = event_window_pos.y + (event_window_pos.height - rectangle->height) / 2;
++ rectangle->y = event_window_pos.y;
++ if (arrow_spacing > 0)
++ rectangle->y += arrow_spacing;
++ else
++ rectangle->y += (event_window_pos.height - rectangle->height) / 2;
+ break;
+ }
+ }
+@@ -1696,6 +1824,10 @@
+ gboolean is_rtl = gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL;
+ gboolean left = (ARROW_IS_LEFT (arrow) && !is_rtl) ||
+ (!ARROW_IS_LEFT (arrow) && is_rtl);
++ GtkSettings *settings = gtk_settings_get_default ();
++ guint timeout;
++
++ g_object_get (settings, "gtk-initial-timeout", &timeout, NULL);
+
+ if (!GTK_WIDGET_HAS_FOCUS (widget))
+ gtk_widget_grab_focus (widget);
+@@ -1706,14 +1838,14 @@
+ if (event->button == 1)
+ {
+ gtk_notebook_do_arrow (notebook, arrow);
+-
++
+ if (!notebook->timer)
+- {
+- notebook->timer = g_timeout_add (NOTEBOOK_INIT_SCROLL_DELAY,
+- (GSourceFunc) gtk_notebook_timer,
+- (gpointer) notebook);
+- notebook->need_timer = TRUE;
+- }
++ {
++ notebook->timer = g_timeout_add (timeout,
++ (GSourceFunc) gtk_notebook_timer,
++ (gpointer) notebook);
++ notebook->need_timer = TRUE;
++ }
+ }
+ else if (event->button == 2)
+ gtk_notebook_page_select (notebook, TRUE);
+@@ -1862,7 +1994,7 @@
+ static void
+ stop_scrolling (GtkNotebook *notebook)
+ {
+- if (notebook->timer)
++ if (notebook->timer)
+ {
+ g_source_remove (notebook->timer);
+ notebook->timer = 0;
+@@ -2343,9 +2475,9 @@
+ */
+ return focus_child_in (notebook, GTK_DIR_TAB_FORWARD);
+ case GTK_DIR_LEFT:
+- return focus_tabs_move (notebook, direction, STEP_PREV);
++ return focus_tabs_move (notebook, direction, STEP_PREV_CYCLE);
+ case GTK_DIR_RIGHT:
+- return focus_tabs_move (notebook, direction, STEP_NEXT);
++ return focus_tabs_move (notebook, direction, STEP_NEXT_CYCLE);
+ }
+ }
+ else /* Focus was not on widget */
+@@ -2481,7 +2613,6 @@
+ * gtk_notebook_redraw_tabs
+ * gtk_notebook_real_remove
+ * gtk_notebook_update_labels
+- * gtk_notebook_timer
+ * gtk_notebook_page_compare
+ * gtk_notebook_real_page_position
+ * gtk_notebook_search_page
+@@ -2574,22 +2705,27 @@
+ gtk_notebook_timer (GtkNotebook *notebook)
+ {
+ gboolean retval = FALSE;
++ guint timeout;
++ GtkSettings *settings;
+
+ GDK_THREADS_ENTER ();
+
++ settings = gtk_settings_get_default ();
++ g_object_get (settings, "gtk-update-timeout", &timeout, NULL);
++
+ if (notebook->timer)
+ {
+ gtk_notebook_do_arrow (notebook, notebook->click_child);
+
+- if (notebook->need_timer)
+- {
+- notebook->need_timer = FALSE;
+- notebook->timer = g_timeout_add (NOTEBOOK_SCROLL_DELAY,
+- (GSourceFunc) gtk_notebook_timer,
+- (gpointer) notebook);
+- }
++ if (notebook->need_timer)
++ {
++ notebook->need_timer = FALSE;
++ notebook->timer = g_timeout_add (timeout,
++ (GSourceFunc) gtk_notebook_timer,
++ (gpointer) notebook);
++ }
+ else
+- retval = TRUE;
++ retval = TRUE;
+ }
+
+ GDK_THREADS_LEAVE ();
+@@ -2781,10 +2917,12 @@
+ switch (direction)
+ {
+ case STEP_PREV:
++ case STEP_PREV_CYCLE:
+ flag = GTK_PACK_END;
+ break;
+
+ case STEP_NEXT:
++ case STEP_NEXT_CYCLE:
+ flag = GTK_PACK_START;
+ break;
+ }
+@@ -2827,6 +2965,37 @@
+ old_list = list;
+ list = list->prev;
+ }
++
++ /* Hildon hack: keyboard navigation should cycle around */
++ if (direction == STEP_PREV_CYCLE)
++ {
++ /* find and return the last (visible) page */
++ list = g_list_last (notebook->children);
++ if (!find_visible)
++ return list;
++ while (list)
++ {
++ page = list->data;
++ if (GTK_WIDGET_VISIBLE (page->child))
++ return list;
++ list = list->prev;
++ }
++ }
++ if (direction == STEP_NEXT_CYCLE)
++ {
++ /* find and return the first (visible) page */
++ list = g_list_first (notebook->children);
++ if (!find_visible)
++ return list;
++ while (list)
++ {
++ page = list->data;
++ if (GTK_WIDGET_VISIBLE (page->child))
++ return list;
++ list = list->next;
++ }
++ }
++
+ return NULL;
+ }
+
+@@ -2850,6 +3019,7 @@
+ gint gap_x = 0, gap_width = 0, step = STEP_PREV;
+ gboolean is_rtl;
+ gint tab_pos;
++ gboolean paint_box_gap = FALSE;
+
+ g_return_if_fail (GTK_IS_NOTEBOOK (widget));
+ g_return_if_fail (area != NULL);
+@@ -2933,15 +3103,37 @@
+ step = STEP_PREV;
+ break;
+ }
+- gtk_paint_box_gap (widget->style, widget->window,
+- GTK_STATE_NORMAL, GTK_SHADOW_OUT,
+- area, widget, "notebook",
+- x, y, width, height,
+- tab_pos, gap_x, gap_width);
++
++ /* hildon hack to postpone painting until it
++ is known if scroll arrows will be drawn */
++ paint_box_gap = TRUE;
+ }
+
++ /* first, figure out if arrows should be drawn */
+ showarrow = FALSE;
+ children = gtk_notebook_search_page (notebook, NULL, step, TRUE);
++ while (children && !showarrow)
++ {
++ page = children->data;
++ children = gtk_notebook_search_page (notebook, children,
++ step, TRUE);
++ if (!GTK_WIDGET_MAPPED (page->tab_label))
++ showarrow = TRUE;
++ }
++
++ /* then draw content area frame */
++ if (paint_box_gap)
++ gtk_paint_box_gap (widget->style, widget->window,
++ GTK_STATE_NORMAL, GTK_SHADOW_OUT,
++ area, widget,
++ (showarrow && notebook->scrollable)
++ ? "notebook_show_arrow"
++ : "notebook",
++ x, y, width, height,
++ tab_pos, gap_x, gap_width);
++
++ /* and finally draw tabs */
++ children = gtk_notebook_search_page (notebook, NULL, step, TRUE);
+ while (children)
+ {
+ page = children->data;
+@@ -3069,10 +3261,15 @@
+ GdkRectangle arrow_rect;
+ GtkArrowType arrow;
+ gboolean is_rtl, left;
++ gint arrow_width, arrow_height;
+
+ gtk_notebook_get_arrow_rect (notebook, &arrow_rect, nbarrow);
+
+ widget = GTK_WIDGET (notebook);
++ gtk_widget_style_get (widget,
++ "arrow-width", &arrow_width,
++ "arrow-height", &arrow_height,
++ NULL);
+
+ is_rtl = gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL;
+ left = (ARROW_IS_LEFT (nbarrow) && !is_rtl) ||
+@@ -3112,7 +3309,7 @@
+ gtk_paint_arrow (widget->style, widget->window, state_type,
+ shadow_type, NULL, widget, "notebook",
+ arrow, TRUE, arrow_rect.x, arrow_rect.y,
+- ARROW_SIZE, ARROW_SIZE);
++ arrow_width, arrow_height);
+ }
+ }
+
+@@ -3143,13 +3340,25 @@
+ gboolean is_rtl = (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL &&
+ (tab_pos == GTK_POS_TOP || tab_pos == GTK_POS_BOTTOM));
+ gint memo_x;
++ gboolean truncate = FALSE;
++ gint arrow_width, arrow_height, arrow_spacing, tab_overlap;
++ gint total_width, ideal_tab_width, n_expanding_tabs;
+
+ if (!notebook->show_tabs || !notebook->children || !notebook->cur_page)
+ return;
+
++ gtk_widget_style_get (widget,
++ "arrow-width", &arrow_width,
++ "arrow-height", &arrow_height,
++ "arrow-spacing", &arrow_spacing,
++ "tab-overlap", &tab_overlap,
++ NULL);
++
+ child_allocation.x = widget->allocation.x + container->border_width;
+ child_allocation.y = widget->allocation.y + container->border_width;
+
++ total_width = allocation->width - 2 * container->border_width - tab_overlap;
++
+ switch (tab_pos)
+ {
+ case GTK_POS_BOTTOM:
+@@ -3198,27 +3407,26 @@
+ if (GTK_WIDGET_VISIBLE (page->child))
+ tab_space += page->requisition.width;
+ }
+- if (tab_space >
+- allocation->width - 2 * container->border_width - TAB_OVERLAP)
++ if (tab_space > total_width)
+ {
+ showarrow = TRUE;
+ page = focus_tab->data;
+
+- tab_space = allocation->width - TAB_OVERLAP -
++ tab_space = allocation->width - tab_overlap -
+ page->requisition.width - 2 * container->border_width;
+ if (notebook->has_after_previous)
+- tab_space -= ARROW_SPACING + ARROW_SIZE;
++ tab_space -= arrow_spacing + arrow_width;
+ if (notebook->has_after_next)
+- tab_space -= ARROW_SPACING + ARROW_SIZE;
++ tab_space -= arrow_spacing + arrow_width;
+ if (notebook->has_before_previous)
+ {
+- tab_space -= ARROW_SPACING + ARROW_SIZE;
+- child_allocation.x += ARROW_SPACING + ARROW_SIZE;
++ tab_space -= arrow_spacing + arrow_width;
++ child_allocation.x += arrow_spacing + arrow_width;
+ }
+ if (notebook->has_before_next)
+ {
+- tab_space -= ARROW_SPACING + ARROW_SIZE;
+- child_allocation.x += ARROW_SPACING + ARROW_SIZE;
++ tab_space -= arrow_spacing + arrow_width;
++ child_allocation.x += arrow_spacing + arrow_width;
+ }
+ }
+ break;
+@@ -3233,19 +3441,19 @@
+ tab_space += page->requisition.height;
+ }
+ if (tab_space >
+- (allocation->height - 2 * container->border_width - TAB_OVERLAP))
++ (allocation->height - 2 * container->border_width - tab_overlap))
+ {
+ showarrow = TRUE;
+ page = focus_tab->data;
+ tab_space = allocation->height
+- - TAB_OVERLAP - 2 * container->border_width
++ - tab_overlap - 2 * container->border_width
+ - page->requisition.height;
+ if (notebook->has_after_previous || notebook->has_after_next)
+- tab_space -= ARROW_SPACING + ARROW_SIZE;
++ tab_space -= arrow_spacing + arrow_height;
+ if (notebook->has_before_previous || notebook->has_before_next)
+ {
+- tab_space -= ARROW_SPACING + ARROW_SIZE;
+- child_allocation.y += ARROW_SPACING + ARROW_SIZE;
++ tab_space -= arrow_spacing + arrow_height;
++ child_allocation.y += arrow_spacing + arrow_height;
+ }
+ }
+ break;
+@@ -3257,6 +3465,10 @@
+ notebook->first_tab = focus_tab;
+ last_child = gtk_notebook_search_page (notebook, focus_tab,
+ STEP_NEXT, TRUE);
++
++ /* Hildon: there is only one visible tab label
++ and it doesn't fit unless it is truncated */
++ truncate = TRUE;
+ }
+ else
+ {
+@@ -3413,7 +3625,7 @@
+ }
+ tab_space -= allocation->height;
+ }
+- tab_space += 2 * container->border_width + TAB_OVERLAP;
++ tab_space += 2 * container->border_width + tab_overlap;
+ tab_space *= -1;
+ notebook->first_tab = gtk_notebook_search_page (notebook, NULL,
+ STEP_NEXT, TRUE);
+@@ -3432,12 +3644,29 @@
+ if (showarrow)
+ {
+ if (notebook->has_after_previous)
+- child_allocation.x -= ARROW_SPACING + ARROW_SIZE;
++ child_allocation.x -= arrow_spacing + arrow_width;
+ if (notebook->has_after_next)
+- child_allocation.x -= ARROW_SPACING + ARROW_SIZE;
++ child_allocation.x -= arrow_spacing + arrow_width;
+ }
+ }
+
++ ideal_tab_width = (total_width / n);
++ n_expanding_tabs = 0;
++
++ while (children)
++ {
++ if (children == last_child)
++ break;
++
++ page = children->data;
++ children = gtk_notebook_search_page (notebook, children, STEP_NEXT,TRUE);
++
++ if (page->requisition.width <= ideal_tab_width)
++ n_expanding_tabs++;
++ }
++
++ children = notebook->first_tab;
++
+ while (children)
+ {
+ if (children == last_child)
+@@ -3452,9 +3681,11 @@
+ children = gtk_notebook_search_page (notebook, children, STEP_NEXT,TRUE);
+
+ delta = 0;
+- if (n && (showarrow || page->expand || notebook->homogeneous))
++
++ if (n && (showarrow || page->expand || notebook->homogeneous) &&
++ (page->requisition.width <= ideal_tab_width))
+ {
+- new_fill = (tab_space * i++) / n;
++ new_fill = (tab_space * i++) / n_expanding_tabs;
+ delta = new_fill - old_fill;
+ old_fill = new_fill;
+ }
+@@ -3463,15 +3694,18 @@
+ {
+ case GTK_POS_TOP:
+ case GTK_POS_BOTTOM:
++ if (truncate)
++ delta *= -1;
++
+ child_allocation.width = (page->requisition.width +
+- TAB_OVERLAP + delta);
++ tab_overlap + delta);
+ if (is_rtl)
+ child_allocation.x -= child_allocation.width;
+ break;
+ case GTK_POS_LEFT:
+ case GTK_POS_RIGHT:
+ child_allocation.height = (page->requisition.height +
+- TAB_OVERLAP + delta);
++ tab_overlap + delta);
+ break;
+ }
+
+@@ -3482,13 +3716,13 @@
+ case GTK_POS_TOP:
+ case GTK_POS_BOTTOM:
+ if (!is_rtl)
+- child_allocation.x += child_allocation.width - TAB_OVERLAP;
++ child_allocation.x += child_allocation.width - tab_overlap;
+ else
+- child_allocation.x += TAB_OVERLAP;
++ child_allocation.x += tab_overlap;
+ break;
+ case GTK_POS_LEFT:
+ case GTK_POS_RIGHT:
+- child_allocation.y += child_allocation.height - TAB_OVERLAP;
++ child_allocation.y += child_allocation.height - tab_overlap;
+ break;
+ }
+
+@@ -3538,14 +3772,14 @@
+ case GTK_POS_TOP:
+ case GTK_POS_BOTTOM:
+ child_allocation.width = (page->requisition.width +
+- TAB_OVERLAP + delta);
++ tab_overlap + delta);
+ if (!is_rtl)
+ child_allocation.x -= child_allocation.width;
+ break;
+ case GTK_POS_LEFT:
+ case GTK_POS_RIGHT:
+ child_allocation.height = (page->requisition.height +
+- TAB_OVERLAP + delta);
++ tab_overlap + delta);
+ child_allocation.y -= child_allocation.height;
+ break;
+ }
+@@ -3557,13 +3791,13 @@
+ case GTK_POS_TOP:
+ case GTK_POS_BOTTOM:
+ if (!is_rtl)
+- child_allocation.x += TAB_OVERLAP;
++ child_allocation.x += tab_overlap;
+ else
+- child_allocation.x += child_allocation.width - TAB_OVERLAP;
++ child_allocation.x += child_allocation.width - tab_overlap;
+ break;
+ case GTK_POS_LEFT:
+ case GTK_POS_RIGHT:
+- child_allocation.y += TAB_OVERLAP;
++ child_allocation.y += tab_overlap;
+ break;
+ }
+
+@@ -3589,8 +3823,12 @@
+ gint padding;
+ gint focus_width;
+ gint tab_pos = get_effective_tab_pos (notebook);
++ gint tab_curvature;
+
+- gtk_widget_style_get (widget, "focus-line-width", &focus_width, NULL);
++ gtk_widget_style_get (widget,
++ "focus-line-width", &focus_width,
++ "tab-curvature", &tab_curvature,
++ NULL);
+
+ xthickness = widget->style->xthickness;
+ ythickness = widget->style->ythickness;
+@@ -3621,7 +3859,7 @@
+ {
+ case GTK_POS_TOP:
+ case GTK_POS_BOTTOM:
+- padding = TAB_CURVATURE + focus_width + notebook->tab_hborder;
++ padding = tab_curvature + focus_width + notebook->tab_hborder;
+ if (page->fill)
+ {
+ child_allocation.x = (xthickness + focus_width +
+@@ -3646,7 +3884,7 @@
+ break;
+ case GTK_POS_LEFT:
+ case GTK_POS_RIGHT:
+- padding = TAB_CURVATURE + focus_width + notebook->tab_vborder;
++ padding = tab_curvature + focus_width + notebook->tab_vborder;
+ if (page->fill)
+ {
+ child_allocation.y = ythickness + padding;
+@@ -4340,7 +4578,7 @@
+ }
+ page->tab_label = tab_label;
+ page->menu_label = menu_label;
+- page->expand = FALSE;
++ page->expand = TRUE;
+ page->fill = TRUE;
+ page->pack = GTK_PACK_START;
+
+@@ -5046,6 +5284,7 @@
+ {
+ page->default_tab = FALSE;
+ page->tab_label = tab_label;
++
+ gtk_widget_set_parent (page->tab_label, GTK_WIDGET (notebook));
+ }
+ else
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkprogress.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkprogress.c.diff
index e69de29bb2..07302bbab8 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkprogress.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkprogress.c.diff
@@ -0,0 +1,20 @@
+--- gtk+-2.6.4/gtk/gtkprogress.c 2004-10-28 18:00:04.000000000 +0300
++++ gtk+-2.6.4/gtk/gtkprogress.c 2005-04-06 16:19:37.066903336 +0300
+@@ -371,6 +371,17 @@
+ widget->allocation.width,
+ widget->allocation.height,
+ -1);
++
++ /* OSSO addition : clear the pixmap first or transparent images
++ * painted on top of it may look stupid when it's blended against
++ * random memory.*/
++ gtk_paint_flat_box (widget->style,
++ progress->offscreen_pixmap,
++ GTK_STATE_NORMAL,
++ GTK_SHADOW_NONE,
++ NULL, widget, NULL,
++ 0, 0, widget->allocation.width, widget->allocation.height);
++
+ GTK_PROGRESS_GET_CLASS (progress)->paint (progress);
+ }
+ }
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkprogressbar.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkprogressbar.c.diff
index e69de29bb2..097e348c41 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkprogressbar.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkprogressbar.c.diff
@@ -0,0 +1,141 @@
+--- gtk+-2.6.4/gtk/gtkprogressbar.c 2005-01-09 19:32:25.000000000 +0200
++++ gtk+-2.6.4/gtk/gtkprogressbar.c 2005-04-06 16:19:37.112896344 +0300
+@@ -40,11 +40,18 @@
+
+
+ #define MIN_HORIZONTAL_BAR_WIDTH 150
+-#define MIN_HORIZONTAL_BAR_HEIGHT 20
++#define MIN_HORIZONTAL_BAR_HEIGHT 30 /* OSSO mod. was 20 */
+ #define MIN_VERTICAL_BAR_WIDTH 22
+ #define MIN_VERTICAL_BAR_HEIGHT 80
+ #define MAX_TEXT_LENGTH 80
+-#define TEXT_SPACING 2
++#define DEFAULT_TEXT_SPACING 2 /* OSSO mod. Changed from
++ * TEXT_SPACING. Now controlled
++ * by "text-spacing" style
++ * property */
++#define DEFAULT_WIDTH_INCREMENT 3
++#define DEFAULT_HEIGHT_INCREMENT 3
++#define DEFAULT_TEXT_XNUDGE 1
++#define DEFAULT_TEXT_YNUDGE 1
+
+ enum {
+ PROP_0,
+@@ -245,6 +252,51 @@
+ PANGO_ELLIPSIZE_NONE,
+ G_PARAM_READWRITE));
+
++ /* OSSO addition. */
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("text-spacing",
++ "Text Spacing",
++ "The amount of pixels between the trough and text.",
++ G_MININT,
++ G_MAXINT,
++ DEFAULT_TEXT_SPACING,
++ G_PARAM_READWRITE));
++
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("width-increment",
++ "width Increment",
++ "The amount of pixels to add to the width size request.",
++ G_MININT,
++ G_MAXINT,
++ DEFAULT_WIDTH_INCREMENT,
++ G_PARAM_READWRITE));
++
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("height-increment",
++ "Height Increment",
++ "The amount of pixels to add to the height size request.",
++ G_MININT,
++ G_MAXINT,
++ DEFAULT_WIDTH_INCREMENT,
++ G_PARAM_READWRITE));
++
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("text-xnudge",
++ "Text XNudge",
++ "Amount of pixels to move the text x position.",
++ G_MININT,
++ G_MAXINT,
++ DEFAULT_TEXT_XNUDGE,
++ G_PARAM_READWRITE));
++
++ gtk_widget_class_install_style_property (widget_class,
++ g_param_spec_int ("text-ynudge",
++ "Text YNudge",
++ "Amount of pixels to move the text y position.",
++ G_MININT,
++ G_MAXINT,
++ DEFAULT_TEXT_YNUDGE,
++ G_PARAM_READWRITE));
+ }
+
+ static void
+@@ -364,7 +416,9 @@
+ {
+ GtkWidget *pbar;
+
+- pbar = gtk_widget_new (GTK_TYPE_PROGRESS_BAR, NULL);
++ pbar = gtk_widget_new (GTK_TYPE_PROGRESS_BAR,
++ "text-xalign", 0.0, /* OSSO addition. */
++ NULL);
+
+ return pbar;
+ }
+@@ -494,15 +548,23 @@
+ PangoRectangle logical_rect;
+ PangoLayout *layout;
+ gint width, height;
++ gint text_spacing;
++ gint width_increment, height_increment;
+
+ g_return_if_fail (GTK_IS_PROGRESS_BAR (widget));
+ g_return_if_fail (requisition != NULL);
++
++ gtk_widget_style_get (widget,
++ "text-spacing", &text_spacing,
++ "width-increment", &width_increment,
++ "height-increment", &height_increment,
++ NULL);
+
+ progress = GTK_PROGRESS (widget);
+ pbar = GTK_PROGRESS_BAR (widget);
+
+- width = 2 * widget->style->xthickness + 3 + 2 * TEXT_SPACING;
+- height = 2 * widget->style->ythickness + 3 + 2 * TEXT_SPACING;
++ width = 2 * widget->style->xthickness + width_increment + 2 * text_spacing;
++ height = 2 * widget->style->ythickness + height_increment + 2 * text_spacing;
+
+ if (progress->show_text && pbar->bar_style != GTK_PROGRESS_DISCRETE)
+ {
+@@ -780,6 +842,13 @@
+ PangoRectangle logical_rect;
+ GdkRectangle prelight_clip, normal_clip;
+
++ gint text_xnudge, text_ynudge;
++
++ gtk_widget_style_get (widget,
++ "text-xnudge", &text_xnudge,
++ "text-ynudge", &text_ynudge,
++ NULL);
++
+ buf = gtk_progress_get_current_text (progress);
+
+ layout = gtk_widget_create_pango_layout (widget, buf);
+@@ -789,12 +858,12 @@
+
+ pango_layout_get_pixel_extents (layout, NULL, &logical_rect);
+
+- x = widget->style->xthickness + 1 +
++ x = widget->style->xthickness + text_xnudge +
+ (widget->allocation.width - 2 * widget->style->xthickness -
+ 2 - logical_rect.width)
+ * progress->x_align;
+
+- y = widget->style->ythickness + 1 +
++ y = widget->style->ythickness + text_ynudge +
+ (widget->allocation.height - 2 * widget->style->ythickness -
+ 2 - logical_rect.height)
+ * progress->y_align;
diff --git a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkradiobutton.c.diff b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkradiobutton.c.diff
index e69de29bb2..f4669c6d9f 100644
--- a/packages/gtk+/gtk+-2.6.4-1.osso7/gtkradiobutton.c.diff
+++ b/packages/gtk+/gtk+-2.6.4-1.osso7/gtkradiobutton.c.diff
@@ -0,0 +1,244 @@
+--- gtk+-2.6.4/gtk/gtkradiobutton.c 2004-08-09 19:59:52.000000000 +0300
++++ gtk+-2.6.4/gtk/gtkradiobutton.c 2005-04-06 16:19:37.126894216 +0300
+@@ -31,6 +31,7 @@
+ #include "gtkradiobutton.h"
+ #include "gtkintl.h"
+
++#define TOGGLE_ON_CLICK "toggle-on-click"
+
+ enum {
+ PROP_0,
+@@ -506,6 +507,9 @@
+ {
+ tmp_list = tmp_list->next;
+
++ if( !tmp_list )
++ return FALSE;
++
+ while (tmp_list)
+ {
+ GtkWidget *child = tmp_list->data;
+@@ -543,7 +547,10 @@
+ if (new_focus)
+ {
+ gtk_widget_grab_focus (new_focus);
+- gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (new_focus), TRUE);
++
++ /* arrow keys select the button ? CHECK THIS!!
++ gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (new_focus), TRUE);
++ */
+ }
+
+ return TRUE;
+@@ -579,7 +586,7 @@
+ GtkToggleButton *toggle_button;
+ GtkRadioButton *radio_button;
+ GtkToggleButton *tmp_button;
+- GtkStateType new_state;
++ GtkStateType new_state = GTK_WIDGET_STATE( button );
+ GSList *tmp_list;
+ gint toggled;
+ gboolean depressed;
+@@ -591,52 +598,54 @@
+ g_object_ref (GTK_WIDGET (button));
+
+ if (toggle_button->active)
+- {
+- tmp_button = NULL;
+- tmp_list = radio_button->group;
+-
+- while (tmp_list)
+- {
+- tmp_button = tmp_list->data;
+- tmp_list = tmp_list->next;
++ {
++ tmp_button = NULL;
++ tmp_list = radio_button->group;
+
+- if (tmp_button->active && tmp_button != toggle_button)
+- break;
++ while (tmp_list)
++ {
++ tmp_button = tmp_list->data;
++ tmp_list = tmp_list->next;
++
++ if (tmp_button->active && tmp_button != toggle_button)
++ break;
+
+- tmp_button = NULL;
+- }
++ tmp_button = NULL;
++ }
+
+- if (!tmp_button)
+- {
+- new_state = (button->in_button ? GTK_STATE_PRELIGHT : GTK_STATE_ACTIVE);
++ if (!tmp_button)
++ {
++ new_state = (button->in_button ?
++ GTK_STATE_PRELIGHT : GTK_STATE_ACTIVE);
++ }
++ else
++ {
++ toggled = TRUE;
++ toggle_button->active = !toggle_button->active;
++ new_state = (button->in_button ? GTK_STATE_PRELIGHT : GTK_STATE_NORMAL);
++ }
+ }
+ else
+ {
+ toggled = TRUE;
+ toggle_button->active = !toggle_button->active;
+- new_state = (button->in_button ? GTK_STATE_PRELIGHT : GTK_STATE_NORMAL);
+- }
+- }
+- else
+- {
+- toggled = TRUE;
+- toggle_button->active = !toggle_button->active;
+
+- tmp_list = radio_button->group;
+- while (tmp_list)
+- {
+- tmp_button = tmp_list->data;
+- tmp_list = tmp_list->next;
+-
+- if (tmp_button->active && (tmp_button != toggle_button))
++ tmp_list = radio_button->group;
++ while (tmp_list)
+ {
+- gtk_button_clicked (GTK_BUTTON (tmp_button));
+- break;
++ tmp_button = tmp_list->data;
++ tmp_list = tmp_list->next;
++
++ if (tmp_button->active && (tmp_button != toggle_button))
++ {
++ gtk_button_clicked (GTK_BUTTON (tmp_button));
++ break;
++ }
+ }
++
++ new_state = (button->in_button ? GTK_STATE_PRELIGHT : GTK_STATE_ACTIVE);
+ }
+
+- new_state = (button->in_button ? GTK_STATE_PRELIGHT : GTK_STATE_ACTIVE);
+- }
+
+ if (toggle_button->inconsistent)
+ depressed = FALSE;
+@@ -663,7 +672,6 @@
+ GdkRectangle *area)
+ {
+ GtkWidget *widget;
+- GtkWidget *child;
+ GtkButton *button;
+ GtkToggleButton *toggle_button;
+ GtkStateType state_type;
+@@ -686,54 +694,80 @@
+ "focus-padding", &focus_pad,
+ NULL);
+
+- _gtk_check_button_get_props (check_button, &indicator_size, &indicator_spacing);
+-
+- x = widget->allocation.x + indicator_spacing + GTK_CONTAINER (widget)->border_width;
+- y = widget->allocation.y + (widget->allocation.height - indicator_size) / 2;
+-
+- child = GTK_BIN (check_button)->child;
+- if (!interior_focus || !(child &a