Bug 329577 - [editor] provide attribute editor for integer and double task attribute types
Summary: [editor] provide attribute editor for integer and double task attribute types
Status: RESOLVED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Mylyn (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows 7
: P3 enhancement (vote)
Target Milestone: 3.5   Edit
Assignee: Thomas Ehrnhoefer CLA
QA Contact:
URL:
Whiteboard:
Keywords: contributed
Depends on: 332328
Blocks: 329664
  Show dependency tree
 
Reported: 2010-11-05 14:18 EDT by Thomas Ehrnhoefer CLA
Modified: 2011-01-13 23:31 EST (History)
4 users (show)

See Also:


Attachments
patch v1 (7.47 KB, patch)
2010-12-09 19:18 EST, Thomas Ehrnhoefer CLA
no flags Details | Diff
mylyn/context/zip (31.83 KB, application/octet-stream)
2010-12-09 19:18 EST, Thomas Ehrnhoefer CLA
no flags Details
patch v2 (depends on bug 332328) (9.52 KB, patch)
2010-12-10 13:46 EST, Thomas Ehrnhoefer CLA
steffen.pingel: iplog+
thomas.ehrnhoefer: review?
Details | Diff
mylyn/context/zip (2.29 KB, application/octet-stream)
2010-12-10 13:46 EST, Thomas Ehrnhoefer CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Thomas Ehrnhoefer CLA 2010-11-05 14:18:26 EDT
Potentially add input validation with decorator.
Comment 1 Thomas Ehrnhoefer CLA 2010-12-09 19:18:53 EST
Created attachment 184916 [details]
patch v1

First try on an attribute editor along with a suggested integration in the framework
Let me know what you think of that Steffen
Comment 2 Thomas Ehrnhoefer CLA 2010-12-09 19:18:55 EST
Created attachment 184917 [details]
mylyn/context/zip
Comment 3 Steffen Pingel CLA 2010-12-10 13:14:05 EST
Thanks Thomas. This looks promising. I have opened bug 332328 to track the API portion of the change. Once that is resolved I am happy to apply a patch based on the new API.
Comment 4 Thomas Ehrnhoefer CLA 2010-12-10 13:46:06 EST
Created attachment 184978 [details]
patch v2 (depends on bug 332328)

(depends on bug 332328)

includes fix for bug 329575 as well
Comment 5 Thomas Ehrnhoefer CLA 2010-12-10 13:46:07 EST
Created attachment 184979 [details]
mylyn/context/zip
Comment 6 Steffen Pingel CLA 2010-12-10 14:19:01 EST
Committed as part of bug 329575.

*** This bug has been marked as a duplicate of bug 329575 ***
Comment 7 Steffen Pingel CLA 2010-12-10 14:30:03 EST
On further review this needs a little bit more work. Values should be retrieved and modified through TaskAttributeMapper. 

I have added methods to support attributes of type double. Can you make the corresponding changes to the patch? You can use BooleanAttributeEditor.get/setValue() as a guideline.
Comment 8 Steffen Pingel CLA 2010-12-10 14:43:37 EST
On second thought, let's go with this patch. Otherwise, invalid value would be discarded on save. We might need to reconsider the current design in the future but generally I believe it's better to allow entering of invalid values and handle this on submit (bug 242430).