Skip to content

Commit

Permalink
Support paste image.#53
Browse files Browse the repository at this point in the history
  • Loading branch information
topcss committed Feb 27, 2019
1 parent 7bf2f5b commit 11c1d1a
Show file tree
Hide file tree
Showing 6 changed files with 19 additions and 10 deletions.
3 changes: 2 additions & 1 deletion app/src/define.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@ export type StatusList = "none" | "opening" | "closing" | "saving";
export let sAboutText = `
Copyright (c) 2019 Jack <br><br>
Version: v${version.join(".")}<br><br>
Thanks: <a href='https://www.52pojie.cn/' target='_blank'>52pojie.cn</a>`;
Thanks: <a href='#' onclick='openUrl("https://www.52pojie.cn/");'>52pojie.cn</a> |
<a href='#' onclick='openUrl("https://github.com/NaoTu/DesktopNaotu");'>Naotu Team.</a>`;

/**
* 当前配置文件的版本
Expand Down
4 changes: 4 additions & 0 deletions app/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,3 +75,7 @@ $(function() {
}
}
});

function openUrl(url: string) {
require("electron").shell.openExternal(url);
}
4 changes: 4 additions & 0 deletions app/src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ import { sIndexUrl } from "./define";

const isDevMode = process.execPath.match(/[\\/]electron/);

process.on('unhandledRejection', error => {
logger.error('unhandledRejection', error);
});

// main.ts启动顺序为:读取系统参数(如系统类型、系统语言)、读取用户设置、初始化插件模块、载入系统插件、载入用户插件、启动主界面、载入菜单栏、其他
const createWindow = async () => {
// 隐藏菜单栏
Expand Down
2 changes: 1 addition & 1 deletion app/src/version.ts
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export let version = [3, 2, 1, 513];
export let version = [3, 2, 2, 517];
14 changes: 7 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
{
"name": "desktopnaotu",
"version": "3.2.1",
"version": "3.2.2",
"description": "桌面版脑图",
"main": "dist/main.js",
"scripts": {
"start": "gulp default",
"packwin32": "electron-packager ./ DesktopNaotu --asar=true --platform=win32 --arch=ia32 --out=../OutApp --icon=app/static/favicon.ico --electron-version=3.0.10 --app-version=3.2.1 --ignore=\"(.git|screenshot|doc|src|app|bower_components|electron-packager)\" --overwrite --prune",
"packwin32dev": "electron-packager ./ DesktopNaotu --platform=win32 --arch=ia32 --out=../OutApp --icon=app/static/favicon.ico --electron-version=3.0.10 --app-version=3.2.1 --ignore=\"(.git|screenshot|doc|bower_components|electron-packager)\" --overwrite --prune",
"packwin64": "electron-packager ./ DesktopNaotu --asar=true --platform=win32 --arch=x64 --out=../OutApp --icon=app/static/favicon.ico --electron-version=3.0.10 --app-version=3.2.1 --ignore=\"(.git|screenshot|doc|src|app|bower_components|electron-packager)\" --overwrite --prune",
"packwin64dev": "electron-packager ./ DesktopNaotu --platform=win32 --arch=x64 --out=../OutApp --icon=app/static/favicon.ico --electron-version=3.0.10 --app-version=3.2.1 --ignore=\"(.git|screenshot|doc|bower_components|electron-packager)\" --overwrite --prune",
"packmacos": "electron-packager ./ DesktopNaotu --asar=true --platform=darwin --arch=x64 --out=../OutApp --icon=app/static/favicon.icns --electron-version=3.0.10 --app-version=3.2.1 --ignore=\"(.git|screenshot|doc|src|app|bower_components|electron-packager)\" --overwrite --prune",
"packlinux": "electron-packager ./ DesktopNaotu --asar=true --platform=linux --arch=x64 --out=../OutApp --icon=app/static/favicon.png --electron-version=3.0.10 --app-version=3.2.1 --ignore=\"(.git|screenshot|doc|src|app|bower_components|electron-packager)\" --overwrite --prune"
"packwin32": "electron-packager ./ DesktopNaotu --asar=true --platform=win32 --arch=ia32 --out=../OutApp --icon=app/static/favicon.ico --electron-version=3.0.10 --app-version=3.2.2 --ignore=\"(.git|screenshot|doc|src|app|bower_components|electron-packager)\" --overwrite --prune",
"packwin32dev": "electron-packager ./ DesktopNaotu --platform=win32 --arch=ia32 --out=../OutApp --icon=app/static/favicon.ico --electron-version=3.0.10 --app-version=3.2.2 --ignore=\"(.git|screenshot|doc|bower_components|electron-packager)\" --overwrite --prune",
"packwin64": "electron-packager ./ DesktopNaotu --asar=true --platform=win32 --arch=x64 --out=../OutApp --icon=app/static/favicon.ico --electron-version=3.0.10 --app-version=3.2.2 --ignore=\"(.git|screenshot|doc|src|app|bower_components|electron-packager)\" --overwrite --prune",
"packwin64dev": "electron-packager ./ DesktopNaotu --platform=win32 --arch=x64 --out=../OutApp --icon=app/static/favicon.ico --electron-version=3.0.10 --app-version=3.2.2 --ignore=\"(.git|screenshot|doc|bower_components|electron-packager)\" --overwrite --prune",
"packmacos": "electron-packager ./ DesktopNaotu --asar=true --platform=darwin --arch=x64 --out=../OutApp --icon=app/static/favicon.icns --electron-version=3.0.10 --app-version=3.2.2 --ignore=\"(.git|screenshot|doc|src|app|bower_components|electron-packager)\" --overwrite --prune",
"packlinux": "electron-packager ./ DesktopNaotu --asar=true --platform=linux --arch=x64 --out=../OutApp --icon=app/static/favicon.png --electron-version=3.0.10 --app-version=3.2.2 --ignore=\"(.git|screenshot|doc|src|app|bower_components|electron-packager)\" --overwrite --prune"
},
"repository": {
"type": "git",
Expand Down
2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"compilerOptions": {
/* Basic Options */
"target": "ES2015" /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017','ES2018' or 'ESNEXT'. */,
"target": "ES3" /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017','ES2018' or 'ESNEXT'. */,
"module": "commonjs" /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', or 'ESNext'. */,
"lib": [
"es2016",
Expand Down

0 comments on commit 11c1d1a

Please sign in to comment.