瀏覽代碼

UI: Remove tabs for About error statements

And change error statements to translation key
田七不甜 2 年之前
父節點
當前提交
890f96ed34
共有 2 個文件被更改,包括 7 次插入4 次删除
  1. 1 0
      UI/data/locale/en-US.ini
  2. 6 4
      UI/window-basic-about.cpp

+ 1 - 0
UI/data/locale/en-US.ini

@@ -1369,6 +1369,7 @@ About.Donate="Make a Contribution"
 About.GetInvolved="Get Involved"
 About.GetInvolved="Get Involved"
 About.Authors="Authors"
 About.Authors="Authors"
 About.License="License"
 About.License="License"
+About.Error="Error! File could not be read.\n\nGo to: %1"
 About.Contribute="Support the OBS Project"
 About.Contribute="Support the OBS Project"
 
 
 # Drag-drop URL
 # Drag-drop URL

+ 6 - 4
UI/window-basic-about.cpp

@@ -133,8 +133,9 @@ void OBSAbout::ShowAbout()
 void OBSAbout::ShowAuthors()
 void OBSAbout::ShowAuthors()
 {
 {
 	std::string path;
 	std::string path;
-	QString error = "Error! File could not be read.\n\n \
-		Go to: https://github.com/obsproject/obs-studio/blob/master/AUTHORS";
+	QString error =
+		QTStr("About.Error")
+			.arg("https://github.com/obsproject/obs-studio/blob/master/AUTHORS");
 
 
 #ifdef __APPLE__
 #ifdef __APPLE__
 	if (!GetDataFilePath("AUTHORS", path)) {
 	if (!GetDataFilePath("AUTHORS", path)) {
@@ -160,8 +161,9 @@ void OBSAbout::ShowAuthors()
 void OBSAbout::ShowLicense()
 void OBSAbout::ShowLicense()
 {
 {
 	std::string path;
 	std::string path;
-	QString error = "Error! File could not be read.\n\n \
-		Go to: https://github.com/obsproject/obs-studio/blob/master/COPYING";
+	QString error =
+		QTStr("About.Error")
+			.arg("https://github.com/obsproject/obs-studio/blob/master/COPYING");
 
 
 	if (!GetDataFilePath("license/gplv2.txt", path)) {
 	if (!GetDataFilePath("license/gplv2.txt", path)) {
 		ui->textBrowser->setPlainText(error);
 		ui->textBrowser->setPlainText(error);