diff --git a/.idea/encodings.xml b/.idea/encodings.xml
new file mode 100644
index 00000000..97626ba4
--- /dev/null
+++ b/.idea/encodings.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.jshintrc b/.jshintrc
index 9f6a4cc3..8e739bf2 100644
--- a/.jshintrc
+++ b/.jshintrc
@@ -88,8 +88,6 @@
"globals" : {
"require": true,
"module": true,
- "console": true,
- "performance": true,
"$": true,
"_": true
}
diff --git a/Gruntfile.js b/Gruntfile.js
index ec088016..26f4f4da 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -16,7 +16,7 @@ module.exports = function(grunt) {
var webpack = require('webpack');
var pkg = require('./package.json');
var dt = new Date().toISOString().replace(/T.*/, '');
- var electronVersion = '0.35.1';
+ var electronVersion = '0.36.0';
function replaceFont(css) {
css.walkAtRules('font-face', function (rule) {
@@ -152,12 +152,15 @@ module.exports = function(grunt) {
manifest: {
options: {
replacements: [
- { pattern: '# YYYY-MM-DD:v0.0.0', replacement: '# ' + dt + ':v' + pkg.version },
- { pattern: 'vElectron', replacement: electronVersion }
+ { pattern: '# YYYY-MM-DD:v0.0.0', replacement: '# ' + dt + ':v' + pkg.version }
]
},
files: { 'dist/manifest.appcache': 'app/manifest.appcache' }
},
+ 'manifest_html': {
+ options: { replacements: [{ pattern: '
-
+
<% lastOpenFiles.forEach(function(file) { %>
-
+
<%- file.name %>
diff --git a/app/templates/settings/settings-file.html b/app/templates/settings/settings-file.html
index ad9db3c3..d064846c 100644
--- a/app/templates/settings/settings-file.html
+++ b/app/templates/settings/settings-file.html
@@ -7,21 +7,27 @@
This file is opened from Dropbox.
<% } %>
<% } else { %>
-
This database is loaded in memory. To enable auto-save and saving with shortcut <%= cmd %>S,
- please, save it to <%= supportFiles ? 'file or ' : '' %>Dropbox.
+
This file is stored in internal app storage.
<% if (!supportFiles) { %>
Want to work seamlessly with local files? Download a desktop app
<% } %>
<% } %>
- Save to file
+ <% if (!storage || storage === 'file') { %>Save <% } %>
+ >Sync with Dropbox
+ <% if (storage !== 'file') { %>Save to file <% } %>
Export to XML
- >
- Sync with Dropbox <%= syncing ? '(working...)' : '' %>
Close
+ <% if (storage) { %>
+
Sync
+
Last sync: <%= syncDate || 'unknown' %> <%= syncing ? '(sync in progress...)' : '' %>
+ <% if (syncError) { %>
Sync error: <%- syncError %>
<% } %>
+ <% } %>
+
Settings
Master password:
diff --git a/app/templates/settings/settings-general.html b/app/templates/settings/settings-general.html
index e0c875f3..2f3bfd3d 100644
--- a/app/templates/settings/settings-general.html
+++ b/app/templates/settings/settings-general.html
@@ -56,6 +56,10 @@
Entries list table view
<% } %>
+
+ />
+ Colorful custom icons in list
+
Function
@@ -85,13 +89,18 @@
<% } %>
- <% if (canMinimizeOnClose) { %>
+ <% if (canMinimize) { %>
/>
+ <%- minimizeOnClose ? 'checked' : '' %> />
Minimize app instead of close
<% } %>
+
+ />
+ Auto-lock on minimize
+
<% if (devTools) { %>
Advanced
diff --git a/app/templates/settings/settings-help.html b/app/templates/settings/settings-help.html
index 8cc5db6a..834022c9 100644
--- a/app/templates/settings/settings-help.html
+++ b/app/templates/settings/settings-help.html
@@ -29,5 +29,5 @@
Updates
-
App twitter: kee_web
+
App twitter: kee_web
diff --git a/bower.json b/bower.json
index 0ff0ad38..f3957cd2 100644
--- a/bower.json
+++ b/bower.json
@@ -24,12 +24,12 @@
"private": true,
"dependencies": {
"backbone": "~1.2.3",
- "baron": "~0.7.11",
+ "baron": "~1.0.1",
"bourbon": "~4.2.5",
- "dropbox": "antelle/dropbox-js#0.10.5",
+ "dropbox": "antelle/dropbox-js#0.10.6",
"font-awesome": "~4.4.0",
"install": "~1.0.4",
- "kdbxweb": "~0.2.7",
+ "kdbxweb": "~0.3.2",
"normalize.css": "~3.0.3",
"pikaday": "~1.3.3",
"zepto": "~1.1.6",
diff --git a/electron/app.js b/electron/app.js
index 9bf72d43..422086b1 100644
--- a/electron/app.js
+++ b/electron/app.js
@@ -28,15 +28,56 @@ app.on('window-all-closed', function() {
app.removeAllListeners('window-all-closed');
app.removeAllListeners('ready');
app.removeAllListeners('open-file');
+ app.removeAllListeners('activate');
var userDataAppFile = path.join(app.getPath('userData'), 'app.js');
delete require.cache[require.resolve('./app.js')];
require(userDataAppFile);
app.emit('ready');
} else {
- app.quit();
+ if (process.platform !== 'darwin') {
+ app.quit();
+ }
}
});
app.on('ready', function() {
+ createMainWindow();
+});
+app.on('open-file', function(e, path) {
+ e.preventDefault();
+ openFile = path;
+ notifyOpenFile();
+});
+app.on('activate', function() {
+ if (process.platform === 'darwin') {
+ if (!mainWindow) {
+ createMainWindow();
+ }
+ }
+});
+app.restartApp = function() {
+ restartPending = true;
+ mainWindow.close();
+ setTimeout(function() { restartPending = false; }, 1000);
+};
+app.openWindow = function(opts) {
+ return new BrowserWindow(opts);
+};
+app.minimizeApp = function() {
+ if (process.platform === 'win32') {
+ mainWindow.minimize();
+ mainWindow.setSkipTaskbar(true);
+ appIcon = new Tray(path.join(__dirname, 'icon.png'));
+ appIcon.on('click', restoreMainWindow);
+ var contextMenu = Menu.buildFromTemplate([
+ { label: 'Open KeeWeb', click: restoreMainWindow },
+ { label: 'Quit KeeWeb', click: closeMainWindow }
+ ]);
+ appIcon.setContextMenu(contextMenu);
+ appIcon.setToolTip('KeeWeb');
+ }
+};
+
+function createMainWindow() {
mainWindow = new BrowserWindow({
show: false,
width: 1000, height: 700, 'min-width': 600, 'min-height': 300,
@@ -54,34 +95,10 @@ app.on('ready', function() {
mainWindow.on('closed', function() {
mainWindow = null;
});
-});
-app.on('open-file', function(e, path) {
- e.preventDefault();
- openFile = path;
- notifyOpenFile();
-});
-app.restartApp = function() {
- restartPending = true;
- mainWindow.close();
- setTimeout(function() { restartPending = false; }, 1000);
-};
-app.openWindow = function(opts) {
- return new BrowserWindow(opts);
-};
-app.minimizeApp = function() {
- if (process.platform === 'win32') {
- mainWindow.minimize();
- mainWindow.setSkipTaskbar(true);
- appIcon = new Tray(path.join(__dirname, 'icon.png'));
- appIcon.on('clicked', restoreMainWindow);
- var contextMenu = Menu.buildFromTemplate([
- { label: 'Open KeeWeb', click: restoreMainWindow },
- { label: 'Quit KeeWeb', click: closeMainWindow }
- ]);
- appIcon.setContextMenu(contextMenu);
- appIcon.setToolTip('KeeWeb');
- }
-};
+ mainWindow.on('minimize', function() {
+ emitBackboneEvent('launcher-minimize');
+ });
+}
function restoreMainWindow() {
appIcon.destroy();
@@ -93,7 +110,11 @@ function restoreMainWindow() {
function closeMainWindow() {
appIcon.destroy();
appIcon = null;
- mainWindow.webContents.executeJavaScript('Backbone.trigger("launcher-exit-request");');
+ emitBackboneEvent('launcher-exit-request');
+}
+
+function emitBackboneEvent(e) {
+ mainWindow.webContents.executeJavaScript('Backbone.trigger("' + e + '");');
}
function setMenu() {
diff --git a/keeweb.iml b/keeweb.iml
index 785b6491..0892b3c4 100644
--- a/keeweb.iml
+++ b/keeweb.iml
@@ -10,6 +10,5 @@
-
\ No newline at end of file
diff --git a/release-notes.md b/release-notes.md
index d8f445a4..a02af186 100644
--- a/release-notes.md
+++ b/release-notes.md
@@ -1,5 +1,17 @@
Release notes
-------------
+##### v0.5 (not released yet)
+2-way merge sync
+`*` all files are now opened with offline support
+`*` disallow opening same files twice
+`*` default theme is now blue
+`+` #46: option to show colorful icons
+`+` #45: optional auto-lock on minimize
+`+` option to disable searching for group
+`+` #62: saving files with empty password
+`+` #56: preserve selected entry after close
+`-` #55: custom scrollbar issues
+
##### v0.4.6 (2015-11-25)
`-` #32: visual glitches on Windows 10