[gnome-screenshot/wip/exalm/cleanups: 2/16] dialog: Make the struct private
- From: Alexander Mikhaylenko <alexm src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-screenshot/wip/exalm/cleanups: 2/16] dialog: Make the struct private
- Date: Fri, 3 Apr 2020 02:13:59 +0000 (UTC)
commit a3af6cea033e9e484aa3960b9efb9549ad75e79f
Author: Alexander Mikhaylenko <alexm gnome org>
Date: Fri Apr 3 03:58:57 2020 +0500
dialog: Make the struct private
This is the second step to making it a class.
src/screenshot-dialog.c | 18 ++++++++++++++++++
src/screenshot-dialog.h | 18 +-----------------
2 files changed, 19 insertions(+), 17 deletions(-)
---
diff --git a/src/screenshot-dialog.c b/src/screenshot-dialog.c
index 141a86a..a9ca538 100644
--- a/src/screenshot-dialog.c
+++ b/src/screenshot-dialog.c
@@ -32,6 +32,24 @@ enum {
LAST_TYPE
};
+struct _ScreenshotDialog {
+ GdkPixbuf *screenshot;
+ GdkPixbuf *preview_image;
+
+ GtkWidget *dialog;
+ GtkWidget *save_widget;
+ GtkWidget *filename_entry;
+ GtkWidget *save_button;
+ GtkWidget *copy_button;
+ GtkWidget *back_button;
+
+ gint drag_x;
+ gint drag_y;
+
+ SaveScreenshotCallback callback;
+ gpointer user_data;
+};
+
static GtkTargetEntry drag_types[] =
{
{ "image/png", 0, TYPE_IMAGE_PNG },
diff --git a/src/screenshot-dialog.h b/src/screenshot-dialog.h
index 65e0aab..8ad83f7 100644
--- a/src/screenshot-dialog.h
+++ b/src/screenshot-dialog.h
@@ -30,23 +30,7 @@ typedef enum {
typedef void (*SaveScreenshotCallback) (ScreenshotResponse response, gpointer *user_data);
-typedef struct {
- GdkPixbuf *screenshot;
- GdkPixbuf *preview_image;
-
- GtkWidget *dialog;
- GtkWidget *save_widget;
- GtkWidget *filename_entry;
- GtkWidget *save_button;
- GtkWidget *copy_button;
- GtkWidget *back_button;
-
- gint drag_x;
- gint drag_y;
-
- SaveScreenshotCallback callback;
- gpointer user_data;
-} ScreenshotDialog;
+typedef struct _ScreenshotDialog ScreenshotDialog;
ScreenshotDialog *screenshot_dialog_new (GdkPixbuf *screenshot,
char *initial_uri,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]