Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 311526

Summary: ImportProjectSetAction should wrap importProjectSet in a WorkspaceModifyOp
Product: [Eclipse Project] Platform Reporter: James Blackburn <jamesblackburn+eclipse>
Component: TeamAssignee: Tomasz Zarna <tomasz.zarna>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 3.6   
Target Milestone: 3.7 M1   
Hardware: PC   
OS: All   
Whiteboard:
Bug Depends on: 321497    
Bug Blocks:    
Attachments:
Description Flags
patch 1 none

Description James Blackburn CLA 2010-05-04 08:24:51 EDT
Created attachment 166943 [details]
patch 1

The API usage on ProjectSetCapability#addToWorkspace(...) says:

	 * Callers from within a UI context should wrapper a call to this method
	 * inside a WorkspaceModifyOperation so that events generated as a result
	 * of this operation are deferred until the outermost operation
	 * has successfully completed.

Unfortunately ImportProjectSetAction doesn't do this leading to very many resource change events being fired during a project set checkout using this action. (The operation ImportProjectSetOperation accessible via the import dialog does the right thing -- it's a TeamOperation which runs checked into the workspace.)

Trivial patch attached.
Comment 1 Tomasz Zarna CLA 2010-05-17 08:36:37 EDT
Yup, it looks you're right. Thanks for the patch, I'll review it as soon as 3.6 is shipped.
Comment 2 James Blackburn CLA 2010-07-28 13:01:57 EDT
A polite ping on this :)
Comment 3 Tomasz Zarna CLA 2010-08-02 10:41:06 EDT
Fixed in HEAD. Thanks for the patch James. Available in builds >=I20100802-1300.