MCPcopy Create free account
hub / github.com/SpartanJ/eepp / getPropertyString

Method getPropertyString

src/eepp/ui/uiscrollview.cpp:348–370  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

346}
347
348std::string UIScrollView::getPropertyString( const PropertyDefinition* propertyDef,
349 const Uint32& propertyIndex ) const {
350 if ( NULL == propertyDef )
351 return "";
352
353 switch ( propertyDef->getPropertyId() ) {
354 case PropertyId::VScrollMode:
355 return getVerticalScrollMode() == ScrollBarMode::Auto
356 ? "auto"
357 : ( getVerticalScrollMode() == ScrollBarMode::AlwaysOn ? "on" : "off" );
358 case PropertyId::HScrollMode:
359 return getHorizontalScrollMode() == ScrollBarMode::Auto
360 ? "auto"
361 : ( getHorizontalScrollMode() == ScrollBarMode::AlwaysOn ? "on" : "off" );
362 case PropertyId::ScrollBarStyle:
363 return mVScroll->getScrollBarType() == UIScrollBar::NoButtons ? "no-buttons"
364 : "two-buttons";
365 case PropertyId::ScrollBarMode:
366 return getViewType() == ScrollViewType::Overlay ? "overlay" : "outside";
367 default:
368 return UITouchDraggableWidget::getPropertyString( propertyDef, propertyIndex );
369 }
370}
371
372std::vector<PropertyId> UIScrollView::getPropertiesImplemented() const {
373 auto props = UITouchDraggableWidget::getPropertiesImplemented();

Callers

nothing calls this directly

Calls 2

getPropertyIdMethod · 0.80
getScrollBarTypeMethod · 0.80

Tested by

no test coverage detected