Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 337407 - [Table] TableItem has negative image width on "0"-width TableColumn
Summary: [Table] TableItem has negative image width on "0"-width TableColumn
Status: RESOLVED FIXED
Alias: None
Product: RAP
Classification: RT
Component: RWT (show other bugs)
Version: 1.4   Edit
Hardware: All All
: P2 minor (vote)
Target Milestone: 1.4 M7   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-02-17 05:23 EST by Tiber Sept CLA
Modified: 2011-03-16 06:38 EDT (History)
1 user (show)

See Also:


Attachments
Patch checks for negative maxImageWidth in TableLCAUtil.getItemMetrics (1.01 KB, patch)
2011-02-17 05:29 EST, Tiber Sept CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Tiber Sept CLA 2011-02-17 05:23:47 EST
Build Identifier: 20100617-1415

Setting the width of a TableColumn to 0 leads to a negative value for the image width, which is transferred to client as part of the item metrics. This in turn either crashes the application (IE) or leaves the image visible because the width value is not accepted.

Reproducible: Always

Steps to Reproduce:
1. Provide the means to set the width of a TableColumn to 0 (e.g. a button)
2. Initially the width of the target column is > 0
3. The target column should contain images
4. Set the width of the target column to 0 by selecting the button
Comment 1 Tiber Sept CLA 2011-02-17 05:29:48 EST
Created attachment 189161 [details]
Patch checks for negative maxImageWidth in TableLCAUtil.getItemMetrics
Comment 2 Ivan Furnadjiev CLA 2011-03-16 06:38:31 EDT
Fixed by ensure that the image width is not negative in TableLCAUtil#getItemMetrics(). Changes are in CVS HEAD.