Commit 0148a589 by Kim Jinsung

画面スリーブさせないように処理追加

parent 0fef32e3
......@@ -9,6 +9,7 @@ import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.view.View;
import android.view.Window;
import android.view.WindowManager;
import jp.odakyu.toiletsignage.application.ToiletApplication;
import jp.odakyu.toiletsignage.constants.ToiletConstants;
......@@ -51,11 +52,15 @@ public class ParentActivity extends AppCompatActivity {
if (isRunning) {
boolean isNetworkConnect = intent.getBooleanExtra(ToiletConstants.KEY_NETWORK_CONNECT,false);
int errorCount = intent.getIntExtra(ToiletConstants.KEY_ERROR_COUNT, -1);
Logger.i(TAG, "isNetworkConnect = " + isNetworkConnect + ", errorCount = " + errorCount);
reloadDisplayView(errorCount, isNetworkConnect);
}
}
};
registerReceiver(broadcastReceiver, filter);
//強制的にスリーブさせない処理追加
getWindow().addFlags(WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON);
}
@Override
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment