After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 694504 - Preferences dialog not working
Preferences dialog not working
Status: RESOLVED FIXED
Product: swell-foop
Classification: Applications
Component: general
git master
Other Linux
: Normal normal
: ---
Assigned To: swell-foop-maint
swell-foop-maint
: 697489 706249 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2013-02-23 09:19 UTC by John Cheetham
Modified: 2013-08-18 16:07 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Fix bug for connect_signals in preferences dialog (1.25 KB, patch)
2013-02-23 17:18 UTC, John Cheetham
needs-work Details | Review
a patch that works (455 bytes, patch)
2013-06-15 03:49 UTC, Matthias Clasen
committed Details | Review

Description John Cheetham 2013-02-23 09:19:32 UTC
I open the preferences dialog and change the board size and nothing happens.

When the preferences dialog is opened I get these message in the terminal:

(swell-foop:28585): Gtk-WARNING **: Could not find signal handler 'set_zealous_animation'

(swell-foop:28585): Gtk-WARNING **: Could not find signal handler 'select_theme'

(swell-foop:28585): Gtk-WARNING **: Could not find signal handler 'update_colors'

(swell-foop:28585): Gtk-WARNING **: Could not find signal handler 'update_size'

The handlers do appear to be present and correctly named in swell-foop.vala.
Comment 1 John Cheetham 2013-02-23 17:18:56 UTC
Created attachment 237249 [details] [review]
Fix bug for connect_signals in preferences dialog

Patch for the above. I added gmodule.
Comment 2 Paolo Borelli 2013-04-07 14:24:53 UTC
*** Bug 697489 has been marked as a duplicate of this bug. ***
Comment 3 Branko Grubic (bitlord) 2013-06-07 08:33:28 UTC
This affects stable 3.8.x ( swell-foop-3.8.1-1.fc19.x86_64 )
Comment 4 Igor Gnatenko 2013-06-13 18:08:03 UTC
Review of attachment 237249 [details] [review]:

I patched with you patch, but nothing changes.
In console: 
(swell-foop:31937): Gtk-WARNING **: Could not find signal handler 'set_zealous_animation'

(swell-foop:31937): Gtk-WARNING **: Could not find signal handler 'select_theme'

(swell-foop:31937): Gtk-WARNING **: Could not find signal handler 'update_colors'

(swell-foop:31937): Gtk-WARNING **: Could not find signal handler 'update_size'
Log from builder:
+ echo 'Patch #0 (0001-Fix-bug-in-preferences-dialog.patch):'
Patch #0 (0001-Fix-bug-in-preferences-dialog.patch):
+ /usr/bin/cat /builddir/build/SOURCES/0001-Fix-bug-in-preferences-dialog.patch
+ /usr/bin/patch -p1 --fuzz=0
patching file configure.ac
patching file src/Makefile.am
+ exit 0
Comment 5 Branko Grubic (bitlord) 2013-06-13 19:19:39 UTC
I also tested the patch from comment #1 applied to stable 3.8.1, no effect
Comment 6 John Cheetham 2013-06-13 21:48:22 UTC
I think you may need to do make clean and ./configure again before doing the make and make install.
Comment 7 Branko Grubic (bitlord) 2013-06-13 21:56:42 UTC
I think everything is done properly, I used fedora src.rpm for 3.8.1 (latest), yumdownloader --source swell-foop, extracted src.rpm, changed spec file, and added patch, and built with rpmbuild -bb swell-foop.spec, upgraded didn't work, I restarted (probably not needed), not fixed. 

Does it work for you with that patch?


.spec file uses default release soruce + patch, and it does ./configure 
...
%build
%configure
make %{?_smp_mflags}
...

Maybe I miss some extra options which aren't enabled by default?
Comment 8 Igor Gnatenko 2013-06-14 10:47:39 UTC
(In reply to comment #6)
> I think you may need to do make clean and ./configure again before doing the
> make and make install.
If you need I can attach build logs.
Comment 9 John Cheetham 2013-06-14 17:40:18 UTC
I tried this using Fedora 19 beta and swell-foop from git master and as you say the patch doesn't work.

I tried again but I don't really know enough to fix this.

The problem is in preferences_cb in swell-foop.vala which does a connect_signals. This should connect the signals specified in data/preferences.ui XML file to the callback functions in swell-foop.vala but it fails to find them. The names of the callback functions (which I can see from from the generated C code) are the same as those in the preferences.ui XML file so that should be OK.

I think it's more likely that it needs to use gmodule and this patch hasn't done it right (though I think it worked previously when I was on an older system).

It explains how to do these autoconnections of signals in https://live.gnome.org/Vala/GTKSample (see 'Loading User Interface from XML File'). After reading that though the swell-foop code looks OK so I'm not sure what the problem is.
Comment 10 Matthias Clasen 2013-06-15 03:49:59 UTC
Created attachment 246872 [details] [review]
a patch that works
Comment 11 Branko Grubic (bitlord) 2013-06-15 04:26:56 UTC
@comment #10 (patch)

Works for you? 

I tried with 3.8.1 stable (again used src.rpm from f19), and it doesn't work, I tried with reboot, same errors, then I cleaned my rpmbuild/ directory and recreated the package, downgraded to version in f19, rebuild the package, upgraded, tried again, and it doesn't work.
Comment 12 Igor Gnatenko 2013-06-15 06:54:53 UTC
Review of attachment 246872 [details] [review]:

I patched 3.8.1 src.rpm and nothing changes. =(
Build log:
DEBUG: + echo 'Patch #0 (0001-Fix-bug-in-preferences-dialog.patch):'
DEBUG: Patch #0 (0001-Fix-bug-in-preferences-dialog.patch):
DEBUG: + /usr/bin/cat /builddir/build/SOURCES/0001-Fix-bug-in-preferences-dialog.patch
DEBUG: + /usr/bin/patch -p1 --fuzz=0
DEBUG: patching file configure.ac
DEBUG: + exit 0
Comment 13 Matthias Clasen 2013-06-15 15:18:23 UTC
Try the update https://admin.fedoraproject.org/updates/swell-foop-3.8.1-2.fc19 and provide karma (negative, if it doesn't work).

You are probably missing the autoreconf invocation that has to be added to %prep to make the configure.in change have any effect.
Comment 14 John Cheetham 2013-06-15 17:17:28 UTC
This RPM package works for me. Thanks.

I did a bit more checking and found that both patches 1 and 2 work correctly as well when compiling from git. The step I was missing was the autogen.sh.  So after building the original version I followed these steps:

1. Quit and restart the terminal
2. apply patch
3. make clean
4. ./autogen.sh
5. make
6. make install

and all is well.
Comment 15 Igor Gnatenko 2013-06-15 17:32:59 UTC
(In reply to comment #13)
> Try the update https://admin.fedoraproject.org/updates/swell-foop-3.8.1-2.fc19
> and provide karma (negative, if it doesn't work).
> 
> You are probably missing the autoreconf invocation that has to be added to
> %prep to make the configure.in change have any effect.
All works! Commented in bodhi.
Comment 16 Branko Grubic (bitlord) 2013-06-16 04:08:57 UTC
Tested package from comment #13 works. 

Thanks all, for providing patches, testing and fixing bug ;-)
Comment 17 Jeremy Bicha 2013-07-21 05:04:49 UTC
Matthias, you may want to just commit the patch. Most of the games have been effectively unmaintained since the gnome-games split.
Comment 18 Michael Catanzaro 2013-08-18 15:58:49 UTC
*** Bug 706249 has been marked as a duplicate of this bug. ***
Comment 19 Michael Catanzaro 2013-08-18 16:07:34 UTC
Pushed, thanks!