Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 59522 - CoolBar.setLocked(true) has no effect if set before coolitems created
Summary: CoolBar.setLocked(true) has no effect if set before coolitems created
Status: RESOLVED DUPLICATE of bug 14330
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 3.0   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform-SWT-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-04-21 16:47 EDT by Michael Van Meekeren CLA
Modified: 2004-04-21 18:17 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Van Meekeren CLA 2004-04-21 16:47:57 EDT
It seems that calling setLocked() too early will have no effect on locking the 
toolbar.

see VI for an example but here is a snippet of code that has this problem

		final CoolBar coolbar2 = new CoolBar(banner, SWT.FLAT);

	>>>>>>	coolbar2.setLocked(true);
		
		coolbar2.setBackground(banner.getDisplay().getSystemColor
(SWT.COLOR_WIDGET_BACKGROUND));
		CBannerTest.coolBar = coolbar2;
		
		banner.setRight(coolbar2);
		
		final ToolBar toolBar2 = new ToolBar(coolbar2, SWT.FLAT | 
SWT.RIGHT | SWT.WRAP);
		
		ToolItem toolItem2 = new ToolItem(toolBar2, SWT.RADIO);
		toolItem2.setText("Open");
		toolItem2.setImage(smallImage4);
		toolItem2 = new ToolItem(toolBar2, SWT.RADIO);
		toolItem2.setText("Java");
		toolItem2.setImage(smallImage1);
		toolItem2 = new ToolItem(toolBar2, SWT.RADIO);
		toolItem2.setText("CVS Repository");
		toolItem2.setImage(smallImage2);
		toolItem2 = new ToolItem(toolBar2, SWT.RADIO);
		toolItem2.setText("Synchronize");
		toolItem2.setImage(smallImage3);
		
		final CoolItem coolItem2 = new CoolItem(coolbar2, 
SWT.DROP_DOWN);
		coolItem2.setControl(toolBar2);
Comment 1 Grant Gayed CLA 2004-04-21 18:17:50 EDT

*** This bug has been marked as a duplicate of 14330 ***