Lines 41-50
Link Here
|
41 |
|
41 |
|
42 |
package org.netbeans.core.windows.model; |
42 |
package org.netbeans.core.windows.model; |
43 |
|
43 |
|
|
|
44 |
import java.util.AbstractMap; |
44 |
import java.util.Collections; |
45 |
import java.util.Collections; |
45 |
import java.util.HashMap; |
46 |
import java.util.HashMap; |
46 |
import java.util.Iterator; |
47 |
import java.util.Iterator; |
47 |
import java.util.Map; |
48 |
import java.util.Map; |
|
|
49 |
import java.util.Map.Entry; |
48 |
import org.netbeans.core.windows.Constants; |
50 |
import org.netbeans.core.windows.Constants; |
49 |
import org.netbeans.core.windows.ModeImpl; |
51 |
import org.netbeans.core.windows.ModeImpl; |
50 |
import org.netbeans.core.windows.ModeStructureSnapshot; |
52 |
import org.netbeans.core.windows.ModeStructureSnapshot; |
Lines 384-392
Link Here
|
384 |
Set<ModeStructureSnapshot.SlidingModeSnapshot> result = |
386 |
Set<ModeStructureSnapshot.SlidingModeSnapshot> result = |
385 |
new HashSet<ModeStructureSnapshot.SlidingModeSnapshot>(); |
387 |
new HashSet<ModeStructureSnapshot.SlidingModeSnapshot>(); |
386 |
for (Map.Entry<ModeImpl, String> curEntry: slidingModes2Sides.entrySet()) { |
388 |
for (Map.Entry<ModeImpl, String> curEntry: slidingModes2Sides.entrySet()) { |
|
|
389 |
final ModeImpl key = curEntry.getKey(); |
390 |
AbstractMap<TopComponent, Integer> lazy = new AbstractMap<TopComponent, Integer>() { |
391 |
Map<TopComponent, Integer> delegate; |
392 |
@Override |
393 |
public Set<Entry<TopComponent, Integer>> entrySet() { |
394 |
if (delegate == null) { |
395 |
delegate = getSlideInSizes(key); |
396 |
} |
397 |
return delegate.entrySet(); |
398 |
} |
399 |
}; |
400 |
|
387 |
result.add(new ModeStructureSnapshot.SlidingModeSnapshot( |
401 |
result.add(new ModeStructureSnapshot.SlidingModeSnapshot( |
388 |
curEntry.getKey(), curEntry.getValue(), |
402 |
curEntry.getKey(), curEntry.getValue(), lazy |
389 |
getSlideInSizes(curEntry.getKey()))); |
403 |
)); |
390 |
} |
404 |
} |
391 |
|
405 |
|
392 |
return result; |
406 |
return result; |