testinggtk r446 - trunk/tests
- From: bjornl svn gnome org
- To: svn-commits-list gnome org
- Subject: testinggtk r446 - trunk/tests
- Date: Wed, 10 Sep 2008 19:01:18 +0000 (UTC)
Author: bjornl
Date: Wed Sep 10 19:01:18 2008
New Revision: 446
URL: http://svn.gnome.org/viewvc/testinggtk?rev=446&view=rev
Log:
Add test for #551699. gtk_scrolled_window_destroy() must not crash when scrolled_window->h/vscrollbar is NULL
Modified:
trunk/tests/test_scrolledwindow.py
Modified: trunk/tests/test_scrolledwindow.py
==============================================================================
--- trunk/tests/test_scrolledwindow.py (original)
+++ trunk/tests/test_scrolledwindow.py Wed Sep 10 19:01:18 2008
@@ -105,3 +105,24 @@
scroll = gtk.ScrolledWindow(None, None)
scroll.set_property('can-focus', False)
assert not scroll.emit('focus', gtk.DIR_UP)
+
+ utils fail_on_warnings
+def test_destroy_when_scrollbars_are_none():
+ '''
+ In this test, the scrolled windows scrollbars are NULL when
+ destroy() in run. Ensure that gtk.ScrolledWindow deals with that
+ scenario properly.
+
+ :bug: #551699
+ '''
+ class Test(gtk.DrawingArea):
+ __gsignals__ = {
+ 'blah' : (gobject.SIGNAL_RUN_LAST,
+ gobject.TYPE_BOOLEAN,
+ (gobject.TYPE_OBJECT, gobject.TYPE_OBJECT))
+ }
+ widget = Test()
+ Test.set_set_scroll_adjustments_signal('blah')
+ sw = gtk.ScrolledWindow()
+ sw.add(widget)
+ sw.destroy()
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]