]> git.pld-linux.org Git - packages/scorched3d.git/commitdiff
- fix building with wxWidgets 3.0 auto/th/scorched3d-43.3d-5
authorJan Rękorajski <baggins@pld-linux.org>
Sat, 18 Jan 2014 17:06:53 +0000 (18:06 +0100)
committerJan Rękorajski <baggins@pld-linux.org>
Sat, 18 Jan 2014 17:06:53 +0000 (18:06 +0100)
- rel 5

scorched3d.spec
wxWidgets3.patch [new file with mode: 0644]

index 85dff3f019e940e4372919edc782aa73450d77f1..82460efa219eaf0f8259110418b74f8f0c4e0853 100644 (file)
@@ -2,7 +2,7 @@ Summary:        A 3D version of the classic DOS game Scorched Earth
 Summary(pl.UTF-8):     Wersja 3D klasycznej DOS-owej gry Scorched Earth
 Name:          scorched3d
 Version:       43.3d
-Release:       4
+Release:       5
 License:       GPL v2+
 Group:         X11/Applications/Games
 Source0:       http://downloads.sourceforge.net/scorched3d/Scorched3D-%{version}-src.tar.gz
@@ -12,6 +12,7 @@ Patch0:               %{name}-types.patch
 Patch1:                %{name}-openal.patch
 Patch2:                %{name}-libpng15.patch
 Patch3:                %{name}-gcc47.patch
+Patch4:                wxWidgets3.patch
 URL:           http://www.scorched3d.co.uk/
 BuildRequires: ImageMagick-coder-png
 BuildRequires: OpenAL-devel >= 0.0.8
@@ -56,6 +57,7 @@ rm -rf scorched-dep-osx scorched
 %patch1 -p1
 %patch2 -p1
 %patch3 -p1
+%patch4 -p1
 
 %build
 %{__aclocal}
diff --git a/wxWidgets3.patch b/wxWidgets3.patch
new file mode 100644 (file)
index 0000000..52567e2
--- /dev/null
@@ -0,0 +1,129 @@
+diff -ur scorched3d-43.3d/src/launcher/wxdialogs/Display.cpp scorched3d-43.3d-wx3/src/launcher/wxdialogs/Display.cpp
+--- scorched3d-43.3d/src/launcher/wxdialogs/Display.cpp        2011-10-11 00:26:43.000000000 +0200
++++ scorched3d-43.3d-wx3/src/launcher/wxdialogs/Display.cpp    2014-01-18 17:36:33.855429533 +0100
+@@ -88,7 +88,7 @@
+       // Sound settings\r
+       wxStaticBox *soundBox = new wxStaticBox(parent, -1, wxT("&Sound"));\r
+       wxStaticBoxSizer *soundSizerMain = new wxStaticBoxSizer(soundBox, wxVERTICAL);\r
+-      wxFlexGridSizer *soundSizer1 = new wxFlexGridSizer(4, 2);\r
++      wxFlexGridSizer *soundSizer1 = new wxFlexGridSizer(4, 2, wxSize(5, 5));\r
+       wxStaticText *volumeText = new wxStaticText(parent, -1, wxT("Sound Volume :"));\r
+       wxStaticText *musicVolumeText = new wxStaticText(parent, -1, wxT("Music Volume :"));\r
+       wxStaticText *ambientVolumeText = new wxStaticText(parent, -1, wxT("Ambient Volume :"));\r
+@@ -137,7 +137,7 @@
+               wxT("Game Detail Options"));\r
+       wxStaticBoxSizer *speedSizer = new wxStaticBoxSizer(speedBox, wxHORIZONTAL);\r
\r
+-      wxGridSizer *loadSizer = new wxFlexGridSizer(2, 2);\r
++      wxGridSizer *loadSizer = new wxFlexGridSizer(2, 2, wxSize(5, 5));\r
+       IDC_LOADULTRA_CTRL = new wxButton(parent,  ID_LOADULTRA, wxT("&Ultra Detail"), wxDefaultPosition, wxSize(120,-1));\r
+       IDC_LOADDEFAULTS_CTRL = new wxButton(parent, ID_LOADDEFAULTS, wxT("&Normal Detail"), wxDefaultPosition, wxSize(120,-1));\r
+       IDC_LOADMEDIUM_CTRL = new wxButton(parent, ID_LOADMEDIUM, wxT("Faster Detail"), wxDefaultPosition, wxSize(120,-1));\r
+@@ -471,7 +471,7 @@
+ {\r
+       wxScrolledWindow *scrolledWindow = new wxScrolledWindow(parent, -1, \r
+               wxDefaultPosition, wxSize(480, 250));\r
+-      wxSizer *sizer = new wxFlexGridSizer(5, 1);\r
++      wxSizer *sizer = new wxFlexGridSizer(5, 1, wxSize(5, 5));\r
+       \r
+       keyboardKeyList.clear();\r
+       if (!Keyboard::instance()->loadKeyFile())\r
+diff -ur scorched3d-43.3d/src/launcher/wxdialogs/DisplayDialog.cpp scorched3d-43.3d-wx3/src/launcher/wxdialogs/DisplayDialog.cpp
+--- scorched3d-43.3d/src/launcher/wxdialogs/DisplayDialog.cpp  2012-01-08 16:26:34.000000000 +0100
++++ scorched3d-43.3d-wx3/src/launcher/wxdialogs/DisplayDialog.cpp      2014-01-18 17:39:41.062094844 +0100
+@@ -733,7 +733,7 @@
+               convertString(S3D::formatStringBuffer("%s.s3m", (const char *) (selection.mb_str(wxConvUTF8)))), // default filename\r
+               wxT(""), // default extension\r
+               wxT("*.s3m"),\r
+-              wxSAVE);\r
++              wxFD_SAVE);\r
+       if (file.empty()) return;\r
+       ModFiles files;\r
+       if (!files.loadModFiles(std::string(selection.mb_str(wxConvUTF8)), false))\r
+@@ -757,7 +757,7 @@
+               wxT(""), // default filename\r
+               wxT(""), // default extension\r
+               wxT("*.s3m"),\r
+-              wxOPEN | wxFILE_MUST_EXIST);\r
++              wxFD_OPEN | wxFD_FILE_MUST_EXIST);\r
+       if (file.empty()) return;\r
+       ModFiles files;\r
+       std::string mod;\r
+diff -ur scorched3d-43.3d/src/launcher/wxdialogs/KeyDialog.cpp scorched3d-43.3d-wx3/src/launcher/wxdialogs/KeyDialog.cpp
+--- scorched3d-43.3d/src/launcher/wxdialogs/KeyDialog.cpp      2011-06-28 01:11:12.000000000 +0200
++++ scorched3d-43.3d-wx3/src/launcher/wxdialogs/KeyDialog.cpp  2014-01-18 17:41:35.702094014 +0100
+@@ -107,7 +107,7 @@
+               keyDialogControlDown = event.ControlDown();\r
+               keyDialogShiftDown = event.ShiftDown();\r
+               keyDialogAltDown = event.AltDown();\r
+-              keyDialogKeyCode = event.KeyCode();\r
++              keyDialogKeyCode = event.GetKeyCode();\r
+               frame_->EndModal(0);\r
+       }\r
+ }\r
+diff -ur scorched3d-43.3d/src/launcher/wxdialogs/SettingsDialog.cpp scorched3d-43.3d-wx3/src/launcher/wxdialogs/SettingsDialog.cpp
+--- scorched3d-43.3d/src/launcher/wxdialogs/SettingsDialog.cpp 2011-09-06 01:29:53.000000000 +0200
++++ scorched3d-43.3d-wx3/src/launcher/wxdialogs/SettingsDialog.cpp     2014-01-18 17:43:23.118759904 +0100
+@@ -105,7 +105,7 @@
+       mainPanel_ = new wxPanel(book_, -1);\r
+       book_->AddPage(mainPanel_, wxT("Main"));\r
+       wxSizer *mainPanelSizer = new wxBoxSizer(wxVERTICAL);\r
+-      wxSizer *sizer = new wxFlexGridSizer(2, 2);\r
++      wxSizer *sizer = new wxFlexGridSizer(2, 2, wxSize(5, 5));\r
+       mainPanelSizer->Add(sizer, 0, wxALL | wxALIGN_CENTER, 10);\r
\r
+       setters_.push_back(\r
+@@ -166,7 +166,7 @@
+ {\r
+       moneyPanel_ = new wxPanel(book_, -1);\r
+       wxSizer *ecoPanelSizer = new wxBoxSizer(wxVERTICAL);\r
+-      wxSizer *sizer = new wxFlexGridSizer(2, 2);\r
++      wxSizer *sizer = new wxFlexGridSizer(2, 2, wxSize(5, 5));\r
+       ecoPanelSizer->Add(sizer, 0, wxALL | wxALIGN_CENTER, 10);\r
\r
+       setters_.push_back(\r
+@@ -215,7 +215,7 @@
+ {\r
+       scorePanel_ = new wxPanel(book_, -1);\r
+       wxSizer *ecoPanelSizer = new wxBoxSizer(wxVERTICAL);\r
+-      wxSizer *sizer = new wxFlexGridSizer(2, 2);\r
++      wxSizer *sizer = new wxFlexGridSizer(2, 2, wxSize(5, 5));\r
+       ecoPanelSizer->Add(sizer, 0, wxALL | wxALIGN_CENTER, 10);\r
\r
+       setters_.push_back(\r
+@@ -249,7 +249,7 @@
+ {\r
+       weaponsPanel_ = new wxPanel(book_, -1);\r
+       wxSizer *ecoPanelSizer = new wxBoxSizer(wxVERTICAL);\r
+-      wxSizer *sizer = new wxFlexGridSizer(2, 2);\r
++      wxSizer *sizer = new wxFlexGridSizer(2, 2, wxSize(5, 5));\r
+       ecoPanelSizer->Add(sizer, 0, wxALL | wxALIGN_CENTER, 10);\r
\r
+       setters_.push_back(\r
+@@ -286,7 +286,7 @@
+ {\r
+       envPanel_ = new wxPanel(book_, -1);\r
+       wxSizer *envPanelSizer = new wxBoxSizer(wxVERTICAL);\r
+-      wxSizer *sizer = new wxFlexGridSizer(2, 2);\r
++      wxSizer *sizer = new wxFlexGridSizer(2, 2, wxSize(5, 5));\r
+       envPanelSizer->Add(sizer, 0, wxALL | wxALIGN_CENTER, 10);\r
\r
+       setters_.push_back(\r
+@@ -337,7 +337,7 @@
+       wxScrolledWindow *scrolledWindow = new wxScrolledWindow(landPanel_, -1, \r
+               wxDefaultPosition, wxSize(225, 200));\r
\r
+-      wxSizer *sizer = new wxFlexGridSizer(3, 3);\r
++      wxSizer *sizer = new wxFlexGridSizer(3, 3, wxSize(5, 5));\r
+       int i = 0;\r
+       std::list<LandscapeDefinitionsEntry> &defns =\r
+               landscapeDefinitions.getAllLandscapes();\r
+@@ -438,7 +438,7 @@
+               wxT("Players are persistent for game"));\r
+       playersPanelSizer->Add(IDC_SERVER_RESIDUAL_CTRL, 0, wxALIGN_CENTER | wxTOP, 10);\r
+               \r
+-      wxSizer *sizer = new wxGridSizer(3, 3);\r
++      wxSizer *sizer = new wxGridSizer(3, 3, wxSize(5, 5));\r
+       playersPanelSizer->Add(sizer, 0, wxALL | wxALIGN_CENTER, 10);\r
\r
+       for (int i=0; i<24; i++)\r
This page took 0.085301 seconds and 4 git commands to generate.