1 /* -*- Mode: C; indent-tabs-mode: nil; c-basic-offset: 4 c-style: "K&R" -*- */
3 /*----------------------------------------------------------------------
5 gpiv - Graphic program for Particle Image Velocimetry, based on gtk/gnome
8 Copyright (C) 2002, 2003, 2004 Gerber van der Graaf
10 This file is part of gpiv.
12 Gpiv is free software; you can redistribute it and/or modify
13 it under the terms of the GNU General Public License as published by
14 the Free Software Foundation; either version 2, or (at your option)
17 This program is distributed in the hope that it will be useful,
18 but WITHOUT ANY WARRANTY; without even the implied warranty of
19 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 GNU General Public License for more details.
22 You should have received a copy of the GNU General Public License
23 along with this program; if not, write to the Free Software Foundation,
24 Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
26 ----------------------------------------------------------------------*/
29 * (Callback) functions for dialogs
30 * $Id: dialog.c,v 1.1 2008-09-16 11:20:18 gerber Exp $
41 on_button_quit_gpiv_clicked (GtkDialog
*dialog
,
45 /*-----------------------------------------------------------------------------
46 * exit, message dialog callbacks
49 g_assert( response
== GTK_RESPONSE_ACCEPT
50 || response
== GTK_RESPONSE_REJECT
);
53 case GTK_RESPONSE_ACCEPT
:
54 free_all_bufmems(display_act
);
58 case GTK_RESPONSE_REJECT
:
59 gtk_widget_destroy(GTK_WIDGET (dialog
));
63 g_warning("on_button_quit_gpiv_clicked: should not arrive here");
71 on_close_buffer_response (GtkDialog
*dialog
,
75 /*-----------------------------------------------------------------------------
78 GpivConsole
*gpiv
= gtk_object_get_data (GTK_OBJECT(dialog
), "gpiv");
79 Display
*disp
= gtk_object_get_data (GTK_OBJECT(dialog
), "display");
82 g_assert ( response
== GTK_RESPONSE_ACCEPT
83 || response
== GTK_RESPONSE_REJECT
);
85 /* g_message ("on_close_buffer_response:: id = %d", */
86 /* display_act->id); */
89 case GTK_RESPONSE_ACCEPT
:
92 * Deleting buffer and data
94 close_buffer (gpiv
, disp
/* , row */);
97 case GTK_RESPONSE_REJECT
:
99 * No action; just keep buffer with (unstored) data
104 g_warning("on_close_buffer_response: should not arrive here");
108 /* g_message ("on_close_buffer_response:: FINISHED"); */