From 91c8233f08e8e73209ee17560c1c3582348b7540 Mon Sep 17 00:00:00 2001 From: Robert Ancell Date: Tue, 30 Jun 2009 19:11:59 +1000 Subject: [PATCH] Import upstream version 3.6.7 --- ChangeLog | 50 +++++++- Makefile.in | 1 + NEWS | 18 ++- configure | 94 ++++++++------ configure.ac | 16 ++- data/Makefile.in | 1 + data/icons/Makefile.in | 1 + data/icons/hicolor/16x16/Makefile.in | 1 + data/icons/hicolor/16x16/apps/Makefile.in | 1 + data/icons/hicolor/22x22/Makefile.in | 1 + data/icons/hicolor/22x22/apps/Makefile.in | 1 + data/icons/hicolor/24x24/Makefile.in | 1 + data/icons/hicolor/24x24/apps/Makefile.in | 1 + data/icons/hicolor/32x32/Makefile.in | 1 + data/icons/hicolor/32x32/apps/Makefile.in | 1 + data/icons/hicolor/48x48/Makefile.in | 1 + data/icons/hicolor/48x48/apps/Makefile.in | 1 + data/icons/hicolor/Makefile.in | 1 + data/icons/hicolor/scalable/Makefile.in | 1 + data/icons/hicolor/scalable/apps/Makefile.in | 1 + doc/Makefile.in | 1 + doc/html/index.html | 2 +- doc/version.xml | 2 +- gladeui/Makefile.am | 2 +- gladeui/Makefile.in | 3 +- gladeui/glade-app.c | 5 +- gladeui/glade-base-editor.c | 25 ++-- gladeui/glade-editor-property.c | 2 +- gladeui/glade-inspector.c | 6 +- gladeui/glade-palette-item.c | 9 +- gladeui/glade-placeholder.c | 8 +- gladeui/glade-popup.c | 13 ++ gladeui/glade-popup.h | 3 + gladeui/glade-property.c | 11 +- gladeui/glade-widget-adaptor.c | 15 ++- gladeui/glade-widget.c | 7 +- help/Makefile.in | 1 + plugins/Makefile.in | 1 + plugins/gnome/Makefile.in | 1 + plugins/gnome/icons/16x16/Makefile.in | 1 + plugins/gnome/icons/22x22/Makefile.in | 1 + plugins/gnome/icons/Makefile.in | 1 + plugins/gtk+/Makefile.in | 1 + plugins/gtk+/glade-activatable-editor.c | 9 +- plugins/gtk+/glade-gtk.c | 128 ++++++++++++++++--- plugins/gtk+/gtk+.xml | 3 +- plugins/gtk+/gtk+.xml.in | 4 +- plugins/gtk+/icons/16x16/Makefile.in | 1 + plugins/gtk+/icons/22x22/Makefile.in | 1 + plugins/gtk+/icons/Makefile.in | 1 + plugins/python/Makefile.in | 1 + src/Makefile.in | 1 + 52 files changed, 352 insertions(+), 112 deletions(-) diff --git a/ChangeLog b/ChangeLog index 9843455..c7dc798 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,9 +1,57 @@ +2009-06-29 Tristan Van Berkom + + * configure.ac, NEWS: Rolling Glade 3.6.7 + + * configure.ac, gladeui/glade-app.c: Added --enable-mac-bundle configure option to + special case runtime path lookups to bundling builds. + + * gladeui/glade-popup.[ch]: Added glade_popup_is_popup_event () to check the correct + GdkEventButton state for a context menu (in a platform independant way). + + * gladeui/glade-base-editor.c, gladeui/glade-editor-property.c, gladeui/glade-palette-item.c, + gladeui/glade-placeholder.c, gladeui/glade-widget.c, gladeui/glade-inspector.c: Use new + popup function to detect whether to show a context menu or not (bug 587128). + + * gladeui/glade-base-editor.c: Fixed crashes with editable treeview column types (bug 586715). + +2009-06-27 Tristan Van Berkom + + * plugins/gtk+/gtk+.xml.in, glade/gtk+/glade-gtk.c: Fixed GtkTextView crashes when + editing the textview in line, now we update the associated GtkTextBuffer:text property + if available or the GtkTextView:text virtual property when in libglade mode. + +2009-06-25 Tristan Van Berkom + + * gladeui/glade-property.c: glade_property_sync_impl(), dont sync properties + that are the primary property of that klass for the said widget (properties + can float outside of widget->properties in some cases, shouldnt effect the + widget though). + + * plugins/gtk+/glade-gtk.c: + - glade_gtk_button_write_widget (), make stock button labels save as + non-translatable automatically (bug 352446). + - Added sync_use_appearance() to reset the use-appearance property when local + widget property updates demand that the appearance be resynchronized (this + is actually a bug in GTK+ somewhere). + - Avoid tampering with the virtual GtkBox:size property while loading a project. + + * plugins/gtk+/gtk+.xml.in: Attributed use-action-appearance property with "needs-sync" + for better chances at a good visual result when copy/pasting etc. + + * plugins/gtk+/glade-activatable-editor.c: Reverse order in which the image is + removed from GtkImageMenuItems (so that mucking with stock doesnt recreate one + 2 lines further), now image menu items with controlling actions dont get orphaned images. + + * gladeui/glade-widget-adaptor.c: Sync remaining properties at load time + which were not specified in the glade file (now the use-action-appearance + property shows up right even if default and not present in the Glade file). + 2009-06-22 Tristan Van Berkom * configure.ac, NEWS: Rolling Glade 3.6.6 * gladeui/glade-app.c, gladeui/Makefile.am: Find quartz specific runtime prefix - using ige_mac_bundle_get_path(). + using ige_mac_bundle_get_path() (bug 586551) * gladeui/glade-project.c: Added algorythm to introspect lowest possible version of GTK+ to depend on for a project, this helps cases where the diff --git a/Makefile.in b/Makefile.in index 5439646..cf935ea 100644 --- a/Makefile.in +++ b/Makefile.in @@ -161,6 +161,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/NEWS b/NEWS index 4970655..3eb50f4 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,19 @@ + +=========== +Glade 3.6.7 +=========== + - Sync up remaining properties at load time (fixes use-action-appearance property + and any other unmentioned property states at load time, also unvails broken + orientation default value in GTK+, bug 587256). + - Fixed glitches with use-action-appearance at save time. + - Make stock button labels save as non-translatable automatically (bug 352446). + - Fixed crashes when handling GtkTextView in GtkBuilder format. + - Fixed crashes with editable treeview column types (bug 586715). + - Detect correct modifiers and buttons to spawn a context menu in a platform + independant way (bug 587128). + - Added --enable-mac-bundle configure argument to resolve paths correctly + when building bundles on osx. + =========== Glade 3.6.6 =========== @@ -8,7 +24,7 @@ Glade 3.6.6 - Migrated to use non-deprecated symbols from glib/GTK+ (Sam Thursfield - bug 572756) - Introspect lowest GTK+ project dependancy when loading files with missing versioning info (bug 586046). - - Fixed runtime path resolutions on osx. + - Fixed runtime path resolutions on osx (bug 586551). =========== Glade 3.6.5 diff --git a/configure b/configure index d097180..4546314 100755 --- a/configure +++ b/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.61 for glade3 3.6.6. +# Generated by GNU Autoconf 2.61 for glade3 3.6.7. # # Report bugs to . # @@ -728,8 +728,8 @@ SHELL=${CONFIG_SHELL-/bin/sh} # Identity of this package. PACKAGE_NAME='glade3' PACKAGE_TARNAME='glade3' -PACKAGE_VERSION='3.6.6' -PACKAGE_STRING='glade3 3.6.6' +PACKAGE_VERSION='3.6.7' +PACKAGE_STRING='glade3 3.6.7' PACKAGE_BUGREPORT='http://bugzilla.gnome.org/enter_bug.cgi?product=glade3' ac_unique_file="gladeui/glade.h" @@ -990,6 +990,7 @@ GDK_TARGET_QUARTZ_TRUE GDK_TARGET_QUARTZ_FALSE IGE_MAC_CFLAGS IGE_MAC_LIBS +IGE_MAC_BUNDLE_FLAG AM_CPPFLAGS AM_CFLAGS AM_CXXFLAGS @@ -1523,7 +1524,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures glade3 3.6.6 to adapt to many kinds of systems. +\`configure' configures glade3 3.6.7 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1594,7 +1595,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of glade3 3.6.6:";; + short | recursive ) echo "Configuration of glade3 3.6.7:";; esac cat <<\_ACEOF @@ -1619,6 +1620,7 @@ Optional Features: --disable-gnome disable gnome catalog --disable-python disable python catalog --disable-scrollkeeper do not make updates to the scrollkeeper database + --enable-mac-bundle enable mac bundling Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] @@ -1725,7 +1727,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -glade3 configure 3.6.6 +glade3 configure 3.6.7 generated by GNU Autoconf 2.61 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @@ -1739,7 +1741,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by glade3 $as_me 3.6.6, which was +It was created by glade3 $as_me 3.6.7, which was generated by GNU Autoconf 2.61. Invocation command line was $ $0 $@ @@ -2114,10 +2116,10 @@ GLADE_MINOR_VERSION=6 cat >>confdefs.h <<\_ACEOF -#define GLADE_MICRO_VERSION 6 +#define GLADE_MICRO_VERSION 7 _ACEOF -GLADE_MICRO_VERSION=6 +GLADE_MICRO_VERSION=7 ac_aux_dir= @@ -2564,7 +2566,7 @@ fi # Define the identity of the package. PACKAGE='glade3' - VERSION='3.6.6' + VERSION='3.6.7' cat >>confdefs.h <<_ACEOF @@ -6299,7 +6301,7 @@ ia64-*-hpux*) ;; *-*-irix6*) # Find out which ABI we are using. - echo '#line 6302 "configure"' > conftest.$ac_ext + echo '#line 6304 "configure"' > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? @@ -9647,11 +9649,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:9650: $lt_compile\"" >&5) + (eval echo "\"\$as_me:9652: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:9654: \$? = $ac_status" >&5 + echo "$as_me:9656: \$? = $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 other than the usual output. @@ -9937,11 +9939,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:9940: $lt_compile\"" >&5) + (eval echo "\"\$as_me:9942: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:9944: \$? = $ac_status" >&5 + echo "$as_me:9946: \$? = $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 other than the usual output. @@ -10041,11 +10043,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:10044: $lt_compile\"" >&5) + (eval echo "\"\$as_me:10046: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:10048: \$? = $ac_status" >&5 + echo "$as_me:10050: \$? = $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 @@ -12418,7 +12420,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext < conftest.$ac_ext <&5) + (eval echo "\"\$as_me:14924: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:14926: \$? = $ac_status" >&5 + echo "$as_me:14928: \$? = $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 other than the usual output. @@ -15023,11 +15025,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:15026: $lt_compile\"" >&5) + (eval echo "\"\$as_me:15028: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:15030: \$? = $ac_status" >&5 + echo "$as_me:15032: \$? = $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 @@ -16621,11 +16623,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:16624: $lt_compile\"" >&5) + (eval echo "\"\$as_me:16626: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:16628: \$? = $ac_status" >&5 + echo "$as_me:16630: \$? = $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 other than the usual output. @@ -16725,11 +16727,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:16728: $lt_compile\"" >&5) + (eval echo "\"\$as_me:16730: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:16732: \$? = $ac_status" >&5 + echo "$as_me:16734: \$? = $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 @@ -18945,11 +18947,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:18948: $lt_compile\"" >&5) + (eval echo "\"\$as_me:18950: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:18952: \$? = $ac_status" >&5 + echo "$as_me:18954: \$? = $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 other than the usual output. @@ -19235,11 +19237,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:19238: $lt_compile\"" >&5) + (eval echo "\"\$as_me:19240: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:19242: \$? = $ac_status" >&5 + echo "$as_me:19244: \$? = $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 other than the usual output. @@ -19339,11 +19341,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:19342: $lt_compile\"" >&5) + (eval echo "\"\$as_me:19344: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:19346: \$? = $ac_status" >&5 + echo "$as_me:19348: \$? = $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 @@ -25220,6 +25222,25 @@ echo "${ECHO_T}yes" >&6; } : fi + IGE_MAC_BUNDLE_FLAG= + + # Check whether --enable-mac-bundle was given. +if test "${enable_mac_bundle+set}" = set; then + enableval=$enable_mac_bundle; build_bundle=yes +else + build_bundle=no +fi + + + if test "x$build_bundle" = xyes; then + { echo "$as_me:$LINENO: enableing mac bundle.." >&5 +echo "$as_me: enableing mac bundle.." >&6;} + + IGE_MAC_BUNDLE_FLAG=-DMAC_BUNDLE + fi + + + fi @@ -25750,7 +25771,7 @@ exec 6>&1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by glade3 $as_me 3.6.6, which was +This file was extended by glade3 $as_me 3.6.7, which was generated by GNU Autoconf 2.61. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -25803,7 +25824,7 @@ Report bugs to ." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF ac_cs_version="\\ -glade3 config.status 3.6.6 +glade3 config.status 3.6.7 configured by $0, generated by GNU Autoconf 2.61, with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" @@ -26322,6 +26343,7 @@ GDK_TARGET_QUARTZ_TRUE!$GDK_TARGET_QUARTZ_TRUE$ac_delim GDK_TARGET_QUARTZ_FALSE!$GDK_TARGET_QUARTZ_FALSE$ac_delim IGE_MAC_CFLAGS!$IGE_MAC_CFLAGS$ac_delim IGE_MAC_LIBS!$IGE_MAC_LIBS$ac_delim +IGE_MAC_BUNDLE_FLAG!$IGE_MAC_BUNDLE_FLAG$ac_delim AM_CPPFLAGS!$AM_CPPFLAGS$ac_delim AM_CFLAGS!$AM_CFLAGS$ac_delim AM_CXXFLAGS!$AM_CXXFLAGS$ac_delim @@ -26330,7 +26352,7 @@ LIBOBJS!$LIBOBJS$ac_delim LTLIBOBJS!$LTLIBOBJS$ac_delim _ACEOF - if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 33; then + if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 34; then break elif $ac_last_try; then { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 diff --git a/configure.ac b/configure.ac index 2b935ae..0fefe98 100644 --- a/configure.ac +++ b/configure.ac @@ -4,7 +4,7 @@ AC_PREREQ(2.52) m4_define(glade_major_version, 3) m4_define(glade_minor_version, 6) -m4_define(glade_micro_version, 6) +m4_define(glade_micro_version, 7) m4_define(glade_version, glade_major_version.glade_minor_version.glade_micro_version) AC_INIT([glade3], [glade_version], @@ -226,6 +226,20 @@ _gdk_tgt=`$PKG_CONFIG --variable=target gdk-2.0` AM_CONDITIONAL([GDK_TARGET_QUARTZ], [test x$_gdk_tgt = xquartz]) if test "x$_gdk_tgt" = xquartz; then PKG_CHECK_MODULES(IGE_MAC, ige-mac-integration) + + IGE_MAC_BUNDLE_FLAG= + + AC_ARG_ENABLE(mac-bundle, + AS_HELP_STRING([--enable-mac-bundle], [enable mac bundling]), + build_bundle=yes, build_bundle=no) + + if test "x$build_bundle" = xyes; then + AC_MSG_NOTICE([enableing mac bundle..]) + + IGE_MAC_BUNDLE_FLAG=-DMAC_BUNDLE + fi + + AC_SUBST(IGE_MAC_BUNDLE_FLAG) AC_SUBST(IGE_MAC_LIBS) AC_SUBST(IGE_MAC_CFLAGS) fi diff --git a/data/Makefile.in b/data/Makefile.in index 5ea8f0f..ba65b8c 100644 --- a/data/Makefile.in +++ b/data/Makefile.in @@ -157,6 +157,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/data/icons/Makefile.in b/data/icons/Makefile.in index 2b25bec..aabf578 100644 --- a/data/icons/Makefile.in +++ b/data/icons/Makefile.in @@ -154,6 +154,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/data/icons/hicolor/16x16/Makefile.in b/data/icons/hicolor/16x16/Makefile.in index f0d0671..d32333c 100644 --- a/data/icons/hicolor/16x16/Makefile.in +++ b/data/icons/hicolor/16x16/Makefile.in @@ -144,6 +144,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/data/icons/hicolor/16x16/apps/Makefile.in b/data/icons/hicolor/16x16/apps/Makefile.in index 643dac0..12605ff 100644 --- a/data/icons/hicolor/16x16/apps/Makefile.in +++ b/data/icons/hicolor/16x16/apps/Makefile.in @@ -145,6 +145,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/data/icons/hicolor/22x22/Makefile.in b/data/icons/hicolor/22x22/Makefile.in index 166dcab..6172dba 100644 --- a/data/icons/hicolor/22x22/Makefile.in +++ b/data/icons/hicolor/22x22/Makefile.in @@ -144,6 +144,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/data/icons/hicolor/22x22/apps/Makefile.in b/data/icons/hicolor/22x22/apps/Makefile.in index f0e1c50..1d3284c 100644 --- a/data/icons/hicolor/22x22/apps/Makefile.in +++ b/data/icons/hicolor/22x22/apps/Makefile.in @@ -145,6 +145,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/data/icons/hicolor/24x24/Makefile.in b/data/icons/hicolor/24x24/Makefile.in index 65d9830..8ee43bb 100644 --- a/data/icons/hicolor/24x24/Makefile.in +++ b/data/icons/hicolor/24x24/Makefile.in @@ -144,6 +144,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/data/icons/hicolor/24x24/apps/Makefile.in b/data/icons/hicolor/24x24/apps/Makefile.in index d4db7ed..e5a19bd 100644 --- a/data/icons/hicolor/24x24/apps/Makefile.in +++ b/data/icons/hicolor/24x24/apps/Makefile.in @@ -145,6 +145,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/data/icons/hicolor/32x32/Makefile.in b/data/icons/hicolor/32x32/Makefile.in index 4463637..d86ccba 100644 --- a/data/icons/hicolor/32x32/Makefile.in +++ b/data/icons/hicolor/32x32/Makefile.in @@ -144,6 +144,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/data/icons/hicolor/32x32/apps/Makefile.in b/data/icons/hicolor/32x32/apps/Makefile.in index b647f2e..0896555 100644 --- a/data/icons/hicolor/32x32/apps/Makefile.in +++ b/data/icons/hicolor/32x32/apps/Makefile.in @@ -145,6 +145,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/data/icons/hicolor/48x48/Makefile.in b/data/icons/hicolor/48x48/Makefile.in index 847664b..58c2da6 100644 --- a/data/icons/hicolor/48x48/Makefile.in +++ b/data/icons/hicolor/48x48/Makefile.in @@ -144,6 +144,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/data/icons/hicolor/48x48/apps/Makefile.in b/data/icons/hicolor/48x48/apps/Makefile.in index fffaaea..1b4a990 100644 --- a/data/icons/hicolor/48x48/apps/Makefile.in +++ b/data/icons/hicolor/48x48/apps/Makefile.in @@ -145,6 +145,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/data/icons/hicolor/Makefile.in b/data/icons/hicolor/Makefile.in index 27372cb..f284daa 100644 --- a/data/icons/hicolor/Makefile.in +++ b/data/icons/hicolor/Makefile.in @@ -144,6 +144,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/data/icons/hicolor/scalable/Makefile.in b/data/icons/hicolor/scalable/Makefile.in index 8406a08..76229dd 100644 --- a/data/icons/hicolor/scalable/Makefile.in +++ b/data/icons/hicolor/scalable/Makefile.in @@ -144,6 +144,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/data/icons/hicolor/scalable/apps/Makefile.in b/data/icons/hicolor/scalable/apps/Makefile.in index 328fb56..2f5afa9 100644 --- a/data/icons/hicolor/scalable/apps/Makefile.in +++ b/data/icons/hicolor/scalable/apps/Makefile.in @@ -145,6 +145,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/doc/Makefile.in b/doc/Makefile.in index 50d270c..770617b 100644 --- a/doc/Makefile.in +++ b/doc/Makefile.in @@ -142,6 +142,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/doc/html/index.html b/doc/html/index.html index 61941b6..0403c2a 100644 --- a/doc/html/index.html +++ b/doc/html/index.html @@ -23,7 +23,7 @@

Tristan Van Berkom

-

for glade3 3.6.5

+

for glade3 3.6.6

Abstract

diff --git a/doc/version.xml b/doc/version.xml index bf65d49..f94a871 100644 --- a/doc/version.xml +++ b/doc/version.xml @@ -1 +1 @@ -glade3 3.6.6 \ No newline at end of file +glade3 3.6.7 \ No newline at end of file diff --git a/gladeui/Makefile.am b/gladeui/Makefile.am index 007e2e5..6dff150 100644 --- a/gladeui/Makefile.am +++ b/gladeui/Makefile.am @@ -1,7 +1,6 @@ common_defines = \ -DG_LOG_DOMAIN=\"GladeUI\" \ - -DGLADE_PREFIX="\"$(prefix)\"" \ -DGLADE_DATADIR="\"$(pkgdatadir)\"" \ -DGLADE_LIBDIR="\"$(pkglibdir)\"" \ -DGLADE_CATALOGSDIR="\"$(pkgdatadir)/catalogs\""\ @@ -76,6 +75,7 @@ libgladeui_1_la_CPPFLAGS = \ libgladeui_1_la_CFLAGS = \ $(GTK_CFLAGS) \ + $(IGE_MAC_BUNDLE_FLAG) \ $(IGE_MAC_CFLAGS) \ $(WARN_CFLAGS) \ $(AM_CFLAGS) diff --git a/gladeui/Makefile.in b/gladeui/Makefile.in index 795596c..45f5b5e 100644 --- a/gladeui/Makefile.in +++ b/gladeui/Makefile.in @@ -208,6 +208,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ @@ -351,7 +352,6 @@ target_os = @target_os@ target_vendor = @target_vendor@ common_defines = \ -DG_LOG_DOMAIN=\"GladeUI\" \ - -DGLADE_PREFIX="\"$(prefix)\"" \ -DGLADE_DATADIR="\"$(pkgdatadir)\"" \ -DGLADE_LIBDIR="\"$(pkglibdir)\"" \ -DGLADE_CATALOGSDIR="\"$(pkgdatadir)/catalogs\""\ @@ -424,6 +424,7 @@ libgladeui_1_la_CPPFLAGS = \ libgladeui_1_la_CFLAGS = \ $(GTK_CFLAGS) \ + $(IGE_MAC_BUNDLE_FLAG) \ $(IGE_MAC_CFLAGS) \ $(WARN_CFLAGS) \ $(AM_CFLAGS) diff --git a/gladeui/glade-app.c b/gladeui/glade-app.c index 53fbc6e..1295a11 100644 --- a/gladeui/glade-app.c +++ b/gladeui/glade-app.c @@ -366,12 +366,13 @@ glade_app_get_locale_dir (void) static void build_package_paths (void) { -#if defined (MAC_INTEGRATION) || defined (G_OS_WIN32) +#if defined (G_OS_WIN32) || (defined (MAC_INTEGRATION) && defined (MAC_BUNDLE)) gchar *prefix; # ifdef G_OS_WIN32 prefix = g_win32_get_package_installation_directory_of_module (NULL); -# else /* MAC_INTEGRATION */ + +# else // defined (MAC_INTEGRATION) && defined (MAC_BUNDLE) IgeMacBundle *bundle = ige_mac_bundle_get_default (); prefix = g_build_filename (ige_mac_bundle_get_path (bundle), "Contents", "Resources", NULL); diff --git a/gladeui/glade-base-editor.c b/gladeui/glade-base-editor.c index 84b027a..7f866ef 100644 --- a/gladeui/glade-base-editor.c +++ b/gladeui/glade-base-editor.c @@ -34,6 +34,7 @@ #include "glade-editor-property.h" #include "glade-base-editor.h" #include "glade-app.h" +#include "glade-popup.h" #include "glade-accumulators.h" #include @@ -279,7 +280,7 @@ glade_base_editor_fill_store_real (GladeBaseEditor *e, GLADE_BASE_EDITOR_TYPE_NAME, type_name, GLADE_BASE_EDITOR_NAME, name, GLADE_BASE_EDITOR_CHILD_TYPES, - get_children_model_for_type (e, G_OBJECT_TYPE (gwidget->object)), + get_children_model_for_child_type (e, G_OBJECT_TYPE (child)), -1); glade_base_editor_fill_store_real (e, gchild, &iter); @@ -737,13 +738,13 @@ glade_base_editor_popup (GladeBaseEditor *editor, gchar *label; gchar *class_name; - if ((model = get_children_model_for_child_type (editor, G_OBJECT_TYPE (widget->object))) == NULL) - return NULL; + model = get_children_model_for_type (editor, G_OBJECT_TYPE (editor->priv->gcontainer->object)); + g_assert (model); + popup = gtk_menu_new (); - if (gtk_tree_model_get_iter_first (model, &iter)) do { @@ -813,11 +814,7 @@ glade_base_editor_popup_handler (GtkWidget *treeview, GtkTreePath *path; GtkWidget *popup; - if (event->button == 3 || - (event->button == 1 && - ((event->state & GDK_MOD1_MASK) != 0 || - (event->state & GDK_MOD2_MASK) != 0 || - (event->state & GDK_MOD2_MASK) != 0))) + if (glade_popup_is_popup_event (event)) { if (gtk_tree_view_get_path_at_pos (GTK_TREE_VIEW (treeview), (gint) event->x, (gint) event->y, &path, NULL, NULL, NULL)) @@ -1963,13 +1960,15 @@ glade_base_editor_add_default_properties (GladeBaseEditor *editor, GtkWidget *label, *entry; GtkTreeModel *child_class; GtkCellRenderer *renderer; - GObject *child = glade_widget_get_object (gchild); - + GObject *child; + g_return_if_fail (GLADE_IS_BASE_EDITOR (editor)); g_return_if_fail (GLADE_IS_WIDGET (gchild)); g_return_if_fail (GLADE_IS_WIDGET (gchild->parent)); - child_class = get_children_model_for_type (editor, G_OBJECT_TYPE (child)); + child = glade_widget_get_object (gchild); + + child_class = get_children_model_for_child_type (editor, G_OBJECT_TYPE (child)); /* Name */ label = gtk_label_new (_("Name :")); @@ -1981,7 +1980,7 @@ glade_base_editor_add_default_properties (GladeBaseEditor *editor, g_signal_connect (entry, "focus-out-event", G_CALLBACK (glade_base_editor_name_focus_out), gchild); glade_base_editor_table_attach (editor, label, entry); - if (child_class) + if (child_class && gtk_tree_model_iter_n_children (child_class, NULL) > 1) { /* Type */ label = gtk_label_new (_("Type :")); diff --git a/gladeui/glade-editor-property.c b/gladeui/glade-editor-property.c index d51d999..55e6aa4 100644 --- a/gladeui/glade-editor-property.c +++ b/gladeui/glade-editor-property.c @@ -234,7 +234,7 @@ glade_editor_property_button_pressed (GtkWidget *widget, GdkEventButton *event, GladeEditorProperty *eprop) { - if (event->button == 3 && event->type == GDK_BUTTON_PRESS) + if (glade_popup_is_popup_event (event)) { glade_popup_property_pop (eprop->property, event); return TRUE; diff --git a/gladeui/glade-inspector.c b/gladeui/glade-inspector.c index 11be2bf..05f63d3 100644 --- a/gladeui/glade-inspector.c +++ b/gladeui/glade-inspector.c @@ -920,11 +920,7 @@ button_press_cb (GtkWidget *widget, /* Give some kind of access in case of missing right button */ if (event->window == gtk_tree_view_get_bin_window (view) && - (event->button == 3 || - (event->button == 1 && - ((event->state & GDK_MOD1_MASK) != 0 || - (event->state & GDK_MOD2_MASK) != 0 || - (event->state & GDK_MOD2_MASK) != 0)))) + glade_popup_is_popup_event (event)) { if (gtk_tree_view_get_path_at_pos (view, (gint) event->x, (gint) event->y, &path, NULL, diff --git a/gladeui/glade-palette-item.c b/gladeui/glade-palette-item.c index 13eb7ff..56e21ca 100644 --- a/gladeui/glade-palette-item.c +++ b/gladeui/glade-palette-item.c @@ -337,17 +337,12 @@ static gboolean glade_palette_item_button_press (GtkWidget *widget, GdkEventButton *event) { - /* Give some kind of access in case of missing right button */ - if (!event->type == GDK_BUTTON_PRESS && - (event->button == 3 || - (event->button == 1 && - ((event->state & GDK_MOD1_MASK) != 0 || - (event->state & GDK_MOD2_MASK) != 0 || - (event->state & GDK_MOD2_MASK) != 0)))) + if (glade_popup_is_popup_event (event)) { GladePaletteItemPrivate *priv = GLADE_PALETTE_ITEM_GET_PRIVATE (widget); glade_popup_palette_pop (priv->adaptor, event); + return TRUE; } return GTK_WIDGET_CLASS (glade_palette_item_parent_class)->button_press_event (widget, event); diff --git a/gladeui/glade-placeholder.c b/gladeui/glade-placeholder.c index fa7f26a..893a954 100644 --- a/gladeui/glade-placeholder.c +++ b/gladeui/glade-placeholder.c @@ -357,13 +357,7 @@ glade_placeholder_button_press (GtkWidget *widget, GdkEventButton *event) } } - /* Give some kind of access in case of missing right button */ - if (!handled && event->type == GDK_BUTTON_PRESS && - (event->button == 3 || - (event->button == 1 && - ((event->state & GDK_MOD1_MASK) != 0 || - (event->state & GDK_MOD2_MASK) != 0 || - (event->state & GDK_MOD2_MASK) != 0)))) + if (!handled && glade_popup_is_popup_event (event)) { glade_popup_placeholder_pop (placeholder, event); handled = TRUE; diff --git a/gladeui/glade-popup.c b/gladeui/glade-popup.c index ddbe12a..67ba7f4 100644 --- a/gladeui/glade-popup.c +++ b/gladeui/glade-popup.c @@ -18,6 +18,7 @@ * * Authors: * Chema Celorio + * Tristan Van Berkom */ #ifdef HAVE_CONFIG_H @@ -797,3 +798,15 @@ glade_popup_simple_pop (GdkEventButton *event) NULL, NULL, button, event_time); } +gboolean +glade_popup_is_popup_event (GdkEventButton *event) +{ + g_return_val_if_fail (event, FALSE); + +#ifdef MAC_INTEGRATION + return (event->type == GDK_BUTTON_PRESS && event->button == 1 && ((event->state & GDK_MOD1_MASK) != 0)); +#else + return (event->type == GDK_BUTTON_PRESS && event->button == 3); +#endif +} + diff --git a/gladeui/glade-popup.h b/gladeui/glade-popup.h index 82f59e7..77fdb03 100644 --- a/gladeui/glade-popup.h +++ b/gladeui/glade-popup.h @@ -27,6 +27,9 @@ void glade_popup_simple_pop (GdkEventButton *event); void glade_popup_property_pop (GladeProperty *property, GdkEventButton *event); + +gboolean glade_popup_is_popup_event (GdkEventButton *event); + G_END_DECLS #endif /* __GLADE_POPUP_H__ */ diff --git a/gladeui/glade-property.c b/gladeui/glade-property.c index 2fc118d..6cecae8 100644 --- a/gladeui/glade-property.c +++ b/gladeui/glade-property.c @@ -334,7 +334,6 @@ glade_property_get_value_impl (GladeProperty *property, GValue *value) static void glade_property_sync_impl (GladeProperty *property) { - /* Heh, here are the many reasons not to * sync a property ;-) */ @@ -351,6 +350,14 @@ glade_property_sync_impl (GladeProperty *property) property->widget == NULL) return; + /* Only the properties from widget->properties should affect the runtime widget. + * (other properties may be used for convenience in the plugin). + */ + if ((property->klass->packing && + property != glade_widget_get_pack_property (property->widget, property->klass->id)) || + property != glade_widget_get_property (property->widget, property->klass->id)) + return; + property->syncing++; /* In the case of construct_only, the widget instance must be rebuilt @@ -1014,7 +1021,7 @@ glade_property_read (GladeProperty *property, GladeProjectFormat fmt; GValue *gvalue = NULL; gchar /* *id, *name, */ *value; - gint translatable, has_context; + gint translatable = FALSE, has_context = FALSE; gchar *comment = NULL, *context = NULL; g_return_if_fail (GLADE_IS_PROPERTY (property)); diff --git a/gladeui/glade-widget-adaptor.c b/gladeui/glade-widget-adaptor.c index 42bee90..9daa6bf 100644 --- a/gladeui/glade-widget-adaptor.c +++ b/gladeui/glade-widget-adaptor.c @@ -868,6 +868,7 @@ glade_widget_adaptor_object_read_widget (GladeWidgetAdaptor *adaptor, GladeSignal *signal; GladeProperty *property; gchar *name, *prop_name; + GList *read_properties = NULL, *l; /* Read in the properties */ for (iter_node = glade_xml_node_get_children (node); @@ -885,13 +886,25 @@ glade_widget_adaptor_object_read_widget (GladeWidgetAdaptor *adaptor, /* Some properties may be special child type of custom, just leave them for the adaptor */ if ((property = glade_widget_get_property (widget, prop_name)) != NULL) + { glade_property_read (property, widget->project, iter_node); + read_properties = g_list_prepend (read_properties, property); + } g_free (prop_name); g_free (name); } - + /* Sync the remaining values not read in from the Glade file.. */ + for (l = widget->properties; l; l = l->next) + { + property = l->data; + + if (!g_list_find (read_properties, property)) + glade_property_sync (property); + } + g_list_free (read_properties); + /* Read in the signals */ for (iter_node = glade_xml_node_get_children (node); iter_node; iter_node = glade_xml_node_next (iter_node)) diff --git a/gladeui/glade-widget.c b/gladeui/glade-widget.c index 2e216db..7d31616 100644 --- a/gladeui/glade-widget.c +++ b/gladeui/glade-widget.c @@ -335,12 +335,7 @@ glade_widget_button_press_event_impl (GladeWidget *gwidget, } /* Give some kind of access in case of missing right button */ - if (!handled && - (event->button == 3 || - (event->button == 1 && - ((event->state & GDK_MOD1_MASK) != 0 || - (event->state & GDK_MOD2_MASK) != 0 || - (event->state & GDK_MOD2_MASK) != 0)))) + if (!handled && glade_popup_is_popup_event (event)) { glade_popup_widget_pop (gwidget, event, TRUE); handled = TRUE; diff --git a/help/Makefile.in b/help/Makefile.in index f79323c..8db9a2e 100644 --- a/help/Makefile.in +++ b/help/Makefile.in @@ -160,6 +160,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/plugins/Makefile.in b/plugins/Makefile.in index c745238..e5cafff 100644 --- a/plugins/Makefile.in +++ b/plugins/Makefile.in @@ -156,6 +156,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/plugins/gnome/Makefile.in b/plugins/gnome/Makefile.in index bea71f0..964b0b2 100644 --- a/plugins/gnome/Makefile.in +++ b/plugins/gnome/Makefile.in @@ -174,6 +174,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/plugins/gnome/icons/16x16/Makefile.in b/plugins/gnome/icons/16x16/Makefile.in index 11fc419..a4342d7 100644 --- a/plugins/gnome/icons/16x16/Makefile.in +++ b/plugins/gnome/icons/16x16/Makefile.in @@ -145,6 +145,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/plugins/gnome/icons/22x22/Makefile.in b/plugins/gnome/icons/22x22/Makefile.in index 7b5a912..57d9a8e 100644 --- a/plugins/gnome/icons/22x22/Makefile.in +++ b/plugins/gnome/icons/22x22/Makefile.in @@ -145,6 +145,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/plugins/gnome/icons/Makefile.in b/plugins/gnome/icons/Makefile.in index 4ad63b8..06efbad 100644 --- a/plugins/gnome/icons/Makefile.in +++ b/plugins/gnome/icons/Makefile.in @@ -144,6 +144,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/plugins/gtk+/Makefile.in b/plugins/gtk+/Makefile.in index 7efae71..f5854f5 100644 --- a/plugins/gtk+/Makefile.in +++ b/plugins/gtk+/Makefile.in @@ -201,6 +201,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/plugins/gtk+/glade-activatable-editor.c b/plugins/gtk+/glade-activatable-editor.c index 59d0b80..97b30e9 100644 --- a/plugins/gtk+/glade-activatable-editor.c +++ b/plugins/gtk+/glade-activatable-editor.c @@ -229,6 +229,10 @@ reset_properties (GladeWidget *gwidget, GladeWidget *image; GladeProperty *property; + reset_property (gwidget, "stock"); + reset_property (gwidget, "use-underline"); + reset_property (gwidget, "use-stock"); + /* Delete image... */ if ((image = get_image_widget (gwidget)) != NULL) { @@ -240,11 +244,6 @@ reset_properties (GladeWidget *gwidget, property = glade_widget_get_property (gwidget, "label"); glade_command_set_property (property, NULL); - - reset_property (gwidget, "stock"); - reset_property (gwidget, "use-underline"); - reset_property (gwidget, "use-stock"); - } else if (use_appearance_changed) { diff --git a/plugins/gtk+/glade-gtk.c b/plugins/gtk+/glade-gtk.c index 6619489..0cb6eff 100644 --- a/plugins/gtk+/glade-gtk.c +++ b/plugins/gtk+/glade-gtk.c @@ -2018,6 +2018,9 @@ glade_gtk_box_set_size (GObject *object, const GValue *value) box = GTK_BOX (object); g_return_if_fail (GTK_IS_BOX (box)); + if (glade_util_object_is_loading (object)) + return; + old_size = g_list_length (box->children); new_size = g_value_get_int (value); @@ -4088,7 +4091,7 @@ glade_gtk_notebook_add_child (GladeWidgetAdaptor *adaptor, /* Just destroy placeholders */ if (GLADE_IS_PLACEHOLDER (child)) - gtk_widget_destroy (child); + gtk_widget_destroy (GTK_WIDGET (child)); else { gwidget = glade_widget_get_from_gobject (child); @@ -5743,6 +5746,24 @@ glade_gtk_color_button_refresh_color (GtkColorButton *button, /* ----------------------------- GtkButton ------------------------------ */ +static void +sync_use_appearance (GladeWidget *gwidget) +{ + GladeProperty *prop = glade_widget_get_property (gwidget, "use-action-appearance"); + gboolean use_appearance = FALSE; + + /* This is the kind of thing we avoid doing at project load time ;-) */ + if (glade_widget_superuser ()) + return; + + glade_property_get (prop, &use_appearance); + if (use_appearance) + { + glade_property_set (prop, FALSE); + glade_property_set (prop, TRUE); + } +} + /* shared between menuitems and toolitems too */ static void evaluate_activatable_property_sensitivity (GObject *object, @@ -5878,6 +5899,15 @@ glade_gtk_button_set_property (GladeWidgetAdaptor *adaptor, if (use_stock) gtk_button_set_label (GTK_BUTTON (object), g_value_get_string (value)); } + else if (strcmp (id, "use-stock") == 0) + { + /* I guess its my bug in GTK+, we need to resync the appearance property + * on GtkButton when the GtkButton:use-stock property changes. + */ + GWA_GET_CLASS (GTK_TYPE_CONTAINER)->set_property (adaptor, object, + id, value); + sync_use_appearance (widget); + } else if (property->klass->version_since_major <= gtk_major_version && property->klass->version_since_minor <= (gtk_minor_version + 1)) GWA_GET_CLASS (GTK_TYPE_CONTAINER)->set_property (adaptor, object, @@ -5926,13 +5956,16 @@ glade_gtk_button_write_widget (GladeWidgetAdaptor *adaptor, /* Do not save GtkColorButton and GtkFontButton label property */ if (!(GTK_IS_COLOR_BUTTON (widget->object) || GTK_IS_FONT_BUTTON (widget->object))) { + /* Make a copy of the GladeProperty, + * override its value and ensure non-translatable if use-stock is TRUE + */ prop = glade_widget_get_property (widget, "label"); - /* Make a copy of the GladeProperty, override its value if use-stock is TRUE */ prop = glade_property_dup (prop, widget); glade_widget_property_get (widget, "use-stock", &use_stock); if (use_stock) { glade_widget_property_get (widget, "stock", &stock); + glade_property_i18n_set_translatable (prop, FALSE); glade_property_set (prop, stock); } glade_property_write (prop, context, node); @@ -6886,6 +6919,12 @@ glade_gtk_image_menu_item_set_use_stock (GObject *object, const GValue *value) glade_widget_property_set_sensitive (widget, "stock", FALSE, NOT_SELECTED_MSG); glade_widget_property_set_sensitive (widget, "accel-group", FALSE, NOT_SELECTED_MSG); } + +#if GTK_CHECK_VERSION (2, 16, 0) + gtk_image_menu_item_set_use_stock (GTK_IMAGE_MENU_ITEM (object), use_stock); + + sync_use_appearance (widget); +#endif } static gboolean @@ -6912,6 +6951,9 @@ glade_gtk_image_menu_item_set_label (GObject *object, const GValue *value) image = gtk_image_new_from_stock (g_value_get_string (value), GTK_ICON_SIZE_MENU); gtk_image_menu_item_set_image (GTK_IMAGE_MENU_ITEM (object), image); + if (use_underline) + gtk_label_set_use_underline (GTK_LABEL (label), TRUE); + /* Get the label string... */ if (text && gtk_stock_lookup (text, &item)) gtk_label_set_label (GTK_LABEL (label), item.label); @@ -8417,22 +8459,65 @@ glade_gtk_label_create_editable (GladeWidgetAdaptor *adaptor, return editable; } -/* ----------------------------- GtkTextView ------------------------------ */ + + +/* ----------------------------- GtkTextBuffer ------------------------------ */ static void -glade_gtk_text_view_changed (GtkTextBuffer *buffer, GladeWidget *gtext) +glade_gtk_text_buffer_changed (GtkTextBuffer *buffer, GladeWidget *gbuffy) { - const gchar *text_prop; + const gchar *text_prop = NULL; GladeProperty *prop; - gchar *text; + gchar *text = NULL; g_object_get (buffer, "text", &text, NULL); + + if ((prop = glade_widget_get_property (gbuffy, "text"))) + { + glade_property_get (prop, &text_prop); + + if (text_prop == NULL || text == NULL || strcmp (text, text_prop)) + glade_command_set_property (prop, text); + } + g_free (text); +} + +void +glade_gtk_text_buffer_post_create (GladeWidgetAdaptor *adaptor, + GObject *object, + GladeCreateReason reason) +{ + GladeWidget *gbuffy; - glade_widget_property_get (gtext, "text", &text_prop); + gbuffy = glade_widget_get_from_gobject (object); - if (strcmp (text, text_prop)) - if ((prop = glade_widget_get_property (gtext, "text"))) - glade_command_set_property (prop, text); + g_signal_connect (object, "changed", + G_CALLBACK (glade_gtk_text_buffer_changed), + gbuffy); +} + +/* ----------------------------- GtkTextView ------------------------------ */ +static void +glade_gtk_text_view_changed (GtkTextBuffer *buffer, GladeWidget *gtext) +{ + const gchar *text_prop = NULL; + GladeProject *project; + GladeProperty *prop; + gchar *text = NULL; + g_object_get (buffer, "text", &text, NULL); + + project = glade_widget_get_project (gtext); + + if (glade_project_get_format (project) == GLADE_PROJECT_FORMAT_LIBGLADE) + { + if ((prop = glade_widget_get_property (gtext, "text"))) + { + glade_property_get (prop, &text_prop); + + if (text_prop == NULL || text == NULL || strcmp (text, text_prop)) + glade_command_set_property (prop, text); + } + } g_free (text); } @@ -8451,20 +8536,27 @@ glade_gtk_text_view_post_create (GladeWidgetAdaptor *adaptor, GObject *object, GladeCreateReason reason) { - GtkTextBuffer *buffy = gtk_text_buffer_new (NULL); - GladeWidget *gtext; + GtkTextBuffer *buffy; + GladeWidget *gtext; + GladeProject *project; gtext = glade_widget_get_from_gobject (object); /* This makes gtk_text_view_set_buffer() stop complaing */ gtk_drag_dest_set (GTK_WIDGET (object), 0, NULL, 0, 0); - - gtk_text_view_set_buffer (GTK_TEXT_VIEW (object), buffy); - g_signal_connect (buffy, "changed", - G_CALLBACK (glade_gtk_text_view_changed), - gtext); + + project = glade_widget_get_project (gtext); + + if (glade_project_get_format (project) == GLADE_PROJECT_FORMAT_LIBGLADE) + { + buffy = gtk_text_buffer_new (NULL); + gtk_text_view_set_buffer (GTK_TEXT_VIEW (object), buffy); + g_signal_connect (buffy, "changed", + G_CALLBACK (glade_gtk_text_view_changed), + gtext); - g_object_unref (G_OBJECT (buffy)); + g_object_unref (G_OBJECT (buffy)); + } /* Glade3 hangs when a TextView gets a double click. So we stop them */ g_signal_connect (object, "button-press-event", diff --git a/plugins/gtk+/gtk+.xml b/plugins/gtk+/gtk+.xml index 9e9ecf8..ac1d6a7 100644 --- a/plugins/gtk+/gtk+.xml +++ b/plugins/gtk+/gtk+.xml @@ -462,7 +462,7 @@ GtkAction - + GParamBoolean @@ -3213,6 +3213,7 @@ + glade_gtk_text_buffer_post_create diff --git a/plugins/gtk+/gtk+.xml.in b/plugins/gtk+/gtk+.xml.in index 4cfddec..d837035 100644 --- a/plugins/gtk+/gtk+.xml.in +++ b/plugins/gtk+/gtk+.xml.in @@ -477,7 +477,8 @@ embedded in another object GtkAction - + GParamBoolean @@ -3279,6 +3280,7 @@ embedded in another object + glade_gtk_text_buffer_post_create diff --git a/plugins/gtk+/icons/16x16/Makefile.in b/plugins/gtk+/icons/16x16/Makefile.in index b9472d4..a95f77d 100644 --- a/plugins/gtk+/icons/16x16/Makefile.in +++ b/plugins/gtk+/icons/16x16/Makefile.in @@ -145,6 +145,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/plugins/gtk+/icons/22x22/Makefile.in b/plugins/gtk+/icons/22x22/Makefile.in index 3feb139..5754901 100644 --- a/plugins/gtk+/icons/22x22/Makefile.in +++ b/plugins/gtk+/icons/22x22/Makefile.in @@ -145,6 +145,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/plugins/gtk+/icons/Makefile.in b/plugins/gtk+/icons/Makefile.in index 944543c..6f95c32 100644 --- a/plugins/gtk+/icons/Makefile.in +++ b/plugins/gtk+/icons/Makefile.in @@ -144,6 +144,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/plugins/python/Makefile.in b/plugins/python/Makefile.in index 4cb2415..b8a1fdf 100644 --- a/plugins/python/Makefile.in +++ b/plugins/python/Makefile.in @@ -165,6 +165,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@ diff --git a/src/Makefile.in b/src/Makefile.in index 287579b..c853301 100644 --- a/src/Makefile.in +++ b/src/Makefile.in @@ -163,6 +163,7 @@ HAVE_GTK_UNIX_PRINT_FALSE = @HAVE_GTK_UNIX_PRINT_FALSE@ HAVE_GTK_UNIX_PRINT_TRUE = @HAVE_GTK_UNIX_PRINT_TRUE@ HELP_DIR = @HELP_DIR@ HTML_DIR = @HTML_DIR@ +IGE_MAC_BUNDLE_FLAG = @IGE_MAC_BUNDLE_FLAG@ IGE_MAC_CFLAGS = @IGE_MAC_CFLAGS@ IGE_MAC_LIBS = @IGE_MAC_LIBS@ INSTALL_DATA = @INSTALL_DATA@