summaryrefslogtreecommitdiff
path: root/libcaja-private/caja-icon-info.c
AgeCommit message (Collapse)AuthorFilesLines
2019-07-01hidpi: ensure all icons are properly scaledlukefromdc1-2/+2
2019-05-06libcaja-private: reduce the scope of some variablesPablo Barciela1-1/+3
2018-10-03Caja-icon-info: Optimize icon lookups by GIcon.lukefromdc1-140/+67
The caja_icon_info_lookup method was potentially doing multiple icon lookups for a single icon, as well as triggering an additional fallback lookup when returning an empty (no pixbuf) CajaIconInfo to CajaFile. This streamlines and simplifies the lookup process. The hash table lookup always occurs first, before any Gtk icon cache lookup is made (these are expensive, according to perf analysis,) and a returned icon info will *always* be added to a hash table, potentially already containing a fallback icon. GIcons stringify well enough to use the strings exclusively for hash keys. This eliminates the extra cost of looking up filenames from the Gtk icon cache. Ported from github.com/linuxmint/nemo/commit/98843e26b48cd3526cacfe90cfa4ba201d1f3aee where this benchmark resulted for Nemo: .# sync; echo 3 > /proc/sys/vm/drop_caches mtwebster:~/bin/nemo[master]> NEMO_BENCHMARK_LOADING=1 nemo /usr/bin with: Nemo startup time: 2.011817 seconds Folder load time: 1.158854 seconds Idle...Folder load time: 1.226699 seconds without: Nemo startup time: 2.464361 seconds Folder load time: 1.591494 seconds Idle...Folder load time: 1.692273 seconds
2018-04-06Fix warnings from HiDPI commitslukefromdc1-0/+3
*caja-pathbar: fix warning,and in the process maybe fix occasional segfaults on opening mounted volumes from the desktop *caja-icon-info: Stop gdk_cairo_surface_create_from_pixbuf: assertion 'GDK_IS_PIXBUF (pixbuf)' failed warning by handling NULL return from function finding the pixbuf caja-icon-canvas-item-c: do not use g_object_unref where it does not work Stop the g_object_unref: assertion 'G_IS_OBJECT (object)' failed warnings on closing icon views
2018-04-04HiDPI: Convert Pixbufs to Cairo SurfacesVictor Kareh1-0/+55
This allows icons in most places to scale up properly for HiDPI displays.
2018-04-04icon-info: hash/store icons using scale factor as well as sizeLionel Landwerlin1-6/+18
Otherwise we might pick up an icon at an invalid size for a given scale. https://bugzilla.gnome.org/show_bug.cgi?id=776896 origin commit: https://gitlab.gnome.org/GNOME/nautilus/commit/53cee1de
2018-04-04Support HiDpi iconsCosimo Cecchi1-20/+34
Port the rendering of icons to cairo surfaces, so that we can apply the GDK scale factor when rendering icons. origin commit: https://gitlab.gnome.org/GNOME/nautilus/commit/0d4555d7
2016-11-22move to GTK+3 (>= 3.14), drop libunique, GTK+2 code, and --with-gtk build ↵lukefromdc1-16/+0
option *Remove GTK_VERSION_CHECK (3, 0, 0) and libunique selectors *Remove GTK2 and libunique specific code. *Leaves selector for specific GTK3 versions. *Remove #DEFINES for vbox/hbox previously required for GTK2 compatability *Keep vbox in caja-spatial-window.c, it is necessary for the desktop to work *spatial-window vbox issue at https://github.com/mate-desktop/caja/issues/591
2016-08-31GTK3: stop warning spew from sidebar, pathbarlukefromdc1-1/+1
The button underallocation warnings came from pathbar sliders picking up padding from themes, then being forced to render to a smaller size in the code. The GTK_ICON_LOOKUP_GENERIC_FALLBACK warnings came from the sidebar icons, this flag is now a source of errors. Unfortunately NULL does not work, so set GTK_ICON_LOOKUP_FORCE_SIZE, which does not create errors and ensures the icon size we actually want in the sidebar is used anyway. Stops all but two of the warnings listed in https://github.com/mate-desktop/caja/issues/561
2016-07-11all: don't use deprecated GMutex/GThread APIraveit651-6/+6
Also, threads area always enabled, so we can remove the G_THREADS_ENABLED conditionals. Require GLib 2.31 for this. taken from: https://git.gnome.org/browse/nautilus/commit/?h=gnome-3-4&id=0594aa1 Note, this fixes a Wimplicit-function-declaration warning in caja-search-engine-simple
2016-01-18GTK3 icon-info: don't use deprecated gtk_icon_info_freeWolfgang Ulbrich1-4/+16
taken from: https://git.gnome.org/browse/nautilus/commit/?id=67028ca
2016-01-13GTK3 icon-info: plug a leakWolfgang Ulbrich1-1/+7
taken from: https://git.gnome.org/browse/nautilus/commit/?h=gnome-3-0&id=705d814
2016-01-13icon-info: use gdk_pixbuf_new_from_stream_at_scale()Wolfgang Ulbrich1-2/+4
https://git.gnome.org/browse/nautilus/commit/?h=gnome-3-0&id=83a83e3
2013-03-03Replace undocumented deprecated g_thread_gettimeStefano Karapetsas1-3/+3
Bump minimum glib version accordingly
2012-11-16[icon-info] add a method to fetch GIcons for user special dirsJasmine Hassan1-0/+27
http://git.gnome.org/browse/nautilus/commit/?id=1df83c6586560a8ae5efc96037e673e52b4b119b
2012-11-14[icon-info] add caja_icon_theme_can_render()Jasmine Hassan1-0/+21
http://git.gnome.org/browse/nautilus/commit/?id=110a0e8f2b9ec96b34e4b76390e3f78adc9cda30
2012-08-12Fixed incorrect fsf addresses. Closes #28.Steve Zesch1-2/+2
2012-01-05location-entry: don't treat '~' as a relative pathStefano Karapetsas1-1/+1
Based on a patch by Reed Lipman <[email protected]> https://bugzilla.gnome.org/show_bug.cgi?id=628802 http://git.gnome.org/browse/nautilus/commit/?h=gnome-2-32&id=5e91bd11bea315b258839890a4ccf4d4b1c49a17
2012-01-05applied 96_no-null-in-g-str-hash.patch from ubuntu natty nautilusStefano Karapetsas1-0/+8
2011-12-01moving from https://github.com/perberos/mate-desktop-environmentPerberos1-0/+751