Commit graph

46 commits

Author SHA1 Message Date
Joshua Lee d275c8bde1 general: Clean up signal handler disconnection
Make use of GLib's new g_clear_signal_handler() function to simplify nautilus'
signal handler disconnection and reduce unneccessary code.

Fixes: #1522
2020-07-08 19:37:24 +01:00
Ondrej Holy fd2e7dfdea general: Run uncrustify script
There are some style issue since the last run. Let's run it again
before enabling style-check CI job.
2020-04-05 16:22:26 +00:00
Vilhelm Prytz ba24423344 eel-canvas: Remove redundant comparison
Comparison is always false because positions >= 1

Makes comparison redundant
2020-03-29 19:43:26 +00:00
Ernestas Kulik 0a6e406344 eel: Remove superfluous include
gdk/gdkprivate.h is no longer a thing in GTK+ 4 and doesn’t seem to be
at all required.
2018-05-28 13:13:56 +03:00
Ernestas Kulik 6286e0a079 general: don’t shadow variables
Shadowing variables is error-prone, since one might mean to refer to a
variable that was declared earlier, but has the same name. Additionally,
being more strict about variable scoping can help make the code more
readable.
2018-03-01 08:37:50 +00:00
Ernestas Kulik d48db627fc eel: remove unused code
Additionally, this commit makes some unused public functions static.
2018-01-02 13:11:10 +02:00
Carlos Soriano 0abaab1c44 general: adjust uncrustify style
https://bugzilla.gnome.org/show_bug.cgi?id=770564
2016-09-06 15:41:06 +02:00
Carlos Soriano 52d960542b general: run uncrustify
And make the style of Nautilus the same for all files.
Hopefully we can fix all the style issues we can find in the next days,
so expect a little of movement on this.

https://bugzilla.gnome.org/show_bug.cgi?id=770564
2016-08-29 18:37:10 +02:00
Ernestas Kulik f3aabd3d17 eel-canvas: don't override deprecated functions
AtkComponentIface's {add,remove}_focus_handler should not be overridden,
since ATK 2.9.4, as atk_component_{add,remove}_focus_handler() are
deprecated.

This commit removes deprecated virtual function overrides.

https://bugzilla.gnome.org/show_bug.cgi?id=762236
2016-05-03 13:16:56 +03:00
Ernestas Kulik 225f2cf768 eel-canvas: use GdkSeat operations
Some GdkDisplay operations have been deprecated in GDK 3.20.

This commit replaces the deprecated code in eel_canvas_item_grab() and
eel_canvas_item_ungrab() functions with new GdkSeat operations.

https://bugzilla.gnome.org/show_bug.cgi?id=762235
2016-05-03 12:57:29 +03:00
Carlos Soriano 1ffb8ca593 general: remove vim modelines
Vim and emacs modelines are used to specify some of the code style in the code.
However, this is misleading and poorly supported since nautilus had a mix of
code style for some time.
Also, the mode lines doesn't specify the whole code style, so we will need to
use a different tool as well to specify the whole code style.
For that, we can just use a different tool for everything.

So remove the mode lines, and in a short future we will reestyle the nautilus
code to have a single code style, and use a tool like editorconfig to specify
the whole code style.
2016-04-04 18:08:36 +02:00
Carlos Soriano ab61aa46d8 eel-canvas: remove background draw handling
This seems no longer necessary. It looks like it was done to avoid
flashing when redrawing, but probably this was fixed sometime in the
past, so a transparent background in a widget doesn't flash anymore.

https://bugzilla.gnome.org/show_bug.cgi?id=761965
2016-02-15 11:38:43 +01:00
Daniel Mustieles e314fbcc99 Updated FSF's address 2014-01-31 14:13:48 +01:00
Alexander Larsson 481cf68948 Fix rename entry position
We need to not modify the cairo_t when we propagate up to the parent class
as this affects where GtkLayout draws the child widgets.

https://bugzilla.gnome.org/show_bug.cgi?id=705464
2013-11-04 16:50:48 +01:00
Srinivasa Ragavan fabea85329 Store the correct current_item if it has changed. It is incorrect to
ignore the new current item just because the mouse is down. It is
later used for right click.

Fixes bgo #704289.
2013-07-17 19:30:47 +05:30
Cosimo Cecchi d486af277f eel-canvas: fix double tap with touchscreen devices
Code here is not doing what the comment (and the symmetric part in
the RELEASE case) says.

https://bugzilla.gnome.org/show_bug.cgi?id=688281
2013-03-08 15:25:40 -05:00
William Jon McCann d721a8f206 Normalize signal names
https://bugzilla.gnome.org/show_bug.cgi?id=692234
2013-01-22 10:47:54 -05:00
Cosimo Cecchi 0dfa2ba20f eel-canvas: use GtkContainerAccessible for EelCanvasAccessible
Removes tons of boilerplate code not needed anymore.
2013-01-03 19:36:21 +01:00
Cosimo Cecchi a4ecbd076f Remove unnecessary gdk_threads_enter/leave calls
Since we don't ever call gdk_threads_init()
2012-08-30 08:48:03 -04:00
Cosimo Cecchi 195e7ee00d eel: don't use GDK_THREADS macros
Use the function equivalents.
2012-07-31 17:08:27 +02:00
Cosimo Cecchi 91a887f916 a11y: add missing prototype 2012-06-08 12:07:38 -04:00
Cosimo Cecchi 6c5baeb762 a11y: fix accessibility implementation for NautilusIconContainer
Clean up a11y code and make sure inheritance for
EelCanvasAccessible->NautilusIconContainerAccessible and for
EelCanvasItemAccessible->NautilusIconCanvasItemAccessible work properly.
This makes the ATK state machinery in EelCanvasItemAccessible work
again, which fixes

https://bugzilla.gnome.org/show_bug.cgi?id=677509
2012-06-07 23:50:34 -04:00
Nelson Benitez Leon 3deb33d449 eel-canvas: ignore extra mouse button events
Ignore button press/release events for mouse buttons greater
than 5 so allowing forward and backward mouse buttons to work
over icons.

Part of bug 660006

Signed-off-by: Nelson Benitez Leon <nbenitezl@gmail.com>
2012-04-04 16:21:37 +02:00
Carlos Garnacho 8c778211e5 eel: Queue resizes on the canvas as elements change visibility
Not queueing resizes may play oddly with the size request caches in
GTK+, resulting in gtk_widget_get_preferred_width/height returning
0 even after the canvas was populated.

https://bugzilla.gnome.org/show_bug.cgi?id=667831
2012-01-16 11:04:07 -05:00
Mike Gorse b11c8a6947 Fix accessibility for gtk 3.2, and send object:state-changed:selected
The code to derive the EelCanvasAccessible class no longer works as of
gtk+ 3.1.9.  Currently the recommended behavior is to derive from
GtkAccessible.

Also, canvas items should send object:state-changed:selected events when
selected and unselected; otherwise AT-SPI will not update its cache.

https://bugzilla.gnome.org/show_bug.cgi?id=650897
2011-09-19 13:32:23 -04:00
Cosimo Cecchi 5c69502773 all: use g_cclosure_marshal_generic() instead of generating marshallers 2011-07-01 12:52:09 -04:00
Cosimo Cecchi d4230de866 all: silence new warnings from GCC 4.6
GCC 4.6 introduced a new warning about variables declared and
initialized, but not really used in the function body. Remove all of
these occurrences to build cleanly.
2011-01-25 09:21:07 -05:00
Cosimo Cecchi 2a1fbaf839 canvas: fix an ACTIVE -> NORMAL typo from GtkStyleContext conversion 2011-01-19 19:44:48 +01:00
Cosimo Cecchi 2ff006dd58 canvas: don't use deprecated GDK grab API 2010-12-26 16:18:53 +01:00
Colin Walters 9403df1b54 Fix cairo-gobject.h include
$ pkg-config --cflags cairo-gobject
-pthread -I/src/build/jhbuild/include/cairo
$ ls /src/build/jhbuild/include/cairo/cairo-gobject.h
/src/build/jhbuild/include/cairo/cairo-gobject.h
2010-12-17 15:21:30 -05:00
Cosimo Cecchi 5cf60d2aa1 eel-canvas: build fix for gdk_window_get_geometry API change 2010-12-06 15:35:48 +01:00
Cosimo Cecchi 0a3aff84fe eel-canvas: port to GtkStyleContext 2010-12-06 15:35:34 +01:00
Cosimo Cecchi 7029d31744 canvas: remove commented out code 2010-11-01 17:41:59 +01:00
Cosimo Cecchi 2260005986 canvas: use GTK_LAYOUT casts instead of going through the parent struct
That's just confusing.
2010-10-30 16:29:15 +02:00
Cosimo Cecchi d811553a4e general: use new GtkScrollable interface 2010-10-30 16:29:13 +02:00
Christian Persch 58832e54b6 [eel] Port the eel canvas to rendering-cleanup-next 2010-09-30 18:48:42 +02:00
Cosimo Cecchi 1f61532161 canvas: don't use GtkObject
This implies adding a 'destroy' signal to EelCanvasItem, with similar
semantics to gtk_object_destroy()
2010-09-30 18:48:41 +02:00
Cosimo Cecchi 8447fd3670 [eel] use glib's i18n API instead of eel's 2010-08-19 15:52:12 +02:00
Benjamin Otte 759f3401be [eel] port EelCanvas to cairo drawing 2010-08-13 17:23:14 +02:00
Cosimo Cecchi 3b671558f1 Fix build with GTK+3 master, use cairo_region_t. 2010-07-01 16:49:38 +02:00
Bastien Nocera e07b688a3b [eel] GSEAL eel-canvas. 2010-06-11 13:25:12 +02:00
Cosimo Cecchi a09d41702b Remove deprecated GTK+ symbols (#565038). 2010-04-26 14:27:43 +02:00
Thomas Hindoe Paaboel Andersen ec8b9a8b58 Replace deprecated GTK_OBJECT_TYPE with G_OBJECT_TYPE
GNOME bug 565038
2010-01-19 19:04:57 +01:00
Alexander Larsson b4cd0d66db Update to latest foocanvas
This has some cleanups and fixes a memory leak that was introduced
in the eel copy by removing gtk_object_sink.
2009-09-07 20:49:29 +02:00
Cosimo Cecchi b695c97018 Remove deprecated GDK/GTK+ symbols
Remove all uses of deprecated GDK and GTK+ symbols, replacing them
with the currently supported equivalents.
Based on a patch from Tal Benavidor (#565038).
2009-04-21 15:06:23 +02:00
Alexander Larsson 7e668edf20 eel/ Import eel into nautilus.
2008-12-15  Alexander Larsson  <alexl@redhat.com>

        * Makefile.am:
        * acconfig.h:
        * configure.in:
	* eel/
        * libnautilus-private/Makefile.am:
	Import eel into nautilus.


svn path=/trunk/; revision=14815
2008-12-15 15:56:41 +00:00