Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 332360 - add resizing context to getResizeConfiguration
Summary: add resizing context to getResizeConfiguration
Status: CLOSED FIXED
Alias: None
Product: Graphiti
Classification: Modeling
Component: Core (show other bugs)
Version: 0.7.0   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: 0.8.0   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard: Indigo M4 theme_round_offs
Keywords:
Depends on:
Blocks:
 
Reported: 2010-12-11 09:36 EST by Volker Wegert CLA
Modified: 2011-06-24 09:05 EDT (History)
2 users (show)

See Also:
matthias.gorning: indigo+
matthias.gorning: iplog+


Attachments
proposed patch (6.96 KB, patch)
2010-12-11 09:37 EST, Volker Wegert CLA
matthias.gorning: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Volker Wegert CLA 2010-12-11 09:36:29 EST
Build Identifier: 

The method getResizeConfiguration() of IResizeFeature should receive the IResizeShapeContext so that the feature can enable or disable the horizontal or vertical resizing facilities dynamically, e. g. based on the selection. There's also a typo in IResizeShapeContext.

Reproducible: Always
Comment 1 Volker Wegert CLA 2010-12-11 09:37:27 EST
Created attachment 185019 [details]
proposed patch

This patch both fixes the typo and extends the method signature.
Comment 2 Volker Wegert CLA 2010-12-11 11:59:03 EST
There is one additional problem: If I switch off both horizontal and vertical resizing, a selected diagram element is no longer highlighted. This can be fixed by changing /org.eclipse.graphiti.ui/src/org/eclipse/graphiti/ui/internal/policy/GFResizableEditPolicy.java, method createShapeHandles: Replace

list.add(new GFSurroundingHandle(owner, cp, supportedResizeDirections, movable));

with 

list.add(new GFSurroundingHandle(owner, cp, PositionConstants.NSEW, movable));
Comment 3 Matthias Gorning CLA 2010-12-13 04:37:32 EST
Patch applied and proposal from comment 2 inserted.
Comment 4 Michael Wenz CLA 2011-04-20 07:36:06 EDT
Corrected whiteboard entry to "theme_round_offs"
Comment 5 Michael Wenz CLA 2011-05-27 09:02:42 EDT
Part of 0.8.0
Comment 6 Michael Wenz CLA 2011-06-24 09:05:38 EDT
Part of Graphiti Indigo 0.8.0