Bug 145736

Summary: [patch] Input dialog could use a combo for multi choice input request
Product: [Eclipse Project] Platform Reporter: Brock Janiczak <brockj>
Component: AntAssignee: Kevin Barnes <cocoakevin>
Status: RESOLVED FIXED QA Contact:
Severity: enhancement    
Priority: P3 CC: Darin_Swanson, xavier.mehaut
Version: 3.2Keywords: contributed
Target Milestone: 3.3 M2   
Hardware: All   
OS: All   
Whiteboard:
Attachments:
Description Flags
patch to org.eclipse.ant.ui none

Description Brock Janiczak CLA 2006-06-07 06:28:45 EDT
Version: 3.2.0
Build id: I20060519-1206

The current SWTInputHandler is a direct copy of the default handler supplied by ANT.  When you specify the validargs attribute on the Input task, the dialog will only allow you to type in one of the valid args.  Because it will only accept these valid values, it makes sense to present all of the options to the user in a combo and have them pick one.

Attached is a patch to org.eclipse.ant.ui that adds this behaviour.

While implementing this feature, i ran across something interesting about the input task.  You can specify a default value, but it will never be used for the multi choice case, as it doesn't allow you to select null or empty.  If this is ever fixed in ant, this input handler shouldn't require any extra changes.
Comment 1 Brock Janiczak CLA 2006-06-07 06:31:34 EDT
Created attachment 43701 [details]
patch to org.eclipse.ant.ui

Patch to add combo for multi choice input requests
Comment 2 Darin Swanson CLA 2006-06-07 10:34:15 EDT
Thanks Brock.
Consider in 3.3.
Comment 3 Darin Swanson CLA 2006-06-07 10:35:22 EDT
*** Bug 33832 has been marked as a duplicate of this bug. ***
Comment 4 Darin Swanson CLA 2006-09-14 10:42:14 EDT
Tested and released the changes.
Comment 5 Darin Swanson CLA 2006-09-14 10:42:38 EDT
Please verify Kevin.