diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..1ecdc79 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/fxkeyboard* diff --git a/src/chrome.manifest b/src/chrome.manifest index 3731dca..c2d5040 100644 --- a/src/chrome.manifest +++ b/src/chrome.manifest @@ -1,12 +1,5 @@ content fxkeyboard chrome/content/ locale fxkeyboard en-US chrome/locale/en-US/ -locale fxkeyboard de-DE chrome/locale/de-DE/ -locale fxkeyboard sl-SI chrome/locale/sl-SI/ -locale fxkeyboard hr-HR chrome/locale/hr-HR/ -locale fxkeyboard ru-RU chrome/locale/ru-RU/ -locale fxkeyboard it-IT chrome/locale/it-IT/ -locale fxkeyboard pl-PL chrome/locale/pl-PL/ -locale fxkeyboard fr-FR chrome/locale/fr-FR/ overlay chrome://browser/content/browser.xul chrome://fxkeyboard/locale/overlay.xul diff --git a/src/chrome/content/overlay.css b/src/chrome/content/overlay.css index fcac560..7891ca2 100644 --- a/src/chrome/content/overlay.css +++ b/src/chrome/content/overlay.css @@ -4,8 +4,5 @@ #fxKeyboardToolbar button { min-width:1px; + font-family: mono; } - -.fxKeyboardActionKeys { - font-weight:bold; -} \ No newline at end of file diff --git a/src/chrome/content/overlay.js b/src/chrome/content/overlay.js index 394692b..fd322e3 100644 --- a/src/chrome/content/overlay.js +++ b/src/chrome/content/overlay.js @@ -32,7 +32,7 @@ var fxKeyboard = { buttons[b].flex = 1; } - this.shift = 0; // 0 closed, 1 open, 2 persistent + //this.shift = 0; // 0 closed, 1 open, 2 persistent this.toolbar = document.getElementById('fxKeyboardToolbar'); this.mainKeys = document.getElementById('fxKeyboardMainKeys'); this.keys = this.mainKeys.getElementsByClassName('fxKeyboardKey'); @@ -88,11 +88,11 @@ var fxKeyboard = { { // press a key on the focused item if (typeof(key)=='string') { - if (this.shift > 0) { + /*if (this.shift > 0) { key = key.toUpperCase(); if ( this.shift<2 ) this.undoShift(); - } + }*/ key = key.charCodeAt(0); } @@ -110,7 +110,7 @@ var fxKeyboard = { evt.initKeyEvent("keypress", true, true, null, false, false, false, false, key, 0); this.focus.dispatchEvent(evt); }, - undoShift: function () { + /*undoShift: function () { fxKeyboard.shift = 0; for( var k in fxKeyboard.keys) { if (fxKeyboard.keys[k].label!==undefined) @@ -145,33 +145,27 @@ var fxKeyboard = { this.undoShift(); break; } - }, - switchAltKeys: function () { + },*/ + switchAltKeys: function ( keep ) { // reset shift - if ( this.shift > 0) { + /*if ( this.shift > 0) { document.getElementById('fxKeyboardShift').style.color = 'inherit'; this.undoShift(); - } + }*/ - switch ( this.alt ) { - case 0: - // show alt - this.mainKeys.collapsed = true; - this.altKeys.collapsed = false; - this.alt = 1; - break; - case 1: - // keep alt + if (this.alt > 0) { + document.getElementById('fxKeyboardAlt').style.color = 'inherit'; + this.mainKeys.collapsed = false; + this.altKeys.collapsed = true; + this.alt = 0; + } else { + this.mainKeys.collapsed = true; + this.altKeys.collapsed = false; + this.alt = 1; + if (keep) { document.getElementById('fxKeyboardAlt').style.color = 'red'; this.alt = 2; - break; - default: - // show default - document.getElementById('fxKeyboardAlt').style.color = 'inherit'; - this.mainKeys.collapsed = false; - this.altKeys.collapsed = true; - this.alt = 0; - break; + } } }, doClear: function() { diff --git a/src/chrome/locale/de-DE/overlay.xul b/src/chrome/locale/de-DE/overlay.xul deleted file mode 100644 index 1abfbb6..0000000 --- a/src/chrome/locale/de-DE/overlay.xul +++ /dev/null @@ -1,96 +0,0 @@ - - - -