how comes that in my project, folding swimlanes is only possible by clicking with both mouse buttons (left and right button) on the folding icon? Clicking with the left mouse button on the icon, does not do anything.

Is this desired behaviour?

Some information:

Creating swimlane with:

graph.insertVertex(swimlane0, null, userobj.toString(), 0, 0, 395, 60, "sl1");

Content of myStyles.xml:

<add as="sl1">
    <add as="shape" value="swimlane"/>
    <add as="startSize" value="40"/>
    <add as="horizontal" value="true"/>
    <add as="autosize" value="1"/>
    <add as="bendable" value="1"/>
    <add as="deletable" value="1"/>
    <add as="opacity" value="100"/>
</add>

Thanks in advance for any help!

(Additionally, where can I find the listener that listens to the mouse click on the fold icon?)

asked 02 Sep '12, 13:04

fachexot's gravatar image

fachexot
461210
accept rate: 11%

edited 10 Sep '12, 04:42

David's gravatar image

David
4.9k21831


See mxGraphHandler.java, line 1229.

link

answered 09 Sep '12, 19:16

Gaudenz's gravatar image

Gaudenz
80.1k1310
accept rate: 39%

Thanks! But I have still no idea why folding works only with both mouse buttons. Do you have any idea or suggestions? (In SchemaEditor example folding with left mouse button works fine) Thanks in advance.

Just noticed that it also works pressing ALT while clicking with left mouse button.. But why not only with one left mouse button, although it works in the jgraphx examples...

(20 Oct '12, 21:54) fachexot

Found it. The creation of a new mxGraphHandler in my custom mxGraphComponent caused the folding to be only possible with both mouse buttons or by holding down ALT while clicking.

mxGraphHandler graphHandler = new mxGraphHandler(this);

Did not understand it yet, but I'm on it.. (Maybe the developers might give a hint)

link

answered 20 Oct '12, 22:21

fachexot's gravatar image

fachexot
461210
accept rate: 11%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×194
×45
×25
×8

Asked: 02 Sep '12, 13:04

Seen: 1,426 times

Last updated: 20 Oct '12, 22:21