| | |
| | | if (lunxun.isPolling() && !lunxun.isPaused()) { |
| | | boolean paused = lunxun.setPollingPaused(true); |
| | | if (paused) { |
| | | System.out.println("进入设置页面,轮询已暂停"); |
| | | //System.out.println("进入设置页面,轮询已暂停"); |
| | | } else { |
| | | System.err.println("进入设置页面,暂停轮询失败"); |
| | | } |
| | |
| | | if (lunxun.checkSerialConnection()) { |
| | | boolean resumed = lunxun.setPollingPaused(false); |
| | | if (resumed) { |
| | | System.out.println("退出设置页面,轮询已恢复"); |
| | | //System.out.println("退出设置页面,轮询已恢复"); |
| | | } else { |
| | | System.err.println("退出设置页面,恢复轮询失败"); |
| | | } |
| | |
| | | } |
| | | } |
| | | } else { |
| | | System.out.println("退出设置页面,保持原有轮询状态 - 运行: " + wasPollingRunning + ", 暂停: " + wasPollingPaused); |
| | | //System.out.println("退出设置页面,保持原有轮询状态 - 运行: " + wasPollingRunning + ", 暂停: " + wasPollingPaused); |
| | | } |
| | | } |
| | | |