This is not the main reason for the specific output in #9994. These ones are
more probably because of similar usage in GTK (which updated its own calls to
g_file_info_get_is_hidden|backup() in version 3.24.38). But we should likely
also update the various calls we have to use the generic
g_file_info_get_attribute_*() variants.
To be fair, it is unclear to me when we can be sure that an attribute is set.
For instance, when we call g_file_enumerate_children() or g_file_query_info()
with specific attributes, docs say that it is still possible for these
attributes to not be set. So I assume it means we should never use direct
accessor functions.
The only exception is that I didn't remove usage of g_file_info_get_name(),
since its docs says:
> * Gets a display name for a file. This is guaranteed to always be set.
Even though it also says just after:
> * It is an error to call this if the #GFileInfo does not contain
> * %G_FILE_ATTRIBUTE_STANDARD_DISPLAY_NAME.
Which is very contradictory. But assuming that this error warning was
over-zealous documentation, I kept the direct accessors since they are supposed
to be slightly more optimized (still according to in-code documentation) so
let's priorize them when we know they are set for sure.
This commit converts `GimpModuleDB` into a `GListModel`. This allows us
to drop quite a bit of custom code to have an adaptive list of modules
by just becoming a `GListModel` implementation.
Next to that, this commit also rewrites `GimpModule` to use the `notify`
signal for its 2 new properties: "auto-load" and "on-disk", rather than
trying to define a custom signal for that. This in turn allows us to use
basic methods like `g_object_bind_property()`.
Finally, the module manager dialog now uses `GtkListBox`, which can
easily bind to that new `GListModel` infrastructure.
* Don't generate our own marshallers if they are available in GLib
already
* Don't set the c_marshaller parameter in `g_signal_new()` if it's a
default marshaller provided by GLib. See commit message of commit
39e4aa3c57 on why this is the case.
... and G_TYPE_INSTANCE_GET_PRIVATE()
g_type_class_add_private() and G_TYPE_INSTANCE_GET_PRIVATE() were
deprecated in GLib 2.58. Instead, use
G_DEFINE_[ABSTRACT_]TYPE_WITH_PRIVATE(), and
G_ADD_PRIVATE[_DYNAMIC](), and the implictly-defined
foo_get_instance_private() functions, all of which are available in
the GLib versions we depend on.
This commit only covers types registered using one of the
G_DEFINE_FOO() macros (i.e., most types), but not types with a
custom registration function, of which we still have a few -- GLib
currently only provides a (non-deprecated) public API for adding a
private struct using the G_DEFINE_FOO() macros.
Note that this commit was 99% auto-generated (because I'm not
*that* crazy :), so if there are any style mismatches... we'll have
to live with them for now.
this implies passing the UTF-8 encoded raw module path from gimprc to
gimp_module_db_load() and gimp_module_db_refresh(), which is strictly
speaking an API break, but I seriously doubt that anyone but GIMP is
actually using libgimpmodule.
- don't include <gdk-pixbuf/gdk-pixbuf.h> in headers in app/
- instead, include it in many .c files instead of <glib-object.h>,
finally acknowledging the fact that app/ depends on gdk-pixbuf almost
globally
- fix up includes as if libgimpbase depended in GIO, which it soon will
2009-01-17 Michael Natterer <mitch@gimp.org>
* all files with a GPL header and all COPYING files:
Change licence to GPLv3 (and to LGPLv3 for libgimp).
Cleaned up some copyright headers and regenerated the parsers in
the ImageMap plugin.
svn path=/trunk/; revision=27913
2007-10-18 Michael Natterer <mitch@gimp.org>
* libgimpmodule/gimpmoduledb.c (gimp_module_db_module_initialize):
simply check for G_MODULE_SUFFIX and remove utility function
is_valid_module_name().
svn path=/trunk/; revision=23876
2006-04-10 Sven Neumann <sven@gimp.org>
* libgimpmodule/gimpmoduledb.c (gimp_module_db_module_remove_func):
don't ignore the return value of g_list_remove().
2005-12-20 Michael Natterer <mitch@gimp.org>
* libgimp/*.c
* libgimpconfig/*.c
* libgimpmodule/*.c
* libgimpthumb/*.c
* libgimpwidgets/*.c: port to G_DEFINE_TYPE() and friends. Some
related cleanup.
2004-07-29 Michael Natterer <mitch@gimp.org>
* libgimpmodule/gimpmoduledb.c: converted tabs to spaces, removed
unused #if 0'ed prototype and unused #includes, minor cleanups.
2004-01-23 Michael Natterer <mitch@gimp.org>
* app/app_procs.c
* app/errors.c
* app/main.c
* app/config/gimpconfigwriter.c
* app/core/gimpdata.c
* app/core/gimpdatafactory.c
* app/gui/user-install-dialog.c
* app/plug-in/plug-ins.c
* app/vectors/gimpvectors-import.c: some more gimp_filename_to_utf8().
* libgimp/gimp.c
* libgimpmodule/gimpmodule.c
* libgimpmodule/gimpmoduledb.c: use it here, too, now that is in
libgimpbase.
2003-07-02 Michael Natterer <mitch@gimp.org>
* libgimpbase/gimpbasetypes.h: changed GimpDatafileLoaderFunc to
take a separate "gpointer user_data" parameter (passing user_data
in a struct was a quite nonstandard API design). Made the
GimpDatafileData pointer const.
* libgimpbase/gimpdatafiles.[ch]: removed user_data from the
GimpDatafileData struct and added "const gchar *basename" so we
don't need to g_path_get_basename() in many callbacks.
* libgimp/gimpmiscui.[ch]: changed gimp_plug_in_parse_path() to
gimp_plug_in_get_path() and return the unparsed path.
* app/core/gimpdatafactory.c
* app/core/gimpenvirontable.c
* app/gui/gui.c
* app/plug-in/plug-ins.c
* libgimpmodule/gimpmoduledb.c
* plug-ins/script-fu/script-fu-scripts.c: changed accordingly.
* plug-ins/FractalExplorer/Dialogs.c
* plug-ins/FractalExplorer/FractalExplorer.[ch]
* plug-ins/FractalExplorer/Globals.c
* plug-ins/gfig/gfig.c
* plug-ins/gflare/gflare.c: use gimp_datafiles_read_directories()
instead of fiddling with g_dir_open() manually. Random cleanups.
2003-01-05 Manish Singh <yosh@gimp.org>
* many files in app, modules and libgimp*: cleanup, removed unecessary
G_OBJECT() casts. Should do the same for plug-ins, when more of them
get undeprecated.
2002-11-06 Sven Neumann <sven@gimp.org>
* app/base/base.c (base_init): don't say we'd use MMX if it is
disabled.
* libgimpmodule/gimpmodule.[ch]
* app/gui/module-browser.c: changed enum values and user-visible
strings to saner values.
* libgimpmodule/gimpmoduledb.c
* plug-ins/tools/tool-safe-mode.c: made them less verbose.
2002-10-29 Sven Neumann <sven@gimp.org>
* libgimpmodule/gimpmodule.c
* libgimpwidgets/gimpcolorscales.c
* libgimpwidgets/gimpcolorselect.c: include libgimp-intl.h, not
gimpintl.h since this is in the gimp14-libgimp translation domain.
* libgimpmodule/gimpmoduledb.c
* libgimptool/gimptool.c: no need to include intl.h from here, there
are no translatable message.
2002-10-20 Michael Natterer <mitch@gimp.org>
* app/core/gimpmoduleinfo.[ch]
* libgimp/gimpmodule.h: separated module query from type
registration by adding a separate "gimp_module_query" function
which must be implemented by modules. Make local copies of the
strings returned by the query function.
* app/core/gimpmodules.c
* app/gui/module-browser.c: changed accordingly.
* modules/cdisplay_gamma.c
* modules/cdisplay_highcontrast.c
* modules/colorsel_triangle.c
* modules/colorsel_water.c: added the gimp_module_query() functions.
2002-10-20 Michael Natterer <mitch@gimp.org>
Ported module loading to GTypeModule, getting rid of all own
module registering/bookkeeping stuff for color selectors and
display filters. The modules now simply register GimpColorSelector
and GimpColorDisplay subclasses, the list of registered subclasses
can then be obtained calling g_type_children() on the abstract
base classes.
This is work in progress and just the first working state after I
started breaking everything...
* app/gui/color-select.[ch]
* libgimp/gimpcolordisplay.h
* libgimp/gimpcolorselector.h: removed.
* app/gui/Makefile.am
* libgimp/Makefile.am: changed accordingly.
* libgimp/gimpmodule.h: massively simplified. All voodoo is gone.
* libgimpwidgets/gimpcolordisplay.[ch]
* libgimpwidgets/gimpcolorselector.[ch]: new abstract base classes
which need to be subclassed by modules.
* libgimpwidgets/gimpcolorselect.[ch]: the built-in color selector
from app/gui/color-select.* ported to be a GimpColorSelector
subclass.
* libgimpwidgets/Makefile.am
* libgimpwidgets/gimpwidgets.h
* libgimpwidgets/gimpwidgetsmarshal.list
* libgimpwidgets/gimpwidgetstypes.h: changed accordingly.
* app/core/gimpmoduleinfo.[ch]: made it a GTypeModule subclass
* app/core/gimpmodules.c: changed accordingly.
* app/core/gimpcontainer.c
* app/core/gimplist.c: HACKED around to allow GimpLists of
GObjects (not GimpObjects). This is EEKy, so I will either make
gimp->modules a simple GList and revert this bit of change, or
allow GObjects all over the place in GimpContainer land...
* app/display/gimpdisplayshell-filter.[ch]
* app/gui/color-notebook.c: removed all module stuff and use
g_type_children() to get the list of available color_selectors
and display_filters.
* app/display/gimpdisplayshell-filter-dialog.c
* app/display/gimpdisplayshell-render.c
* app/gui/module-browser.c: changed accordingly.
* app/gui/gui.c: ref the built-in color selector's class before
the modules are queried so it appears first in the list of
GimpColorSelector's children.
* modules/Makefile.am: build the water color selector again.
* modules/cdisplay_gamma.c
* modules/cdisplay_highcontrast.c
* modules/colorsel_triangle.c
* modules/colorsel_water.c: ported them all to the new API.
* modules/gimpmodregister.[ch]: removed the old EMX module hack.
2002-01-31 Michael Natterer <mitch@gimp.org>
* app/core/gimp.c
* app/core/gimpdocuments.c
* app/core/gimpmodules.c
* app/core/gimppalette.c: fixed some get_memsize()
implementations, give useful names to some global objects so the
new mem profile of "the_gimp" looks nicer.
* app/gui/menus.c
* app/gui/commands.[ch]: added a "Debug" menu to the toolbox,
offer a mem profile of the global "Gimp" instance.
2001-11-20 Rebecca Walter <rjp@mail.tele.dk>
* app/core/gimpedit.c
* app/core/gimpimagefile.c
* app/core/gimpmoduleinfo.c
* app/core/gimpmodules.c
* app/core/gimppalette.c
* app/core/gimppattern.c: More of the extensive proofing. Fun fun fun!
2001-11-20 Michael Natterer <mitch@gimp.org>
* app/core/gimp.c: put a g_object_ref() on a different line.
* app/core/gimpdrawable-bucket-fill.c
* app/core/gimpmodules.c: ne need to #include "core/..." here.
* app/display/gimpdisplay-handlers.c: added debugging output
because we have an image refcounting problem :(
* app/display/gimpdisplayshell-handlers.c: fixed a signal
disconnection.
* app/tools/gimpbezierselecttool.[ch]
* app/tools/gimpblendtool.c
* app/tools/gimpbucketfilltool.c
* app/tools/gimpbycolorselecttool.c
* app/tools/gimpclonetool.c
* app/tools/gimpcolorpickertool.c
* app/tools/gimpcroptool.c
* app/tools/gimpellipseselecttool.c
* app/tools/gimpfreeselecttool.c
* app/tools/gimpfuzzyselecttool.c
* app/tools/gimpinktool.c
* app/tools/gimpiscissorstool.c
* app/tools/gimpmagnifytool.c
* app/tools/gimpmeasuretool.c
* app/tools/gimprectselecttool.c
* app/tools/gimpsmudgetool.c: get the tool's options via
tool->tool_info->tool_options, not from the local statis pointer.
Some minor cleanups & function reordering.
* app/widgets/gimpdockbook.c: return TRUE from the notebook tabs'
"button_press" handler, connect DND before cnnecting to
"button_press" because we now stop it's emission.
2001-10-19 Michael Natterer <mitch@gimp.org>
* app/Makefile.am: link the app in a different order as some init
functions are called from core/gimp.c instead of app_procs.c now.
* app/app_procs.[ch]: made app_init_update_status() private and
pass it as callback to various init functions.
* app/plug_in.[ch]: plug_in_init() take "gimp" and "status_callback"
parameters.
* app/undo.c: use "gimage->gimp" instead of "the_gimp", don't
include "app_procs.h".
* app/core/core-types.h: added "GimpInitStatusFunc" typedef.
* app/core/gimp.[ch]: gimp_initialize() and gimp_restore() now
take a "status_callback" as parameter. Don't include "app_procs.h".
* app/core/gimpmodules.c: putting the modules in a strong
container was a bad idea because it may be impossible to finalize
a GimpModuleInfo object belonging to a stalled module.
* app/gui/color-area.c: use G_N_ELEMENTS().
* app/gui/session.c: don't call app_init_update_status() and don't
include "app_procs.h" because this happens after the splash is
hidden.
* tools/pdbgen/app.pl
* app/pdb/internal_procs.[ch]: pass a "status_callback" to
internal_procs_init(), don't include "app_procs.h".
* plug-ins/Makefile.am: build gfig, gimpressionist and imagemap
again.
* plug-ins/MapObject/mapobject_preview.c
* plug-ins/MapObject/mapobject_ui.c: s/gdk_image_unref/g_object_unref/
* plug-ins/gfig/gfig.c
* plug-ins/gimpressionist/brush.c
* plug-ins/gimpressionist/gimpressionist.c
* plug-ins/gimpressionist/ppmtool.[ch]
* plug-ins/gimpressionist/presets.c
* plug-ins/imagemap/imap_browse.[ch]
* plug-ins/imagemap/imap_csim.y
* plug-ins/imagemap/imap_edit_area_info.c
* plug-ins/imagemap/imap_file.c
* plug-ins/imagemap/imap_main.c
* plug-ins/imagemap/imap_menu.c
* plug-ins/imagemap/imap_polygon.c
* plug-ins/imagemap/imap_popup.c
* plug-ins/imagemap/imap_preferences.c
* plug-ins/imagemap/imap_taglist.c
* plug-ins/imagemap/imap_tools.c: ported to current GLib/Gtk+.
* plug-ins/gap/gap_arr_dialog.c
* plug-ins/gap/gap_decode_xanim.c
* plug-ins/gap/gap_filter_foreach.c
* plug-ins/gap/gap_filter_main.c
* plug-ins/gap/gap_frontends_main.c
* plug-ins/gap/gap_lib.c
* plug-ins/gap/gap_main.c
* plug-ins/gap/gap_mod_layer.c
* plug-ins/gap/gap_mov_dialog.c
* plug-ins/gap/gap_navigator_dialog.c
* plug-ins/gap/resize.c: half-way fixed this one too but I'm not
willing to fix tons of duplicated and deprecated app/ code...
2001-10-18 Michael Natterer <mitch@gimp.org>
* app/Makefile.am
* app/module_db.[ch]: removed.
* app/core/Makefile.am
* app/core/core-types.h
* app/core/gimpmoduleinfo.[ch]
* app/core/gimpmodules.[ch]: new files containing the module info
object and the module list handling code.
* app/gui/Makefile.am
* app/gui/module-browser.[ch]: new files containing the GUI.
* app/xcf/xcf.[ch]: pass a "Gimp" pointer to xcf_exit().
* app/core/gimp.[ch]: handle modules and xcf init/exit here too.
* app/app_procs.c: don't touch the modules and xcf stuff any more.
* app/gui/dialogs-constructors.c: changed accordingly.
2001-10-18 Michael Natterer <mitch@gimp.org>
* POTFILES.in: module_db.c has moved.