summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVincent Petry <pvince81@owncloud.com>2014-07-07 15:57:26 +0200
committerVincent Petry <pvince81@owncloud.com>2014-07-07 15:57:26 +0200
commit130b8018a1193a9a21b359dd5dfb249efe0a16da (patch)
tree68ba9302fb54b53f54c30b0e98cc8ebcf702434d
parent71fe5d672e516ee7c6ed9833a828b99acf9e6d13 (diff)
downloadnextcloud-server-130b8018a1193a9a21b359dd5dfb249efe0a16da.tar.gz
nextcloud-server-130b8018a1193a9a21b359dd5dfb249efe0a16da.zip
Improved external share dialog
Changed title, label and buttons. Removed icon.
-rw-r--r--apps/files_sharing/js/external.js35
1 files changed, 31 insertions, 4 deletions
diff --git a/apps/files_sharing/js/external.js b/apps/files_sharing/js/external.js
index 969a2b184d4..e743d2e2d32 100644
--- a/apps/files_sharing/js/external.js
+++ b/apps/files_sharing/js/external.js
@@ -42,13 +42,40 @@
}
};
if (!passwordProtected) {
- OC.dialogs.confirm(t('files_sharing', 'Add {name} from {owner}@{remote}', {name: name, owner: owner, remote: remoteClean})
- , t('files_sharing','Add Share'), callback, true);
+ OC.dialogs.confirm(
+ t(
+ 'files_sharing',
+ 'Do you want to add the remote share {name} from {owner}@{remote}?',
+ {name: name, owner: owner, remote: remoteClean}
+ ),
+ t('files_sharing','Remote share'),
+ callback,
+ true
+ ).then(this._adjustDialog);
} else {
- OC.dialogs.prompt(t('files_sharing', 'Add {name} from {owner}@{remote}', {name: name, owner: owner, remote: remoteClean})
- , t('files_sharing','Add Share'), callback, true, t('files_sharing','Password'), true);
+ OC.dialogs.prompt(
+ t(
+ 'files_sharing',
+ 'Do you want to add the remote share {name} from {owner}@{remote}?',
+ {name: name, owner: owner, remote: remoteClean}
+ ),
+ t('files_sharing','Remote share'),
+ callback,
+ true,
+ t('files_sharing','Remote share password'),
+ true
+ ).then(this._adjustDialog);
}
};
+
+ OCA.Sharing._adjustDialog = function() {
+ var $dialog = $('.oc-dialog:visible');
+ var $buttons = $dialog.find('button');
+ // hack the buttons
+ $dialog.find('.ui-icon').remove();
+ $buttons.eq(0).text(t('core', 'Cancel'));
+ $buttons.eq(1).text(t('core', 'Add remote share'));
+ };
})();
$(document).ready(function () {