1 | package com.jsql.view.swing.action; | |
2 | ||
3 | import com.jsql.util.I18nUtil; | |
4 | import com.jsql.view.swing.util.MediatorHelper; | |
5 | import com.jsql.view.swing.util.UiUtil; | |
6 | ||
7 | import javax.swing.*; | |
8 | import java.awt.*; | |
9 | import java.awt.event.ActionEvent; | |
10 | ||
11 | public class ActionCloseTabResult extends AbstractAction { | |
12 | | |
13 | @Override | |
14 | public void actionPerformed(ActionEvent e) { | |
15 |
1
1. actionPerformed : removed call to com/jsql/view/swing/action/ActionCloseTabResult::perform → NO_COVERAGE |
ActionCloseTabResult.perform(MediatorHelper.tabResults().getSelectedIndex()); |
16 | } | |
17 | | |
18 | public static void perform(int closeTabNumber) { | |
19 |
2
1. perform : changed conditional boundary → NO_COVERAGE 2. perform : negated conditional → NO_COVERAGE |
if (MediatorHelper.tabResults().getTabCount() > 0) { |
20 |
1
1. perform : removed call to com/jsql/view/swing/tab/TabResults::removeTabAt → NO_COVERAGE |
MediatorHelper.tabResults().removeTabAt(closeTabNumber); |
21 | ||
22 |
1
1. perform : negated conditional → NO_COVERAGE |
if (MediatorHelper.tabResults().getTabCount() == 0) { |
23 | var splitPaneTopBottom = MediatorHelper.frame().getSplitNS(); | |
24 | JSplitPane splitPaneLeftRight = splitPaneTopBottom.getSplitEW(); | |
25 | int dividerLocation = splitPaneLeftRight.getDividerLocation(); | |
26 | ||
27 | var label = new JLabel(UiUtil.APP_BIG.getIcon()); | |
28 |
1
1. perform : removed call to javax/swing/JLabel::setMinimumSize → NO_COVERAGE |
label.setMinimumSize(new Dimension(100, 0)); |
29 |
1
1. perform : negated conditional → NO_COVERAGE |
if (ComponentOrientation.LEFT_TO_RIGHT.equals(ComponentOrientation.getOrientation(I18nUtil.getCurrentLocale()))) { |
30 |
1
1. perform : removed call to javax/swing/JSplitPane::setRightComponent → NO_COVERAGE |
splitPaneLeftRight.setRightComponent(label); |
31 | } else { | |
32 |
1
1. perform : removed call to javax/swing/JSplitPane::setLeftComponent → NO_COVERAGE |
splitPaneLeftRight.setLeftComponent(label); |
33 | } | |
34 | ||
35 |
1
1. perform : removed call to javax/swing/JSplitPane::setDividerLocation → NO_COVERAGE |
splitPaneLeftRight.setDividerLocation(dividerLocation); |
36 | } | |
37 | } | |
38 | } | |
39 | } | |
Mutations | ||
15 |
1.1 |
|
19 |
1.1 2.2 |
|
20 |
1.1 |
|
22 |
1.1 |
|
28 |
1.1 |
|
29 |
1.1 |
|
30 |
1.1 |
|
32 |
1.1 |
|
35 |
1.1 |