Skip to content

Ticket 8067 switch instruments #1669

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,8 @@ public void widgetSelected(SelectionEvent e) {
}

private void resetChangeLabels() {
addChangeListeners();
updateChangeListeners();
addChangeListeners();
changeLabelsIfDifferentFromCachedValues();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
import uk.ac.stfc.isis.ibex.ui.dae.experimentsetup.periods.PeriodsViewModel;
import uk.ac.stfc.isis.ibex.ui.dae.experimentsetup.timechannels.TimeChannelsViewModel;


/**
* The view model that contains the logic for displaying how the experiment is
* set up on the DAE.
Expand Down Expand Up @@ -291,17 +292,17 @@ private Map<String, ArrayList<String>> getTableInstrumentCachedValues(String nam
}

/**
* Saves the current maps of cached values and loads the one related to the instrument that is being loaded.
*
* @param newInstrument
* The name of the instrument that is being loaded.
*/
public void switchInstrumentCachedValues(String newInstrument) {
setInstrumentCachedValues(currentInstrumentName);
cachedValues = getInstrumentCachedValues(newInstrument);
radioBtnsCachedValues = getRadioBtnsInstrumentCachedValues(newInstrument);
tableCachedValues = getTableInstrumentCachedValues(newInstrument);
currentInstrumentName = newInstrument;
}
* Saves the current maps of cached values and loads the one related to the
* instrument that is being loaded.
*
* @param newInstrument The name of the instrument that is being loaded.
*/
public void switchInstrumentCachedValues(String newInstrument) {
setInstrumentCachedValues(currentInstrumentName);
cachedValues = getInstrumentCachedValues(newInstrument);
radioBtnsCachedValues = getRadioBtnsInstrumentCachedValues(newInstrument);
tableCachedValues = getTableInstrumentCachedValues(newInstrument);
currentInstrumentName = newInstrument;

}
}
2 changes: 1 addition & 1 deletion script_definitions