Skip to content

Commit 5fe44ac

Browse files
committed
fix day-night mode switch
1 parent 268c028 commit 5fe44ac

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/com/dreamteam/app/ui/Main.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -281,6 +281,7 @@ public void onClick(View v)
281281

282282
private void switchMode()
283283
{
284+
isNight = AppContext.getPrefrences(this).getBoolean("day_night_mode", false);
284285
Editor editor = AppContext.getPrefrences(this).edit();
285286
//切回日间模式
286287
if(isNight)
@@ -296,7 +297,7 @@ private void switchMode()
296297
isNight = true;
297298
bgLayout.setBackgroundResource(R.drawable.home_bg_night);
298299
switchModeBtn.setImageResource(R.drawable.composer_moon);
299-
Toast.makeText(Main.this, R.string.switch2Day, Toast.LENGTH_SHORT).show();
300+
Toast.makeText(Main.this, R.string.switch2Night, Toast.LENGTH_SHORT).show();
300301
}
301302
editor.putBoolean("day_night_mode", isNight);
302303
editor.commit();

0 commit comments

Comments
 (0)