[gthumb] removed the custom cursors and the function to load them.
- From: Paolo Bacchilega <paobac src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gthumb] removed the custom cursors and the function to load them.
- Date: Fri, 14 Jan 2011 19:17:20 +0000 (UTC)
commit 2b52e7d42620d0cbb889c3275d59a9febfa50d23
Author: Paolo Bacchilega <paobac src gnome org>
Date: Fri Jan 14 20:11:15 2011 +0100
removed the custom cursors and the function to load them.
configure.ac | 1 -
extensions/gstreamer_tools/gth-media-viewer-page.c | 2 +-
gthumb/Makefile.am | 4 -
gthumb/cursors/Makefile.am | 9 --
gthumb/cursors/hand-closed-data.xbm | 9 --
gthumb/cursors/hand-closed-mask.xbm | 9 --
gthumb/cursors/hand-open-data.xbm | 9 --
gthumb/cursors/hand-open-mask.xbm | 9 --
gthumb/cursors/void-data.xbm | 5 -
gthumb/cursors/void-mask.xbm | 5 -
gthumb/gth-cursors.c | 116 --------------------
gthumb/gth-cursors.h | 46 --------
gthumb/gth-image-dragger.c | 24 +----
gthumb/gth-image-selector.c | 1 -
gthumb/gth-image-viewer.c | 3 +-
po/POTFILES.in | 2 -
16 files changed, 6 insertions(+), 248 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index 38d6a4c..7e2df80 100644
--- a/configure.ac
+++ b/configure.ac
@@ -619,7 +619,6 @@ extensions/webalbums/data/albumthemes/NeatRound/Makefile
extensions/webalbums/data/albumthemes/Wiki/Makefile
extensions/webalbums/data/ui/Makefile
gthumb/Makefile
-gthumb/cursors/Makefile
po/Makefile.in
tests/Makefile
])
diff --git a/extensions/gstreamer_tools/gth-media-viewer-page.c b/extensions/gstreamer_tools/gth-media-viewer-page.c
index 9dfa057..d524b90 100644
--- a/extensions/gstreamer_tools/gth-media-viewer-page.c
+++ b/extensions/gstreamer_tools/gth-media-viewer-page.c
@@ -136,7 +136,7 @@ video_area_realize_cb (GtkWidget *widget,
GthMediaViewerPage *self = user_data;
self->priv->cursor = gdk_cursor_new (GDK_LEFT_PTR);
- self->priv->cursor_void = gth_cursor_get (gtk_widget_get_window (self->priv->area), GTH_CURSOR_VOID);
+ self->priv->cursor_void = gdk_cursor_new_for_display (gtk_widget_get_display (self->priv->area), GDK_BLANK_CURSOR);
if (self->priv->cursor_visible)
gdk_window_set_cursor (gtk_widget_get_window (self->priv->area), self->priv->cursor);
else
diff --git a/gthumb/Makefile.am b/gthumb/Makefile.am
index f914a7e..c118877 100644
--- a/gthumb/Makefile.am
+++ b/gthumb/Makefile.am
@@ -1,5 +1,3 @@
-SUBDIRS = cursors
-
bin_PROGRAMS = gthumb
ENUM_TYPES = \
@@ -40,7 +38,6 @@ PUBLIC_HEADER_FILES = \
gth-buffer-data.h \
gth-browser.h \
gth-cell-renderer-thumbnail.h \
- gth-cursors.h \
gth-dumb-notebook.h \
gth-duplicable.h \
gth-embedded-dialog.h \
@@ -157,7 +154,6 @@ gthumb_SOURCES = \
gth-browser-actions-callbacks.c \
gth-buffer-data.c \
gth-cell-renderer-thumbnail.c \
- gth-cursors.c \
gth-dumb-notebook.c \
gth-duplicable.c \
gth-embedded-dialog.c \
diff --git a/gthumb/gth-image-dragger.c b/gthumb/gth-image-dragger.c
index 5a84f02..c398c68 100644
--- a/gthumb/gth-image-dragger.c
+++ b/gthumb/gth-image-dragger.c
@@ -22,7 +22,6 @@
#include <config.h>
#include <math.h>
#include "glib-utils.h"
-#include "gth-cursors.h"
#include "gth-image-dragger.h"
@@ -67,21 +66,6 @@ gth_image_dragger_instance_init (GthImageDragger *dragger)
static void
-_gth_image_dragger_update_cursor (GthImageDragger *self)
-{
- GdkCursor *cursor;
-
- if (self->priv->draggable)
- cursor = gth_cursor_get (gtk_widget_get_window (GTK_WIDGET (self->priv->viewer)), GTH_CURSOR_HAND_OPEN);
- else
- cursor = gdk_cursor_new (GDK_LEFT_PTR);
- gth_image_viewer_set_cursor (self->priv->viewer, cursor);
-
- gdk_cursor_unref (cursor);
-}
-
-
-static void
gth_image_dragger_realize (GthImageViewerTool *base)
{
/* void */
@@ -115,8 +99,6 @@ gth_image_dragger_size_allocate (GthImageViewerTool *base,
v_upper = gtk_adjustment_get_upper (viewer->vadj);
self->priv->draggable = (h_page_size > 0) && (v_page_size > 0) && ((h_upper > h_page_size) || (v_upper > v_page_size));
- if (gtk_widget_get_realized (GTK_WIDGET (viewer)))
- _gth_image_dragger_update_cursor (self);
}
@@ -189,7 +171,7 @@ gth_image_dragger_button_press (GthImageViewerTool *self,
GdkCursor *cursor;
int retval;
- cursor = gth_cursor_get (gtk_widget_get_window (widget), GTH_CURSOR_HAND_CLOSED);
+ cursor = gdk_cursor_new_from_name (gtk_widget_get_display (widget), "grabbing");
retval = gdk_pointer_grab (gtk_widget_get_window (widget),
FALSE,
(GDK_POINTER_MOTION_MASK
@@ -198,7 +180,9 @@ gth_image_dragger_button_press (GthImageViewerTool *self,
NULL,
cursor,
event->time);
- gdk_cursor_unref (cursor);
+
+ if (cursor != NULL)
+ gdk_cursor_unref (cursor);
if (retval != 0)
return FALSE;
diff --git a/gthumb/gth-image-selector.c b/gthumb/gth-image-selector.c
index 7161941..eadf676 100644
--- a/gthumb/gth-image-selector.c
+++ b/gthumb/gth-image-selector.c
@@ -23,7 +23,6 @@
#include <stdlib.h>
#include <math.h>
#include "glib-utils.h"
-#include "gth-cursors.h"
#include "gth-image-selector.h"
#include "gth-marshal.h"
diff --git a/gthumb/gth-image-viewer.c b/gthumb/gth-image-viewer.c
index b596912..4ae4757 100644
--- a/gthumb/gth-image-viewer.c
+++ b/gthumb/gth-image-viewer.c
@@ -25,7 +25,6 @@
#include <glib/gi18n.h>
#include <gdk/gdkkeysyms.h>
#include <gtk/gtk.h>
-#include "gth-cursors.h"
#include "gth-enum-types.h"
#include "gth-image-dragger.h"
#include "gth-image-viewer.h"
@@ -356,7 +355,7 @@ gth_image_viewer_realize (GtkWidget *widget)
gtk_widget_set_style (widget, style);
self->priv->cursor = gdk_cursor_new (GDK_LEFT_PTR);
- self->priv->cursor_void = gth_cursor_get (window, GTH_CURSOR_VOID);
+ self->priv->cursor_void = gdk_cursor_new_for_display (gtk_widget_get_display (widget), GDK_BLANK_CURSOR);
if (self->priv->cursor_visible)
gdk_window_set_cursor (window, self->priv->cursor);
else
diff --git a/po/POTFILES.in b/po/POTFILES.in
index 8b4cc6b..0fcf642 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -609,8 +609,6 @@ gthumb/gth-buffer-data.c
gthumb/gth-buffer-data.h
gthumb/gth-cell-renderer-thumbnail.c
gthumb/gth-cell-renderer-thumbnail.h
-gthumb/gth-cursors.c
-gthumb/gth-cursors.h
gthumb/gth-dumb-notebook.c
gthumb/gth-dumb-notebook.h
gthumb/gth-duplicable.c
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]