diff --git a/src/webui/webapplication.cpp b/src/webui/webapplication.cpp index 0eb163a4f..67ce61421 100644 --- a/src/webui/webapplication.cpp +++ b/src/webui/webapplication.cpp @@ -187,7 +187,7 @@ QString WebApplication::generateSid() void WebApplication::translateDocument(QString& data) { - const QRegExp regex(QString::fromUtf8("_\\(([\\w\\s?!:\\/\\(\\),%µ&\\-\\.]+)\\)")); + const QRegExp regex("QBT_TR\\((([^\\)]|\\)(?!QBT_TR))+)\\)QBT_TR"); const QRegExp mnemonic("\\(?&([a-zA-Z]?\\))?"); const std::string contexts[] = { "TransferListFiltersWidget", "TransferListWidget", "PropertiesWidget", diff --git a/src/webui/www/private/index.html b/src/webui/www/private/index.html index 60d4fd10a..e60fa79e5 100644 --- a/src/webui/www/private/index.html +++ b/src/webui/www/private/index.html @@ -3,7 +3,7 @@ - _(qBittorrent web User Interface) + QBT_TR(qBittorrent web User Interface)QBT_TR @@ -33,85 +33,85 @@
   - _(&Add torrent file...) - _(Add &link to torrent...) - _(Delete) - _(Resume) - _(Pause) + QBT_TR(&Add torrent file...)QBT_TR + QBT_TR(Add &link to torrent...)QBT_TR + QBT_TR(Delete)QBT_TR + QBT_TR(Resume)QBT_TR + QBT_TR(Pause)QBT_TR - _(Move to bottom) - _(Decrease priority) - _(Increase priority) - _(Move to top) + QBT_TR(Move to bottom)QBT_TR + QBT_TR(Decrease priority)QBT_TR + QBT_TR(Increase priority)QBT_TR + QBT_TR(Move to top)QBT_TR - _(Options) + QBT_TR(Options)QBT_TR
@@ -122,7 +122,7 @@ Connection Status - _(Alternative speed limits) + QBT_TR(Alternative speed limits)QBT_TR diff --git a/src/webui/www/private/login.html b/src/webui/www/private/login.html index c229ad67b..a9cf7d471 100644 --- a/src/webui/www/private/login.html +++ b/src/webui/www/private/login.html @@ -3,7 +3,7 @@ - _(qBittorrent web User Interface) + QBT_TR(qBittorrent web User Interface)QBT_TR @@ -23,10 +23,10 @@
-

_(List of trackers to add (one per line):)


+

QBT_TR(List of trackers to add (one per line):)QBT_TR



- _(Add) + QBT_TR(Add)QBT_TR
diff --git a/src/webui/www/public/confirmdeletion.html b/src/webui/www/public/confirmdeletion.html index e43b28629..a92526f3e 100644 --- a/src/webui/www/public/confirmdeletion.html +++ b/src/webui/www/public/confirmdeletion.html @@ -2,7 +2,7 @@ - _(Deletion confirmation - qBittorrent) + QBT_TR(Deletion confirmation - qBittorrent)QBT_TR @@ -64,10 +64,10 @@ window.addEvent('domready', function(){
-

  _(Are you sure you want to delete the selected torrents from the transfer list?)

-     

+

  QBT_TR(Are you sure you want to delete the selected torrents from the transfer list?)QBT_TR

+     

-      +     
diff --git a/src/webui/www/public/download.html b/src/webui/www/public/download.html index 5dc27bdbf..edd823f25 100644 --- a/src/webui/www/public/download.html +++ b/src/webui/www/public/download.html @@ -2,7 +2,7 @@ - _(Add &link to torrent...) + QBT_TR(Add &link to torrent...)QBT_TR @@ -10,10 +10,10 @@

-

_(Download Torrents from their URL or Magnet link)

+

QBT_TR(Download Torrents from their URL or Magnet link)QBT_TR

-

_(Only one link per line)

- +

QBT_TR(Only one link per line)QBT_TR

+
diff --git a/src/webui/www/public/downloadlimit.html b/src/webui/www/public/downloadlimit.html index 8ca91a9e8..e375de8db 100644 --- a/src/webui/www/public/downloadlimit.html +++ b/src/webui/www/public/downloadlimit.html @@ -2,7 +2,7 @@ - _(Torrent Download Speed Limiting) + QBT_TR(Torrent Download Speed Limiting)QBT_TR @@ -12,7 +12,7 @@
-
_(Download limit:) _(KiB/s)
+
QBT_TR(Download limit:)QBT_TR QBT_TR(KiB/s)QBT_TR
@@ -51,7 +51,7 @@ } } - +
@@ -13,12 +13,12 @@ diff --git a/src/webui/www/public/preferences_content.html b/src/webui/www/public/preferences_content.html index e92f546cc..7ef820815 100644 --- a/src/webui/www/public/preferences_content.html +++ b/src/webui/www/public/preferences_content.html @@ -1,102 +1,102 @@
- _(Listening Port) - + QBT_TR(Listening Port)QBT_TR +
- +
- _(Connections Limits) + QBT_TR(Connections Limits)QBT_TR
- +
- +
- +
- _(Global Rate Limits) + QBT_TR(Global Rate Limits)QBT_TR - + - +
- +   _(KiB/s)  QBT_TR(KiB/s)QBT_TR
- +   _(KiB/s)  QBT_TR(KiB/s)QBT_TR
- _(Options) + QBT_TR(Options)QBT_TR -
+
-
+
-
+
- _(Alternative Global Rate Limits) + QBT_TR(Alternative Global Rate Limits)QBT_TR - + - +
- _(Upload:) + QBT_TR(Upload:)QBT_TR   _(KiB/s)  QBT_TR(KiB/s)QBT_TR
- _(Download:) + QBT_TR(Download:)QBT_TR   _(KiB/s)  QBT_TR(KiB/s)QBT_TR
- - _(from) + + QBT_TR(from)QBT_TR : - _(to) + QBT_TR(to)QBT_TR :
- _(When:) + QBT_TR(When:)QBT_TR
@@ -105,161 +105,161 @@
- +
diff --git a/src/webui/www/public/uploadlimit.html b/src/webui/www/public/uploadlimit.html index aa9f938f6..c7a51ebc8 100644 --- a/src/webui/www/public/uploadlimit.html +++ b/src/webui/www/public/uploadlimit.html @@ -2,7 +2,7 @@ - _(Torrent Upload Speed Limiting) + QBT_TR(Torrent Upload Speed Limiting)QBT_TR @@ -12,7 +12,7 @@
-
_(Upload limit:) _(KiB/s)
+
QBT_TR(Upload limit:)QBT_TR QBT_TR(KiB/s)QBT_TR
@@ -51,7 +51,7 @@ } } - +