3 * Copyright (C) 2011, Red Hat, Inc.
4 * Authors: Benjamin Otte <otte@gnome.org>
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library. If not, see <http://www.gnu.org/licenses/>.
23 test_9d6da33ff5c5e41e3521e1afd63d2d67bc915753 (void)
25 GtkWidget *window, *label;
27 window = gtk_window_new (GTK_WINDOW_POPUP);
28 label = gtk_label_new ("I am sensitive.");
29 gtk_container_add (GTK_CONTAINER (window), label);
31 gtk_widget_set_sensitive (label, FALSE);
32 gtk_widget_set_sensitive (window, FALSE);
33 gtk_widget_set_sensitive (label, TRUE);
34 gtk_widget_set_sensitive (window, TRUE);
36 g_assert (gtk_widget_get_sensitive (label));
38 gtk_widget_destroy (window);
42 test_94f00eb04dd1433cf1cc9a3341f485124e38abd1 (void)
44 GtkWidget *window, *label;
46 window = gtk_window_new (GTK_WINDOW_POPUP);
47 label = gtk_label_new ("I am insensitive.");
48 gtk_container_add (GTK_CONTAINER (window), label);
50 gtk_widget_set_sensitive (window, FALSE);
51 gtk_widget_set_sensitive (label, FALSE);
52 gtk_widget_set_sensitive (label, TRUE);
54 g_assert (!gtk_widget_is_sensitive (label));
56 gtk_widget_destroy (window);
60 main (int argc, char *argv[])
62 gtk_test_init (&argc, &argv, NULL);
64 g_test_add_func ("/regression/94f00eb04dd1433cf1cc9a3341f485124e38abd1", test_94f00eb04dd1433cf1cc9a3341f485124e38abd1);
65 g_test_add_func ("/regression/9d6da33ff5c5e41e3521e1afd63d2d67bc915753", test_9d6da33ff5c5e41e3521e1afd63d2d67bc915753);