~ubuntu-branches/ubuntu/trusty/cheese/trusty

« back to all changes in this revision

Viewing changes to tests/cheese-test-flash.c

  • Committer: Bazaar Package Importer
  • Author(s): Laurent Bigonville
  • Date: 2011-07-23 00:37:49 UTC
  • mfrom: (1.3.6 upstream)
  • mto: (7.3.2 experimental) (1.6.1)
  • mto: This revision was merged to the branch mainline in revision 62.
  • Revision ID: james.westby@ubuntu.com-20110723003749-l1l8kk5wf6iadczb
Tags: upstream-3.0.1
ImportĀ upstreamĀ versionĀ 3.0.1

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
#include <gtk/gtk.h>
2
2
#include "cheese-flash.h"
3
3
 
 
4
static gboolean
 
5
delete_callback (GtkWidget *window,
 
6
                 GdkEvent  *event,
 
7
                 gpointer   data)
 
8
{
 
9
  gtk_widget_destroy (window);
 
10
  gtk_main_quit ();
 
11
  return FALSE;
 
12
}
 
13
 
4
14
static void
5
15
button_clicked (GtkButton *button,
6
16
                CheeseFlash *flash)
16
26
        gtk_init (&argc, &argv);
17
27
 
18
28
        window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
 
29
        g_signal_connect (G_OBJECT (window), "delete-event",
 
30
                        G_CALLBACK (delete_callback), NULL);
19
31
        flash = cheese_flash_new (window);
20
32
        button = gtk_button_new_with_label ("Fire flash");
21
33
        g_signal_connect (G_OBJECT (button), "clicked",