switchToTab method
Switch to a different tab and load its data
Implementation
void switchToTab(String tabName) {
if (tabs.contains(tabName)) {
// Save current tab data
saveCurrentTabData();
// Update screen reference
// Note: This would require updating the screen parameter, which might need a different approach
// For now, we'll just update the tabsJson and reload data
// Load the new tab's data
loadTabData(tabName);
}
}