Drag and Drop Multiple Pictogram elements from the Palette

I have created custom Objects in the palette that can drag and drop individual pictogram elements using a class that extends AbstractAddFeature. What I would like to know if it is possible to drag and drop an item from the palette that contains multiple pictogram elements, such as task1, task2 and a connection between them? I cannot do this with my class from above since
@Override
public PictogramElement add(IAddContext context) {}
only returns one PictogramElement.

Hi,
In my editor I am adding rectangle with associated label that are separate pictogram elements. However they are both linked to the same business object and more linked to each other.
Please look at example from my code:
@Override
public PictogramElement add(IAddContext context) {
final Task addedTask = (Task) context.getNewObject();
final ContainerShape target = context.getTargetContainer();
final IPeCreateService peCreateService = Graphiti.getPeCreateService();
final IGaService gaService = Graphiti.getGaService();
final ContainerShape containerShape = peCreateService.createContainerShape(target, true);
int width = 0;
int height = 0;
width = context.getWidth() <= 0 ? getWidth() : context.getWidth();
height = context.getHeight() <= 0 ? getHeight() : context.getHeight();
final Rectangle invisibleRectangle = gaService.createInvisibleRectangle(containerShape);
gaService.setLocationAndSize(invisibleRectangle, context.getX(), context.getY(), width, height);
// create and set visible rectangle inside invisible rectangle
RoundedRectangle roundedRectangle = gaService.createRoundedRectangle(invisibleRectangle, 20, 20);
roundedRectangle.setParentGraphicsAlgorithm(invisibleRectangle);
roundedRectangle.setStyle(addedTask.isOnlyLocal() ? onlyLocalStyle : getStyle());
if(!addedTask.isAtomic()) roundedRectangle.setLineStyle(LineStyle.DOT);
gaService.setLocationAndSize(roundedRectangle, 0, 0, width, height);
insertInside(peCreateService, gaService, width, height, containerShape, invisibleRectangle, addedTask);
ContainerShape labelShape = addLabel(target, addedTask.getId(), width, height, context.getX(), context.getY());
link(containerShape, new Object[] {addedTask, labelShape});
link(labelShape, new Object[] {addedTask, containerShape});
updatePictogramElement(labelShape);
layoutPictogramElement(labelShape);
addInternalPorts(addedTask, containerShape);
updatePictogramElement(containerShape);
return containerShape;
I think that linking or making somehow relation between pictogram elements should be enough.

Similar Messages

  • There is absolutely NO way to drag and drop newly purchased music from the Purchased list on the phone into my iTunes library?  I'm finding it hard to believe that something so simple cannot be done!

    I like to make MP3 CD's when I have people over, or when my friends have people over so I can just pop them into the CD player and let them play all night without having to worry about changing the CD or anything.  Well, Apple's music is in AAC format, so I have to convert the songs to MP3 files using the converter in iTunes.  So I'll convert them to MP3's and just delete the AAC file so I don't have doubles.  The problem is, the next time I plug the phone into my laptop to transfer new purchases, iTunes thinks that the songs I converted aren't there anymore because the phone has them as AAC files, and iTunes has them as MP3 files, so it doubles the music again...EVERY time!!  It's very frustrating!  So this is why instead of clicking Transfer Purchases, I would like to be able to just drag and drop the songs I want from the Purchased list on the phone into my iTunes library.  I hope I explained this right...lol.  Unfortunately, it doesn't seem like I'm able to do that.  I'm hoping maybe somebody here can help me out and give me some pointers on what to do about this.  Thanks!!

    That stinks!  I can actually do that at my house...I just plug my iPhone right into the wire that's plugged into my receiver in my living room...but some of my friends aren't "technology savvy"...lol...so they just have DVD players and I'll put the CD in there because it will read an MP3 disc.  What's funny, is I have the phone set to "Manually Manage Music", and when I plugged it into the laptop just now, the one song I downloaded last night on the phone, transferred over to the iTunesl library.  That NEVER happens.  And it only transferred the one song...it didn't double the other songs like it ususally does.  I swear, iTunes does what it wants, when it wants sometimes...lol.  Thank you for your quick response. 

  • I DRAG AND DROP A VIDEO CLIP FROM THE EVENT BROWSER THAT IS 7.9 SECONDS INTO MY IMOVIE I'VE STARTED AND IT CHANGES IN THE PROJECT TO 4.9 SECONDS - HOW CAN I KEEP THE LENGTH THE SAME

    I drag a video clip from Event to Project into my imovie I've started.  The video clip length changes from 7.9 seconds to 4.9 seconds. How can I stop that length from being changed?

    If you are using transitions either side of the clip they will use some of the clip to generate the effect, there isn't anything you can do unless you remove or shorten the transition.
    If you aren't using transitions it may be that you are only selecting part of the clip in the event window, try dragging out the yellow frame to include all the video you want in the project.

  • Can't drag and drop Multiple pictures

    I can no longer drag and drop multiple iPhoto pictures to the Desktop. Drag and drop a single picture works OK but multiple pictures just doesn't work. I was able to do this in the past. I'm using version 9.4.2. Repairing Disk Utilities and restarting has not helped.
    Can anyone help? Your help is appreciated.
    Rookie

    Try this: make a temporary, backup copy of the library if you don't already have one (Control-click on the library and select Duplicate from the contextual menu) and try the following:
    1 - launch iPhoto with the Command+Option keys held down and rebuild the library.
    2 - Select and run Option #1.
    OT

  • Drag and drop photo in elements 12

    Trying to drag an edited picture from photobin in Elements 12 onto a blank documents. Elements is resizing my photo to fit the blank document. I don't want it to resize. I want to drag and drop multiple photos onto a new blank doument as I have in other versions.

    I suspect you are doing this in the Photo Bin. Do it from the Layers panel (drag the layers you want from each photo to the blank document) and they won't resize (see note).  If you only want a single layer to represent each image either temporarily flatten the image, or use select all and edit> copy merged followed by a paste into the blank document.
    Note: You need to ensure that your image resolutions are consistent across the images, otherwise they will appear as different sizes in the blank document.
    Cheers,
    Neale
    Insanity is hereditary, you get it from your children

  • Im trying to drag and drop a email group from contacts to a new email message. But it will not let me in OS X Mavericks. Before I upgraded I could do this.

    Im trying to drag and drop a email group from contacts to a new email message. But it will not let me in OS X Mavericks. Before I upgraded I could do this.

    I just posted this fix to another thread and thought it might be useful to post to all of the threads I read trying to fix the problem. Here it is:
    Having the same issue over here with Mavericks 10.9.1 on a new Macbook Pro/Retina. Just now found a workaround/fix/whatever:
    - click on your group in the group pane of the address panel
    - click anywhere in the name pane and select all (command + a)
    - click the "To:" or "Cc:" or "Bcc:" tab right above the group pane at the top of the address panel window.
    The names of all of the individuals in the group will appear as an expanded list in whatever field you clicked. It takes a second or two to happen.

  • When moving a file using drag and drop, as I hover over the destination folder it no longer opens, so I can't drop the file into the folder.  Why?

    When moving a file using drag and drop, as I hover over the destination folder it no longer opens, so I can't drop the file into the folder.  Why?  I have a heirarchical embedded folder structure under \Documents.  Usually, as I drag the file to be moved over the various folders, they will blink twice, then expand/open to reveal contents (in Finder).  Now, when the file to be moved is held (hovering) over the destination folder, it will not blink or expand, so there's no place to drop the file.  If I release the mouse button, the file image disappears, showing that it is "going back to the place it came from", a.k.a. was not moved.  This just started happening.  I noticed it after upgrading to Mavericks.  Is this a bug or could anything else be causing this?

    As of today, Apple Support discovered during a remote support session with me that the same thing happens on their own system.  It is isolated to "Column View"; the Icon and List views in Finder behave correctly.  Issue is being escalated to engineering, and Apple will call to report status in a couple days.  In all likelihood, this is a bug that will need to be addressed in a future update.

  • Unable to drag and drop videos or music from PC folder to ITunes.  Any ideas why?

    Why can I not drag and drop videos or music from PC folder to ITunes?

    I can only guess since you provide no details, but my guess is that these are either not industry-standard MPEG-4 videos but rather one of the offshoots that use the same file extension, or they're a resolution, frame rate or aspect ratio that iTunes can't accept. Can the videos and tracks be played in QuickTime Player? If so, open the Movie Inspector, find the Format information, and post that here along with your versions of Windows and iTunes. That might help people figure out what might be going wrong.
    Regards.

  • How do I drag and drop multiple files on a control?

    LabVIEW supports dragging and dropping a single file on a path control, and have the path control populated appropriately. I want a user to be able to highlight multiple files (say, from the OS Find File window, or anywhere really) and drop them into a path array control in LabVIEW. I was hoping putting a path control in an array would do the trick, but it didn't. The mouse cursor changes to the "+" icon as it did for a single file, but when I release the button the system just beeps. Is this even doable?
    Thanks, Bob Martin

    I guess I was hoping that the path control would realize it was in an array, and starting with the actual control where the drop occurred (if more than one item of the array is visible) start populating subsequent slots with the other file paths.
    I'm not sure how much work would be involved, but maybe I could make a control in VB that would accept the drop event and output the path array I'm looking for. I've never made a control in VB for LabVIEW before, so I'm leary of how much time that would take. I'll add this to my list of "things to do that never seem to get enough priority to do."

  • I have a 5th gen iPod Touch. I have made playlists in iTunes. I need to get them to the iPod. When I had a Classic, it was automatic. You could drag and drop using iTunes music to the playlist in iTunes and it would automatically sync to the Classic.

    I have a 5th gen iPoc Touch. In the past, with the Classic, I could drag and drop from my iTunes music to a Classic playlist through iTunes. Now, the playlist I create in iTunes doesn't show on the Touch. I have maybe 29 GB of music on my Touch. I have already created playlists in iTunes that have substantial amounts of songs in each. How can I get those playlists on the Touch without doing a total sync that wipes the iPod? Is there a way to do it?
    As well, I am noticing here that my 5th gen iPod doesn't show as a registered device. How do I register it?

    For how to sync see:
    iTunes: Syncing media content to iOS devices and iPod       
    Try syncing using the manual method                
    Managing content manually on iPhone, iPad, and iPod
    This may also help:
    Adjusting to iTunes 12

  • I have 2 auxillary disk drives for my MacBokk Pro. Time Machine uses one for backup and I use the other for storage, but I am unable to create a new folder or drag and drop files or folders to the aux drive.

    I am unable to create a new folder on either of my auxillary disk drives.  I can access the files and folders that were there when I transferred one of the drives from a PC.  Time machine uses one for backup and I want to use the other to store photos which are large files.  An help would be appreciated.

    Thanks for the reply.  If I reformat the drive will I be able to access the files on it from the MAC.  I do not share the drive with a PC.  The files were originally created on a PC which I no longer use.  I do want to continue to access the files put there by the PC.  I would like to not have to copy them over to the MAC hard drive just to use them.  The second aux drive is new and works fine because it was formatted by the MAC.  I can drag and drop files there and work with just as if they were on the internal drive.

  • I no longer have iTunes library.xml on my PC but I have all of my songs.  How do I download them to my iPhone - it won't allow me to drag and drop though my PC recognizes the device.

    My PC has all of my iTunes and it recognizes my iPhone 4 device but I cannot drag and drop the songs.  How do I copy the songs to my new iPhone without having to re-purchase everything?  Unfortunately, It appears I no longer have iTunes Music Library.xml on my PC.

    My husband and I are using the same iTunes account on all mac & pc computers, but the libraries are different on each machine.  We always manually manage our music (no auto sync).  iTunes is up to date on the PCs.  My husband uses our joint iTunes account on his pc, but once again, has a different collection in his library from those on the other machines.  He can't load any music from his PC to his iphone 4.  I can load music from my mac library to my iphone 4s, but cannot load from my pc library to my iphone 4s.  How can I switch my main library that it syncs with from the mac to the pc?
    Thanks

  • Drag and drop file into Outlook from AIR application

    I am hoping to see if this would be possible with the Adobe AIR API. We currently have a desktop AIR application that clients install in order to facilitate certain operations triggered via a web application (such as opening files directly from the web).
    One of the actions we are requested to support is the ability to drag and drop files from our web application directly into Outlook and have the file added as an attachment. I saw the documentation at Adobe Flash Platform * Dropping file promises and was wondering if this might be a possibility, or if there was some other method of performing this.
    We are trying to get around the fact that users now have to download a document to their desktop before being able to attach in Outlook.
    Thanks for any assistance.

    You just aren't calling the right NativeDragManager functions. See http://help.adobe.com/en_US/as3/dev/WS5b3ccc516d4fbf351e63e3d118666ade46-7d83.html

  • Drag and drop to view data from database

    hi,
    totally new to dreamweaver cs4, had some real helpful pointers already on there forums so thanks.
    i was wondering, how can you drag and drop in dreamweaver cs4 to display contents of a mysql database? i have worked a bit with .net vwd in past and you dragged over say a list view to display data and really just want to be able to do the same in dreamweaver cs4 but not sure what it would come under in the php menu bar or data option in menu bar?
    can anyone point me in right direction?
    many thanks
    andy

    deansy55 wrote:
    i was wondering, how can you drag and drop in dreamweaver cs4 to display contents of a mysql database?
    Read the Help pages starting here: http://help.adobe.com/en_US/Dreamweaver/10.0_Using/WScbb6b82af5544594822510a94ae8d65-78d3a .html.
    There's also a tutorial here: http://www.adobe.com/devnet/dreamweaver/articles/first_dynamic_site_pt1.html.
    Basically, you create a recordset, and then drag the results from the Bindings panel.

  • Drag and Drop Multiple attachments issue

    I'm having trouble with Mail - when I receive an email with multiple attachments, I like to drag and drop them into the folder short cuts that appear on the left of the finder windows. When I go to that folder later on the attachments aren't there, but their is a text file. The text file name is "yyyy". The number of "y" characters corresponds the number of attachments that I drag their. Has any one had this trouble before. I have done a total reinstall of the system on to a clean hard drive, and it is still happening. The G5 Dual 2.3 was new in Dec 05.
    (this is my first posting, so please be patient if I'm not doing this correctly)
    Cheers Andy

    Andy, the safer way would be to press the Save button that is in the header of your email and then select the folder where you want it saved.

Maybe you are looking for

  • ABAP Query - Want to limit the number of records to 5

    I have a query based on a a table join (MKPF with MSEG) infoset. I want to limit the number of records to first five. How to deal with it?

  • I tunes doesn t lauch need quick time 7.5

    my i tunes doesn t want to launch.it asked me an older version of quick time 7.5 or before but i tried and nothing happened HELP

  • TS4268 What does it mean 'This person cannot be reached by iMessage at this time'?

    I have iMessage to my friend successfully before.  But yesterday when I tried to iMessage him again, these words appear 'This person cannot be reached by iMessage at this time?  What does it mean?

  • Report Internal Error....

    Hi, I am tryint to develop a matrix group report. With One group at the top 1)(Customer Info) Inside the cross product group 1)And the Row Group (Resource Info) 2)And the Column Group (Period ) outside the cross product group. 1)Cell Info (Visit Info

  • Scalability of Materialized views

    Hi All, We are trying to replicate some tables (5 Tables)in our database from another Database. These tables are having data around 25 Million records each. I am planning to implement a Materialized view in our database pointing to source database an