diff --git a/Common/onelab.h b/Common/onelab.h index 49b4e724c0d9f825b88cc381dfbc4129603e1ca5..38a83fa6fa4f4638054f1dd81b1aa21ddb51d863 100644 --- a/Common/onelab.h +++ b/Common/onelab.h @@ -618,11 +618,11 @@ namespace onelab{ typename std::set<T*, parameterLessThan>::iterator it = ps.find((T*)&p); if(it != ps.end()){ (*it)->update(p); - if(client.size()) (*it)->addClient(client, true); + if(client.size()) (*it)->addClient(client, parameter::defaultChangedValue()); } else{ T* newp = new T(p); - if(client.size()) newp->addClient(client, true); + if(client.size()) newp->addClient(client, parameter::defaultChangedValue()); ps.insert(newp); } return true; @@ -645,7 +645,7 @@ namespace onelab{ T tmp(name); typename std::set<T*, parameterLessThan>::iterator it = ps.find(&tmp); if(it != ps.end()){ - if(client.size()) (*it)->addClient(client, true); + if(client.size()) (*it)->addClient(client, parameter::defaultChangedValue()); p.push_back(**it); } } @@ -657,7 +657,7 @@ namespace onelab{ T tmp(name); typename std::set<T*, parameterLessThan>::iterator it = ps.find(&tmp); if(it != ps.end()){ - if(client.size()) (*it)->addClient(client, true); + if(client.size()) (*it)->addClient(client, parameter::defaultChangedValue()); return *it; } return NULL; diff --git a/Fltk/onelabGroup.cpp b/Fltk/onelabGroup.cpp index 8aef387ea5fa01bbe97d956c2a21dba58e300420..2fa71c1acbf5d2747fcdb6b8e2a38d35862fd4f8 100644 --- a/Fltk/onelabGroup.cpp +++ b/Fltk/onelabGroup.cpp @@ -177,8 +177,7 @@ void onelab_cb(Fl_Widget *w, void *data) if(action == "compute"){ // after computing with this solver, mark the parameters as unchanged // for this solver - onelab::server::instance()->setChanged(false, c->getName()); - + onelab::server::instance()->setChanged(0, c->getName()); FlGui::instance()->onelab->checkForErrors(c->getName()); } if(FlGui::instance()->onelab->stop()) break; diff --git a/contrib/mobile/drawContext.cpp b/contrib/mobile/drawContext.cpp index 09ecb16c1e45395364c26c0d9fd33ea9adb47c96..7163dc3454dc566a6c1acbdc773d8e8049b7d72d 100644 --- a/contrib/mobile/drawContext.cpp +++ b/contrib/mobile/drawContext.cpp @@ -76,7 +76,7 @@ void drawContext::load(std::string filename) onelab_cb("check"); // mark all parameters as changed to force complete first run - onelab::server::instance()->setChanged(true); + onelab::server::instance()->setChanged(3); } void drawContext::eventHandler(int event, float x, float y) diff --git a/contrib/mobile/iOS/Onelab/Parameter.mm b/contrib/mobile/iOS/Onelab/Parameter.mm index d78297a616df1ff33e9cc8ec92f02e7534d1efca..0a21300bb82bfcad7a22e264115f368787018e8e 100644 --- a/contrib/mobile/iOS/Onelab/Parameter.mm +++ b/contrib/mobile/iOS/Onelab/Parameter.mm @@ -39,7 +39,7 @@ -(void)editValue { - if(onelab_cb("check") == 1){ + if(onelab_cb("check") > 0){ [[NSNotificationCenter defaultCenter] postNotificationName:@"requestRender" object:nil]; [[NSNotificationCenter defaultCenter] postNotificationName:@"refreshParameters" object:nil]; } diff --git a/contrib/mobile/iOS/Onelab/ParametersViewController.mm b/contrib/mobile/iOS/Onelab/ParametersViewController.mm index 1f27ccaae57959aa435adad719e3d43d56913217..6afe39596863d4ea0e1b161240877c7ad8258142 100644 --- a/contrib/mobile/iOS/Onelab/ParametersViewController.mm +++ b/contrib/mobile/iOS/Onelab/ParametersViewController.mm @@ -103,7 +103,7 @@ double value = [[alertView textFieldAtIndex:0].text doubleValue]; number[0].setValue(value); onelab::server::instance()->set(number[0]); - if(onelab_cb("check") == 1){ + if(onelab_cb("check") > 0){ [[NSNotificationCenter defaultCenter] postNotificationName:@"requestRender" object:nil]; [[NSNotificationCenter defaultCenter] postNotificationName:@"refreshParameters" object:nil]; }