1
|
/*******************************************************************************
|
2
|
* Copyright 2005, CHISEL Group, University of Victoria, Victoria, BC, Canada.
|
3
|
* All rights reserved. This program and the accompanying materials are made
|
4
|
* available under the terms of the Eclipse Public License v1.0 which
|
5
|
* accompanies this distribution, and is available at
|
6
|
* http://www.eclipse.org/legal/epl-v10.html
|
7
|
*
|
8
|
* Contributors: The Chisel Group, University of Victoria
|
9
|
*******************************************************************************/
|
10
|
package org.eclipse.zest.layouts.constraints;
|
11
|
|
12
|
/**
|
13
|
*
|
14
|
* @author Chris Bennett
|
15
|
*
|
16
|
*/
|
17
|
public class BasicEntityConstraint implements LayoutConstraint {
|
18
|
|
19
|
public boolean hasPreferredLocation = false;
|
20
|
|
21
|
public double preferredX;
|
22
|
public double preferredY;
|
23
|
|
24
|
public boolean hasPreferredSize = false;
|
25
|
public double preferredWidth;
|
26
|
public double preferredHeight;
|
27
|
|
28
|
public BasicEntityConstraint() {
|
29
|
clear();
|
30
|
}
|
31
|
|
32
|
/*
|
33
|
* (non-Javadoc)
|
34
|
* @see org.eclipse.zest.layouts.constraints.LayoutConstraint#clear()
|
35
|
*/
|
36
|
public void clear() {
|
37
|
this.hasPreferredLocation = false;
|
38
|
this.hasPreferredSize = false;
|
39
|
this.preferredX = 0.0;
|
40
|
this.preferredY = 0.0;
|
41
|
this.preferredWidth = 0.0;
|
42
|
this.preferredHeight = 0.0;
|
43
|
}
|
44
|
}
|