Skip to content
Snippets Groups Projects
Commit d0113186 authored by Michael Borisov's avatar Michael Borisov
Browse files

Merge branch 'master' of https://github.com/open-ephys/GUI.git

parents d5321bf5 c8f77dce
No related branches found
No related tags found
No related merge requests found
......@@ -848,6 +848,7 @@ void ChannelMappingEditor::mouseUp(const MouseEvent& e)
setChannelPosition(i,electrodeButtons[i]->getChannelNum());
}
setConfigured(true);
getEditorViewport()->makeEditorVisible(this, false, true);
}
}
......
......@@ -68,6 +68,25 @@ void ChannelMappingNode::updateSettings()
if (getNumInputs() > 0)
channelBuffer.setSize(getNumInputs(), 10000);
previousChannelCount = getNumInputs();
if (editorIsConfigured)
{
OwnedArray<Channel> tempArray;
channels.swapWith(tempArray);
j=0;
for (int i=0; i < getNumInputs(); i++)
{
int realChan = channelArray[i];
if (enabledChannelArray[realChan])
{
channels.add(tempArray[realChan]);
j++;
}
}
tempArray.clear(false);
settings.numOutputs=j;
}
/*
if (getNumInputs() != previousChannelCount)
{
previousChannelCount = getNumInputs();
......@@ -103,7 +122,7 @@ void ChannelMappingNode::updateSettings()
}
}
settings.numOutputs=j;
}
}*/
}
......
......@@ -329,6 +329,15 @@ void LfpDisplayCanvas::update()
resized();
}
else
{
for (int i = 0; i < processor->getNumInputs(); i++)
{
lfpDisplay->channels[i]->updateType();
lfpDisplay->channelInfo[i]->updateType();
}
}
}
......@@ -1538,6 +1547,12 @@ LfpChannelDisplay::~LfpChannelDisplay()
}
void LfpChannelDisplay::updateType()
{
type = canvas->getChannelType(chan);
typeStr = canvas->getTypeName(type);
}
void LfpChannelDisplay::setEnabledState(bool state)
{
......@@ -1848,6 +1863,13 @@ LfpChannelDisplayInfo::LfpChannelDisplayInfo(LfpDisplayCanvas* canvas_, LfpDispl
}
void LfpChannelDisplayInfo::updateType()
{
type = canvas->getChannelType(chan);
typeStr = canvas->getTypeName(type);
repaint();
}
void LfpChannelDisplayInfo::buttonClicked(Button* button)
{
......
......@@ -314,6 +314,7 @@ public:
}
channelType getType();
void updateType();
bool fullredraw; // used to indicate that a full redraw is required. is set false after each full redraw
......@@ -361,6 +362,7 @@ public:
void resized();
void setEnabledState(bool);
void updateType();
private:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment