[cheese/cheese-window-refactor: 8/8] Forgot to add cheese-commands.c to version control
- From: Filippo Argiolas <fargiolas src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [cheese/cheese-window-refactor: 8/8] Forgot to add cheese-commands.c to version control
- Date: Sun, 31 Jan 2010 10:50:13 +0000 (UTC)
commit 69d75e7d7ff5d8ac5ec7f0b899160b87747ca372
Author: Filippo Argiolas <filippo argiolas gmail com>
Date: Thu Jan 28 20:43:09 2010 +0100
Forgot to add cheese-commands.c to version control
Oops, sorry, too late to squash it into some previous commit.
src/cheese-commands.c | 39 +++++++++++++++++++++++++++++++++++++++
src/cheese-commands.h | 1 +
2 files changed, 40 insertions(+), 0 deletions(-)
---
diff --git a/src/cheese-commands.c b/src/cheese-commands.c
new file mode 100644
index 0000000..aebd35b
--- /dev/null
+++ b/src/cheese-commands.c
@@ -0,0 +1,39 @@
+/*
+ * Copyright © 2010 Filippo Argiolas <filippo argiolas gmail com>
+ * Copyright © 2007,2008 daniel g. siegel <dgsiegel gnome org>
+ * Copyright © 2007,2008 Jaap Haitsma <jaap haitsma org>
+ *
+ * Licensed under the GNU General Public License Version 2
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#include "cheese-commands.h"
+#include <gdk/gdkx.h>
+
+void
+cheese_cmd_quit (GtkAction *action, CheeseWindow *window)
+{
+ gtk_widget_destroy (GTK_WIDGET (window));
+}
+
+void
+cheese_cmd_bring_to_front (CheeseWindow *window)
+{
+ guint32 startup_timestamp = gdk_x11_get_server_time (gtk_widget_get_window (GTK_WIDGET (window)));
+
+ gdk_x11_window_set_user_time (gtk_widget_get_window (GTK_WIDGET (window)), startup_timestamp);
+
+ gtk_window_present (GTK_WINDOW (window));
+}
diff --git a/src/cheese-commands.h b/src/cheese-commands.h
index 94042b4..c26de34 100644
--- a/src/cheese-commands.h
+++ b/src/cheese-commands.h
@@ -34,6 +34,7 @@
G_BEGIN_DECLS
void cheese_cmd_quit (GtkAction *action, CheeseWindow *window);
+void cheese_cmd_bring_to_front (CheeseWindow *window);
void cheese_cmd_help_contents (GtkAction *action, CheeseWindow *cheese_window);
void cheese_cmd_about (GtkAction *action, CheeseWindow *cheese_window);
void cheese_cmd_file_open (GtkWidget *widget, CheeseWindow *cheese_window);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]