| 292 | } |
| 293 | |
| 294 | Rectangle<int> CtrlrComponent::getUsableRect() |
| 295 | { |
| 296 | Rectangle<int> r = Component::getLocalBounds(); |
| 297 | if ((bool)getProperty(Ids::componentLabelVisible) == false) |
| 298 | { |
| 299 | return (r); |
| 300 | } |
| 301 | |
| 302 | if (getProperty(Ids::componentLabelPosition) == Ids::top.toString()) |
| 303 | { |
| 304 | return (r.removeFromBottom(componentNameLabel.getHeight()).withTop(componentNameLabel.getHeight())); |
| 305 | } |
| 306 | |
| 307 | if (getProperty(Ids::componentLabelPosition) == Ids::bottom.toString()) |
| 308 | { |
| 309 | return (r.withHeight(r.getHeight()-componentNameLabel.getHeight())); |
| 310 | } |
| 311 | |
| 312 | if (getProperty(Ids::componentLabelPosition) == Ids::left.toString()) |
| 313 | { |
| 314 | return (r.withLeft (componentNameLabel.getWidth()).withWidth(r.getWidth() - componentNameLabel.getWidth())); |
| 315 | } |
| 316 | |
| 317 | if (getProperty(Ids::componentLabelPosition) == Ids::right.toString()) |
| 318 | { |
| 319 | r.removeFromRight (componentNameLabel.getWidth()); |
| 320 | return (r); |
| 321 | } |
| 322 | return (r); |
| 323 | } |
| 324 | |
| 325 | void CtrlrComponent::valueTreePropertyChanged (ValueTree &treeWhosePropertyHasChanged, const Identifier &property) |
| 326 | { |
nothing calls this directly
no test coverage detected