and update their color transforms with the new monitor's color
profile. A widget is considered changing monitors when its toplevel
window's center crosses, in order to let widgets within one window
have consistent colors.
For instance, modifying a layer and going directly to draw in the canvas
should not cancel the layer name.
You can still cancel a layer renaming in progress with ESC.
during the lifetime of the widget. Leaving that up to the GtkTreeView
was working for mysterious reasons even during destruction of the
widget. It's safer and cleaner this way.
Remove the button_release handler again, setting dnd_widget to NULL on
container change is enough to fix the crash I've seen, I added the
other handler just out of paranoia and apparently didn't test it.
no matter how editing was started (double click, keyboard activate, F2).
Connect to "editing-started" of the name cell and set the object's
real name directly on the GtkCellEditable, instead of trying to hack
around in the tree store before the actual editing starts.
so all the view renderers already have the right context when the
parent interface code selects the right item, which in turn requires
the context to be already set on the renderers. Fixes warnings when
dragging dockables around.
Add new utility function gimp_get_all_modifiers_mask() which returns
all modifiers used for "useful" things on the current platform, like
in the commit below.
Introduced two virtual functions to a GimpViewable
'set_expanded' and 'get_expanded'
and a PROP_GROUP_ITEM_FLAGS to load/save the expanded state
of layer_groups and use them.
instead of checking for event->button == 3, so context menus
work correctly on the Mac. Didn't change the image menu yet
because thet requires some more refactoring.
Add a "pre-clicked" signal to GimpCellRendererViewable that can
prevent a selection from happening. Move the Alt-Click code in
GimpLayerTreeView to this signal and if a layer is Alt-Clicked, don't
go ahead and make the layer active. Also add a test for this use case.
Keep a list of GimpCellRendererViewable around and add API to add
them. When items are removed or the store is cleared, set the
renderers' "viewable" property to NULL so they don't keep refing the
viewable.
This is not really "model" code but needs to be done for all container
views that have viewable cell renderers.
GimpContainerComboBox and GimpContainerEntry lacked that clearing, so
this change might fix some cases where objects (even images) were
removed but still stuck in memory until the model changed again.
Implemented infrastructure for multiple selection support.
GimpContainerTreeView actually provides such functionality.
All other GimpContainerViews should work as before.
- gimp_container_tree_view_prepend_toggle_cell_renderer() to
gimp_container_tree_view_add_toggle_cell()
- gimp_container_tree_view_prepend_cell_renderer() to
gimp_container_tree_view_add_renderer_cell()
because "prepend" is an implementation detail, "renderer" is obsolete,
and in the second case it's not "cell renderer" but really a "renderer
cell".
If we didn't click on any cell, but on empty space in the expander
column of a row that has children, let GtkTreeView process the button
press to maybe handle a click on an expander.
* app/core/gimpimage.[ch]: rename all gimp_image_reposition_foo() to
gimp_image_reorder_foo() and added "new_parent" parameters. Factor
out calculating of the item's new container and index to a utility
function.
* app/core/core-enums.[ch]: rename the REPOSITION undos to REORDER.
* app/core/gimpimage-undo-push.[ch]
* app/core/gimpchannelpropundo.[ch]
* app/core/gimplayerpropundo.[ch]
* app/vectors/gimpvectorspropundo.[ch]: change accordingly. Remember
the old parent item in all item reorder undos.
* app/widgets/gimpitemtreeview.h: change GimpReorderItemFunc prototype
accordingly.
* app/widgets/gimpchanneltreeview.c
* app/widgets/gimplayertreeview.c
* app/widgets/gimpvectorstreeview.c (class_init): follow image API
name changes.
* app/widgets/gimpitemtreeview.c (gimp_item_tree_view_drop_viewable):
implement reordering of items between groups.
* app/widgets/gimpcontainertreeview.c
(gimp_container_tree_view_reorder_item): fix to reorder the item
within its level of the tree (unrelated to above changes, but needed
to make them work).