mirror of
https://github.com/BoostIo/Boostnote
synced 2025-12-14 02:06:29 +00:00
Fix scheduled theme change timing
This commit is contained in:
@@ -190,6 +190,7 @@ class Main extends React.Component {
|
|||||||
'menubar:togglemenubar',
|
'menubar:togglemenubar',
|
||||||
this.toggleMenuBarVisible.bind(this)
|
this.toggleMenuBarVisible.bind(this)
|
||||||
)
|
)
|
||||||
|
clearInterval(this.refreshTheme)
|
||||||
}
|
}
|
||||||
|
|
||||||
toggleMenuBarVisible() {
|
toggleMenuBarVisible() {
|
||||||
|
|||||||
@@ -10,8 +10,8 @@ const chooseTheme = ui => {
|
|||||||
const minutes = now.getHours() * 60 + now.getMinutes()
|
const minutes = now.getHours() * 60 + now.getMinutes()
|
||||||
|
|
||||||
const isEndAfterStart = end > start
|
const isEndAfterStart = end > start
|
||||||
const isBetweenStartAndEnd = minutes >= start && minutes <= end
|
const isBetweenStartAndEnd = minutes >= start && minutes < end
|
||||||
const isBetweenEndAndStart = minutes >= start || minutes <= end
|
const isBetweenEndAndStart = minutes >= start || minutes < end
|
||||||
|
|
||||||
if (
|
if (
|
||||||
(isEndAfterStart && isBetweenStartAndEnd) ||
|
(isEndAfterStart && isBetweenStartAndEnd) ||
|
||||||
|
|||||||
@@ -335,7 +335,7 @@ class UiTab extends React.Component {
|
|||||||
</div>
|
</div>
|
||||||
<div styleName='group-section'>
|
<div styleName='group-section'>
|
||||||
<div styleName='container'>
|
<div styleName='container'>
|
||||||
<div styleName='range-slider' id='firstRow'>
|
<div id='firstRow'>
|
||||||
<span
|
<span
|
||||||
id='rs-bullet-1'
|
id='rs-bullet-1'
|
||||||
styleName='rs-label'
|
styleName='rs-label'
|
||||||
@@ -353,7 +353,7 @@ class UiTab extends React.Component {
|
|||||||
onChange={e => this.handleUIChange(e)}
|
onChange={e => this.handleUIChange(e)}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<div styleName='range-slider' id='secondRow'>
|
<div id='secondRow'>
|
||||||
<span
|
<span
|
||||||
id='rs-bullet-2'
|
id='rs-bullet-2'
|
||||||
styleName='rs-label'
|
styleName='rs-label'
|
||||||
|
|||||||
Reference in New Issue
Block a user