Merge pull request #4106 from nextcloud/richDocumentsGrabFocus

Richdocuments: grab focus on resume
This commit is contained in:
Andy Scherzinger 2019-06-04 17:08:22 +02:00 committed by GitHub
commit 4e12a88e14
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -348,6 +348,14 @@ public class RichDocumentsWebView extends ExternalSiteWebView {
}
}
@Override
protected void onResume() {
super.onResume();
webview.evaluateJavascript("if (typeof OCA.RichDocuments.documentsMain.postGrabFocus !== 'undefined') " +
"{ OCA.RichDocuments.documentsMain.postGrabFocus(); }", null);
}
private class RichDocumentsMobileInterface {
@JavascriptInterface
public void close() {