Browse Source

修复「启动时隐藏」选项的问题。

oldj 8 years ago
parent
commit
05aa868083
4 changed files with 5 additions and 5 deletions
  1. 0 1
      app/ui/bundle.js
  2. 1 1
      app/version.js
  3. 1 1
      package.json
  4. 3 2
      ui/frame/preferences.jsx

File diff suppressed because it is too large
+ 0 - 1
app/ui/bundle.js


+ 1 - 1
app/version.js

@@ -1 +1 @@
-exports.version = [3,3,5,5265];
+exports.version = [3,3,5,5266];

+ 1 - 1
package.json

@@ -110,4 +110,4 @@
       "presets": ["latest", "stage-0"]
     }
   }
-}
+}

+ 3 - 2
ui/frame/preferences.jsx

@@ -42,6 +42,7 @@ export default class PreferencesPrompt extends React.Component {
       Agent.pact('getPref')
         .then(pref => {
           this.setState(Object.assign({}, pref, {show: true}))
+          console.log(pref)
         })
     })
 
@@ -185,7 +186,7 @@ export default class PreferencesPrompt extends React.Component {
         <div className="title">{lang.auto_launch}</div>
         <div className="cnt">
           <Checkbox
-            defaultValue={this.state.auto_launch}
+            value={this.state.auto_launch}
             onChange={(e) => this.updateAutoLaunch(e.target.checked)}
           />
         </div>
@@ -201,7 +202,7 @@ export default class PreferencesPrompt extends React.Component {
         <div className="title">{lang.hide_at_launch}</div>
         <div className="cnt">
           <Checkbox
-            defaultValue={this.state.hide_at_launch}
+            checked={this.state.hide_at_launch}
             onChange={(e) => this.updateMinimizeAtLaunch(e.target.checked)}
           />
         </div>

Some files were not shown because too many files changed in this diff