Skip to content

Commit

Permalink
LfpViewer: fix TTL toggle button
Browse files Browse the repository at this point in the history
  • Loading branch information
anjaldoshi committed Oct 14, 2024
1 parent 1451187 commit 541672b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
3 changes: 1 addition & 2 deletions Plugins/LfpViewer/EventDisplayInterface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ EventDisplayInterface::EventDisplayInterface (LfpDisplay* display_, LfpDisplaySp

chButton = std::make_unique<UtilityButton> (String (channelNumber + 1));
chButton->setRadius (5.0f);
chButton->setEnabledState (true);
chButton->addListener (this);
addAndMakeVisible (chButton.get());

Expand Down Expand Up @@ -65,7 +64,7 @@ void EventDisplayInterface::buttonClicked (Button* button)
display->setEventDisplayState (channelNumber, true);
}

chButton->setEnabledState (! isEnabled);
isEnabled = ! isEnabled;

repaint();
}
Expand Down
3 changes: 1 addition & 2 deletions Plugins/LfpViewer/EventDisplayInterface.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,9 @@ class EventDisplayInterface : public Component,
/** Checks whether events should be displayed for this channel*/
void checkEnabledState();

bool isEnabled;

private:
int channelNumber;
bool isEnabled;

LfpDisplay* display;
LfpDisplaySplitter* canvasSplit;
Expand Down

0 comments on commit 541672b

Please sign in to comment.