add titles to buttons on pad and code
This commit is contained in:
parent
ebf5c27453
commit
44fe95c76b
@ -200,14 +200,18 @@ define([
|
|||||||
var $rightside = $bar.find('.' + Toolbar.constants.rightside);
|
var $rightside = $bar.find('.' + Toolbar.constants.rightside);
|
||||||
|
|
||||||
/* add an export button */
|
/* add an export button */
|
||||||
var $export = $('<button>')
|
var $export = $('<button>', {
|
||||||
|
title: Messages.exportButtonTitle,
|
||||||
|
})
|
||||||
.text(Messages.exportButton)
|
.text(Messages.exportButton)
|
||||||
.addClass('rightside-button')
|
.addClass('rightside-button')
|
||||||
.click(exportText);
|
.click(exportText);
|
||||||
$rightside.append($export);
|
$rightside.append($export);
|
||||||
|
|
||||||
/* add an import button */
|
/* add an import button */
|
||||||
var $import = $('<button>')
|
var $import = $('<button>',{
|
||||||
|
title: Messages.importButtonTitle
|
||||||
|
})
|
||||||
.text(Messages.importButton)
|
.text(Messages.importButton)
|
||||||
.addClass('rightside-button')
|
.addClass('rightside-button')
|
||||||
.click(Cryptpad.importContent('text/plain', function (content, file) {
|
.click(Cryptpad.importContent('text/plain', function (content, file) {
|
||||||
@ -231,7 +235,8 @@ define([
|
|||||||
|
|
||||||
/* add a rename button */
|
/* add a rename button */
|
||||||
var $setTitle = $('<button>', {
|
var $setTitle = $('<button>', {
|
||||||
id: 'name-pad'
|
id: 'name-pad',
|
||||||
|
title: Messages.renameButtonTitle,
|
||||||
})
|
})
|
||||||
.addClass('rightside-button')
|
.addClass('rightside-button')
|
||||||
.text(Messages.renameButton)
|
.text(Messages.renameButton)
|
||||||
@ -252,6 +257,7 @@ define([
|
|||||||
/* add a forget button */
|
/* add a forget button */
|
||||||
var $forgetPad = $('<button>', {
|
var $forgetPad = $('<button>', {
|
||||||
id: 'cryptpad-forget',
|
id: 'cryptpad-forget',
|
||||||
|
title: Messages.forgetButtonTitle,
|
||||||
})
|
})
|
||||||
.text(Messages.forgetButton)
|
.text(Messages.forgetButton)
|
||||||
.addClass('cryptpad-forget rightside-button')
|
.addClass('cryptpad-forget rightside-button')
|
||||||
|
|||||||
@ -435,13 +435,17 @@ define([
|
|||||||
var $rightside = $bar.find('.' + Toolbar.constants.rightside);
|
var $rightside = $bar.find('.' + Toolbar.constants.rightside);
|
||||||
|
|
||||||
/* add an export button */
|
/* add an export button */
|
||||||
var $export = $('<button>')
|
var $export = $('<button>', {
|
||||||
|
title: Messages.exportButtonTitle,
|
||||||
|
})
|
||||||
.text(Messages.exportButton)
|
.text(Messages.exportButton)
|
||||||
.addClass('rightside-button')
|
.addClass('rightside-button')
|
||||||
.click(exportFile);
|
.click(exportFile);
|
||||||
|
|
||||||
/* add an import button */
|
/* add an import button */
|
||||||
var $import = $('<button>')
|
var $import = $('<button>', {
|
||||||
|
title: Messages.importButtonTitle
|
||||||
|
})
|
||||||
.text(Messages.importButton)
|
.text(Messages.importButton)
|
||||||
.addClass('rightside-button')
|
.addClass('rightside-button')
|
||||||
.click(Cryptpad.importContent('text/plain', function (content) {
|
.click(Cryptpad.importContent('text/plain', function (content) {
|
||||||
@ -454,6 +458,7 @@ define([
|
|||||||
/* add a rename button */
|
/* add a rename button */
|
||||||
var $rename = $('<button>', {
|
var $rename = $('<button>', {
|
||||||
id: 'name-pad',
|
id: 'name-pad',
|
||||||
|
title: Messages.renameButtonTitle,
|
||||||
})
|
})
|
||||||
.addClass('cryptpad-rename rightside-button')
|
.addClass('cryptpad-rename rightside-button')
|
||||||
.text(Messages.renameButton)
|
.text(Messages.renameButton)
|
||||||
@ -476,6 +481,7 @@ define([
|
|||||||
/* add a forget button */
|
/* add a forget button */
|
||||||
var $forgetPad = $('<button>', {
|
var $forgetPad = $('<button>', {
|
||||||
id: 'cryptpad-forget',
|
id: 'cryptpad-forget',
|
||||||
|
title: Messages.forgetButtonTitle,
|
||||||
})
|
})
|
||||||
.text(Messages.forgetButton)
|
.text(Messages.forgetButton)
|
||||||
.addClass('cryptpad-forget rightside-button')
|
.addClass('cryptpad-forget rightside-button')
|
||||||
@ -492,7 +498,7 @@ define([
|
|||||||
// set the hash
|
// set the hash
|
||||||
window.location.hash = info.channel + secret.key;
|
window.location.hash = info.channel + secret.key;
|
||||||
|
|
||||||
var title = document.title = Cryptpad.getPadTitle();
|
var title = document.title = Cryptpad.getPadTitle() || $title.val();
|
||||||
Cryptpad.rememberPad(title);
|
Cryptpad.rememberPad(title);
|
||||||
Cryptpad.styleAlerts();
|
Cryptpad.styleAlerts();
|
||||||
};
|
};
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user