Skip to content

Commit

Permalink
clean up TrackBase
Browse files Browse the repository at this point in the history
  • Loading branch information
turner committed Jan 15, 2025
1 parent 1c019bb commit ca8a2d2
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions js/trackBase.js
Original file line number Diff line number Diff line change
Expand Up @@ -538,7 +538,7 @@ class TrackBase {

menuItems.push('<hr/>')

function dialogPresentationHandler() {
const dialogPresentationHandler = () => {

if (this.trackView.track.selected) {
this.browser.dataRangeDialog.configure(this.trackView.browser.getSelectedTrackViews())
Expand All @@ -552,21 +552,21 @@ class TrackBase {

if (this.logScale !== undefined) {

function logScaleHandler() {
const logScaleHandler = () => {
this.logScale = !this.logScale
this.trackView.repaintViews()
}

menuItems.push({element: createCheckbox("Log scale", this.logScale), click: logScaleHandler})
}

function autoScaleHandler() {
const autoScaleHandler = () => {
this.autoscaleGroup = undefined
this.autoscale = !this.autoscale
this.browser.updateViews()
}

menuItems.push({element: createCheckbox("Log scale", this.logScale), click: autoScaleHandler})
menuItems.push({element: createCheckbox("Log scale", this.autoscale), click: autoScaleHandler})
}

return menuItems
Expand All @@ -584,6 +584,7 @@ class TrackBase {
* Return the first feature in this track whose start position is > position
* @param chr
* @param position
* @param direction
* @returns {Promise<void>}
*/
async nextFeatureAfter(chr, position, direction) {
Expand Down

0 comments on commit ca8a2d2

Please sign in to comment.