comparison flys-client/src/main/java/de/intevation/flys/client/client/ui/FLYSWorkspace.java @ 3522:6eeacd0bbe26

New projects are now maximized by default. flys-client/trunk@5321 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Christian Lins <christian.lins@intevation.de>
date Thu, 30 Aug 2012 20:54:14 +0000
parents fe23bbf0ea11
children 6a8f83c538e3
comparison
equal deleted inserted replaced
3521:ffbdd093da74 3522:6eeacd0bbe26
27 * The default constructor creates an empty FLYSWorkspace with no 27 * The default constructor creates an empty FLYSWorkspace with no
28 * CollectionViews opened. 28 * CollectionViews opened.
29 */ 29 */
30 public FLYSWorkspace() { 30 public FLYSWorkspace() {
31 views = new HashMap<String, CollectionView>(); 31 views = new HashMap<String, CollectionView>();
32
33 setWidth("100%");
34 setHeight("100%");
32 } 35 }
33 36
34 37
35 /** 38 /**
36 * This method adds a new CollectionView to this workspace and stores a 39 * This method adds a new CollectionView to this workspace and stores a
37 * reference in {@link views}. 40 * reference in {@link views}.
38 * 41 *
39 * @param collectionView A new CollectionView. 42 * @param collectionView A new CollectionView.
40 */ 43 */
41 public void addView(String uuid, CollectionView collectionView) { 44 public void addView(String uuid, CollectionView collectionView) {
42 int num = views != null ? views.size() : 0; 45 collectionView.moveTo(0, 0);
43 int factor = num % MAX_WINDOWS; 46 collectionView.setMaximized(true);
44
45 collectionView.moveTo(factor * WINDOW_OFFSET, factor * WINDOW_OFFSET);
46 47
47 views.put(uuid, collectionView); 48 views.put(uuid, collectionView);
48 addChild(collectionView); 49 addChild(collectionView);
49 } 50 }
50 51

http://dive4elements.wald.intevation.org