eepp: Improved default click step for scrollable widgets.

ecode: Never block main thread when sending messages to an LSP.
Ctrl/Cmd + Alt + Click -> now executes "Go to definition".
Improved modifier keys when used in combination with mouse clicks.
This commit is contained in:
Martín Lucas Golini
2023-03-03 03:33:30 -03:00
parent 8e1c33ff7d
commit 235e66d6ad
12 changed files with 162 additions and 134 deletions

View File

@@ -274,15 +274,19 @@ void UniversalLocator::initLocateBar( UILocateBar* locateBar, UITextInput* locat
ModelIndex idx(
modelEvent->getModel()->index( modelEvent->getModelIndex().row(), 2 ) );
if ( idx.isValid() ) {
auto cmd = modelEvent->getModel()->data( idx, ModelRole::Display ).toString();
String cmd = modelEvent->getModel()->data( idx, ModelRole::Display ).toString();
mApp->runCommand( cmd );
if ( !mSplitter->getCurWidget()->isType( UI_TYPE_TERMINAL ) ) {
if ( mSplitter->curEditorIsNotNull() &&
mSplitter->getCurEditor()->getDocument().hasCommand( cmd ) )
mSplitter->getCurEditor()->setFocus();
}
if ( cmd != "open-locatebar" ) {
hideLocateBar();
} else {
mLocateInput->setFocus();
}
}
hideLocateBar();
} else {
Variant vName( modelEvent->getModel()->data(
modelEvent->getModel()->index( modelEvent->getModelIndex().row(), 0 ),