Open AlphaWHH opened 4 months ago
Start with preset is set to any option in the config, the 'New Tab From Preset':1Terminal should open a single terminal.
In any configuration the 'New Tab From Preset':1Terminal will open the selected option in the config under start with preset.
Current code Mainwindow.cpp line 363-364 presetsMenu->addAction(QIcon(), tr("1 &Terminal"), this, SLOT(addNewTab()));
PROBLEM AREA: Line 879 void MainWindow::addNewTab(TerminalConfig cfg) { if (Properties::Instance()->terminalsPreset == 3) consoleTabulator->preset4Terminals(); else if (Properties::Instance()->terminalsPreset == 2) consoleTabulator->preset2Vertical(); else if (Properties::Instance()->terminalsPreset == 1) consoleTabulator->preset2Horizontal(); else consoleTabulator->addNewTab(cfg); // disabled actions are updated by TabWidget::onCurrentChanged() } PROPOSED SOLUTION: Mainwindow.cpp line 363-364 presetsMenu->addAction(QIcon(), tr("1 &Terminal"), this, SLOT(consoleTabulator->addNewTab(cfg);));
Expected Behavior
Start with preset is set to any option in the config, the 'New Tab From Preset':1Terminal should open a single terminal.
Current Behavior
In any configuration the 'New Tab From Preset':1Terminal will open the selected option in the config under start with preset.
Steps to Reproduce (for bugs)
Possible Solution
Current code Mainwindow.cpp line 363-364 presetsMenu->addAction(QIcon(), tr("1 &Terminal"), this, SLOT(addNewTab()));
PROBLEM AREA: Line 879 void MainWindow::addNewTab(TerminalConfig cfg) { if (Properties::Instance()->terminalsPreset == 3) consoleTabulator->preset4Terminals(); else if (Properties::Instance()->terminalsPreset == 2) consoleTabulator->preset2Vertical(); else if (Properties::Instance()->terminalsPreset == 1) consoleTabulator->preset2Horizontal(); else consoleTabulator->addNewTab(cfg); // disabled actions are updated by TabWidget::onCurrentChanged() } PROPOSED SOLUTION: Mainwindow.cpp line 363-364 presetsMenu->addAction(QIcon(), tr("1 &Terminal"), this, SLOT(consoleTabulator->addNewTab(cfg);));