]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Only use lowercase filenames
authorFreddy <schro.sb@gmail.com>
Sun, 5 Jan 2020 21:22:17 +0000 (22:22 +0100)
committerFreddy <schro.sb@gmail.com>
Sun, 5 Jan 2020 21:22:17 +0000 (22:22 +0100)
Apparently Windows can cause problems with mixed case filenames

qcsrc/menu/xonotic/_mod.inc
qcsrc/menu/xonotic/_mod.qh
qcsrc/menu/xonotic/dialog_multiplayer_join_ToS.qc [deleted file]
qcsrc/menu/xonotic/dialog_multiplayer_join_ToS.qh [deleted file]
qcsrc/menu/xonotic/dialog_multiplayer_join_serverinfo.qc
qcsrc/menu/xonotic/dialog_multiplayer_join_termsofservice.qc [new file with mode: 0644]
qcsrc/menu/xonotic/dialog_multiplayer_join_termsofservice.qh [new file with mode: 0644]

index 30cdb98040e736979bbefe8309d7ca9b05279cc1..ab9211c5b2eded99e63512ece464f8e1e9d79fc6 100644 (file)
@@ -50,7 +50,7 @@
 #include <menu/xonotic/dialog_multiplayer_join.qc>
 #include <menu/xonotic/dialog_multiplayer_join_serverinfo.qc>
 #include <menu/xonotic/dialog_multiplayer_join_serverinfotab.qc>
-#include <menu/xonotic/dialog_multiplayer_join_ToS.qc>
+#include <menu/xonotic/dialog_multiplayer_join_termsofservice.qc>
 #include <menu/xonotic/dialog_multiplayer_media.qc>
 #include <menu/xonotic/dialog_multiplayer_media_demo.qc>
 #include <menu/xonotic/dialog_multiplayer_media_demo_startconfirm.qc>
index fd4897cd04187351cccb78a7a426d544bb8f1365..43363792ef982ceb6efc4e068834663d275ffc14 100644 (file)
@@ -50,7 +50,7 @@
 #include <menu/xonotic/dialog_multiplayer_join.qh>
 #include <menu/xonotic/dialog_multiplayer_join_serverinfo.qh>
 #include <menu/xonotic/dialog_multiplayer_join_serverinfotab.qh>
-#include <menu/xonotic/dialog_multiplayer_join_ToS.qh>
+#include <menu/xonotic/dialog_multiplayer_join_termsofservice.qh>
 #include <menu/xonotic/dialog_multiplayer_media.qh>
 #include <menu/xonotic/dialog_multiplayer_media_demo.qh>
 #include <menu/xonotic/dialog_multiplayer_media_demo_startconfirm.qh>
diff --git a/qcsrc/menu/xonotic/dialog_multiplayer_join_ToS.qc b/qcsrc/menu/xonotic/dialog_multiplayer_join_ToS.qc
deleted file mode 100644 (file)
index fa6ac23..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-#include "dialog_multiplayer_join_ToS.qh"
-
-#include "textbox.qh"
-#include <lib/urllib.qh>
-
-
-entity makeXonoticServerToSTab()
-{
-       entity me;
-       me = NEW(XonoticServerToSTab);
-       me.configureDialog(me);
-       return me;
-}
-
-void XonoticServerToSTab_loadToS(entity me, string downloadurl)
-{
-       url_single_fopen(downloadurl, FILE_READ, AdditionalServerInfo_OnGet, me);
-}
-
-void XonoticServerToSTab_fill(entity me)
-{
-       entity e;
-    me.TR(me);
-        me.TD(me, me.rows, me.columns, e = makeXonoticTextBox());
-        me.textBox = e;
-}
-
-void AdditionalServerInfo_OnGet(entity fh, entity me, int status)
-{
-       switch (status) {
-               case URL_READY_CLOSED:
-               {
-                       break;
-               }
-        case URL_READY_ERROR:
-        {
-            me.text = strzone("Error reading ToS");
-            me.textBox.setText(me.textBox, me.text);
-            break;
-        }
-               case URL_READY_CANREAD:
-               {
-            strfree(me.text);
-            string temp = "";
-                       for (string s; (s = url_fgets(fh)); )
-                       {
-                if (temp != "")
-                {
-                                   temp = strcat(temp, "\n", s);
-                }
-                else
-                {
-                    temp = s;
-                }
-                       }
-                       url_fclose(fh);
-            me.text = strzone(temp);
-            me.textBox.setText(me.textBox, me.text);
-                       break;
-               }
-               default:
-               {
-                       break;
-               }
-       }
-}
diff --git a/qcsrc/menu/xonotic/dialog_multiplayer_join_ToS.qh b/qcsrc/menu/xonotic/dialog_multiplayer_join_ToS.qh
deleted file mode 100644 (file)
index aa2d19f..0000000
+++ /dev/null
@@ -1,18 +0,0 @@
-#pragma once
-
-#include "tab.qh"
-CLASS(XonoticServerToSTab, XonoticTab)
-       METHOD(XonoticServerToSTab, fill, void(entity));
-       METHOD(XonoticServerToSTab, loadToS, void(entity, string));
-       ATTRIB(XonoticServerToSTab, title, string, _("Terms of Service"));
-       ATTRIB(XonoticServerToSTab, color, vector, SKINCOLOR_DIALOG_SERVERINFO);
-       ATTRIB(XonoticServerToSTab, intendedWidth, float, 0.8);
-       ATTRIB(XonoticServerToSTab, rows, float, 17);
-       ATTRIB(XonoticServerToSTab, columns, float, 6.2);
-
-    ATTRIB(XonoticServerToSTab, text, string);
-       ATTRIB(XonoticServerToSTab, textBox, entity);
-ENDCLASS(XonoticServerToSTab)
-entity makeXonoticServerToSTab();
-
-void AdditionalServerInfo_OnGet(entity fh, entity pass, int status);
index 8ad71677337bed1e67710fefe3e13dfbec5eb6e7..c2cad99fc06b7bd188760ba95afc0f0bc3c73d98 100644 (file)
@@ -7,7 +7,7 @@
 #include "textlabel.qh"
 #include "button.qh"
 #include "dialog_multiplayer_join_serverinfotab.qh"
-#include "dialog_multiplayer_join_ToS.qh"
+#include "dialog_multiplayer_join_termsofservice.qh"
 
 
 void XonoticServerInfoDialog_loadServerInfo(entity me, float i)
diff --git a/qcsrc/menu/xonotic/dialog_multiplayer_join_termsofservice.qc b/qcsrc/menu/xonotic/dialog_multiplayer_join_termsofservice.qc
new file mode 100644 (file)
index 0000000..8a26235
--- /dev/null
@@ -0,0 +1,66 @@
+#include "dialog_multiplayer_join_termsofservice.qh"
+
+#include "textbox.qh"
+#include <lib/urllib.qh>
+
+
+entity makeXonoticServerToSTab()
+{
+       entity me;
+       me = NEW(XonoticServerToSTab);
+       me.configureDialog(me);
+       return me;
+}
+
+void XonoticServerToSTab_loadToS(entity me, string downloadurl)
+{
+       url_single_fopen(downloadurl, FILE_READ, AdditionalServerInfo_OnGet, me);
+}
+
+void XonoticServerToSTab_fill(entity me)
+{
+       entity e;
+    me.TR(me);
+        me.TD(me, me.rows, me.columns, e = makeXonoticTextBox());
+        me.textBox = e;
+}
+
+void AdditionalServerInfo_OnGet(entity fh, entity me, int status)
+{
+       switch (status) {
+               case URL_READY_CLOSED:
+               {
+                       break;
+               }
+        case URL_READY_ERROR:
+        {
+            me.text = strzone("Error reading ToS");
+            me.textBox.setText(me.textBox, me.text);
+            break;
+        }
+               case URL_READY_CANREAD:
+               {
+            strfree(me.text);
+            string temp = "";
+                       for (string s; (s = url_fgets(fh)); )
+                       {
+                if (temp != "")
+                {
+                                   temp = strcat(temp, "\n", s);
+                }
+                else
+                {
+                    temp = s;
+                }
+                       }
+                       url_fclose(fh);
+            me.text = strzone(temp);
+            me.textBox.setText(me.textBox, me.text);
+                       break;
+               }
+               default:
+               {
+                       break;
+               }
+       }
+}
diff --git a/qcsrc/menu/xonotic/dialog_multiplayer_join_termsofservice.qh b/qcsrc/menu/xonotic/dialog_multiplayer_join_termsofservice.qh
new file mode 100644 (file)
index 0000000..aa2d19f
--- /dev/null
@@ -0,0 +1,18 @@
+#pragma once
+
+#include "tab.qh"
+CLASS(XonoticServerToSTab, XonoticTab)
+       METHOD(XonoticServerToSTab, fill, void(entity));
+       METHOD(XonoticServerToSTab, loadToS, void(entity, string));
+       ATTRIB(XonoticServerToSTab, title, string, _("Terms of Service"));
+       ATTRIB(XonoticServerToSTab, color, vector, SKINCOLOR_DIALOG_SERVERINFO);
+       ATTRIB(XonoticServerToSTab, intendedWidth, float, 0.8);
+       ATTRIB(XonoticServerToSTab, rows, float, 17);
+       ATTRIB(XonoticServerToSTab, columns, float, 6.2);
+
+    ATTRIB(XonoticServerToSTab, text, string);
+       ATTRIB(XonoticServerToSTab, textBox, entity);
+ENDCLASS(XonoticServerToSTab)
+entity makeXonoticServerToSTab();
+
+void AdditionalServerInfo_OnGet(entity fh, entity pass, int status);