Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
View | Details | Raw Unified | Return to bug 251093 | Differences between
and this patch

Collapse All | Expand All

(-)src/org/eclipse/draw2d/ScalableLayeredPane.java (-2 / +9 lines)
Lines 1-5 Link Here
1
/*******************************************************************************
1
/*******************************************************************************
2
 * Copyright (c) 2000, 2005 IBM Corporation and others.
2
 * Copyright (c) 2000, 2010 IBM Corporation and others.
3
 * All rights reserved. This program and the accompanying materials
3
 * All rights reserved. This program and the accompanying materials
4
 * are made available under the terms of the Eclipse Public License v1.0
4
 * are made available under the terms of the Eclipse Public License v1.0
5
 * which accompanies this distribution, and is available at
5
 * which accompanies this distribution, and is available at
Lines 10-15 Link Here
10
 *******************************************************************************/
10
 *******************************************************************************/
11
package org.eclipse.draw2d;
11
package org.eclipse.draw2d;
12
12
13
import org.eclipse.swt.SWT;
14
13
import org.eclipse.draw2d.geometry.Dimension;
15
import org.eclipse.draw2d.geometry.Dimension;
14
import org.eclipse.draw2d.geometry.Rectangle;
16
import org.eclipse.draw2d.geometry.Rectangle;
15
import org.eclipse.draw2d.geometry.Translatable;
17
import org.eclipse.draw2d.geometry.Translatable;
Lines 42-48 Link Here
42
 * @see Figure#getPreferredSize(int, int)
44
 * @see Figure#getPreferredSize(int, int)
43
 */
45
 */
44
public Dimension getMinimumSize(int wHint, int hHint) {
46
public Dimension getMinimumSize(int wHint, int hHint) {
45
	Dimension d = super.getMinimumSize((int) (wHint / getScale()), (int)(hHint / getScale()));
47
		Dimension d = super
48
				.getMinimumSize(
49
						wHint != SWT.DEFAULT ? (int) (wHint / getScale())
50
								: SWT.DEFAULT,
51
						hHint != SWT.DEFAULT ? (int) (hHint / getScale())
52
								: SWT.DEFAULT);
46
	int w = getInsets().getWidth();
53
	int w = getInsets().getWidth();
47
	int h = getInsets().getHeight();
54
	int h = getInsets().getHeight();
48
	return d.getExpanded(-w, -h)
55
	return d.getExpanded(-w, -h)

Return to bug 251093