summaryrefslogtreecommitdiff
path: root/libmate-desktop
AgeCommit message (Collapse)AuthorFilesLines
2020-01-09thumbnail: some code-styling fixesraveit652-115/+112
- replace remaining tabs with spaces - fixes some indents
2020-01-09Deprecate mate_desktop_thumbnail_scale_down_pixbuf()Bastien Nocera2-121/+17
As scaling down by huge factors is now fixed in gdk-pixbuf. Require the newer gdk-pixbuf as well, to avoid running into a pre-fix version. https://bugzilla.gnome.org/show_bug.cgi?id=775991 origin commit: https://gitlab.gnome.org/GNOME/gnome-desktop/commit/cb64228
2020-01-09thumbnailer: Always prefer the backend provided previewBastien Nocera1-2/+64
If a preview exists for a particular file, in particular a preview icon for videos and images on external devices, prefer those to running a script. https://bugzilla.gnome.org/show_bug.cgi?id=738503 origin commit: https://gitlab.gnome.org/GNOME/gnome-desktop/commit/370b985 https://gitlab.gnome.org/GNOME/gnome-desktop/commit/e629e46 https://gitlab.gnome.org/GNOME/gnome-desktop/commit/a15db1d https://gitlab.gnome.org/GNOME/gnome-desktop/commit/fc19c94
2020-01-09thumbnail: Always use external gdk-pixbuf thumbnailerBastien Nocera2-361/+3
Instead of special-casing gdk-pixbuf-supported image formats, use an external thumbnailer. This will give us the ability to: - cancel running thumbnail operations - avoid memory leaks, buffer overflows, double-frees, etc. in the image loaders having an impact on the application - limit resource usage when thumbnailing https://bugzilla.gnome.org/show_bug.cgi?id=768064 origin commit: https://gitlab.gnome.org/GNOME/gnome-desktop/commit/b69fde6 https://gitlab.gnome.org/GNOME/gnome-desktop/commit/dba6d95
2020-01-09thumbnail: Demote a log message from WARNING to DEBUGraveit651-1/+1
Failure to create a GdkPixbufLoader for a specific MIME type doesn't necessarily indicate an error. It is possible that the fallback code would still be able to parse the image data. For example, Canon CR2 RAW files have the MIME type image/x-canon-cr2. While we don't have a loader for that specific MIME type, the TIFF loader can still parse the data. In case the fallback code failed to parse the image data, we get a WARNING anyway: MateDesktop-WARNING **: Error creating thumbnail for ... Having a log message to indicate that we are using the fallback code is useful for debugging, but there is no need for the WARNING. It can be extra noise and needlessly interferes with things like G_DEBUG=fatal-warnings. https://bugzilla.gnome.org/show_bug.cgi?id=762504 origin commit: https://gitlab.gnome.org/GNOME/gnome-desktop/commit/7507254
2020-01-09thumbnail factory: Disconnect signal handlers in finalizeMatthias Clasen1-46/+43
We are seeing crashes in Fedora that point at the settings signal handlers getting run after the thumbnail factory is finalized. Explicitly disconnecting the handlers in finalize is the right thing to do, anyway. While we are at it, replace some of the cleanup code in finalize with g_clear_pointer and g_clear_object, as suggested by Colin. https://bugzilla.gnome.org/show_bug.cgi?id=761049 origin commit: https://gitlab.gnome.org/GNOME/gnome-desktop/commit/f32c389
2020-01-09thumbnail: Move thumbnail generation/saving to a few helperJasper St. Pierre1-203/+127
functions Another cleanup in preparation for a new "simple" thumbnail API. https://bugzilla.gnome.org/show_bug.cgi?id=684026 https://bugzilla.gnome.org/show_bug.cgi?id=784915 origin commit: https://gitlab.gnome.org/GNOME/gnome-desktop/commit/97f6f77 https://gitlab.gnome.org/GNOME/gnome-desktop/commit/ef4734f https://gitlab.gnome.org/GNOME/gnome-desktop/commit/911091d
2020-01-09thumbnail: Clean up path generation codeJasper St. Pierre1-100/+66
Put the path calculation code in one spot. https://bugzilla.gnome.org/show_bug.cgi?id=684026 origin commit: https://gitlab.gnome.org/GNOME/gnome-desktop/commit/57c18b8 https://gitlab.gnome.org/GNOME/gnome-desktop/commit/ef0f02e
2020-01-09thumbnailer: Try harder to create a failed thumbnailJuan Antonio Marin1-13/+9
If a failed thumbnail is created because the pixbuf fail to save (for instance if user is over quota) we should still try to rename the temporary file that might have been created. If not, the thumbnail will not be marked as failed, and thumbnailing will be reattempted. https://bugzilla.gnome.org/show_bug.cgi?id=728775 origin commit: https://gitlab.gnome.org/GNOME/gnome-desktop/commit/54f68ab
2020-01-09Add missing cases to switch statementPhilip Withnall1-41/+103
This shuts up a gcc warning by adding support for thumbnail directories being unmounted or moved. https://bugzilla.gnome.org/show_bug.cgi?id=709819 origin commit: https://gitlab.gnome.org/GNOME/gnome-desktop/commit/c064fab
2020-01-09lib: Add thumbnail test applicationBastien Nocera2-1/+70
origin commit: https://gitlab.gnome.org/GNOME/gnome-desktop/commit/cb04925 https://gitlab.gnome.org/GNOME/gnome-desktop/commit/36b131c
2020-01-09Increase the size of thumbnails to 256William Jon McCann1-1/+3
origin commit: https://gitlab.gnome.org/GNOME/gnome-desktop/commit/c587265
2019-12-08avoid redundant redeclarationsPablo Barciela2-6/+1
2019-10-31Treat time_t as gint64 to convert from/to stringOBATA Akio1-5/+7
"time_t" may not equal with "long", especiall 32-bit platforms resolved "Year 2038 problem". There are no standard way to convert time_t from/to string, but GLib2 using gint64 type as a time internally, so it is reasonable to use gint64 for such purpose.
2019-08-11Replace deprecated gtk_css_provider_get_defaultraveit651-1/+6
2019-08-11mate-bg-crossfade: replace tabs with spacesraveit652-461/+461
fixes codestyling, caused by usage of different tab size in editors.
2019-07-23mate-colorsel: avoid deprecated 'gtk_hscale_new'Pablo Barciela1-1/+1
2019-07-03Remove trailing whitespacesLaurent Napias14-588/+588
2019-06-11check both {$prefix,/usr}/share/locale dirs for translationWu Xiaotian1-15/+31
2019-06-11Add test code for mate-languages.Wu Xiaotian4-1/+115
2019-05-25build: use localedir instead of DATADIRNAMEMarty E. Plummer1-1/+1
Signed-off-by: Marty E. Plummer <[email protected]>
2019-05-22add abi checkMarty E. Plummer1-0/+247
Signed-off-by: Marty E. Plummer <[email protected]>
2019-05-22treewide: add meson buildMarty E. Plummer2-0/+151
Signed-off-by: Marty E. Plummer <[email protected]>
2019-03-25mate-desktop-thumbnail: avoid 'NULL' parameterPablo Barciela1-1/+1
Fixes Clang static analyzer warning: mate-desktop-thumbnail.c:933:54: warning: Null pointer passed as an argument to a 'nonnull' parameter g_checksum_update (checksum, (const guchar *) uri, strlen (uri)); ^~~~~~~~~~~~
2019-03-25mate-thumbnail-pixbuf-utils: Fix division by zeroPablo Barciela1-3/+9
Fixes Clang static analyzer warning: mate-thumbnail-pixbuf-utils.c:160:17: warning: Division by zero *dest++ = r / n_pixels; ~~^~~~~~~~~~
2019-03-25mate-bg: Fix memory leakPablo Barciela1-0/+2
Fixes Clang static analyzer warning: mate-bg.c:2764:2: warning: Potential leak of memory pointed to by 'size' g_queue_push_tail (parser->stack, g_strdup (name)); ^~~~~~~~~~~~~~~~~
2019-03-17[Security] Use 'g_strlcpy' instead of 'strcpy'Pablo Barciela2-2/+2
Fixes Clang static analyzer warnings: mate-rr-config.c:549:3: warning: Call to function 'strcpy' is insecure as it does not provide bounding of the memory buffer. Replace unbounded copy functions with analogous functions that support length arguments such as 'strlcpy'. CWE-119 strcpy (output->priv->vendor, "???"); ^~~~~~ mate-desktop-item.c:2118:2: warning: Call to function 'strcpy' is insecure as it does not provide bounding of the memory buffer. Replace unbounded copy functions with analogous functions that support length arguments such as 'strlcpy'. CWE-119 strcpy (the_exec, exec); ^~~~~~
2019-03-17[Security] test-ditem: Use 'g_strlcat' instead of 'strcat'Pablo Barciela1-1/+1
Fixes Clang static analyzer warning: test-ditem.c:94:2: warning: Call to function 'strcat' is insecure as it does not provide bounding of the memory buffer. Replace unbounded copy functions with analogous functions that support length arguments such as 'strlcat'. CWE-119 strcat (path, "/foo.desktop"); ^~~~~~
2019-03-15mate-hsv: avoid duplicate initialization in variablePablo Barciela1-1/+0
avoid Clang static analyzer warning: mate-hsv.c:913:19: warning: Value stored to 'priv' during its initialization is never read MateHSVPrivate *priv = hsv->priv; ^~~~ ~~~~~~~~~
2019-03-11mate-hsv: avoid deprecated 'gdk_device_grab/ungrab'Pablo Barciela1-10/+9
2019-03-11mate-colorsel: avoid deprecated 'GtkHSV', use 'MateHSV' insteadPablo Barciela1-11/+12
2019-03-11MateHSV implementation (GtkHSV fork)Pablo Barciela3-0/+1542
2019-02-07mate-colorsel: avoid deprecated 'gtk_widget_modify_bg'Pablo Barciela1-5/+26
2019-01-29[mate-rr] Avoid deprecated g_type_class_add_privateWu Xiaotian4-15/+9
2019-01-29Improve indentsWu Xiaotian1-2/+2
2019-01-29Avoid deprecated g_type_class_add_privateWu Xiaotian3-20/+6
Changed MateBgCrossfade, MateColorbutton and MateDesktopThumbnail
2019-01-29[mate-colorsel] Avoid deprecated g_type_class_add_privateWu Xiaotian2-51/+49
2019-01-09mate-bg: avoid deprecated 'g_settings_list_keys'Pablo Barciela1-3/+7
2018-12-12mate-bg: Corrected some commentsZhang Xianwei1-3/+3
There are some incorrect comments in mate_bg_create_surface_scale. Fix them. Signed-off-by: Zhang Xianwei <[email protected]>
2018-08-15mate-desktop-item: replace deprecated gdk_error_trap_push/popraveit651-2/+8
2018-08-15mate-rr-config: replace deprecated gdk_flushraveit651-1/+3
2018-08-15mate-rr: replace deprecated Gdk functionsraveit651-13/+23
2018-08-15mate-bg-crossfade: replace deprecated gdk_error_trap_push/popraveit651-4/+6
2018-08-15mate-bg: replace deprecated gdk_error_trap_push/popraveit651-4/+8
2018-07-03add mate-language apisyetist3-0/+1352
2018-04-25Support background fallback on HiDPIVictor Kareh2-2/+43
This change is a super hacky way of supporting the fallback desktop background (without caja) on HiDPI displays. It does this by doing two things: providing a function for scaled-up background surfaces using cairo_scale; and triggering a change signal when the entire background schema is re-loaded, and so triggering a redraw.
2018-03-30mate-rr-labeler: fix font-color for dark themesraveit651-3/+3
Fixes https://github.com/ubuntu-mate/ubuntu-mate-artwork/issues/29
2018-01-27building: remove < gtk+-3.22 bits and bump required gtk+ versionraveit655-63/+1
2017-12-17WidthOfScreen and HeightOfScreen implementationPablo Barciela3-18/+9
This commit reverts: https://github.com/mate-desktop/mate-desktop/commit/6137212bce120c9eb5555ae777fc7fea2f71e43e And it applies an alternative to fix the deprecated functions: gdk_screen_get_width gdk_screen_get_height
2017-08-26drop MateAboutDialogmonsta3-2430/+0