Skip to content

Commit

Permalink
Update notification.js
Browse files Browse the repository at this point in the history
1:修改报错提示,改成中文本地化语言
1:Modify the error message to a localized Chinese language
  • Loading branch information
lein2023 authored May 23, 2023
1 parent 672dbda commit 8a3dd14
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions utility/notification.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ class Notification {
}
static async backgroundLayerIsMissing() {
const r1 = await dialog_box.prompt(
'You need a white background layer present in your document',
'您需要在文档中显示一个白色背景层',
'',
['Cancel', 'Create']
)
Expand Down Expand Up @@ -72,20 +72,20 @@ class Notification {
return false
}
static async inactiveSelectionArea(is_active_session) {
let buttons = ['Cancel', 'Rectangular Marquee']
let buttons = ['取消', '矩形选框工具']
if (is_active_session) {
buttons.push('Continue Session')
}
const r1 = await dialog_box.prompt(
'Please Select a Rectangular Area',
'You Forgot to select a Rectangular Area',
'请选择一个矩形区域',
'您忘记选择矩形区域了',
buttons
)
if (r1 === 'Cancel') {
if (r1 === '取消') {
/* cancelled or No */
console.log('cancel')
return false
} else if (r1 === 'Rectangular Marquee') {
} else if (r1 === '矩形选框工具') {
console.log('Rectangular Marquee')
psapi.selectMarqueeRectangularToolExe()
return false // should this be false?! what does true and false means in this context?! Yes: it should be false since boolean value represent wither we have an active selection area or not
Expand Down

0 comments on commit 8a3dd14

Please sign in to comment.