From 718d613cdcc5ce778c0ad398692c583a32af2680 Mon Sep 17 00:00:00 2001 From: David Norton Date: Wed, 21 Jun 2006 23:22:37 +0000 Subject: [PATCH] Command-shift-S should now work as soon as you start Firefox. Lots of localization, moving style out of XUL and into overlay.css --- .../chromeFiles/content/scholar/itemPane.js | 10 +-- .../chromeFiles/content/scholar/itemPane.xul | 16 ++-- chrome/chromeFiles/content/scholar/overlay.js | 8 +- .../chromeFiles/content/scholar/overlay.xul | 15 ++-- .../content/scholar/preferences.xul | 2 +- .../locale/en-US/scholar/preferences.dtd | 3 +- .../locale/en-US/scholar/scholar.dtd | 22 +++--- .../locale/en-US/scholar/scholar.properties | 20 +++-- .../skin/default/scholar/overlay.css | 76 +++++++++++-------- 9 files changed, 97 insertions(+), 75 deletions(-) diff --git a/chrome/chromeFiles/content/scholar/itemPane.js b/chrome/chromeFiles/content/scholar/itemPane.js index cb413c0c9f..75eb55717a 100644 --- a/chrome/chromeFiles/content/scholar/itemPane.js +++ b/chrome/chromeFiles/content/scholar/itemPane.js @@ -129,7 +129,7 @@ ScholarItemPane = new function() function changeTypeTo(id) { - if(id != _itemBeingEdited.getType() && confirm('Are you sure you want to change the item type? Certain fields may be lost.')) + if(id != _itemBeingEdited.getType() && confirm(Scholar.getString('pane.item.changeType'))) { _itemBeingEdited.setType(id); _itemBeingEdited.save(); @@ -321,7 +321,7 @@ ScholarItemPane = new function() function removeSelectedNote() { if(_notesField.value != "") - if(!confirm("Are you sure you want to delete the selected note?")) + if(!confirm(Scholar.getString('pane.item.notes.delete.confirm'))) return; var id = _selectedNoteID(); @@ -348,7 +348,7 @@ ScholarItemPane = new function() function addNote() { modifySelectedNote(); - _notesMenu.appendItem('Untitled Note',null); + _notesMenu.appendItem(Scholar.getString('pane.item.notes.untitled'),null); _notesMenu.selectedIndex = _notesMenu.firstChild.childNodes.length-1; onNoteSelected(); @@ -380,7 +380,7 @@ ScholarItemPane = new function() if(t == "") { - return "Untitled Note"; + return Scholar.getString('pane.item.notes.untitled'); } else { @@ -392,7 +392,7 @@ ScholarItemPane = new function() { var c = _notesMenu.firstChild.childNodes.length; - _notesLabel.value = c + " note" + (c != 1 ? "s" : "") + ":"; + _notesLabel.value = Scholar.getString('pane.item.notes.count.'+(c != 1 ? "plural" : "singular")).replace('%1',c) + ":"; } function _selectedNoteID() diff --git a/chrome/chromeFiles/content/scholar/itemPane.xul b/chrome/chromeFiles/content/scholar/itemPane.xul index 934b36c275..f22f63659e 100644 --- a/chrome/chromeFiles/content/scholar/itemPane.xul +++ b/chrome/chromeFiles/content/scholar/itemPane.xul @@ -5,12 +5,12 @@ xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">