ActionHideShowResult.java

1
package com.jsql.view.swing.panel.split;
2
3
import com.jsql.view.swing.util.MediatorHelper;
4
5
import java.awt.event.ActionEvent;
6
import java.awt.event.ActionListener;
7
8
/**
9
 * MouseAdapter to show/hide bottom panel.
10
 */
11
public class ActionHideShowResult implements ActionListener {
12
    
13
    /**
14
     * Hide bottom panel if both main and bottom are visible, also
15
     * displays an ersatz bar replacing tabbedpane.
16
     * Or else if only main panel is visible then displays bottom panel
17
     * and hide ersatz panel.
18
     */
19
    @Override
20
    public void actionPerformed(ActionEvent e) {
21
        
22
        var splitHorizontalTopBottom = MediatorHelper.frame().getSplitHorizontalTopBottom();
23
        
24
        if (
25 1 1. actionPerformed : negated conditional → NO_COVERAGE
            splitHorizontalTopBottom.getTopComponent().isVisible()
26 1 1. actionPerformed : negated conditional → NO_COVERAGE
            && splitHorizontalTopBottom.getBottomComponent().isVisible()
27
        ) {
28
            
29 1 1. actionPerformed : removed call to com/jsql/view/swing/panel/PanelConsoles::setDividerLocation → NO_COVERAGE
            MediatorHelper.panelConsoles().setDividerLocation(splitHorizontalTopBottom.getDividerLocation());
30 1 1. actionPerformed : removed call to java/awt/Component::setVisible → NO_COVERAGE
            splitHorizontalTopBottom.getTopComponent().setVisible(false);
31 1 1. actionPerformed : removed call to com/jsql/view/swing/panel/split/SplitHorizontalTopBottom::disableDragSize → NO_COVERAGE
            splitHorizontalTopBottom.disableDragSize();
32 1 1. actionPerformed : removed call to javax/swing/plaf/basic/BasicArrowButton::setVisible → NO_COVERAGE
            MediatorHelper.panelConsoles().getButtonShowNorth().setVisible(false);
33
            
34
        } else if (
35 1 1. actionPerformed : negated conditional → NO_COVERAGE
            splitHorizontalTopBottom.getTopComponent().isVisible()
36 1 1. actionPerformed : negated conditional → NO_COVERAGE
            && !splitHorizontalTopBottom.getBottomComponent().isVisible()
37
        ) {
38
            
39 1 1. actionPerformed : removed call to com/jsql/view/swing/panel/split/SplitHorizontalTopBottom::setDividerLocation → NO_COVERAGE
            splitHorizontalTopBottom.setDividerLocation(MediatorHelper.panelConsoles().getDividerLocation());
40 1 1. actionPerformed : removed call to java/awt/Component::setVisible → NO_COVERAGE
            splitHorizontalTopBottom.getBottomComponent().setVisible(true);
41 1 1. actionPerformed : removed call to java/awt/Component::setVisible → NO_COVERAGE
            splitHorizontalTopBottom.getTopComponent().setVisible(true);
42 1 1. actionPerformed : removed call to com/jsql/view/swing/panel/split/SplitHorizontalTopBottom::enableDragSize → NO_COVERAGE
            splitHorizontalTopBottom.enableDragSize();
43
        }
44
    }
45
}

Mutations

25

1.1
Location : actionPerformed
Killed by : none
negated conditional → NO_COVERAGE

26

1.1
Location : actionPerformed
Killed by : none
negated conditional → NO_COVERAGE

29

1.1
Location : actionPerformed
Killed by : none
removed call to com/jsql/view/swing/panel/PanelConsoles::setDividerLocation → NO_COVERAGE

30

1.1
Location : actionPerformed
Killed by : none
removed call to java/awt/Component::setVisible → NO_COVERAGE

31

1.1
Location : actionPerformed
Killed by : none
removed call to com/jsql/view/swing/panel/split/SplitHorizontalTopBottom::disableDragSize → NO_COVERAGE

32

1.1
Location : actionPerformed
Killed by : none
removed call to javax/swing/plaf/basic/BasicArrowButton::setVisible → NO_COVERAGE

35

1.1
Location : actionPerformed
Killed by : none
negated conditional → NO_COVERAGE

36

1.1
Location : actionPerformed
Killed by : none
negated conditional → NO_COVERAGE

39

1.1
Location : actionPerformed
Killed by : none
removed call to com/jsql/view/swing/panel/split/SplitHorizontalTopBottom::setDividerLocation → NO_COVERAGE

40

1.1
Location : actionPerformed
Killed by : none
removed call to java/awt/Component::setVisible → NO_COVERAGE

41

1.1
Location : actionPerformed
Killed by : none
removed call to java/awt/Component::setVisible → NO_COVERAGE

42

1.1
Location : actionPerformed
Killed by : none
removed call to com/jsql/view/swing/panel/split/SplitHorizontalTopBottom::enableDragSize → NO_COVERAGE

Active mutators

Tests examined


Report generated by PIT 1.16.1