| 1199 | } |
| 1200 | |
| 1201 | ScriptCreatedComponentWrappers::ButtonWrapper::ButtonWrapper(ScriptContentComponent *content, ScriptingApi::Content::ScriptButton *sb, int index) : |
| 1202 | ScriptCreatedComponentWrapper(content, index) |
| 1203 | { |
| 1204 | HiToggleButton *b = new HiToggleButton(sb->name.toString()); |
| 1205 | |
| 1206 | b->addListener(this); |
| 1207 | |
| 1208 | b->setup(getProcessor(), getIndex(), sb->name.toString()); |
| 1209 | |
| 1210 | if (sb->getPopupData().isObject()) |
| 1211 | { |
| 1212 | auto r = sb->getPopupPosition(); |
| 1213 | b->setPopupData(sb->getPopupData(), r); |
| 1214 | } |
| 1215 | |
| 1216 | b->updateValue(dontSendNotification); |
| 1217 | |
| 1218 | |
| 1219 | component = b; |
| 1220 | |
| 1221 | initAllProperties(); |
| 1222 | |
| 1223 | MouseCursor cursor; |
| 1224 | if (setMouseCursorFromParentPanel(sb, cursor)) |
| 1225 | b->setMouseCursor(cursor); |
| 1226 | } |
| 1227 | |
| 1228 | |
| 1229 | ScriptCreatedComponentWrappers::ButtonWrapper::~ButtonWrapper() |
nothing calls this directly
no test coverage detected