2001-12-05 Jens Finke <jens@triq.net>
* Makefile.am: Switch from xml-i18n-tools to intltool.
(INCLUDES): Use EOG_CFLAGS.
(eog_collection_LDADD): Use EOG_LIBS.
2001-06-30 Jens Finke <jens@gnome.org>
* eog-image-loader.c: Call gdk_pixbuf_loader_close before
gdk_pixbuf_loader_get_pixbuf. Otherwise we fail to open xpm and tiff
images, due to some hacks in gdk-pixbuf.
2001-06-14 Jens Finke <jens@gnome.org>
* eog-collection-preferences.c:
(ecp_create_view_page): Merged code from
ecp_create_(layout|color)_page into this new function, so we have
all properties on one page. Also added gconf support for storing
the settings and beautified the dialog.
(ecp_create_color_page), (ecp_create_layout_page): Removed.
(ecp_activate_layout_cb), (ecp_activate_color_cb): Use gconf for
storing settings.
(eog_collection_preferences_create_page): Create only one page
through ecp_create_view_page.
* eog-collection-view.[ch]:
(prop_control_get_prop): Handle only one property page.
(layout_changed_cb), (color_changed_cb): New functions, callbacks
for changes in the gconf database.
(set_configuration_values): New function, obtain values from gconf
database and install listeners to key changes.
(eog_collection_view_construct): Init gconf, use
set_configuration_values.
(eog_collection_view_set_layout_mode),
(eog_collection_view_set_background_color): Removed.
2001-06-01 Jens Finke <jens@gnome.org>
* Makefile.am (INCLUDES), (eog_collection_LDADD): Added gnome-vfs
flags.
* cimage.[ch] (cimage_new): Create GnomeVFSURI from text uri and
use cimage_new_uri.
(cimage_new_uri): New function, creates an cimage from
GnomeVFSURI.
(cimage_get_uri): Return GnomeVFSURI object.
(cimage_is_directory): Use GnomeVFS functions to determine file
type.
* eog-collection-model.c (loading_context_free): New helper
function.
(directory_visit_cb): New function, opens a single file contained
in a directory.
(real_storage_loading): Renamed to real_dir_loading, uses GnomeVFS
functions now, removed all the BonoboStorage/Stream stuff.
(directory_filter_cb): New function, determines what kind of files
we can handle within a directory.
(real_stream_loading): Renamed to real_file_loading, uses GnomeVFS
functions now, removed all the BonoboStorage/Stream stuff.
(eog_collection_model_set_uri),
(eog_collection_model_set_uri_list),
(prepare_context): Use GnomeVFS functions, removed all the
BonoboStorage/Stream stuff.
* eog-collection-view.c (eog_collection_view_get_prop): Adapted to
cimage changes.
* eog-image-loader.c (load_uri): Use GnomeVFS functions, removed
all the BonoboStorage/Stream stuff.
* eog-item-factory-simple.c (ii_factory_update_item): Adapted to
cimage changes.
* main.c (init_server_factory): Call gnome-vfs-init.
2001-05-31 Jens Finke <jens@gnome.org>
* Makefile.am (INCLUDES): Added $(EXTRA_GNOME_CFLAGS) [all these
extra flags are really a mess, maybe its time for a cleanup].
(eog_collection_LDADD): Added $(EXTAR_GNOME_LIBS).
2001-05-30 Jens Finke <jens@gnome.org>
* cimage.[ch]: (cimage_set_dimensions),
(cimage_get_width), (cimage_get_height): New functions.
* eog-collection-model.[ch]:
(eog_collection_model_get_selected_image): New function, which
returns the single selected image.
* eog-collection-view.c:
(eog_collection_view_get_prop): If only a single image is
selected, provide detailed informations about it in the
'window/status' text.
* eog-image-loader.c (loading_finished): Set image dimensions.
2001-05-29 Jens Finke <jens@gnome.org>
* eog-collection-model.[ch]:
(eog_collection_model_class_init): Add 'base_uri_changed' signal.
(eog_collection_model_set_uri),
(eog_collection_model_set_uri_list): Emit 'base_uri_changed' if
neccessary.
(eog_collection_model_toggle_select_status),
(select_all_images),
(unselect_all_images): Emit 'selection_changed' signal.
(eog_collection_model_get_selected_length): New function, which
returns the number of selected images.
* eog-collection-view.c: Renamed properties to 'window/title' and
'window/status', which is more consistent with the rest of the
bonobo property naming scheme.
(eog_collection_view_get_prop): View only the base_uri of this
collection, new handler for the PROP_WINDOW_STATUS property.
(update_properties),
(update_status_text),
(update_title_text),
(model_size_changed),
(model_selection_changed),
(model_base_uri_changed): New functions (or slightly renamed),
which introduce a nice async property change client notification.
(eog_collection_view_construct): Connect to new model signals.
2001-05-21 Jens Finke <jens@gnome.org>
* eog-collection-model.c, eog-image-loader.c,
eog-item-factory-simple.c, eog-wrap-list.c: Guarded debug messages
with #ifdef COLLECTION_DEBUG. Some were so unneccessary that I
removed them completely.
* eog-collection-control.c (eog_control_construct): Add property
bag to control.
* eog-collection-model.[ch]: Added a base_uri attribute, which stores
the common part of all viewed URIs. Maybe this doesn't work under
all conditions.
(eog_collection_model_set_uri),
(eog_collection_model_set_uri_list): Set base_uri.
(eog_collection_model_get_base_uri): New function.
* eog-collection-view.[ch]: Added property bag attribute.
(eog_collection_view_get_property_bag),
(eog_collection_view_get_prop),
(eog_collection_view_set_prop): New functions.
(update_title_property),
(model_interval_size_changed): New functions to update the
'window_title' property correctly.
(eog_collection_view_construct): Create property bag and listen to
model interval changes.
2001-04-23 Jens Finke <jens@gnome.org>
This patch enables the collection component to load a bunch of
single files too. It's even possible to mix directory contents and
simple files.
* eog-collection-model.c (EogCollectionModelPrivate): Removed
storage, uri and idle_id attributes.
(LoadingContext): New structure which holds all neccessary
informations to load an URI.
(real_image_loading): Removed.
(eog_collection_model_set_uri_list),
(prepare_context),
(real_storage_loading),
(real_stream_loading): New functions.
(eog_collection_model_set_uri): Rewrote this one.
* eog-collection-view.c
(impl_GNOME_EOG_ImageCollection_openURIList): New function.
2001-04-23 Jens Finke <jens@gnome.org>
* cimage.[ch]: s/path/uri/
* eog_image_loader.c: Added queue and idle loop based loading. Due
to this, the EogImageLoader doesn't depend on EogCollectionModel
anymore.
(eog_image_loader_set_model): Removed.
(loading_canceled),
(loading_finished),
(setup_next_uri): New functions.
(real_image_loading): Renamed to load_uri and revised.
(eog_image_loader_start): Append image to load to queue, changed signature.
* eog_collection_model.c
(eog_collection_model_get_next_loading_context): Removed.
(eog_collection_model_real_image_loading): Assemble correct URI
for cimage objects, call eog_image_loader_start and emit
INTERVAL_ADDED signale for every single cimage object.
(eog_collection_model_get_uri): Use cimage_get_uri function.
* eog_item_factory_simple.c (ii_factory_update_item): Use
cimage_get_uri.
2001-04-18 Jens Finke <jens@gnome.org>
* eog-collection-preferences.[ch], eog-item-factory-simple.[ch],
eog-item-factory.[ch], eog-wrap-list.[ch]: Use standard program
copyright notice at top of file.
2001-04-11 Jens Finke <jens@gnome.org>
* eog-collection-preferences.[ch]: New files.
* Makefile.am (SOURCES): Added the new files.
* eog-collection-view.[ch]:
(eog_collection_view_set_layout_mode),
(eog_collection_view_set_background_color),
(prop_control_get_prop),
(prop_control_get_cb): New functions.
(eog_collection_view_construct): Create BonoboPropertyControl object.
* eog_wrap_list.c: (eog_wrap_list_set_layout_mode),
(eog_wrap_list_set_background_color): New function.
(do_layout_check): Added support for different item layout
flavours: vertical, horizontal and rectangle.
(update): Check for new global update hint GLOBAL_LAYOUT_MODE_CHANGED.
* eog_wrap_list.h: (eog_wrap_list_set_layout_mode),
(eog_wrap_list_set_background_color): New function declarations.
(EogLayoutMode): New enumeration.
2001-04-10 Jens Finke <jens@gnome.org>
I did the changes since 2001-04-02 on holidays in the south france
sun without internet access, so I commit these at once now. Its
likely that I forgot some minor changes.
* eog-item-factory-simple.c (eog_item_factory_simple_construct):
New Function.
(eog_item_factory_simple_new): Call construct method.
(shade_bgr_destroy_notify_cb): New function.
(ii_factory_update_item): Set item border to black, use shaded
background for images, set font color to white.
2001-04-07 Jens Finke <jens@gnome.org>
* eog-wrap-list.c (handle_item_event): Recognize CTRL and SHIFT
key modifiers and behave accordingly.
(get_item_view_position): New handy function.
* eog-collection-model.c
(eog_collection_model_toggle_select_status): Takes a single id now
instead of a GList of ids. The list isn't really needed and its much
easier to use it this way.
2001-04-05 Jens Finke <jens@gnome.org>
* eog-wrap-list.c (EogWrapListPrivate struct): Added view_order
list.
(compare_item_caption): New function to create a sorted list of
items according to their caption.
(do_item_added_update): Attach caption to item object and insert
it into the sorted view_order list.
(do_item_rearrangement): Traverse view_order list instead of hash
table.
(rearrange_single_item): Use GFunc like signature.
2001-04-04 Jens Finke <jens@gnome.org>
* cimage.[ch] (cimage_toggle_select_status): New function
* eog-collection-model.[ch]
(eog_collection_model_toggle_select_status),
(eog_collection_model_set_select_status_all)
(select_all_images),
(unselect_all_images): New functions.
* eog-wrap-list.c (handle_canvas_click): New function.
(eog_wrap_list_construct): Connect to canvas "button-press-event"
signal.
(handle_item_event): Process GDK_BUTTON_PRESS event.
* eog-item-factory-simple.c (ii_factory_update_item): Indicate if
the thumbnail is selected or not.
2001-04-02 Jens Finke <jens@gnome.org>
* eog-wrap-list.c (do_item_added_update): Attach unique id to
canvas item and connect to 'event' signal.
(handle_item_event): Read unique id from item and propagate it
together with emmited signal.
2001-03-27 Jens Finke <jens@gnome.org>
* eog-collection-model.c, eog-wrap-list.c: Use hash table to hold
all the loaded images, instead of a simple list.
2001-03-21 Jens Finke <jens@gnome.org>
* eog-image-list.[ch], eog-image-selection-model.[ch],
gnome-icon-list-model.[ch], gnome-list-model.[ch],
gnome-list-selection-model.[ch], gnome-list-view.[ch],
gnome-position-list-model.[ch], gnome-wrap-list.[ch]: Removed
files. These contained a lot of lagacy stuff, which isn't used
anymore.
* eog-wrap-list.[ch]: New files. This substitutes the old
gnome-wrap-list, provides smooth scrolling, is faster and
does correct layouting.
* Makefile.am (SOURCES): Adapted to above changes.
* eog-collection-model.[ch]: Use a GList of unique ids as
parameter for the interval_added, interval_changed and
interval_removed signals.
* eog-collection-view.c (eog_collection_view_construct): Use
EogWrapList instead of GnomeWrapList.
* gnome-icon-item-factory.c (ii_factory_configure_item): Renamed
to ii_factory_update_item, adapted to work with EogWrapList.
(ii_factory_create_item): Added unique_id to parameter list.
* gnome-list-item-factory.[ch] (configure_item signal): Renamed to
update_item, removed last 3 parameter.
(create_item signal): Added unique_id to paramter list.
2001-03-12 Jens Finke <jens@gnome.org>
* eog-collection-control.[ch]: Parent class is EogCollectionView
now. Use BonoboXObject functionality.
(handle_open_uri): New function.
(eog_control_construct): Rewrote this completely.
* eog-collection-model.[ch]: Handle URIs now instead of
Bonobo_Storage objects. URIs will be resolved to storages
internally.
(eog_control_set_storage): Removed.
(eog_control_set_uri): New function.
(eog_control_get_uri): New function.
(eog_control_destroy): Set attributes to NULL after freeing.
* eog-collection-view.c
(impl_GNOME_EOG_ImageCollection_setStorage): Removed.
(impl_GNOME_EOG_ImageCollection_openURI): New function.
(eog_collection_view_class_init): Add signal 'open_uri'.
(handle_item_dbl_click): New function.
(eog_collection_view_construct): Connect to signal 'item_dbl_click'.
* eog-collection-view.h (_EogCollectionViewClass): Signal 'open_uri' added.
* eog_image_loader.c (real_image_loading): Removed unneccessary io
buffer initialisation. Free the buffer correctly.
* gnome-wrap-list.c (class_init): Add signal 'item_dbl_click'.
(handle_item_event): Added case for item double click.
* gnome-wrap-list.h (_GnomeWrapListClass): Signal 'item_dbl_click'
added.
2001-03-07 Jens Finke <jens@gnome.org>
* Makefile.am: Added support for xml-i18n-tools.
* GNOME_EOG_Collection.oafinfo: Renamed to
GNOME_EOG_Collection.oaf.in and marked strings for translation
where appropriate.
2001-03-06 Jens Finke <jens@gnome.org>
* GNOME_EOG_Collection.oafinfo: Added 'x-directory/normal' to list
of supported mime types.
* Makefile.am (SOURCES): eog-collection-model.[ch] added.
* cimage.c (get_unique_id): Uncommented.
(cimage_new): Set unique_id again. I think we need this to support
basic file operations like 'rename' or 'remove'.
* eog-collection-view.c
(impl_GNOME_EOG_ImageCollection_addImages): Removed.
(impl_GNOME_EOG_ImageCollection_setStorage): New function.
(eog_collection_view_destroy): Free 'model', 'sel_model' and
'factory'.
(eog_collection_view_class_init): Set correct parent class. This
fixes the crash, which was introduced with the BonoboXObject
switch.
(eog_collection_view_construct): Use EogCollectionModel now.
* eog-image-loader.c: Added 'loading_finished', '_canceled' and
'_failed' signals.
(eog_image_loader_set_model), (eog_image_loader_destroy): Use
EogCollectionModel instead of EogImageListModel.
(real_image_loading): Use Bonobo_Stream Objects instead of native
file operations.
* eog-image-loader.h: Renamed 'IS_EOG_IMAGE_LOADER[_CLASS]' to
'EOG_IS_IMAGE_LOADER[_CLASS]' for consistency.
* gnome-icon-item-factory.c, gnome-list-item-factory.[ch],
gnome-list-view.[ch], gnome-wrap-list.c: Updated to use
EogCollectionModel instead of EogImageListModel.
* eog-collection-model.[ch]: New files.