summaryrefslogtreecommitdiffstats
path: root/core/js/sharedialogview.js
diff options
context:
space:
mode:
authorVincent Petry <pvince81@owncloud.com>2015-10-02 16:35:33 +0200
committerVincent Petry <pvince81@owncloud.com>2015-10-02 16:39:27 +0200
commit1562da3691e69e5872a32e0582b3316aa3e16991 (patch)
treeed9337d8bfd1e0f19a6a4bb4565c24b9d9235d2a /core/js/sharedialogview.js
parentaf01c043601c31ba0f7b1f3f173d8bdc6f85295f (diff)
downloadnextcloud-server-1562da3691e69e5872a32e0582b3316aa3e16991.tar.gz
nextcloud-server-1562da3691e69e5872a32e0582b3316aa3e16991.zip
Focus on share field after first display
Diffstat (limited to 'core/js/sharedialogview.js')
-rw-r--r--core/js/sharedialogview.js9
1 files changed, 8 insertions, 1 deletions
diff --git a/core/js/sharedialogview.js b/core/js/sharedialogview.js
index ee31ed33132..7b02e6a3a50 100644
--- a/core/js/sharedialogview.js
+++ b/core/js/sharedialogview.js
@@ -174,12 +174,19 @@
// only show the loading spinner for the first request (for now)
if (!this._loadingOnce) {
this._toggleLoading(true);
- this._loadingOnce = true;
}
},
_onEndRequest: function() {
+ var self = this;
this._toggleLoading(false);
+ if (!this._loadingOnce) {
+ this._loadingOnce = true;
+ // the first time, focus on the share field after the spinner disappeared
+ _.defer(function() {
+ self.$('#shareWith').focus();
+ });
+ }
},
render: function() {