EMMA Coverage Report (generated Wed Feb 13 07:49:24 ICT 2008)
[all classes][net.sourceforge.hiveboard.view]

COVERAGE SUMMARY FOR SOURCE FILE [MattePainterManager.java]

nameclass, %method, %block, %line, %
MattePainterManager.java100% (1/1)100% (3/3)100% (44/44)100% (13/13)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class MattePainterManager100% (1/1)100% (3/3)100% (44/44)100% (13/13)
MattePainterManager (JComponent): void 100% (1/1)100% (16/16)100% (5/5)
createAnimator (FullScreenPrefs, String): Animator 100% (1/1)100% (23/23)100% (6/6)
paint (Graphics2D): void 100% (1/1)100% (5/5)100% (2/2)

1//  Copyright 2004-2007 Jean-Francois Poilpret
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7//     http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14 
15package net.sourceforge.hiveboard.view;
16 
17import java.awt.Graphics2D;
18 
19import javax.swing.JComponent;
20 
21import org.jdesktop.animation.timing.Animator;
22 
23public final class MattePainterManager extends AbstractMattePainter
24{
25        public MattePainterManager(JComponent pane)
26        {
27                setPane(pane);
28                // Initialize all painters
29                _scrollPainter = new ScrollingMattePainter();
30                _fixedPainter = new FixedMattePainter();
31        }
32 
33        @Override public Animator createAnimator(FullScreenPrefs prefs, String content)
34        {
35                if (prefs.isAutoScroll())
36                {
37                        _painter = _scrollPainter;
38                }
39                else
40                {
41                        _painter = _fixedPainter;
42                }
43                _painter.setPane(getPane());
44                return _painter.createAnimator(prefs, content);
45        }
46 
47        @Override public void paint(Graphics2D graf)
48        {
49                _painter.paint(graf);
50        }
51 
52        final private AbstractMattePainter        _scrollPainter;
53        final private AbstractMattePainter        _fixedPainter;
54 
55        private AbstractMattePainter                _painter;
56}

[all classes][net.sourceforge.hiveboard.view]
EMMA 2.0.5312 (C) Vladimir Roubtsov