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, write to the
18 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
19 * Boston, MA 02111-1307, USA.
25 test_9d6da33ff5c5e41e3521e1afd63d2d67bc915753 (void)
27 GtkWidget *window, *label;
29 window = gtk_window_new (GTK_WINDOW_POPUP);
30 label = gtk_label_new ("I am sensitive.");
31 gtk_container_add (GTK_CONTAINER (window), label);
33 gtk_widget_set_sensitive (label, FALSE);
34 gtk_widget_set_sensitive (window, FALSE);
35 gtk_widget_set_sensitive (label, TRUE);
36 gtk_widget_set_sensitive (window, TRUE);
38 g_assert (gtk_widget_get_sensitive (label));
40 gtk_widget_destroy (window);
44 test_94f00eb04dd1433cf1cc9a3341f485124e38abd1 (void)
46 GtkWidget *window, *label;
48 window = gtk_window_new (GTK_WINDOW_POPUP);
49 label = gtk_label_new ("I am insensitive.");
50 gtk_container_add (GTK_CONTAINER (window), label);
52 gtk_widget_set_sensitive (window, FALSE);
53 gtk_widget_set_sensitive (label, FALSE);
54 gtk_widget_set_sensitive (label, TRUE);
56 g_assert (!gtk_widget_is_sensitive (label));
58 gtk_widget_destroy (window);
62 main (int argc, char *argv[])
64 gtk_test_init (&argc, &argv, NULL);
66 g_test_add_func ("/regression/94f00eb04dd1433cf1cc9a3341f485124e38abd1", test_94f00eb04dd1433cf1cc9a3341f485124e38abd1);
67 g_test_add_func ("/regression/9d6da33ff5c5e41e3521e1afd63d2d67bc915753", test_9d6da33ff5c5e41e3521e1afd63d2d67bc915753);