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

Method checkWidgetPick

src/eepp/ui/tools/uiwidgetinspector.cpp:186–201  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

184}
185
186void UIWidgetInspector::checkWidgetPick( UISceneNode* sceneNode, UITreeView* widgetTree,
187 bool wasHighlightOver, UITableView* tableView ) {
188 Input* input = sceneNode->getWindow()->getInput();
189 if ( input->getClickTrigger() & EE_BUTTON_LMASK ) {
190 Node* node = sceneNode->getEventDispatcher()->getMouseOverNode();
191 WidgetTreeModel* model = static_cast<WidgetTreeModel*>( widgetTree->getModel() );
192 ModelIndex index( model->getModelIndex( node ) );
193 widgetTree->setSelection( index );
194 sceneNode->setHighlightOver( wasHighlightOver );
195 sceneNode->getEventDispatcher()->setDisableMousePress( false );
196 } else {
197 sceneNode->runOnMainThread( [sceneNode, widgetTree, wasHighlightOver, tableView]() {
198 checkWidgetPick( sceneNode, widgetTree, wasHighlightOver, tableView );
199 } );
200 }
201}
202
203}}} // namespace EE::UI::Tools

Callers

nothing calls this directly

Calls 10

getMouseOverNodeMethod · 0.80
getModelIndexMethod · 0.80
setHighlightOverMethod · 0.80
setDisableMousePressMethod · 0.80
runOnMainThreadMethod · 0.80
getInputMethod · 0.45
getWindowMethod · 0.45
getEventDispatcherMethod · 0.45
getModelMethod · 0.45
setSelectionMethod · 0.45

Tested by

no test coverage detected