pull/1238/head
gedoor 3 years ago
parent b4ddf5c281
commit 30df9b03bd
  1. 5
      app/src/main/java/io/legado/app/service/WebService.kt
  2. 2
      app/src/main/res/values-es-rES/strings.xml
  3. 2
      app/src/main/res/values-ja-rJP/strings.xml
  4. 2
      app/src/main/res/values-pt-rBR/strings.xml
  5. 2
      app/src/main/res/values-zh-rHK/strings.xml
  6. 2
      app/src/main/res/values-zh-rTW/strings.xml
  7. 2
      app/src/main/res/values-zh/strings.xml
  8. 7
      app/src/main/res/values/non_translat.xml
  9. 2
      app/src/main/res/values/strings.xml

@ -73,11 +73,11 @@ class WebService : BaseService() {
if (webSocketServer?.isAlive == true) { if (webSocketServer?.isAlive == true) {
webSocketServer?.stop() webSocketServer?.stop()
} }
val address = NetworkUtils.getLocalIPAddress()
if (address != null) {
val port = getPort() val port = getPort()
httpServer = HttpServer(port) httpServer = HttpServer(port)
webSocketServer = WebSocketServer(port + 1) webSocketServer = WebSocketServer(port + 1)
val address = NetworkUtils.getLocalIPAddress()
if (address != null) {
try { try {
httpServer?.start() httpServer?.start()
webSocketServer?.start(1000 * 30) // 通信超时设置 webSocketServer?.start(1000 * 30) // 通信超时设置
@ -88,6 +88,7 @@ class WebService : BaseService() {
upNotification() upNotification()
} catch (e: IOException) { } catch (e: IOException) {
toastOnUi(e.localizedMessage ?: "") toastOnUi(e.localizedMessage ?: "")
e.printStackTrace()
stopSelf() stopSelf()
} }
} else { } else {

@ -87,7 +87,6 @@
<string name="web_service">Servicio Web</string> <string name="web_service">Servicio Web</string>
<string name="web_service_desc">Fuente de edición web y lectura de libros</string> <string name="web_service_desc">Fuente de edición web y lectura de libros</string>
<string name="web_edit_source">Editar fuentes de libros en la web</string> <string name="web_edit_source">Editar fuentes de libros en la web</string>
<string name="http_ip">http://%1$s:%2$d</string>
<string name="offline_cache">Caché sin conexión</string> <string name="offline_cache">Caché sin conexión</string>
<string name="offline_cache_t">Caché sin conexión</string> <string name="offline_cache_t">Caché sin conexión</string>
<string name="offline_cache_s">precarga el o los capítulos(s) seleccionado(s) en Almacenamiento en caché</string> <string name="offline_cache_s">precarga el o los capítulos(s) seleccionado(s) en Almacenamiento en caché</string>
@ -157,7 +156,6 @@
<string name="ps_hide_navigation_bar">Ocultar botones virtuales durante lectura</string> <string name="ps_hide_navigation_bar">Ocultar botones virtuales durante lectura</string>
<string name="pt_hide_navigation_bar">Oculta barra de navegación</string> <string name="pt_hide_navigation_bar">Oculta barra de navegación</string>
<string name="re_navigation_bar_color">Color de barra de navegación</string> <string name="re_navigation_bar_color">Color de barra de navegación</string>
<string name="git_hub">GitHub</string>
<string name="scoring">Evaluación</string> <string name="scoring">Evaluación</string>
<string name="send_mail">E-mail</string> <string name="send_mail">E-mail</string>
<string name="can_not_open">Error al abrir</string> <string name="can_not_open">Error al abrir</string>

@ -87,7 +87,6 @@
<string name="web_service">Web service</string> <string name="web_service">Web service</string>
<string name="web_service_desc">Web edit source and read book</string> <string name="web_service_desc">Web edit source and read book</string>
<string name="web_edit_source">Edit book sources on the web</string> <string name="web_edit_source">Edit book sources on the web</string>
<string name="http_ip">http://%1$s:%2$d</string>
<string name="offline_cache">Offline cache</string> <string name="offline_cache">Offline cache</string>
<string name="offline_cache_t">Offline cache</string> <string name="offline_cache_t">Offline cache</string>
<string name="offline_cache_s">cache the selected chapter(s) to Storage</string> <string name="offline_cache_s">cache the selected chapter(s) to Storage</string>
@ -157,7 +156,6 @@
<string name="ps_hide_navigation_bar">Hide virtual buttons when reading</string> <string name="ps_hide_navigation_bar">Hide virtual buttons when reading</string>
<string name="pt_hide_navigation_bar">Hide navigation bar</string> <string name="pt_hide_navigation_bar">Hide navigation bar</string>
<string name="re_navigation_bar_color">Navigation bar color</string> <string name="re_navigation_bar_color">Navigation bar color</string>
<string name="git_hub">GitHub</string>
<string name="scoring">Rating</string> <string name="scoring">Rating</string>
<string name="send_mail">Email</string> <string name="send_mail">Email</string>
<string name="can_not_open">Open failed</string> <string name="can_not_open">Open failed</string>

@ -87,7 +87,6 @@
<string name="web_service">Serviço Web</string> <string name="web_service">Serviço Web</string>
<string name="web_service_desc">Fonte de edição web e livro lidos</string> <string name="web_service_desc">Fonte de edição web e livro lidos</string>
<string name="web_edit_source">Editar fontes de livros na web</string> <string name="web_edit_source">Editar fontes de livros na web</string>
<string name="http_ip">http://%1$s:%2$d</string>
<string name="offline_cache">Cache off-line</string> <string name="offline_cache">Cache off-line</string>
<string name="offline_cache_t">Cache off-line</string> <string name="offline_cache_t">Cache off-line</string>
<string name="offline_cache_s">salvar o(s) capítulo(s) selecionado(s) no Armazenamento em cache</string> <string name="offline_cache_s">salvar o(s) capítulo(s) selecionado(s) no Armazenamento em cache</string>
@ -157,7 +156,6 @@
<string name="ps_hide_navigation_bar">Esconder botões virtuais durante a leitura</string> <string name="ps_hide_navigation_bar">Esconder botões virtuais durante a leitura</string>
<string name="pt_hide_navigation_bar">Ocultar a barra de navegação</string> <string name="pt_hide_navigation_bar">Ocultar a barra de navegação</string>
<string name="re_navigation_bar_color">Cor da barra de navegação</string> <string name="re_navigation_bar_color">Cor da barra de navegação</string>
<string name="git_hub">GitHub</string>
<string name="scoring">Avaliação</string> <string name="scoring">Avaliação</string>
<string name="send_mail">E-mail</string> <string name="send_mail">E-mail</string>
<string name="can_not_open">Falha ao abrir</string> <string name="can_not_open">Falha ao abrir</string>

@ -84,7 +84,6 @@
<string name="web_service">Web 服務</string> <string name="web_service">Web 服務</string>
<string name="web_service_desc">瀏覽器寫源,看書</string> <string name="web_service_desc">瀏覽器寫源,看書</string>
<string name="web_edit_source">web 編輯書源</string> <string name="web_edit_source">web 編輯書源</string>
<string name="http_ip">http://%1$s:%2$d</string>
<string name="offline_cache">離線緩存</string> <string name="offline_cache">離線緩存</string>
<string name="offline_cache_t">離線緩存</string> <string name="offline_cache_t">離線緩存</string>
<string name="offline_cache_s">緩存已選擇的章節到本地</string> <string name="offline_cache_s">緩存已選擇的章節到本地</string>
@ -154,7 +153,6 @@
<string name="ps_hide_navigation_bar">閲讀介面隱藏導航欄</string> <string name="ps_hide_navigation_bar">閲讀介面隱藏導航欄</string>
<string name="pt_hide_navigation_bar">隱藏導航欄</string> <string name="pt_hide_navigation_bar">隱藏導航欄</string>
<string name="re_navigation_bar_color">導航欄顏色</string> <string name="re_navigation_bar_color">導航欄顏色</string>
<string name="git_hub">GitHub</string>
<string name="scoring">評分</string> <string name="scoring">評分</string>
<string name="send_mail">發送電子郵件</string> <string name="send_mail">發送電子郵件</string>
<string name="can_not_open">無法打開</string> <string name="can_not_open">無法打開</string>

@ -86,7 +86,6 @@
<string name="web_service">Web 服務</string> <string name="web_service">Web 服務</string>
<string name="web_service_desc">瀏覽器寫源,看書</string> <string name="web_service_desc">瀏覽器寫源,看書</string>
<string name="web_edit_source">web編輯書源</string> <string name="web_edit_source">web編輯書源</string>
<string name="http_ip">http://%1$s:%2$d</string>
<string name="offline_cache">離線快取</string> <string name="offline_cache">離線快取</string>
<string name="offline_cache_t">離線快取</string> <string name="offline_cache_t">離線快取</string>
<string name="offline_cache_s">快取選擇的章節到本機</string> <string name="offline_cache_s">快取選擇的章節到本機</string>
@ -156,7 +155,6 @@
<string name="ps_hide_navigation_bar">閱讀介面隱藏虛擬按鍵</string> <string name="ps_hide_navigation_bar">閱讀介面隱藏虛擬按鍵</string>
<string name="pt_hide_navigation_bar">隱藏導航欄</string> <string name="pt_hide_navigation_bar">隱藏導航欄</string>
<string name="re_navigation_bar_color">導航欄顏色</string> <string name="re_navigation_bar_color">導航欄顏色</string>
<string name="git_hub">GitHub</string>
<string name="scoring">評分</string> <string name="scoring">評分</string>
<string name="send_mail">發送郵件</string> <string name="send_mail">發送郵件</string>
<string name="can_not_open">無法打開</string> <string name="can_not_open">無法打開</string>

@ -86,7 +86,6 @@
<string name="web_service">Web 服务</string> <string name="web_service">Web 服务</string>
<string name="web_service_desc">浏览器写源,看书</string> <string name="web_service_desc">浏览器写源,看书</string>
<string name="web_edit_source">web编辑书源</string> <string name="web_edit_source">web编辑书源</string>
<string name="http_ip">http://%1$s:%2$d</string>
<string name="offline_cache">离线缓存</string> <string name="offline_cache">离线缓存</string>
<string name="offline_cache_t">离线缓存</string> <string name="offline_cache_t">离线缓存</string>
<string name="offline_cache_s">缓存选择的章节到本地</string> <string name="offline_cache_s">缓存选择的章节到本地</string>
@ -156,7 +155,6 @@
<string name="ps_hide_navigation_bar">阅读界面隐藏虚拟按键</string> <string name="ps_hide_navigation_bar">阅读界面隐藏虚拟按键</string>
<string name="pt_hide_navigation_bar">隐藏导航栏</string> <string name="pt_hide_navigation_bar">隐藏导航栏</string>
<string name="re_navigation_bar_color">导航栏颜色</string> <string name="re_navigation_bar_color">导航栏颜色</string>
<string name="git_hub">GitHub</string>
<string name="scoring">评分</string> <string name="scoring">评分</string>
<string name="send_mail">发送邮件</string> <string name="send_mail">发送邮件</string>
<string name="can_not_open">无法打开</string> <string name="can_not_open">无法打开</string>

@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<resources xmlns:tools="http://schemas.android.com/tools" tools:ignore="MissingTranslation">
<string name="http_ip">http://%1$s:%2$d</string>
<string name="git_hub">GitHub</string>
</resources>

@ -87,7 +87,6 @@
<string name="web_service">Web service</string> <string name="web_service">Web service</string>
<string name="web_service_desc">Web edit source and read book</string> <string name="web_service_desc">Web edit source and read book</string>
<string name="web_edit_source">Edit book sources on the web</string> <string name="web_edit_source">Edit book sources on the web</string>
<string name="http_ip">http://%1$s:%2$d</string>
<string name="offline_cache">Offline cache</string> <string name="offline_cache">Offline cache</string>
<string name="offline_cache_t">Offline cache</string> <string name="offline_cache_t">Offline cache</string>
<string name="offline_cache_s">cache the selected chapter(s) to Storage</string> <string name="offline_cache_s">cache the selected chapter(s) to Storage</string>
@ -157,7 +156,6 @@
<string name="ps_hide_navigation_bar">Hide virtual buttons when reading</string> <string name="ps_hide_navigation_bar">Hide virtual buttons when reading</string>
<string name="pt_hide_navigation_bar">Hide navigation bar</string> <string name="pt_hide_navigation_bar">Hide navigation bar</string>
<string name="re_navigation_bar_color">Navigation bar color</string> <string name="re_navigation_bar_color">Navigation bar color</string>
<string name="git_hub">GitHub</string>
<string name="scoring">Rating</string> <string name="scoring">Rating</string>
<string name="send_mail">Email</string> <string name="send_mail">Email</string>
<string name="can_not_open">Open failed</string> <string name="can_not_open">Open failed</string>

Loading…
Cancel
Save