@@ -692,7 +692,7 @@ OSLToyMainWindow::OSLToyMainWindow(OSLToyRenderer* rend, int xr, int yr)
692692 control_area_layout->addWidget (restartButton);
693693
694694 searchPathEditor
695- = new OSLToySearchPathEditor (this , [this ](auto && paths) mutable {
695+ = new OSLToySearchPathEditor (this , [& ](auto && paths) mutable {
696696 update_include_search_paths (paths);
697697 });
698698
@@ -1052,7 +1052,7 @@ OSLToyMainWindow::timed_rerender_trigger(void)
10521052 m_working = 1 ;
10531053 renderer ()->set_time (now);
10541054 }
1055- trigger_pool.push ([= ](int ) { this ->osl_do_rerender (now); });
1055+ trigger_pool.push ([& ](int ) { this ->osl_do_rerender (now); });
10561056}
10571057
10581058
@@ -1300,10 +1300,10 @@ OSLToyMainWindow::make_param_adjustment_row(ParamRec* param,
13001300 diddleCheckbox->setCheckState (Qt::Checked);
13011301#if QT_VERSION >= QT_VERSION_CHECK(6, 8, 0)
13021302 connect (diddleCheckbox, &QCheckBox::checkStateChanged, this ,
1303- [= ](Qt::CheckState state) { set_param_diddle (param, int (state)); });
1303+ [& ](Qt::CheckState state) { set_param_diddle (param, int (state)); });
13041304#else
13051305 connect (diddleCheckbox, &QCheckBox::stateChanged, this ,
1306- [= ](int state) { set_param_diddle (param, state); });
1306+ [& ](int state) { set_param_diddle (param, state); });
13071307#endif
13081308 layout->addWidget (diddleCheckbox, row, 0 );
13091309
@@ -1332,7 +1332,7 @@ OSLToyMainWindow::make_param_adjustment_row(ParamRec* param,
13321332 layout->addWidget (adjustWidget, row, 2 );
13331333 param->widgets .push_back (adjustWidget);
13341334 connect<void (QSpinBox::*)(int )>(adjustWidget, &QSpinBox::valueChanged,
1335- this , [= ](int ) {
1335+ this , [& ](int ) {
13361336 set_param_instance_value (param);
13371337 });
13381338 } else if (param->type == TypeDesc::FLOAT) {
@@ -1341,7 +1341,7 @@ OSLToyMainWindow::make_param_adjustment_row(ParamRec* param,
13411341 param->widgets .push_back (adjustWidget);
13421342 connect<void (QDoubleSpinBox::*)(double )>(
13431343 adjustWidget, &QDoubleSpinBox::valueChanged, this ,
1344- [= ](double ) { set_param_instance_value (param); });
1344+ [& ](double ) { set_param_instance_value (param); });
13451345 } else if (param->type .is_vec3 ()) {
13461346 auto xyzBox = new QWidget;
13471347 auto xyzLayout = new QHBoxLayout;
@@ -1367,7 +1367,7 @@ OSLToyMainWindow::make_param_adjustment_row(ParamRec* param,
13671367 param->widgets .push_back (adjustWidget);
13681368 connect<void (QDoubleSpinBox::*)(double )>(
13691369 adjustWidget, &QDoubleSpinBox::valueChanged, this ,
1370- [= ](double ) { set_param_instance_value (param); });
1370+ [& ](double ) { set_param_instance_value (param); });
13711371 }
13721372 layout->addWidget (xyzBox, row, 2 );
13731373 } else if (param->type == TypeDesc::STRING) {
@@ -1376,12 +1376,12 @@ OSLToyMainWindow::make_param_adjustment_row(ParamRec* param,
13761376 layout->addWidget (adjustWidget, row, 2 );
13771377 param->widgets .push_back (adjustWidget);
13781378 connect (adjustWidget, &QLineEdit::returnPressed, this ,
1379- [= ]() { set_param_instance_value (param); });
1379+ [& ]() { set_param_instance_value (param); });
13801380 }
13811381
13821382 auto resetButton = new QPushButton (" Reset" );
13831383 connect (resetButton, &QPushButton::clicked, this ,
1384- [= ]() { reset_param_to_default (param); });
1384+ [& ]() { reset_param_to_default (param); });
13851385 layout->addWidget (resetButton, row, 3 );
13861386
13871387 set_ui_to_paramval (param);
0 commit comments