summaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
authorGeorg Ehrke <georg@ownCloud.com>2013-05-25 12:16:25 +0200
committerGeorg Ehrke <georg@ownCloud.com>2013-05-25 12:16:25 +0200
commitaf57996d1ee66463999a33c0a80505fb6027e443 (patch)
tree7faaa79547c152221929cc88e437c8a7265ae4a9 /core
parent1bed3253abfc627a6dd698fc62a617285c1d7c84 (diff)
parent6a6c18dfab494324d5fa7c2ea7a299830dd79612 (diff)
downloadnextcloud-server-af57996d1ee66463999a33c0a80505fb6027e443.tar.gz
nextcloud-server-af57996d1ee66463999a33c0a80505fb6027e443.zip
Merge branch 'master' into oc_preview
Diffstat (limited to 'core')
-rw-r--r--core/css/styles.css19
-rw-r--r--core/js/config.php6
-rw-r--r--core/js/oc-dialogs.js536
-rw-r--r--core/l10n/ar.php4
-rw-r--r--core/l10n/bg_BG.php2
-rw-r--r--core/l10n/bn_BD.php4
-rw-r--r--core/l10n/ca.php5
-rw-r--r--core/l10n/cs_CZ.php4
-rw-r--r--core/l10n/cy_GB.php4
-rw-r--r--core/l10n/da.php4
-rw-r--r--core/l10n/de.php4
-rw-r--r--core/l10n/de_DE.php4
-rw-r--r--core/l10n/el.php4
-rw-r--r--core/l10n/eo.php4
-rw-r--r--core/l10n/es.php5
-rw-r--r--core/l10n/es_AR.php4
-rw-r--r--core/l10n/et_EE.php5
-rw-r--r--core/l10n/eu.php4
-rw-r--r--core/l10n/fa.php4
-rw-r--r--core/l10n/fi_FI.php6
-rw-r--r--core/l10n/fr.php4
-rw-r--r--core/l10n/gl.php5
-rw-r--r--core/l10n/he.php4
-rw-r--r--core/l10n/hr.php4
-rw-r--r--core/l10n/hu_HU.php4
-rw-r--r--core/l10n/id.php4
-rw-r--r--core/l10n/is.php4
-rw-r--r--core/l10n/it.php5
-rw-r--r--core/l10n/ja_JP.php5
-rw-r--r--core/l10n/ka_GE.php4
-rw-r--r--core/l10n/ko.php4
-rw-r--r--core/l10n/lb.php4
-rw-r--r--core/l10n/lt_LT.php4
-rw-r--r--core/l10n/lv.php4
-rw-r--r--core/l10n/mk.php4
-rw-r--r--core/l10n/ms_MY.php2
-rw-r--r--core/l10n/my_MM.php4
-rw-r--r--core/l10n/nb_NO.php4
-rw-r--r--core/l10n/nl.php4
-rw-r--r--core/l10n/nn_NO.php4
-rw-r--r--core/l10n/oc.php4
-rw-r--r--core/l10n/pl.php6
-rw-r--r--core/l10n/pt_BR.php5
-rw-r--r--core/l10n/pt_PT.php4
-rw-r--r--core/l10n/ro.php4
-rw-r--r--core/l10n/ru.php4
-rw-r--r--core/l10n/ru_RU.php6
-rw-r--r--core/l10n/si_LK.php4
-rw-r--r--core/l10n/sk_SK.php4
-rw-r--r--core/l10n/sl.php4
-rw-r--r--core/l10n/sq.php4
-rw-r--r--core/l10n/sr.php4
-rw-r--r--core/l10n/sv.php4
-rw-r--r--core/l10n/ta_LK.php4
-rw-r--r--core/l10n/te.php2
-rw-r--r--core/l10n/th_TH.php4
-rw-r--r--core/l10n/tr.php4
-rw-r--r--core/l10n/ug.php2
-rw-r--r--core/l10n/uk.php4
-rw-r--r--core/l10n/ur_PK.php4
-rw-r--r--core/l10n/vi.php4
-rw-r--r--core/l10n/zh_CN.GB2312.php4
-rw-r--r--core/l10n/zh_CN.php4
-rw-r--r--core/l10n/zh_HK.php2
-rw-r--r--core/l10n/zh_TW.php4
-rw-r--r--core/templates/filepicker.html10
-rw-r--r--core/templates/message.html3
67 files changed, 382 insertions, 443 deletions
diff --git a/core/css/styles.css b/core/css/styles.css
index 93f2cecbfe9..70a840d6890 100644
--- a/core/css/styles.css
+++ b/core/css/styles.css
@@ -382,13 +382,22 @@ a.bookmarklet { background-color:#ddd; border:1px solid #ccc; padding:5px;paddin
.ui-datepicker-prev,.ui-datepicker-next{ border:1px solid #ddd; background:#fff; }
/* ---- DIALOGS ---- */
-#dirup {width:4%;}
-#dirtree {width:92%;}
-#filelist {height:270px; overflow-y:auto; background-color:white; width:100%;}
-.filepicker_element_selected { background-color:lightblue;}
-.filepicker_loader {height:170px; width:100%; background-color:#333; -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=30)"; filter:alpha(opacity=30); opacity:.3; visibility:visible; position:absolute; top:0; left:0; text-align:center; padding-top:150px;}
+#oc-dialog-filepicker-content .dirtree {width:92%; overflow:hidden; }
+#oc-dialog-filepicker-content .dirtree .home {
+ background-image:url('../img/places/home.svg');
+ background-repeat:no-repeat;
+ background-position: left center;
+}
+#oc-dialog-filepicker-content .dirtree span:not(:last-child) { cursor: pointer; }
+#oc-dialog-filepicker-content .dirtree span:last-child { font-weight: bold; }
+#oc-dialog-filepicker-content .dirtree span:not(:last-child)::after { content: '>'; padding: 3px;}
+#oc-dialog-filepicker-content .filelist {height:270px; overflow-y:auto; background-color:white; width:100%;}
+#oc-dialog-filepicker-content .filelist img { margin: 2px 1em 0 4px; }
+#oc-dialog-filepicker-content .filelist .date { float:right;margin-right:1em; }
+#oc-dialog-filepicker-content .filepicker_element_selected { background-color:lightblue;}
.ui-dialog {position:fixed !important;}
span.ui-icon {float: left; margin: 3px 7px 30px 0;}
+.loading { background: url('../img/loading.gif') no-repeat center; cursor: wait; }
/* ---- CATEGORIES ---- */
#categoryform .scrollarea { position:absolute; left:10px; top:10px; right:10px; bottom:50px; overflow:auto; border:1px solid #ddd; background:#f8f8f8; }
diff --git a/core/js/config.php b/core/js/config.php
index 48bea6ae542..53a8fb96388 100644
--- a/core/js/config.php
+++ b/core/js/config.php
@@ -26,8 +26,8 @@ $array = array(
"oc_debug" => (defined('DEBUG') && DEBUG) ? 'true' : 'false',
"oc_webroot" => "\"".OC::$WEBROOT."\"",
"oc_appswebroots" => str_replace('\\/', '/', json_encode($apps_paths)), // Ugly unescape slashes waiting for better solution
- "oc_current_user" => "document.head.getAttribute('data-user')",
- "oc_requesttoken" => "document.head.getAttribute('data-requesttoken')",
+ "oc_current_user" => "document.getElementsByTagName('head')[0].getAttribute('data-user')",
+ "oc_requesttoken" => "document.getElementsByTagName('head')[0].getAttribute('data-requesttoken')",
"datepickerFormatDate" => json_encode($l->l('jsdate', 'jsdate')),
"dayNames" => json_encode(
array(
@@ -62,4 +62,4 @@ $array = array(
// Echo it
foreach ($array as $setting => $value) {
echo("var ". $setting ."=".$value.";\n");
-} \ No newline at end of file
+}
diff --git a/core/js/oc-dialogs.js b/core/js/oc-dialogs.js
index 990c3f8bf38..e1d3657724e 100644
--- a/core/js/oc-dialogs.js
+++ b/core/js/oc-dialogs.js
@@ -1,7 +1,7 @@
/**
* ownCloud
*
- * @author Bartek Przybylski
+ * @author Bartek Przybylski, Christopher Schäpers, Thomas Tanghus
* @copyright 2012 Bartek Przybylski bartek@alefzero.eu
*
* This library is free software; you can redistribute it and/or
@@ -23,6 +23,11 @@
* this class to ease the usage of jquery dialogs
*/
var OCdialogs = {
+ // dialog button types
+ YES_NO_BUTTONS: 70,
+ OK_BUTTONS: 71,
+ // used to name each dialog
+ dialogs_counter: 0,
/**
* displays alert dialog
* @param text content of dialog
@@ -31,8 +36,7 @@ var OCdialogs = {
* @param modal make the dialog modal
*/
alert:function(text, title, callback, modal) {
- var content = '<p><span class="ui-icon ui-icon-alert"></span>' + escapeHTML(text) + '</p>';
- OCdialogs.message(content, title, OCdialogs.ALERT_DIALOG, OCdialogs.OK_BUTTON, callback, modal);
+ this.message(text, title, 'alert', OCdialogs.OK_BUTTON, callback, modal);
},
/**
* displays info dialog
@@ -42,8 +46,7 @@ var OCdialogs = {
* @param modal make the dialog modal
*/
info:function(text, title, callback, modal) {
- var content = '<p><span class="ui-icon ui-icon-info"></span>' + escapeHTML(text) + '</p>';
- OCdialogs.message(content, title, OCdialogs.ALERT_DIALOG, OCdialogs.OK_BUTTON, callback, modal);
+ this.message(text, title, 'info', OCdialogs.OK_BUTTON, callback, modal);
},
/**
* displays confirmation dialog
@@ -53,82 +56,7 @@ var OCdialogs = {
* @param modal make the dialog modal
*/
confirm:function(text, title, callback, modal) {
- var content = '<p><span class="ui-icon ui-icon-notice"></span>' + escapeHTML(text) + '</p>';
- OCdialogs.message(content, title, OCdialogs.ALERT_DIALOG, OCdialogs.YES_NO_BUTTONS, callback, modal);
- },
- /**
- * prompt for user input
- * @param text content of dialog
- * @param title dialog title
- * @param callback which will be triggered when user presses OK (input text will be passed to callback)
- * @param modal make the dialog modal
- */
- prompt:function(text, title, default_value, callback, modal) {
- var input = '<input type="text" id="oc-dialog-prompt-input" value="' + escapeHTML(default_value) + '" style="width:90%">';
- var content = '<p><span class="ui-icon ui-icon-pencil"></span>' + escapeHTML(text) + ':<br/>' + input + '</p>';
- OCdialogs.message(content, title, OCdialogs.PROMPT_DIALOG, OCdialogs.OK_BUTTON, callback, modal);
- },
- /**
- * prompt user for input with custom form
- * fields should be passed in following format: [{text:'prompt text', name:'return name', type:'input type', value: 'default value'},...]
- * example:
- * var fields=[{text:'Test', name:'test', type:'select', options:[{text:'hello1',value:1},{text:'hello2',value:2}] }];
- * @param fields to display
- * @param title dialog title
- * @param callback which will be triggered when user presses OK (user answers will be passed to callback in following format: [{name:'return name', value: 'user value'},...])
- * @param modal make the dialog modal
- */
- form:function(fields, title, callback, modal) {
- var content = '<table>';
- $.each(fields, function(index, field){
- content += '<tr><td>' + escapeHTML(field.text) + '</td><td>';
- var type = field.type;
-
- if (type === 'text' || type === 'checkbox' || type === 'password') {
- content += '<input type="' + type + '" name="' + field.name + '"';
- if (type === 'checkbox' && field.value === true) {
- content += ' checked="checked"';
- } else if (type === 'text' || type === 'password' && val.value) {
- content += ' value="' + escapeHTML(field.value) + '"';
- }
- content += '>';
- } else if (type === 'select') {
- content += '<select name="' + escapeHTML(field.name) + '"';
- if (field.value !== undefined) {
- content += ' value="' + escapeHTML(field.value) + '"';
- }
- content += '>';
- $.each(field.options, function(index, field_option){
- content += '<option value="' + escapeHTML(field_option.value) + '">' + escapeHTML(field_option.text) + '</option>';
- });
- content += '</select>';
- }
- content += '</td></tr>';
-
- });
- content += '</table>';
-
- var dialog_name = 'oc-dialog-' + OCdialogs.dialogs_counter + '-content';
- var dialog_id = '#' + dialog_name;
- var dialog_div = '<div id="' + dialog_name + '" title="' + escapeHTML(title) + '">' + content + '</div>';
- if (modal === undefined) { modal = false };
- $('body').append(dialog_div);
- var buttonlist = [{
- text: t('core', 'Ok'),
- click: function(){ OCdialogs.form_ok_handler(callback, dialog_id); }
- },
- {
- text: t('core', 'Cancel'),
- click: function(){ $(dialog_id).dialog('close'); }
- }];
- var dialog_height = ( $('tr', dialog_div).length + 1 ) * 30 + 120;
- $(dialog_id).dialog({
- width: (4/9) * $(document).width(),
- height: dialog_height,
- modal: modal,
- buttons: buttonlist
- });
- OCdialogs.dialogs_counter++;
+ this.message(text, title, 'notice', OCdialogs.YES_NO_BUTTONS, callback, modal);
},
/**
* show a file picker to pick a file from
@@ -139,288 +67,262 @@ var OCdialogs = {
* @param modal make the dialog modal
*/
filepicker:function(title, callback, multiselect, mimetype_filter, modal) {
- var dialog_name = 'oc-dialog-' + OCdialogs.dialogs_counter + '-content';
- var dialog_id = '#' + dialog_name;
- var dialog_content = '<button id="dirup">↑</button><select id="dirtree"></select><div id="filelist"></div>';
- var dialog_loader = '<div class="filepicker_loader"><img src="' + OC.filePath('gallery','img','loading.gif') + '"></div>';
- var dialog_div = '<div id="' + dialog_name + '" title="' + escapeHTML(title) + '">' + dialog_content + dialog_loader + '</div>';
- if (modal === undefined) { modal = false };
- if (multiselect === undefined) { multiselect = false };
- if (mimetype_filter === undefined) { mimetype_filter = '' };
+ var self = this;
+ $.when(this._getFilePickerTemplate()).then(function($tmpl) {
+ var dialog_name = 'oc-dialog-filepicker-content';
+ var dialog_id = '#' + dialog_name;
+ if(self.$filePicker) {
+ self.$filePicker.dialog('close');
+ }
+ self.$filePicker = $tmpl.octemplate({
+ dialog_name: dialog_name,
+ title: title
+ }).data('path', '');
- $('body').append(dialog_div);
+ if (modal === undefined) { modal = false };
+ if (multiselect === undefined) { multiselect = false };
+ if (mimetype_filter === undefined) { mimetype_filter = '' };
- $(dialog_id).data('path', '/');
+ $('body').append(self.$filePicker);
- $(dialog_id + ' #dirtree').focus().change( {dcid: dialog_id}, OCdialogs.handleTreeListSelect );
- $(dialog_id + ' #dirup').click( {dcid: dialog_id}, OCdialogs.filepickerDirUp );
- $(dialog_id).ready(function(){
- $.getJSON(OC.filePath('files', 'ajax', 'rawlist.php'), { mimetype: mimetype_filter } ,function(request) {
- OCdialogs.fillFilePicker(request, dialog_id);
- });
- $.getJSON(OC.filePath('files', 'ajax', 'rawlist.php'), { mimetype: "httpd/unix-directory" }, function(request) {
- OCdialogs.fillTreeList(request, dialog_id);
- });
- }).data('multiselect', multiselect).data('mimetype',mimetype_filter);
+ self.$filePicker.ready(function() {
+ self.$filelist = self.$filePicker.find('.filelist');
+ self.$dirTree = self.$filePicker.find('.dirtree');
+ self.$dirTree.on('click', 'span:not(:last-child)', self, self._handleTreeListSelect);
+ self.$filelist.on('click', 'li', function(event) {
+ self._handlePickerClick(event, $(this));
+ });
+ self._fillFilePicker('');
+ }).data('multiselect', multiselect).data('mimetype',mimetype_filter);
- // build buttons
- var functionToCall = function() {
- if (callback !== undefined) {
- var datapath;
- if (multiselect === true) {
- datapath = [];
- $(dialog_id + ' .filepicker_element_selected .filename').each(function(index, element) {
- datapath.push( $(dialog_id).data('path') + $(element).text() );
- });
- } else {
- var datapath = $(dialog_id).data('path');
- datapath += $(dialog_id+' .filepicker_element_selected .filename').text();
+ // build buttons
+ var functionToCall = function() {
+ if (callback !== undefined) {
+ var datapath;
+ if (multiselect === true) {
+ datapath = [];
+ self.$filelist.find('.filepicker_element_selected .filename').each(function(index, element) {
+ datapath.push(self.$filePicker.data('path') + '/' + $(element).text());
+ });
+ } else {
+ var datapath = self.$filePicker.data('path');
+ datapath += '/' + self.$filelist.find('.filepicker_element_selected .filename').text();
+ }
+ callback(datapath);
+ self.$filePicker.dialog('close');
}
- callback(datapath);
- $(dialog_id).dialog('close');
- }
- };
- var buttonlist = [{
- text: t('core', 'Choose'),
- click: functionToCall
- },
- {
- text: t('core', 'Cancel'),
- click: function(){$(dialog_id).dialog('close'); }
- }];
+ };
+ var buttonlist = [{
+ text: t('core', 'Choose'),
+ click: functionToCall
+ },
+ {
+ text: t('core', 'Cancel'),
+ click: function(){self.$filePicker.dialog('close'); }
+ }];
- $(dialog_id).dialog({
- width: (4/9)*$(document).width(),
- height: 420,
- modal: modal,
- buttons: buttonlist
+ self.$filePicker.dialog({
+ closeOnEscape: true,
+ width: (4/9)*$(document).width(),
+ height: 420,
+ modal: modal,
+ buttons: buttonlist,
+ close: function(event, ui) {
+ self.$filePicker.dialog('destroy').remove();
+ self.$filePicker = null;
+ }
+ });
+ })
+ .fail(function() {
+ alert(t('core', 'Error loading file picker template'));
});
- OCdialogs.dialogs_counter++;
},
/**
* Displays raw dialog
* You better use a wrapper instead ...
*/
message:function(content, title, dialog_type, buttons, callback, modal) {
- var dialog_name = 'oc-dialog-' + OCdialogs.dialogs_counter + '-content';
- var dialog_id = '#' + dialog_name;
- var dialog_div = '<div id="' + dialog_name + '" title="' + escapeHTML(title) + '">' + content + '</div>';
- if (modal === undefined) { modal = false };
- $('body').append(dialog_div);
- var buttonlist = [];
- switch (buttons) {
- case OCdialogs.YES_NO_BUTTONS:
- buttonlist = [{
- text: t('core', 'Yes'),
- click: function(){
- if (callback !== undefined) { callback(true) };
- $(dialog_id).dialog('close');
- }
- },
- {
- text: t('core', 'No'),
- click: function(){
- if (callback !== undefined) { callback(false) };
- $(dialog_id).dialog('close');
- }
- }];
- break;
- case OCdialogs.OK_BUTTON:
- var functionToCall;
- switch(dialog_type) {
- case OCdialogs.ALERT_DIALOG:
- functionToCall = function() {
+ $.when(this._getMessageTemplate()).then(function($tmpl) {
+ var dialog_name = 'oc-dialog-' + OCdialogs.dialogs_counter + '-content';
+ var dialog_id = '#' + dialog_name;
+ var $dlg = $tmpl.octemplate({
+ dialog_name: dialog_name,
+ title: title,
+ message: content,
+ type: dialog_type
+ });
+ if (modal === undefined) { modal = false };
+ $('body').append($dlg);
+ var buttonlist = [];
+ switch (buttons) {
+ case OCdialogs.YES_NO_BUTTONS:
+ buttonlist = [{
+ text: t('core', 'Yes'),
+ click: function(){
+ if (callback !== undefined) { callback(true) };
$(dialog_id).dialog('close');
- if(callback !== undefined) { callback() };
- };
- break;
- case OCdialogs.PROMPT_DIALOG:
- buttonlist[1] = {
- text: t('core', 'Cancel'),
- click: function() { $(dialog_id).dialog('close'); }
- };
- functionToCall = function() { OCdialogs.prompt_ok_handler(callback, dialog_id); };
- break;
- }
- buttonlist[0] = {
- text: t('core', 'Ok'),
- click: functionToCall
- };
- break;
- };
+ }
+ },
+ {
+ text: t('core', 'No'),
+ click: function(){
+ if (callback !== undefined) { callback(false) };
+ $(dialog_id).dialog('close');
+ }
+ }];
+ break;
+ case OCdialogs.OK_BUTTON:
+ var functionToCall = function() {
+ $(dialog_id).dialog('close');
+ if(callback !== undefined) { callback() };
+ };
+ buttonlist[0] = {
+ text: t('core', 'Ok'),
+ click: functionToCall
+ };
+ break;
+ };
- $(dialog_id).dialog({
- width: (4/9) * $(document).width(),
- height: 180,
- modal: modal,
- buttons: buttonlist
+ $(dialog_id).dialog({
+ closeOnEscape: true,
+ modal: modal,
+ buttons: buttonlist
+ });
+ OCdialogs.dialogs_counter++;
+ })
+ .fail(function() {
+ alert(t('core', 'Error loading file picker template'));
});
- OCdialogs.dialogs_counter++;
},
- // dialog button types
- YES_NO_BUTTONS: 70,
- OK_BUTTONS: 71,
- // dialogs types
- ALERT_DIALOG: 80,
- INFO_DIALOG: 81,
- FORM_DIALOG: 82,
- // used to name each dialog
- dialogs_counter: 0,
-
- determineValue: function(element) {
- if ( $(element).attr('type') === 'checkbox' ) {
- return element.checked;
+ _getFilePickerTemplate: function() {
+ var defer = $.Deferred();
+ if(!this.$filePickerTemplate) {
+ var self = this;
+ $.get(OC.filePath('core', 'templates', 'filepicker.html'), function(tmpl) {
+ self.$filePickerTemplate = $(tmpl);
+ self.$listTmpl = self.$filePickerTemplate.find('.filelist li:first-child').detach();
+ defer.resolve(self.$filePickerTemplate);
+ })
+ .fail(function() {
+ defer.reject();
+ });
} else {
- return $(element).val();
+ defer.resolve(this.$filePickerTemplate);
}
+ return defer.promise();
},
-
- prompt_ok_handler: function(callback, dialog_id) {
- $(dialog_id).dialog('close');
- if (callback !== undefined) { callback($(dialog_id + " input#oc-dialog-prompt-input").val()) };
- },
-
- form_ok_handler: function(callback, dialog_id) {
- if (callback !== undefined) {
- var valuelist = [];
- $(dialog_id + ' input, ' + dialog_id + ' select').each(function(index, element) {
- valuelist[index] = { name: $(element).attr('name'), value: OCdialogs.determineValue(element) };
+ _getMessageTemplate: function() {
+ var defer = $.Deferred();
+ if(!this.$messageTemplate) {
+ var self = this;
+ $.get(OC.filePath('core', 'templates', 'message.html'), function(tmpl) {
+ self.$messageTemplate = $(tmpl);
+ defer.resolve(self.$messageTemplate);
+ })
+ .fail(function() {
+ defer.reject();
});
- $(dialog_id).dialog('close');
- callback(valuelist);
} else {
- $(dialog_id).dialog('close');
+ defer.resolve(this.$messageTemplate);
+ }
+ return defer.promise();
+ },
+ _getFileList: function(dir, mimeType) {
+ return $.getJSON(
+ OC.filePath('files', 'ajax', 'rawlist.php'),
+ {dir: dir, mimetype: mimeType}
+ );
+ },
+ _determineValue: function(element) {
+ if ( $(element).attr('type') === 'checkbox' ) {
+ return element.checked;
+ } else {
+ return $(element).val();
}
},
+
/**
* fills the filepicker with files
*/
- fillFilePicker:function(request, dialog_content_id) {
- var template_content = '<img src="*MIMETYPEICON*" style="margin: 2px 1em 0 4px;"><span class="filename">*NAME*</span><div style="float:right;margin-right:1em;">*LASTMODDATE*</div>';
- var template = '<div data-entryname="*ENTRYNAME*" data-dcid="' + escapeHTML(dialog_content_id) + '" data="*ENTRYTYPE*">*CONTENT*</div>';
- var files = '';
+ _fillFilePicker:function(dir) {
var dirs = [];
var others = [];
- $.each(request.data, function(index, file) {
- if (file.type === 'dir') {
- dirs.push(file);
- } else {
- others.push(file);
- }
- });
- var sorted = dirs.concat(others);
- for (var i = 0; i < sorted.length; i++) {
- files_content = template_content.replace('*LASTMODDATE*', OC.mtime2date(sorted[i].mtime)).replace('*NAME*', escapeHTML(sorted[i].name)).replace('*MIMETYPEICON*', sorted[i].mimetype_icon);
- files += template.replace('*ENTRYNAME*', escapeHTML(sorted[i].name)).replace('*ENTRYTYPE*', escapeHTML(sorted[i].type)).replace('*CONTENT*', files_content);
- }
+ var self = this;
+ this.$filelist.empty().addClass('loading');
+ this.$filePicker.data('path', dir);
+ $.when(this._getFileList(dir, this.$filePicker.data('mimetype'))).then(function(response) {
+ $.each(response.data, function(index, file) {
+ if (file.type === 'dir') {
+ dirs.push(file);
+ } else {
+ others.push(file);
+ }
+ });
- $(dialog_content_id + ' #filelist').html(files);
- $('#filelist div').click(function() {
- OCdialogs.handlePickerClick($(this), $(this).data('entryname'), dialog_content_id);
- });
+ self._fillSlug();
+ var sorted = dirs.concat(others);
- $(dialog_content_id + ' .filepicker_loader').css('visibility', 'hidden');
- },
- /**
- * fills the tree list with directories
- */
- fillTreeList: function(request, dialog_id) {
- var template = '<option value="*COUNT*">*NAME*</option>';
- var paths = '<option value="0">' + escapeHTML($(dialog_id).data('path')) + '</option>';
- $.each(request.data, function(index, file) {
- paths += template.replace('*COUNT*', index).replace('*NAME*', escapeHTML(file.name));
- });
+ $.each(sorted, function(idx, entry) {
+ $li = self.$listTmpl.octemplate({
+ type: entry.type,
+ dir: dir,
+ filename: entry.name,
+ date: OC.mtime2date(entry.mtime)
+ });
+ $li.find('img').attr('src', entry.mimetype_icon);
+ self.$filelist.append($li);
+ });
- $(dialog_id + ' #dirtree').html(paths);
+ self.$filelist.removeClass('loading');
+ });
},
/**
- * handle selection made in the tree list
+ * fills the tree list with directories
*/
- handleTreeListSelect:function(event) {
- if ($("option:selected", this).html().indexOf('/') !== -1) { // if there's a slash in the selected path, don't append it
- $(event.data.dcid).data('path', $("option:selected", this).html());
- } else {
- $(event.data.dcid).data('path', $(event.data.dcid).data('path') + $("option:selected", this).html() + '/');
+ _fillSlug: function() {
+ this.$dirTree.empty();
+ var self = this
+ var path = this.$filePicker.data('path');
+ var $template = $('<span data-dir="{dir}">{name}</span>');
+ if(path) {
+ var paths = path.split('/');
+ $.each(paths, function(index, dir) {
+ var dir = paths.pop();
+ if(dir === '') {
+ return false;
+ }
+ self.$dirTree.prepend($template.octemplate({
+ dir: paths.join('/') + '/' + dir,
+ name: dir
+ }));
+ });
}
- $(event.data.dcid + ' .filepicker_loader').css('visibility', 'visible');
- $.getJSON(
- OC.filePath('files', 'ajax', 'rawlist.php'),
- {
- dir: $(event.data.dcid).data('path'),
- mimetype: $(event.data.dcid).data('mimetype')
- },
- function(request) { OCdialogs.fillFilePicker(request, event.data.dcid) }
- );
- $.getJSON(
- OC.filePath('files', 'ajax', 'rawlist.php'),
- {
- dir: $(event.data.dcid).data('path'),
- mimetype: "httpd/unix-directory"
- },
- function(request) { OCdialogs.fillTreeList(request, event.data.dcid) }
- );
+ $template.octemplate({
+ dir: '',
+ name: '&nbsp;&nbsp;&nbsp;&nbsp;' // Ugly but works ;)
+ }, {escapeFunction: null}).addClass('home svg').prependTo(this.$dirTree);
},
/**
- * go one directory up
+ * handle selection made in the tree list
*/
- filepickerDirUp:function(event) {
- var old_path = $(event.data.dcid).data('path');
- if ( old_path !== "/") {
- var splitted_path = old_path.split("/");
- var new_path = ""
- for (var i = 0; i < splitted_path.length - 2; i++) {
- new_path += splitted_path[i] + "/"
- }
- $(event.data.dcid).data('path', new_path);
- $.getJSON(
- OC.filePath('files', 'ajax', 'rawlist.php'),
- {
- dir: $(event.data.dcid).data('path'),
- mimetype: $(event.data.dcid).data('mimetype')
- },
- function(request) { OCdialogs.fillFilePicker(request, event.data.dcid) }
- );
- $.getJSON(
- OC.filePath('files', 'ajax', 'rawlist.php'),
- {
- dir: $(event.data.dcid).data('path'),
- mimetype: "httpd/unix-directory"
- },
- function(request) { OCdialogs.fillTreeList(request, event.data.dcid) }
- );
- }
+ _handleTreeListSelect:function(event) {
+ var self = event.data;
+ var dir = $(event.target).data('dir');
+ self._fillFilePicker(dir);
},
/**
* handle clicks made in the filepicker
*/
- handlePickerClick:function(element, name, dialog_content_id) {
- if ( $(element).attr('data') === 'file' ){
- if ( $(dialog_content_id).data('multiselect') !== true) {
- $(dialog_content_id + ' .filepicker_element_selected').removeClass('filepicker_element_selected');
+ _handlePickerClick:function(event, $element) {
+ if ($element.data('type') === 'file') {
+ if (this.$filePicker.data('multiselect') !== true || !event.ctrlKey) {
+ this.$filelist.find('.filepicker_element_selected').removeClass('filepicker_element_selected');
}
- $(element).toggleClass('filepicker_element_selected');
+ $element.toggleClass('filepicker_element_selected');
return;
- } else if ( $(element).attr('data') === 'dir' ) {
- var datapath = escapeHTML( $(dialog_content_id).data('path') + name + '/' );
- $(dialog_content_id).data('path', datapath);
- $(dialog_content_id + ' .filepicker_loader').css('visibility', 'visible');
- $.getJSON(
- OC.filePath('files', 'ajax', 'rawlist.php'),
- {
- dir: datapath,
- mimetype: $(dialog_content_id).data('mimetype')
- },
- function(request){ OCdialogs.fillFilePicker(request, dialog_content_id) }
- );
- $.getJSON(
- OC.filePath('files', 'ajax', 'rawlist.php'),
- {
- dir: datapath,
- mimetype: "httpd/unix-directory"
- },
- function(request) { OCdialogs.fillTreeList(request, dialog_content_id) }
- );
+ } else if ( $element.data('type') === 'dir' ) {
+ this._fillFilePicker(this.$filePicker.data('path') + '/' + $element.data('entryname'))
}
}
};
diff --git a/core/l10n/ar.php b/core/l10n/ar.php
index 587e59695ca..8bd4429338a 100644
--- a/core/l10n/ar.php
+++ b/core/l10n/ar.php
@@ -44,11 +44,11 @@
"months ago" => "شهر مضى",
"last year" => "السنةالماضية",
"years ago" => "سنة مضت",
-"Ok" => "موافق",
-"Cancel" => "الغاء",
"Choose" => "اختيار",
+"Cancel" => "الغاء",
"Yes" => "نعم",
"No" => "لا",
+"Ok" => "موافق",
"The object type is not specified." => "نوع العنصر غير محدد.",
"Error" => "خطأ",
"The app name is not specified." => "اسم التطبيق غير محدد.",
diff --git a/core/l10n/bg_BG.php b/core/l10n/bg_BG.php
index 74e28bf2900..6c04907e15b 100644
--- a/core/l10n/bg_BG.php
+++ b/core/l10n/bg_BG.php
@@ -28,10 +28,10 @@
"last month" => "последният месец",
"last year" => "последната година",
"years ago" => "последните години",
-"Ok" => "Добре",
"Cancel" => "Отказ",
"Yes" => "Да",
"No" => "Не",
+"Ok" => "Добре",
"Error" => "Грешка",
"Share" => "Споделяне",
"Share with" => "Споделено с",
diff --git a/core/l10n/bn_BD.php b/core/l10n/bn_BD.php
index 63a80edad38..218bbce04aa 100644
--- a/core/l10n/bn_BD.php
+++ b/core/l10n/bn_BD.php
@@ -43,11 +43,11 @@
"months ago" => "মাস পূর্বে",
"last year" => "গত বছর",
"years ago" => "বছর পূর্বে",
-"Ok" => "তথাস্তু",
-"Cancel" => "বাতির",
"Choose" => "বেছে নিন",
+"Cancel" => "বাতির",
"Yes" => "হ্যাঁ",
"No" => "না",
+"Ok" => "তথাস্তু",
"The object type is not specified." => "অবজেক্টের ধরণটি সুনির্দিষ্ট নয়।",
"Error" => "সমস্যা",
"The app name is not specified." => "অ্যাপের নামটি সুনির্দিষ্ট নয়।",
diff --git a/core/l10n/ca.php b/core/l10n/ca.php
index a1430d547f5..323ef7997fa 100644
--- a/core/l10n/ca.php
+++ b/core/l10n/ca.php
@@ -44,11 +44,12 @@
"months ago" => "mesos enrere",
"last year" => "l'any passat",
"years ago" => "anys enrere",
-"Ok" => "D'acord",
-"Cancel" => "Cancel·la",
"Choose" => "Escull",
+"Cancel" => "Cancel·la",
+"Error loading file picker template" => "Error en carregar la plantilla del seleccionador de fitxers",
"Yes" => "Sí",
"No" => "No",
+"Ok" => "D'acord",
"The object type is not specified." => "No s'ha especificat el tipus d'objecte.",
"Error" => "Error",
"The app name is not specified." => "No s'ha especificat el nom de l'aplicació.",
diff --git a/core/l10n/cs_CZ.php b/core/l10n/cs_CZ.php
index be354386e10..06cf7c214be 100644
--- a/core/l10n/cs_CZ.php
+++ b/core/l10n/cs_CZ.php
@@ -44,11 +44,11 @@
"months ago" => "před měsíci",
"last year" => "minulý rok",
"years ago" => "před lety",
-"Ok" => "Ok",
-"Cancel" => "Zrušit",
"Choose" => "Vybrat",
+"Cancel" => "Zrušit",
"Yes" => "Ano",
"No" => "Ne",
+"Ok" => "Ok",
"The object type is not specified." => "Není určen typ objektu.",
"Error" => "Chyba",
"The app name is not specified." => "Není určen název aplikace.",
diff --git a/core/l10n/cy_GB.php b/core/l10n/cy_GB.php
index a874d43965d..cdb2576d457 100644
--- a/core/l10n/cy_GB.php
+++ b/core/l10n/cy_GB.php
@@ -44,11 +44,11 @@
"months ago" => "misoedd yn ôl",
"last year" => "y llynedd",
"years ago" => "blwyddyn yn ôl",
-"Ok" => "Iawn",
-"Cancel" => "Diddymu",
"Choose" => "Dewisiwch",
+"Cancel" => "Diddymu",
"Yes" => "Ie",
"No" => "Na",
+"Ok" => "Iawn",
"The object type is not specified." => "Nid yw'r math o wrthrych wedi cael ei nodi.",
"Error" => "Gwall",
"The app name is not specified." => "Nid yw enw'r pecyn wedi cael ei nodi.",
diff --git a/core/l10n/da.php b/core/l10n/da.php
index 43b2f4f840a..4e9f742e80d 100644
--- a/core/l10n/da.php
+++ b/core/l10n/da.php
@@ -44,11 +44,11 @@
"months ago" => "måneder siden",
"last year" => "sidste år",
"years ago" => "år siden",
-"Ok" => "OK",
-"Cancel" => "Annuller",
"Choose" => "Vælg",
+"Cancel" => "Annuller",
"Yes" => "Ja",
"No" => "Nej",
+"Ok" => "OK",
"The object type is not specified." => "Objekttypen er ikke angivet.",
"Error" => "Fejl",
"The app name is not specified." => "Den app navn er ikke angivet.",
diff --git a/core/l10n/de.php b/core/l10n/de.php
index b53bda109dd..62e9925b945 100644
--- a/core/l10n/de.php
+++ b/core/l10n/de.php
@@ -44,11 +44,11 @@
"months ago" => "Vor Monaten",
"last year" => "Letztes Jahr",
"years ago" => "Vor Jahren",
-"Ok" => "OK",
-"Cancel" => "Abbrechen",
"Choose" => "Auswählen",
+"Cancel" => "Abbrechen",
"Yes" => "Ja",
"No" => "Nein",
+"Ok" => "OK",
"The object type is not specified." => "Der Objekttyp ist nicht angegeben.",
"Error" => "Fehler",
"The app name is not specified." => "Der App-Name ist nicht angegeben.",
diff --git a/core/l10n/de_DE.php b/core/l10n/de_DE.php
index 7e9b64193c6..f395c192bd0 100644
--- a/core/l10n/de_DE.php
+++ b/core/l10n/de_DE.php
@@ -44,11 +44,11 @@
"months ago" => "Vor Monaten",
"last year" => "Letztes Jahr",
"years ago" => "Vor Jahren",
-"Ok" => "OK",
-"Cancel" => "Abbrechen",
"Choose" => "Auswählen",
+"Cancel" => "Abbrechen",
"Yes" => "Ja",
"No" => "Nein",
+"Ok" => "OK",
"The object type is not specified." => "Der Objekttyp ist nicht angegeben.",
"Error" => "Fehler",
"The app name is not specified." => "Der App-Name ist nicht angegeben.",
diff --git a/core/l10n/el.php b/core/l10n/el.php
index dbe0d0ee3d6..11295105e31 100644
--- a/core/l10n/el.php
+++ b/core/l10n/el.php
@@ -44,11 +44,11 @@
"months ago" => "μήνες πριν",
"last year" => "τελευταίο χρόνο",
"years ago" => "χρόνια πριν",
-"Ok" => "Οκ",
-"Cancel" => "Άκυρο",
"Choose" => "Επιλέξτε",
+"Cancel" => "Άκυρο",
"Yes" => "Ναι",
"No" => "Όχι",
+"Ok" => "Οκ",
"The object type is not specified." => "Δεν καθορίστηκε ο τύπος του αντικειμένου.",
"Error" => "Σφάλμα",
"The app name is not specified." => "Δεν καθορίστηκε το όνομα της εφαρμογής.",
diff --git a/core/l10n/eo.php b/core/l10n/eo.php
index 1889de1ea23..72cdf90c61e 100644
--- a/core/l10n/eo.php
+++ b/core/l10n/eo.php
@@ -43,11 +43,11 @@
"months ago" => "monatoj antaŭe",
"last year" => "lastajare",
"years ago" => "jaroj antaŭe",
-"Ok" => "Akcepti",
-"Cancel" => "Nuligi",
"Choose" => "Elekti",
+"Cancel" => "Nuligi",
"Yes" => "Jes",
"No" => "Ne",
+"Ok" => "Akcepti",
"The object type is not specified." => "Ne indikiĝis tipo de la objekto.",
"Error" => "Eraro",
"The app name is not specified." => "Ne indikiĝis nomo de la aplikaĵo.",
diff --git a/core/l10n/es.php b/core/l10n/es.php
index d99ac861cea..4b8d5c7b189 100644
--- a/core/l10n/es.php
+++ b/core/l10n/es.php
@@ -44,11 +44,12 @@
"months ago" => "hace meses",
"last year" => "el año pasado",
"years ago" => "hace años",
-"Ok" => "Aceptar",
-"Cancel" => "Cancelar",
"Choose" => "Seleccionar",
+"Cancel" => "Cancelar",
+"Error loading file picker template" => "Error cargando la plantilla del seleccionador de archivos",
"Yes" => "Sí",
"No" => "No",
+"Ok" => "Aceptar",
"The object type is not specified." => "No se ha especificado el tipo de objeto",
"Error" => "Error",
"The app name is not specified." => "No se ha especificado el nombre de la aplicación.",
diff --git a/core/l10n/es_AR.php b/core/l10n/es_AR.php
index 8f778437087..38b0791b94b 100644
--- a/core/l10n/es_AR.php
+++ b/core/l10n/es_AR.php
@@ -44,11 +44,11 @@
"months ago" => "meses atrás",
"last year" => "el año pasado",
"years ago" => "años atrás",
-"Ok" => "Aceptar",
-"Cancel" => "Cancelar",
"Choose" => "Elegir",
+"Cancel" => "Cancelar",
"Yes" => "Sí",
"No" => "No",
+"Ok" => "Aceptar",
"The object type is not specified." => "El tipo de objeto no esta especificado. ",
"Error" => "Error",
"The app name is not specified." => "El nombre de la aplicación no esta especificado.",
diff --git a/core/l10n/et_EE.php b/core/l10n/et_EE.php
index 79d3024f014..fd050624089 100644
--- a/core/l10n/et_EE.php
+++ b/core/l10n/et_EE.php
@@ -44,11 +44,12 @@
"months ago" => "kuu tagasi",
"last year" => "viimasel aastal",
"years ago" => "aastat tagasi",
-"Ok" => "Ok",
-"Cancel" => "Loobu",
"Choose" => "Vali",
+"Cancel" => "Loobu",
+"Error loading file picker template" => "Viga failivalija malli laadimisel",
"Yes" => "Jah",
"No" => "Ei",
+"Ok" => "Ok",
"The object type is not specified." => "Objekti tüüp pole määratletud.",
"Error" => "Viga",
"The app name is not specified." => "Rakenduse nimi ole määratletud",
diff --git a/core/l10n/eu.php b/core/l10n/eu.php
index 9c9d28133cf..1ec4ee8f5c4 100644
--- a/core/l10n/eu.php
+++ b/core/l10n/eu.php
@@ -44,11 +44,11 @@
"months ago" => "hilabete",
"last year" => "joan den urtean",
"years ago" => "urte",
-"Ok" => "Ados",
-"Cancel" => "Ezeztatu",
"Choose" => "Aukeratu",
+"Cancel" => "Ezeztatu",
"Yes" => "Bai",
"No" => "Ez",
+"Ok" => "Ados",
"The object type is not specified." => "Objetu mota ez dago zehaztuta.",
"Error" => "Errorea",
"The app name is not specified." => "App izena ez dago zehaztuta.",
diff --git a/core/l10n/fa.php b/core/l10n/fa.php
index ff73e804483..fb8a312587c 100644
--- a/core/l10n/fa.php
+++ b/core/l10n/fa.php
@@ -44,11 +44,11 @@
"months ago" => "ماه‌های قبل",
"last year" => "سال قبل",
"years ago" => "سال‌های قبل",
-"Ok" => "قبول",
-"Cancel" => "منصرف شدن",
"Choose" => "انتخاب کردن",
+"Cancel" => "منصرف شدن",
"Yes" => "بله",
"No" => "نه",
+"Ok" => "قبول",
"The object type is not specified." => "نوع شی تعیین نشده است.",
"Error" => "خطا",
"The app name is not specified." => "نام برنامه تعیین نشده است.",
diff --git a/core/l10n/fi_FI.php b/core/l10n/fi_FI.php
index 3f50e814845..1f7a01e0e06 100644
--- a/core/l10n/fi_FI.php
+++ b/core/l10n/fi_FI.php
@@ -42,11 +42,11 @@
"months ago" => "kuukautta sitten",
"last year" => "viime vuonna",
"years ago" => "vuotta sitten",
-"Ok" => "Ok",
-"Cancel" => "Peru",
"Choose" => "Valitse",
+"Cancel" => "Peru",
"Yes" => "Kyllä",
"No" => "Ei",
+"Ok" => "Ok",
"Error" => "Virhe",
"The app name is not specified." => "Sovelluksen nimeä ei ole määritelty.",
"The required file {file} is not installed!" => "Vaadittua tiedostoa {file} ei ole asennettu!",
@@ -84,6 +84,7 @@
"The update was successful. Redirecting you to ownCloud now." => "Päivitys onnistui. Selain ohjautuu nyt ownCloudiisi.",
"ownCloud password reset" => "ownCloud-salasanan nollaus",
"Use the following link to reset your password: {link}" => "Voit palauttaa salasanasi seuraavassa osoitteessa: {link}",
+"Request failed!<br>Did you make sure your email/username was right?" => "Pyyntö epäonnistui!<br>Olihan sähköpostiosoitteesi/käyttäjätunnuksesi oikein?",
"You will receive a link to reset your password via Email." => "Saat sähköpostitse linkin nollataksesi salasanan.",
"Username" => "Käyttäjätunnus",
"Request reset" => "Tilaus lähetetty",
@@ -118,6 +119,7 @@
"Database host" => "Tietokantapalvelin",
"Finish setup" => "Viimeistele asennus",
"web services under your control" => "verkkopalvelut hallinnassasi",
+"%s is available. Get more information on how to update." => "%s on saatavilla. Lue lisätietoja, miten päivitys asennetaan.",
"Log out" => "Kirjaudu ulos",
"Automatic logon rejected!" => "Automaattinen sisäänkirjautuminen hylättiin!",
"If you did not change your password recently, your account may be compromised!" => "Jos et vaihtanut salasanaasi äskettäin, tilisi saattaa olla murrettu.",
diff --git a/core/l10n/fr.php b/core/l10n/fr.php
index 84ea35abcf2..b01625a887b 100644
--- a/core/l10n/fr.php
+++ b/core/l10n/fr.php
@@ -44,11 +44,11 @@
"months ago" => "il y a plusieurs mois",
"last year" => "l'année dernière",
"years ago" => "il y a plusieurs années",
-"Ok" => "Ok",
-"Cancel" => "Annuler",
"Choose" => "Choisir",
+"Cancel" => "Annuler",
"Yes" => "Oui",
"No" => "Non",
+"Ok" => "Ok",
"The object type is not specified." => "Le type d'objet n'est pas spécifié.",
"Error" => "Erreur",
"The app name is not specified." => "Le nom de l'application n'est pas spécifié.",
diff --git a/core/l10n/gl.php b/core/l10n/gl.php
index 7269e792744..98652695446 100644
--- a/core/l10n/gl.php
+++ b/core/l10n/gl.php
@@ -44,11 +44,12 @@
"months ago" => "meses atrás",
"last year" => "último ano",
"years ago" => "anos atrás",
-"Ok" => "Aceptar",
-"Cancel" => "Cancelar",
"Choose" => "Escoller",
+"Cancel" => "Cancelar",
+"Error loading file picker template" => "Produciuse un erro ao cargar o modelo do selector de ficheiros",
"Yes" => "Si",
"No" => "Non",
+"Ok" => "Aceptar",
"The object type is not specified." => "Non se especificou o tipo de obxecto.",
"Error" => "Erro",
"The app name is not specified." => "Non se especificou o nome do aplicativo.",
diff --git a/core/l10n/he.php b/core/l10n/he.php
index 25603360741..eb2c3f3d153 100644
--- a/core/l10n/he.php
+++ b/core/l10n/he.php
@@ -44,11 +44,11 @@
"months ago" => "חודשים",
"last year" => "שנה שעברה",
"years ago" => "שנים",
-"Ok" => "בסדר",
-"Cancel" => "ביטול",
"Choose" => "בחירה",
+"Cancel" => "ביטול",
"Yes" => "כן",
"No" => "לא",
+"Ok" => "בסדר",
"The object type is not specified." => "סוג הפריט לא צוין.",
"Error" => "שגיאה",
"The app name is not specified." => "שם היישום לא צוין.",
diff --git a/core/l10n/hr.php b/core/l10n/hr.php
index e79e71d4b2d..660b47c54fd 100644
--- a/core/l10n/hr.php
+++ b/core/l10n/hr.php
@@ -28,11 +28,11 @@
"months ago" => "mjeseci",
"last year" => "prošlu godinu",
"years ago" => "godina",
-"Ok" => "U redu",
-"Cancel" => "Odustani",
"Choose" => "Izaberi",
+"Cancel" => "Odustani",
"Yes" => "Da",
"No" => "Ne",
+"Ok" => "U redu",
"Error" => "Greška",
"Share" => "Podijeli",
"Error while sharing" => "Greška prilikom djeljenja",
diff --git a/core/l10n/hu_HU.php b/core/l10n/hu_HU.php
index 4c44404fbc6..6b477746f25 100644
--- a/core/l10n/hu_HU.php
+++ b/core/l10n/hu_HU.php
@@ -44,11 +44,11 @@
"months ago" => "több hónapja",
"last year" => "tavaly",
"years ago" => "több éve",
-"Ok" => "Ok",
-"Cancel" => "Mégsem",
"Choose" => "Válasszon",
+"Cancel" => "Mégsem",
"Yes" => "Igen",
"No" => "Nem",
+"Ok" => "Ok",
"The object type is not specified." => "Az objektum típusa nincs megadva.",
"Error" => "Hiba",
"The app name is not specified." => "Az alkalmazás neve nincs megadva.",
diff --git a/core/l10n/id.php b/core/l10n/id.php
index 984822af1e3..065a4f2e727 100644
--- a/core/l10n/id.php
+++ b/core/l10n/id.php
@@ -44,11 +44,11 @@
"months ago" => "beberapa bulan lalu",
"last year" => "tahun kemarin",
"years ago" => "beberapa tahun lalu",
-"Ok" => "Oke",
-"Cancel" => "Batal",
"Choose" => "Pilih",
+"Cancel" => "Batal",
"Yes" => "Ya",
"No" => "Tidak",
+"Ok" => "Oke",
"The object type is not specified." => "Tipe objek tidak ditentukan.",
"Error" => "Galat",
"The app name is not specified." => "Nama aplikasi tidak ditentukan.",
diff --git a/core/l10n/is.php b/core/l10n/is.php
index d30d8bca11b..bd8b58b2904 100644
--- a/core/l10n/is.php
+++ b/core/l10n/is.php
@@ -43,11 +43,11 @@
"months ago" => "mánuðir síðan",
"last year" => "síðasta ári",
"years ago" => "einhverjum árum",
-"Ok" => "Í lagi",
-"Cancel" => "Hætta við",
"Choose" => "Veldu",
+"Cancel" => "Hætta við",
"Yes" => "Já",
"No" => "Nei",
+"Ok" => "Í lagi",
"The object type is not specified." => "Tegund ekki tilgreind",
"Error" => "Villa",
"The app name is not specified." => "Nafn forrits ekki tilgreint",
diff --git a/core/l10n/it.php b/core/l10n/it.php
index 15fba6ec7d3..ce8f6411295 100644
--- a/core/l10n/it.php
+++ b/core/l10n/it.php
@@ -44,11 +44,12 @@
"months ago" => "mesi fa",
"last year" => "anno scorso",
"years ago" => "anni fa",
-"Ok" => "Ok",
-"Cancel" => "Annulla",
"Choose" => "Scegli",
+"Cancel" => "Annulla",
+"Error loading file picker template" => "Errore durante il caricamento del modello del selezionatore di file",
"Yes" => "Sì",
"No" => "No",
+"Ok" => "Ok",
"The object type is not specified." => "Il tipo di oggetto non è specificato.",
"Error" => "Errore",
"The app name is not specified." => "Il nome dell'applicazione non è specificato.",
diff --git a/core/l10n/ja_JP.php b/core/l10n/ja_JP.php
index 783fe288ba3..8395a1d272e 100644
--- a/core/l10n/ja_JP.php
+++ b/core/l10n/ja_JP.php
@@ -44,11 +44,12 @@
"months ago" => "月前",
"last year" => "一年前",
"years ago" => "年前",
-"Ok" => "OK",
-"Cancel" => "キャンセル",
"Choose" => "選択",
+"Cancel" => "キャンセル",
+"Error loading file picker template" => "ファイルピッカーのテンプレートの読み込みエラー",
"Yes" => "はい",
"No" => "いいえ",
+"Ok" => "OK",
"The object type is not specified." => "オブジェクタイプが指定されていません。",
"Error" => "エラー",
"The app name is not specified." => "アプリ名がしていされていません。",
diff --git a/core/l10n/ka_GE.php b/core/l10n/ka_GE.php
index fd2e512654f..b474548eae8 100644
--- a/core/l10n/ka_GE.php
+++ b/core/l10n/ka_GE.php
@@ -44,11 +44,11 @@
"months ago" => "თვის წინ",
"last year" => "ბოლო წელს",
"years ago" => "წლის წინ",
-"Ok" => "დიახ",
-"Cancel" => "უარყოფა",
"Choose" => "არჩევა",
+"Cancel" => "უარყოფა",
"Yes" => "კი",
"No" => "არა",
+"Ok" => "დიახ",
"The object type is not specified." => "ობიექტის ტიპი არ არის მითითებული.",
"Error" => "შეცდომა",
"The app name is not specified." => "აპლიკაციის სახელი არ არის მითითებული.",
diff --git a/core/l10n/ko.php b/core/l10n/ko.php
index 08713edaee1..6b97d672cfd 100644
--- a/core/l10n/ko.php
+++ b/core/l10n/ko.php
@@ -44,11 +44,11 @@
"months ago" => "개월 전",
"last year" => "작년",
"years ago" => "년 전",
-"Ok" => "승락",
-"Cancel" => "취소",
"Choose" => "선택",
+"Cancel" => "취소",
"Yes" => "예",
"No" => "아니요",
+"Ok" => "승락",
"The object type is not specified." => "객체 유형이 지정되지 않았습니다.",
"Error" => "오류",
"The app name is not specified." => "앱 이름이 지정되지 않았습니다.",
diff --git a/core/l10n/lb.php b/core/l10n/lb.php
index f2277445f9c..4c312df6618 100644
--- a/core/l10n/lb.php
+++ b/core/l10n/lb.php
@@ -28,11 +28,11 @@
"months ago" => "Méint hier",
"last year" => "Läscht Joer",
"years ago" => "Joren hier",
-"Ok" => "OK",
-"Cancel" => "Ofbriechen",
"Choose" => "Auswielen",
+"Cancel" => "Ofbriechen",
"Yes" => "Jo",
"No" => "Nee",
+"Ok" => "OK",
"Error" => "Fehler",
"Share" => "Deelen",
"Password" => "Passwuert",
diff --git a/core/l10n/lt_LT.php b/core/l10n/lt_LT.php
index 85b76fe6948..1cd400117c8 100644
--- a/core/l10n/lt_LT.php
+++ b/core/l10n/lt_LT.php
@@ -33,11 +33,11 @@
"months ago" => "prieš mėnesį",
"last year" => "praeitais metais",
"years ago" => "prieš metus",
-"Ok" => "Gerai",
-"Cancel" => "Atšaukti",
"Choose" => "Pasirinkite",
+"Cancel" => "Atšaukti",
"Yes" => "Taip",
"No" => "Ne",
+"Ok" => "Gerai",
"Error" => "Klaida",
"Share" => "Dalintis",
"Error while sharing" => "Klaida, dalijimosi metu",
diff --git a/core/l10n/lv.php b/core/l10n/lv.php
index 18af82e4e36..e3d668d0183 100644
--- a/core/l10n/lv.php
+++ b/core/l10n/lv.php
@@ -44,11 +44,11 @@
"months ago" => "mēnešus atpakaļ",
"last year" => "gājušajā gadā",
"years ago" => "gadus atpakaļ",
-"Ok" => "Labi",
-"Cancel" => "Atcelt",
"Choose" => "Izvēlieties",
+"Cancel" => "Atcelt",
"Yes" => "Jā",
"No" => "Nē",
+"Ok" => "Labi",
"The object type is not specified." => "Nav norādīts objekta tips.",
"Error" => "Kļūda",
"The app name is not specified." => "Nav norādīts lietotnes nosaukums.",
diff --git a/core/l10n/mk.php b/core/l10n/mk.php
index a6c06e4780a..b0c39debb8a 100644
--- a/core/l10n/mk.php
+++ b/core/l10n/mk.php
@@ -43,11 +43,11 @@
"months ago" => "пред месеци",
"last year" => "минатата година",
"years ago" => "пред години",
-"Ok" => "Во ред",
-"Cancel" => "Откажи",
"Choose" => "Избери",
+"Cancel" => "Откажи",
"Yes" => "Да",
"No" => "Не",
+"Ok" => "Во ред",
"The object type is not specified." => "Не е специфициран типот на објект.",
"Error" => "Грешка",
"The app name is not specified." => "Името на апликацијата не е специфицирано.",
diff --git a/core/l10n/ms_MY.php b/core/l10n/ms_MY.php
index 70581ff7693..e7dc73a32c1 100644
--- a/core/l10n/ms_MY.php
+++ b/core/l10n/ms_MY.php
@@ -21,10 +21,10 @@
"November" => "November",
"December" => "Disember",
"Settings" => "Tetapan",
-"Ok" => "Ok",
"Cancel" => "Batal",
"Yes" => "Ya",
"No" => "Tidak",
+"Ok" => "Ok",
"Error" => "Ralat",
"Share" => "Kongsi",
"Password" => "Kata laluan",
diff --git a/core/l10n/my_MM.php b/core/l10n/my_MM.php
index ef8be954ede..6ea6a2c7bb5 100644
--- a/core/l10n/my_MM.php
+++ b/core/l10n/my_MM.php
@@ -21,11 +21,11 @@
"last month" => "ပြီးခဲ့သောလ",
"last year" => "မနှစ်က",
"years ago" => "နှစ် အရင်က",
-"Ok" => "အိုကေ",
-"Cancel" => "ပယ်ဖျက်မည်",
"Choose" => "ရွေးချယ်",
+"Cancel" => "ပယ်ဖျက်မည်",
"Yes" => "ဟုတ်",
"No" => "မဟုတ်ဘူး",
+"Ok" => "အိုကေ",
"Password" => "စကားဝှက်",
"Set expiration date" => "သက်တမ်းကုန်ဆုံးမည့်ရက်သတ်မှတ်မည်",
"Expiration date" => "သက်တမ်းကုန်ဆုံးမည့်ရက်",
diff --git a/core/l10n/nb_NO.php b/core/l10n/nb_NO.php
index 6efb31a7def..30d3f91df2a 100644
--- a/core/l10n/nb_NO.php
+++ b/core/l10n/nb_NO.php
@@ -34,11 +34,11 @@
"months ago" => "måneder siden",
"last year" => "forrige år",
"years ago" => "år siden",
-"Ok" => "Ok",
-"Cancel" => "Avbryt",
"Choose" => "Velg",
+"Cancel" => "Avbryt",
"Yes" => "Ja",
"No" => "Nei",
+"Ok" => "Ok",
"Error" => "Feil",
"Share" => "Del",
"Error while sharing" => "Feil under deling",
diff --git a/core/l10n/nl.php b/core/l10n/nl.php
index 7e823b2e61d..a39f34fb90c 100644
--- a/core/l10n/nl.php
+++ b/core/l10n/nl.php
@@ -44,11 +44,11 @@
"months ago" => "maanden geleden",
"last year" => "vorig jaar",
"years ago" => "jaar geleden",
-"Ok" => "Ok",
-"Cancel" => "Annuleer",
"Choose" => "Kies",
+"Cancel" => "Annuleer",
"Yes" => "Ja",
"No" => "Nee",
+"Ok" => "Ok",
"The object type is not specified." => "Het object type is niet gespecificeerd.",
"Error" => "Fout",
"The app name is not specified." => "De app naam is niet gespecificeerd.",
diff --git a/core/l10n/nn_NO.php b/core/l10n/nn_NO.php
index d11ff92fa88..de181ccc7ad 100644
--- a/core/l10n/nn_NO.php
+++ b/core/l10n/nn_NO.php
@@ -44,11 +44,11 @@
"months ago" => "månadar sidan",
"last year" => "i fjor",
"years ago" => "år sidan",
-"Ok" => "Greitt",
-"Cancel" => "Avbryt",
"Choose" => "Vel",
+"Cancel" => "Avbryt",
"Yes" => "Ja",
"No" => "Nei",
+"Ok" => "Greitt",
"The object type is not specified." => "Objekttypen er ikkje spesifisert.",
"Error" => "Feil",
"The app name is not specified." => "Programnamnet er ikkje spesifisert.",
diff --git a/core/l10n/oc.php b/core/l10n/oc.php
index a384b0315bb..1d14428f183 100644
--- a/core/l10n/oc.php
+++ b/core/l10n/oc.php
@@ -29,11 +29,11 @@
"months ago" => "meses a",
"last year" => "an passat",
"years ago" => "ans a",
-"Ok" => "D'accòrdi",
-"Cancel" => "Annula",
"Choose" => "Causís",
+"Cancel" => "Annula",
"Yes" => "Òc",
"No" => "Non",
+"Ok" => "D'accòrdi",
"Error" => "Error",
"Share" => "Parteja",
"Error while sharing" => "Error al partejar",
diff --git a/core/l10n/pl.php b/core/l10n/pl.php
index 5c8434984cf..045da821f2e 100644
--- a/core/l10n/pl.php
+++ b/core/l10n/pl.php
@@ -44,11 +44,12 @@
"months ago" => "miesięcy temu",
"last year" => "w zeszłym roku",
"years ago" => "lat temu",
-"Ok" => "OK",
-"Cancel" => "Anuluj",
"Choose" => "Wybierz",
+"Cancel" => "Anuluj",
+"Error loading file picker template" => "Błąd podczas ładowania pliku wybranego szablonu",
"Yes" => "Tak",
"No" => "Nie",
+"Ok" => "OK",
"The object type is not specified." => "Nie określono typu obiektu.",
"Error" => "Błąd",
"The app name is not specified." => "Nie określono nazwy aplikacji.",
@@ -88,6 +89,7 @@
"The update was successful. Redirecting you to ownCloud now." => "Aktualizacji zakończyła się powodzeniem. Przekierowuję do ownCloud.",
"ownCloud password reset" => "restart hasła ownCloud",
"Use the following link to reset your password: {link}" => "Użyj tego odnośnika by zresetować hasło: {link}",
+"The link to reset your password has been sent to your email.<br>If you do not receive it within a reasonable amount of time, check your spam/junk folders.<br>If it is not there ask your local administrator ." => "Link do zresetowania hasła została wysłana na adres email. <br> Jeśli nie otrzymasz go w najbliższym czasie, sprawdź folder ze spamem. <br> Jeśli go tam nie ma zwrócić się do administratora tego ownCloud-a.",
"Request failed!<br>Did you make sure your email/username was right?" => "Żądanie niepowiodło się!<br>Czy Twój email/nazwa użytkownika są poprawne?",
"You will receive a link to reset your password via Email." => "Odnośnik służący do resetowania hasła zostanie wysłany na adres e-mail.",
"Username" => "Nazwa użytkownika",
diff --git a/core/l10n/pt_BR.php b/core/l10n/pt_BR.php
index b52a9bb508a..59c8f69aee7 100644
--- a/core/l10n/pt_BR.php
+++ b/core/l10n/pt_BR.php
@@ -44,11 +44,12 @@
"months ago" => "meses atrás",
"last year" => "último ano",
"years ago" => "anos atrás",
-"Ok" => "Ok",
-"Cancel" => "Cancelar",
"Choose" => "Escolha",
+"Cancel" => "Cancelar",
+"Error loading file picker template" => "Template selecionador Erro ao carregar arquivo",
"Yes" => "Sim",
"No" => "Não",
+"Ok" => "Ok",
"The object type is not specified." => "O tipo de objeto não foi especificado.",
"Error" => "Erro",
"The app name is not specified." => "O nome do app não foi especificado.",
diff --git a/core/l10n/pt_PT.php b/core/l10n/pt_PT.php
index 1084fc618f7..0b2f511cb8e 100644
--- a/core/l10n/pt_PT.php
+++ b/core/l10n/pt_PT.php
@@ -44,11 +44,11 @@
"months ago" => "meses atrás",
"last year" => "ano passado",
"years ago" => "anos atrás",
-"Ok" => "Ok",
-"Cancel" => "Cancelar",
"Choose" => "Escolha",
+"Cancel" => "Cancelar",
"Yes" => "Sim",
"No" => "Não",
+"Ok" => "Ok",
"The object type is not specified." => "O tipo de objecto não foi especificado",
"Error" => "Erro",
"The app name is not specified." => "O nome da aplicação não foi especificado",
diff --git a/core/l10n/ro.php b/core/l10n/ro.php
index 36ee8ab4b6c..3d25a5f042b 100644
--- a/core/l10n/ro.php
+++ b/core/l10n/ro.php
@@ -44,11 +44,11 @@
"months ago" => "luni în urmă",
"last year" => "ultimul an",
"years ago" => "ani în urmă",
-"Ok" => "Ok",
-"Cancel" => "Anulare",
"Choose" => "Alege",
+"Cancel" => "Anulare",
"Yes" => "Da",
"No" => "Nu",
+"Ok" => "Ok",
"The object type is not specified." => "Tipul obiectului nu a fost specificat",
"Error" => "Eroare",
"The app name is not specified." => "Numele aplicației nu a fost specificat",
diff --git a/core/l10n/ru.php b/core/l10n/ru.php
index 43dd398119d..781eb1bbfa8 100644
--- a/core/l10n/ru.php
+++ b/core/l10n/ru.php
@@ -44,11 +44,11 @@
"months ago" => "несколько месяцев назад",
"last year" => "в прошлом году",
"years ago" => "несколько лет назад",
-"Ok" => "Ок",
-"Cancel" => "Отменить",
"Choose" => "Выбрать",
+"Cancel" => "Отменить",
"Yes" => "Да",
"No" => "Нет",
+"Ok" => "Ок",
"The object type is not specified." => "Тип объекта не указан",
"Error" => "Ошибка",
"The app name is not specified." => "Имя приложения не указано",
diff --git a/core/l10n/ru_RU.php b/core/l10n/ru_RU.php
index 8fb568aee7e..580df5961f8 100644
--- a/core/l10n/ru_RU.php
+++ b/core/l10n/ru_RU.php
@@ -1,3 +1,7 @@
<?php $TRANSLATIONS = array(
-"Settings" => "Настройки"
+"Settings" => "Настройки",
+"Cancel" => "Отмена",
+"Error" => "Ошибка",
+"Share" => "Сделать общим",
+"Add" => "Добавить"
);
diff --git a/core/l10n/si_LK.php b/core/l10n/si_LK.php
index c1e8ba37ed9..be7c1a24aad 100644
--- a/core/l10n/si_LK.php
+++ b/core/l10n/si_LK.php
@@ -28,11 +28,11 @@
"months ago" => "මාස කීපයකට පෙර",
"last year" => "පෙර අවුරුද්දේ",
"years ago" => "අවුරුදු කීපයකට පෙර",
-"Ok" => "හරි",
-"Cancel" => "එපා",
"Choose" => "තෝරන්න",
+"Cancel" => "එපා",
"Yes" => "ඔව්",
"No" => "එපා",
+"Ok" => "හරි",
"Error" => "දෝෂයක්",
"Share" => "බෙදා හදා ගන්න",
"Share with" => "බෙදාගන්න",
diff --git a/core/l10n/sk_SK.php b/core/l10n/sk_SK.php
index 6a2d0aa5ece..2dfaa01b5a1 100644
--- a/core/l10n/sk_SK.php
+++ b/core/l10n/sk_SK.php
@@ -44,11 +44,11 @@
"months ago" => "pred mesiacmi",
"last year" => "minulý rok",
"years ago" => "pred rokmi",
-"Ok" => "Ok",
-"Cancel" => "Zrušiť",
"Choose" => "Výber",
+"Cancel" => "Zrušiť",
"Yes" => "Áno",
"No" => "Nie",
+"Ok" => "Ok",
"The object type is not specified." => "Nešpecifikovaný typ objektu.",
"Error" => "Chyba",
"The app name is not specified." => "Nešpecifikované meno aplikácie.",
diff --git a/core/l10n/sl.php b/core/l10n/sl.php
index 28548071306..a433aa2cc4e 100644
--- a/core/l10n/sl.php
+++ b/core/l10n/sl.php
@@ -44,11 +44,11 @@
"months ago" => "mesecev nazaj",
"last year" => "lansko leto",
"years ago" => "let nazaj",
-"Ok" => "V redu",
-"Cancel" => "Prekliči",
"Choose" => "Izbor",
+"Cancel" => "Prekliči",
"Yes" => "Da",
"No" => "Ne",
+"Ok" => "V redu",
"The object type is not specified." => "Vrsta predmeta ni podana.",
"Error" => "Napaka",
"The app name is not specified." => "Ime programa ni podano.",
diff --git a/core/l10n/sq.php b/core/l10n/sq.php
index 8769a833e18..40562add933 100644
--- a/core/l10n/sq.php
+++ b/core/l10n/sq.php
@@ -44,11 +44,11 @@
"months ago" => "muaj më parë",
"last year" => "vitin e shkuar",
"years ago" => "vite më parë",
-"Ok" => "Në rregull",
-"Cancel" => "Anulo",
"Choose" => "Zgjidh",
+"Cancel" => "Anulo",
"Yes" => "Po",
"No" => "Jo",
+"Ok" => "Në rregull",
"The object type is not specified." => "Nuk është specifikuar tipi i objektit.",
"Error" => "Veprim i gabuar",
"The app name is not specified." => "Nuk është specifikuar emri i app-it.",
diff --git a/core/l10n/sr.php b/core/l10n/sr.php
index 2329dc49b17..49664f19f34 100644
--- a/core/l10n/sr.php
+++ b/core/l10n/sr.php
@@ -41,11 +41,11 @@
"months ago" => "месеци раније",
"last year" => "прошле године",
"years ago" => "година раније",
-"Ok" => "У реду",
-"Cancel" => "Откажи",
"Choose" => "Одабери",
+"Cancel" => "Откажи",
"Yes" => "Да",
"No" => "Не",
+"Ok" => "У реду",
"The object type is not specified." => "Врста објекта није подешена.",
"Error" => "Грешка",
"The app name is not specified." => "Име програма није унето.",
diff --git a/core/l10n/sv.php b/core/l10n/sv.php
index 26bcebdf6c5..d4154678b65 100644
--- a/core/l10n/sv.php
+++ b/core/l10n/sv.php
@@ -44,11 +44,11 @@
"months ago" => "månader sedan",
"last year" => "förra året",
"years ago" => "år sedan",
-"Ok" => "Ok",
-"Cancel" => "Avbryt",
"Choose" => "Välj",
+"Cancel" => "Avbryt",
"Yes" => "Ja",
"No" => "Nej",
+"Ok" => "Ok",
"The object type is not specified." => "Objekttypen är inte specificerad.",
"Error" => "Fel",
"The app name is not specified." => " Namnet på appen är inte specificerad.",
diff --git a/core/l10n/ta_LK.php b/core/l10n/ta_LK.php
index b01f8df945e..b67f5e967ec 100644
--- a/core/l10n/ta_LK.php
+++ b/core/l10n/ta_LK.php
@@ -39,11 +39,11 @@
"months ago" => "மாதங்களுக்கு முன்",
"last year" => "கடந்த வருடம்",
"years ago" => "வருடங்களுக்கு முன்",
-"Ok" => "சரி",
-"Cancel" => "இரத்து செய்க",
"Choose" => "தெரிவுசெய்க ",
+"Cancel" => "இரத்து செய்க",
"Yes" => "ஆம்",
"No" => "இல்லை",
+"Ok" => "சரி",
"The object type is not specified." => "பொருள் வகை குறிப்பிடப்படவில்லை.",
"Error" => "வழு",
"The app name is not specified." => "செயலி பெயர் குறிப்பிடப்படவில்லை.",
diff --git a/core/l10n/te.php b/core/l10n/te.php
index 040ab9b550e..1469d37296f 100644
--- a/core/l10n/te.php
+++ b/core/l10n/te.php
@@ -33,10 +33,10 @@
"months ago" => "నెలల క్రితం",
"last year" => "పోయిన సంవత్సరం",
"years ago" => "సంవత్సరాల క్రితం",
-"Ok" => "సరే",
"Cancel" => "రద్దుచేయి",
"Yes" => "అవును",
"No" => "కాదు",
+"Ok" => "సరే",
"Error" => "పొరపాటు",
"Password" => "సంకేతపదం",
"Send" => "పంపించు",
diff --git a/core/l10n/th_TH.php b/core/l10n/th_TH.php
index 1114726434c..66f5629b933 100644
--- a/core/l10n/th_TH.php
+++ b/core/l10n/th_TH.php
@@ -43,11 +43,11 @@
"months ago" => "เดือน ที่ผ่านมา",
"last year" => "ปีที่แล้ว",
"years ago" => "ปี ที่ผ่านมา",
-"Ok" => "ตกลง",
-"Cancel" => "ยกเลิก",
"Choose" => "เลือก",
+"Cancel" => "ยกเลิก",
"Yes" => "ตกลง",
"No" => "ไม่ตกลง",
+"Ok" => "ตกลง",
"The object type is not specified." => "ชนิดของวัตถุยังไม่ได้รับการระบุ",
"Error" => "ข้อผิดพลาด",
"The app name is not specified." => "ชื่อของแอปยังไม่ได้รับการระบุชื่อ",
diff --git a/core/l10n/tr.php b/core/l10n/tr.php
index 29a6e7a286f..47574a01259 100644
--- a/core/l10n/tr.php
+++ b/core/l10n/tr.php
@@ -44,11 +44,11 @@
"months ago" => "ay önce",
"last year" => "geçen yıl",
"years ago" => "yıl önce",
-"Ok" => "Tamam",
-"Cancel" => "İptal",
"Choose" => "seç",
+"Cancel" => "İptal",
"Yes" => "Evet",
"No" => "Hayır",
+"Ok" => "Tamam",
"The object type is not specified." => "Nesne türü belirtilmemiş.",
"Error" => "Hata",
"The app name is not specified." => "uygulama adı belirtilmedi.",
diff --git a/core/l10n/ug.php b/core/l10n/ug.php
index 4727e37debd..c1bf48e07dd 100644
--- a/core/l10n/ug.php
+++ b/core/l10n/ug.php
@@ -23,10 +23,10 @@
"1 hour ago" => "1 سائەت ئىلگىرى",
"today" => "بۈگۈن",
"yesterday" => "تۈنۈگۈن",
-"Ok" => "جەزملە",
"Cancel" => "ۋاز كەچ",
"Yes" => "ھەئە",
"No" => "ياق",
+"Ok" => "جەزملە",
"Error" => "خاتالىق",
"Share" => "ھەمبەھىر",
"Share with" => "ھەمبەھىر",
diff --git a/core/l10n/uk.php b/core/l10n/uk.php
index a9e4117a619..65577297c3c 100644
--- a/core/l10n/uk.php
+++ b/core/l10n/uk.php
@@ -44,11 +44,11 @@
"months ago" => "місяці тому",
"last year" => "минулого року",
"years ago" => "роки тому",
-"Ok" => "Ok",
-"Cancel" => "Відмінити",
"Choose" => "Обрати",
+"Cancel" => "Відмінити",
"Yes" => "Так",
"No" => "Ні",
+"Ok" => "Ok",
"The object type is not specified." => "Не визначено тип об'єкту.",
"Error" => "Помилка",
"The app name is not specified." => "Не визначено ім'я програми.",
diff --git a/core/l10n/ur_PK.php b/core/l10n/ur_PK.php
index 544d041e48f..cf26212c25e 100644
--- a/core/l10n/ur_PK.php
+++ b/core/l10n/ur_PK.php
@@ -14,11 +14,11 @@
"November" => "نومبر",
"December" => "دسمبر",
"Settings" => "سیٹینگز",
-"Ok" => "اوکے",
-"Cancel" => "منسوخ کریں",
"Choose" => "منتخب کریں",
+"Cancel" => "منسوخ کریں",
"Yes" => "ہاں",
"No" => "نہیں",
+"Ok" => "اوکے",
"Error" => "ایرر",
"Error while sharing" => "شئیرنگ کے دوران ایرر",
"Error while unsharing" => "شئیرنگ ختم کرنے کے دوران ایرر",
diff --git a/core/l10n/vi.php b/core/l10n/vi.php
index 31c4a37545c..3e320ecf800 100644
--- a/core/l10n/vi.php
+++ b/core/l10n/vi.php
@@ -44,11 +44,11 @@
"months ago" => "tháng trước",
"last year" => "năm trước",
"years ago" => "năm trước",
-"Ok" => "Đồng ý",
-"Cancel" => "Hủy",
"Choose" => "Chọn",
+"Cancel" => "Hủy",
"Yes" => "Có",
"No" => "Không",
+"Ok" => "Đồng ý",
"The object type is not specified." => "Loại đối tượng không được chỉ định.",
"Error" => "Lỗi",
"The app name is not specified." => "Tên ứng dụng không được chỉ định.",
diff --git a/core/l10n/zh_CN.GB2312.php b/core/l10n/zh_CN.GB2312.php
index 7e98d69b642..2e0d0da6f2f 100644
--- a/core/l10n/zh_CN.GB2312.php
+++ b/core/l10n/zh_CN.GB2312.php
@@ -41,11 +41,11 @@
"months ago" => "月前",
"last year" => "去年",
"years ago" => "年前",
-"Ok" => "好的",
-"Cancel" => "取消",
"Choose" => "选择",
+"Cancel" => "取消",
"Yes" => "是",
"No" => "否",
+"Ok" => "好的",
"The object type is not specified." => "未指定对象类型。",
"Error" => "出错",
"The app name is not specified." => "未指定应用名称。",
diff --git a/core/l10n/zh_CN.php b/core/l10n/zh_CN.php
index c37f7b2602b..59dd4d2b86a 100644
--- a/core/l10n/zh_CN.php
+++ b/core/l10n/zh_CN.php
@@ -44,11 +44,11 @@
"months ago" => "月前",
"last year" => "去年",
"years ago" => "年前",
-"Ok" => "好",
-"Cancel" => "取消",
"Choose" => "选择(&C)...",
+"Cancel" => "取消",
"Yes" => "是",
"No" => "否",
+"Ok" => "好",
"The object type is not specified." => "未指定对象类型。",
"Error" => "错误",
"The app name is not specified." => "未指定App名称。",
diff --git a/core/l10n/zh_HK.php b/core/l10n/zh_HK.php
index c4f40095177..21418fe2eeb 100644
--- a/core/l10n/zh_HK.php
+++ b/core/l10n/zh_HK.php
@@ -23,10 +23,10 @@
"yesterday" => "昨日",
"last month" => "前一月",
"months ago" => "個月之前",
-"Ok" => "OK",
"Cancel" => "取消",
"Yes" => "Yes",
"No" => "No",
+"Ok" => "OK",
"Error" => "錯誤",
"Shared" => "已分享",
"Share" => "分享",
diff --git a/core/l10n/zh_TW.php b/core/l10n/zh_TW.php
index 6537e6dff07..4de91230327 100644
--- a/core/l10n/zh_TW.php
+++ b/core/l10n/zh_TW.php
@@ -44,11 +44,11 @@
"months ago" => "幾個月前",
"last year" => "去年",
"years ago" => "幾年前",
-"Ok" => "好",
-"Cancel" => "取消",
"Choose" => "選擇",
+"Cancel" => "取消",
"Yes" => "是",
"No" => "否",
+"Ok" => "好",
"The object type is not specified." => "未指定物件類型。",
"Error" => "錯誤",
"The app name is not specified." => "沒有指定 app 名稱。",
diff --git a/core/templates/filepicker.html b/core/templates/filepicker.html
new file mode 100644
index 00000000000..e761fbdb567
--- /dev/null
+++ b/core/templates/filepicker.html
@@ -0,0 +1,10 @@
+<div id="{dialog_name}" title="{title}">
+ <span class="dirtree"></span>
+ <ul class="filelist">
+ <li data-entryname="{filename}" data-type="{type}">
+ <img />
+ <span class="filename">{filename}</span>
+ <span class="date">{date}</span>
+ </li>
+ </ul>
+</div>
diff --git a/core/templates/message.html b/core/templates/message.html
new file mode 100644
index 00000000000..59048100f32
--- /dev/null
+++ b/core/templates/message.html
@@ -0,0 +1,3 @@
+<div id="{dialog_name}" title="{title}">
+ <p><span class="ui-icon ui-icon-{type}"></span>{message}</p>
+</div>