mirror of https://github.com/rusefi/RomRaider.git
Added a button to the left margin of each tabbed pane for quick access to the Learning Table Values dialog (handy on touch screens).
This commit is contained in:
parent
ae9b6f8fbb
commit
110b4e2a32
|
@ -165,6 +165,7 @@ import com.romraider.logger.ecu.ui.paramlist.ParameterRow;
|
||||||
import com.romraider.logger.ecu.ui.playback.PlaybackManagerImpl;
|
import com.romraider.logger.ecu.ui.playback.PlaybackManagerImpl;
|
||||||
import com.romraider.logger.ecu.ui.swing.layout.BetterFlowLayout;
|
import com.romraider.logger.ecu.ui.swing.layout.BetterFlowLayout;
|
||||||
import com.romraider.logger.ecu.ui.swing.menubar.EcuLoggerMenuBar;
|
import com.romraider.logger.ecu.ui.swing.menubar.EcuLoggerMenuBar;
|
||||||
|
import com.romraider.logger.ecu.ui.swing.menubar.action.LearningTableValuesAction;
|
||||||
import com.romraider.logger.ecu.ui.swing.menubar.action.LogFileNameFieldAction;
|
import com.romraider.logger.ecu.ui.swing.menubar.action.LogFileNameFieldAction;
|
||||||
import com.romraider.logger.ecu.ui.swing.menubar.action.ToggleButtonAction;
|
import com.romraider.logger.ecu.ui.swing.menubar.action.ToggleButtonAction;
|
||||||
import com.romraider.logger.ecu.ui.swing.vertical.VerticalTextIcon;
|
import com.romraider.logger.ecu.ui.swing.vertical.VerticalTextIcon;
|
||||||
|
@ -856,9 +857,37 @@ public final class EcuLogger extends AbstractFrame implements MessageListener {
|
||||||
}
|
}
|
||||||
|
|
||||||
private JComponent buildTabbedPane() {
|
private JComponent buildTabbedPane() {
|
||||||
addSplitPaneTab("Data", buildSplitPane(buildParamListPane(dataTabParamListTableModel, dataTabSwitchListTableModel, dataTabExternalListTableModel), buildDataTab()), buildUnselectAllButton());
|
addSplitPaneTab(
|
||||||
addSplitPaneTab("Graph", buildSplitPane(buildParamListPane(graphTabParamListTableModel, graphTabSwitchListTableModel, graphTabExternalListTableModel), buildGraphTab()), buildUnselectAllButton());
|
"Data",
|
||||||
addSplitPaneTab("Dashboard", buildSplitPane(buildParamListPane(dashboardTabParamListTableModel, dashboardTabSwitchListTableModel, dashboardTabExternalListTableModel), buildDashboardTab()), buildUnselectAllButton(), buildToggleGaugeStyleButton());
|
buildSplitPane(
|
||||||
|
buildParamListPane(
|
||||||
|
dataTabParamListTableModel,
|
||||||
|
dataTabSwitchListTableModel,
|
||||||
|
dataTabExternalListTableModel),
|
||||||
|
buildDataTab()),
|
||||||
|
buildUnselectAllButton(),
|
||||||
|
buildLtvButton());
|
||||||
|
addSplitPaneTab(
|
||||||
|
"Graph",
|
||||||
|
buildSplitPane(
|
||||||
|
buildParamListPane(
|
||||||
|
graphTabParamListTableModel,
|
||||||
|
graphTabSwitchListTableModel,
|
||||||
|
graphTabExternalListTableModel),
|
||||||
|
buildGraphTab()),
|
||||||
|
buildUnselectAllButton(),
|
||||||
|
buildLtvButton());
|
||||||
|
addSplitPaneTab(
|
||||||
|
"Dashboard",
|
||||||
|
buildSplitPane(
|
||||||
|
buildParamListPane(
|
||||||
|
dashboardTabParamListTableModel,
|
||||||
|
dashboardTabSwitchListTableModel,
|
||||||
|
dashboardTabExternalListTableModel),
|
||||||
|
buildDashboardTab()),
|
||||||
|
buildUnselectAllButton(),
|
||||||
|
buildLtvButton(),
|
||||||
|
buildToggleGaugeStyleButton());
|
||||||
tabbedPane.add("MAF", mafTab.getPanel());
|
tabbedPane.add("MAF", mafTab.getPanel());
|
||||||
tabbedPane.add("Injector", injectorTab.getPanel());
|
tabbedPane.add("Injector", injectorTab.getPanel());
|
||||||
tabbedPane.add("Dyno", dynoTab.getPanel());
|
tabbedPane.add("Dyno", dynoTab.getPanel());
|
||||||
|
@ -945,6 +974,16 @@ public final class EcuLogger extends AbstractFrame implements MessageListener {
|
||||||
return button;
|
return button;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private JButton buildLtvButton() {
|
||||||
|
final JButton button = new JButton();
|
||||||
|
VerticalTextIcon textIcon =
|
||||||
|
new VerticalTextIcon(button, "Learning Values", ROTATE_LEFT);
|
||||||
|
button.setIcon(textIcon);
|
||||||
|
button.setPreferredSize(new Dimension(25, 90));
|
||||||
|
button.addActionListener(new LearningTableValuesAction(this));
|
||||||
|
return button;
|
||||||
|
}
|
||||||
|
|
||||||
private void addSplitPaneTab(String name, final JSplitPane splitPane, JComponent... extraControls) {
|
private void addSplitPaneTab(String name, final JSplitPane splitPane, JComponent... extraControls) {
|
||||||
final JToggleButton toggleListButton = new JToggleButton();
|
final JToggleButton toggleListButton = new JToggleButton();
|
||||||
toggleListButton.setToolTipText(TOGGLE_LIST_TT_TEXT);
|
toggleListButton.setToolTipText(TOGGLE_LIST_TT_TEXT);
|
||||||
|
|
Loading…
Reference in New Issue