diff --git a/Generals/Code/GameEngine/GameEngine.dsp b/Generals/Code/GameEngine/GameEngine.dsp index 7614adb92f9..fa30157b068 100644 --- a/Generals/Code/GameEngine/GameEngine.dsp +++ b/Generals/Code/GameEngine/GameEngine.dsp @@ -434,10 +434,6 @@ SOURCE=.\Source\Common\INI\INIWater.cpp SOURCE=.\Source\Common\INI\INIWeapon.cpp # End Source File -# Begin Source File - -SOURCE=.\Source\Common\INI\INIWebpageURL.cpp -# End Source File # End Group # Begin Group "Audio" @@ -2267,14 +2263,6 @@ SOURCE=.\Source\GameClient\Water.cpp # Begin Group "GameNetwork" # PROP Default_Filter "" -# Begin Group "WOLBrowser" - -# PROP Default_Filter ".cpp" -# Begin Source File - -SOURCE=.\Source\GameNetwork\WOLBrowser\WebBrowser.cpp -# End Source File -# End Group # Begin Group "GameSpy" # PROP Default_Filter "" @@ -4360,19 +4348,6 @@ SOURCE=.\Include\GameClient\WinInstanceData.h # End Group # Begin Group "GameNetwork.H" -# PROP Default_Filter "" -# Begin Group "WOLBrowser H" - -# PROP Default_Filter ".h" -# Begin Source File - -SOURCE=.\Include\GameNetwork\WOLBrowser\FEBDispatch.h -# End Source File -# Begin Source File - -SOURCE=.\Include\GameNetwork\WOLBrowser\WebBrowser.h -# End Source File -# End Group # Begin Group "GameSpyLibs.H" # PROP Default_Filter "" diff --git a/Generals/Code/GameEngine/Include/Common/GameEngine.h b/Generals/Code/GameEngine/Include/Common/GameEngine.h index e483db6548d..3022de14faa 100644 --- a/Generals/Code/GameEngine/Include/Common/GameEngine.h +++ b/Generals/Code/GameEngine/Include/Common/GameEngine.h @@ -52,7 +52,6 @@ class ModuleFactory; class ThingFactory; class FunctionLexicon; class Radar; -class WebBrowser; class ParticleSystemManager; /** @@ -96,7 +95,6 @@ class GameEngine : public SubsystemInterface virtual ThingFactory *createThingFactory( void ) = 0; ///< Factory for the thing factory virtual FunctionLexicon *createFunctionLexicon( void ) = 0; ///< Factory for Function Lexicon virtual Radar *createRadar( void ) = 0; ///< Factory for radar - virtual WebBrowser *createWebBrowser( void ) = 0; ///< Factory for embedded browser virtual ParticleSystemManager* createParticleSystemManager( void ) = 0; virtual AudioManager *createAudioManager( void ) = 0; ///< Factory for Audio Manager diff --git a/Generals/Code/GameEngine/Include/Common/INI.h b/Generals/Code/GameEngine/Include/Common/INI.h index 85603e7e8ad..b13a06882f8 100644 --- a/Generals/Code/GameEngine/Include/Common/INI.h +++ b/Generals/Code/GameEngine/Include/Common/INI.h @@ -195,7 +195,6 @@ class INI static void parseAudioEventDefinition( INI *ini ); static void parseDialogDefinition( INI *ini ); static void parseMusicTrackDefinition( INI *ini ); - static void parseWebpageURLDefinition( INI *ini ); static void parseHeaderTemplateDefinition( INI *ini ); static void parseParticleSystemDefinition( INI *ini ); static void parseWaterSettingDefinition( INI *ini ); diff --git a/Generals/Code/GameEngine/Include/GameNetwork/WOLBrowser/FEBDispatch.h b/Generals/Code/GameEngine/Include/GameNetwork/WOLBrowser/FEBDispatch.h deleted file mode 100644 index 2e12ba0df73..00000000000 --- a/Generals/Code/GameEngine/Include/GameNetwork/WOLBrowser/FEBDispatch.h +++ /dev/null @@ -1,106 +0,0 @@ -/* -** Command & Conquer Generals(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -//////////////////////////////////////////////////////////////////////////////// -// // -// (c) 2001-2003 Electronic Arts Inc. // -// // -//////////////////////////////////////////////////////////////////////////////// - -// -// FEBDispatch class is a template class which, when inherited from, can implement the -// IDispatch for a COM object with a type library. -// - -#ifndef _FEBDISPATCH_H__ -#define _FEBDISPATCH_H__ - -#include -extern CComModule _Module; -#include -#include // For _bstr_t. - -#include "oleauto.h" - -template -class FEBDispatch : -public CComObjectRootEx, -public CComCoClass, -public C -{ -public: - - BEGIN_COM_MAP(T) - COM_INTERFACE_ENTRY(C) - COM_INTERFACE_ENTRY_AGGREGATE(IID_IDispatch, m_dispatch) - END_COM_MAP() - - FEBDispatch() - { - m_ptinfo = NULL; - m_dispatch = NULL; - - ITypeLib *ptlib; - HRESULT hr; - HRESULT TypeLibraryLoadResult; - char filename[256]; - - GetModuleFileName(NULL, filename, sizeof(filename)); - _bstr_t bstr(filename); - - TypeLibraryLoadResult = LoadTypeLib(bstr, &ptlib); - - DEBUG_ASSERTCRASH(TypeLibraryLoadResult == 0, ("Can't load type library for Embedded Browser")); - - if (TypeLibraryLoadResult == S_OK) - { - hr = ptlib->GetTypeInfoOfGuid(*I, &m_ptinfo); - ptlib->Release(); - - if (hr == S_OK) - { - hr = CreateStdDispatch(static_cast(this), static_cast(this), m_ptinfo, &m_dispatch); - - m_dispatch->AddRef(); - // Don't release the IUnknown from CreateStdDispatch without calling AddRef. - // It looks like CreateStdDispatch doesn't call AddRef on the IUnknown it returns. - } - } - - if ( (m_dispatch == NULL) ) - { - DEBUG_LOG(("Error creating Dispatch for Web interface\n")); - } - } - - virtual ~FEBDispatch() - { - if (m_ptinfo) - m_ptinfo->Release(); - - if (m_dispatch) - m_dispatch->Release(); - } - - IUnknown *m_dispatch; - -private: - ITypeInfo *m_ptinfo; -}; - -#endif diff --git a/Generals/Code/GameEngine/Include/GameNetwork/WOLBrowser/WebBrowser.h b/Generals/Code/GameEngine/Include/GameNetwork/WOLBrowser/WebBrowser.h deleted file mode 100644 index b587ff92fce..00000000000 --- a/Generals/Code/GameEngine/Include/GameNetwork/WOLBrowser/WebBrowser.h +++ /dev/null @@ -1,127 +0,0 @@ -/* -** Command & Conquer Generals(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -//////////////////////////////////////////////////////////////////////////////// -// // -// (c) 2001-2003 Electronic Arts Inc. // -// // -//////////////////////////////////////////////////////////////////////////////// - -/****************************************************************************** -* -* NAME -* $Archive: $ -* -* DESCRIPTION -* Web Browser -* -* PROGRAMMER -* Bryan Cleveland -* $Author: $ -* -* VERSION INFO -* $Revision: $ -* $Modtime: $ -* -******************************************************************************/ - -#pragma once - -#ifndef __WEBBROWSER_H__ -#define __WEBBROWSER_H__ - -#include "Common/SubsystemInterface.h" -#include -#include -#include -#include "EABrowserDispatch/BrowserDispatch.h" -#include "FEBDispatch.h" - -class GameWindow; - -class WebBrowserURL : public MemoryPoolObject -{ - MEMORY_POOL_GLUE_WITH_USERLOOKUP_CREATE( WebBrowserURL, "WebBrowserURL" ) - -public: - - WebBrowserURL(); - // virtual destructor prototype defined by memory pool object - - const FieldParse *getFieldParse( void ) const { return m_URLFieldParseTable; } - - AsciiString m_tag; - AsciiString m_url; - - WebBrowserURL *m_next; - - static const FieldParse m_URLFieldParseTable[]; ///< the parse table for INI definition - -}; - - - -class WebBrowser : - public FEBDispatch, - public SubsystemInterface - { - public: - void init( void ); - void reset( void ); - void update( void ); - - // Create an instance of the embedded browser for Dune Emperor. - virtual Bool createBrowserWindow(char *tag, GameWindow *win) = 0; - virtual void closeBrowserWindow(GameWindow *win) = 0; - - WebBrowserURL *makeNewURL(AsciiString tag); - WebBrowserURL *findURL(AsciiString tag); - - protected: - // Protected to prevent direct construction via new, use CreateInstance() instead. - WebBrowser(); - virtual ~WebBrowser(); - - // Protected to prevent copy and assignment - WebBrowser(const WebBrowser&); - const WebBrowser& operator=(const WebBrowser&); - -// Bool RetrievePageURL(const char* page, char* url, int size); -// Bool RetrieveHTMLPath(char* path, int size); - - protected: - ULONG mRefCount; - WebBrowserURL *m_urlList; - - //--------------------------------------------------------------------------- - // IUnknown methods - //--------------------------------------------------------------------------- - protected: - HRESULT STDMETHODCALLTYPE QueryInterface(REFIID riid, void** ppvObject); - ULONG STDMETHODCALLTYPE AddRef(void); - ULONG STDMETHODCALLTYPE Release(void); - - //--------------------------------------------------------------------------- - // IBrowserDispatch methods - //--------------------------------------------------------------------------- - public: - STDMETHOD(TestMethod)(Int num1); - }; - -extern CComObject *TheWebBrowser; -#endif // __WEBBROWSER_H__ diff --git a/Generals/Code/GameEngine/Source/Common/GameEngine.cpp b/Generals/Code/GameEngine/Source/Common/GameEngine.cpp index 1d0367876fe..e90e63ea727 100644 --- a/Generals/Code/GameEngine/Source/Common/GameEngine.cpp +++ b/Generals/Code/GameEngine/Source/Common/GameEngine.cpp @@ -100,7 +100,6 @@ #include "GameClient/GUICallbacks.h" #include "GameNetwork/NetworkInterface.h" -#include "GameNetwork/WOLBrowser/WebBrowser.h" #include "GameNetwork/LANAPI.h" #include "GameNetwork/GameSpy/GameResultsThread.h" #include "GameNetwork/GameSpy/PeerDefs.h" @@ -171,7 +170,6 @@ void initSubsystem(SUBSYSTEM*& sysref, AsciiString name, SUBSYSTEM* sys, Xfer *p //------------------------------------------------------------------------------------------------- extern HINSTANCE ApplicationHInstance; ///< our application instance -extern CComModule _Module; //------------------------------------------------------------------------------------------------- static void updateTGAtoDDS(); @@ -191,8 +189,6 @@ GameEngine::GameEngine( void ) m_maxFPS = 0; m_quitting = FALSE; m_isActive = FALSE; - - _Module.Init(NULL, ApplicationHInstance); } //------------------------------------------------------------------------------------------------- @@ -227,8 +223,6 @@ GameEngine::~GameEngine() Drawable::killStaticImages(); - _Module.Term(); - #ifdef PERF_TIMERS PerfGather::termPerfDump(); #endif @@ -379,7 +373,6 @@ void GameEngine::init( int argc, char *argv[] ) #endif initSubsystem(TheActionManager,"TheActionManager", MSGNEW("GameEngineSubsystem") ActionManager(), NULL); - //initSubsystem((CComObject *)TheWebBrowser,"(CComObject *)TheWebBrowser", (CComObject *)createWebBrowser(), NULL); initSubsystem(TheGameStateMap,"TheGameStateMap", MSGNEW("GameEngineSubsystem") GameStateMap, NULL, NULL, NULL ); initSubsystem(TheGameState,"TheGameState", MSGNEW("GameEngineSubsystem") GameState, NULL, NULL, NULL ); diff --git a/Generals/Code/GameEngine/Source/Common/INI/INI.cpp b/Generals/Code/GameEngine/Source/Common/INI/INI.cpp index 000f7ceaae3..3814433bdc0 100644 --- a/Generals/Code/GameEngine/Source/Common/INI/INI.cpp +++ b/Generals/Code/GameEngine/Source/Common/INI/INI.cpp @@ -133,7 +133,6 @@ static const BlockParse theTypeTable[] = { "WaterSet", INI::parseWaterSettingDefinition }, { "WaterTransparency", INI::parseWaterTransparencyDefinition}, { "Weapon", INI::parseWeaponTemplateDefinition }, - { "WebpageURL", INI::parseWebpageURLDefinition }, { "HeaderTemplate", INI::parseHeaderTemplateDefinition }, { "StaticGameLOD", INI::parseStaticGameLODDefinition }, { "DynamicGameLOD", INI::parseDynamicGameLODDefinition }, diff --git a/Generals/Code/GameEngine/Source/Common/INI/INIWebpageURL.cpp b/Generals/Code/GameEngine/Source/Common/INI/INIWebpageURL.cpp deleted file mode 100644 index 9615b7eac1c..00000000000 --- a/Generals/Code/GameEngine/Source/Common/INI/INIWebpageURL.cpp +++ /dev/null @@ -1,128 +0,0 @@ -/* -** Command & Conquer Generals(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -//////////////////////////////////////////////////////////////////////////////// -// // -// (c) 2001-2003 Electronic Arts Inc. // -// // -//////////////////////////////////////////////////////////////////////////////// - -// FILE: INIWebpageURL.cpp ///////////////////////////////////////////////////////////////////////////// -// Author: Bryan Cleveland, November 2001 -// Desc: Parsing Webpage URL INI entries -/////////////////////////////////////////////////////////////////////////////////////////////////// - -// INCLUDES /////////////////////////////////////////////////////////////////////////////////////// -#include "PreRTS.h" // This must go first in EVERY cpp file int the GameEngine - -#include "Common/INI.h" -#include "Common/Registry.h" -#include "GameNetwork/WOLBrowser/WebBrowser.h" - -#ifdef _INTERNAL -// for occasional debugging... -//#pragma optimize("", off) -//#pragma MESSAGE("************************************** WARNING, optimization disabled for debugging purposes") -#endif - -/////////////////////////////////////////////////////////////////////////////////////////////////// -// PRIVATE DATA /////////////////////////////////////////////////////////////////////////////////// -/////////////////////////////////////////////////////////////////////////////////////////////////// - -/////////////////////////////////////////////////////////////////////////////////////////////////// -// PUBLIC FUNCTIONS /////////////////////////////////////////////////////////////////////////////// -/////////////////////////////////////////////////////////////////////////////////////////////////// - -AsciiString encodeURL(AsciiString source) -{ - if (source.isEmpty()) - { - return AsciiString::TheEmptyString; - } - - AsciiString target; - AsciiString allowedChars = "$-_.+!*'(),\\"; - const char *ptr = source.str(); - while (*ptr) - { - if (isalnum(*ptr) || allowedChars.find(*ptr)) - { - target.concat(*ptr); - } - else - { - AsciiString tmp; - target.concat('%'); - tmp.format("%2.2x", ((int)*ptr)); - target.concat(tmp); - } - ++ptr; - } - - return target; -} - -//------------------------------------------------------------------------------------------------- -/** Parse Music entry */ -//------------------------------------------------------------------------------------------------- -void INI::parseWebpageURLDefinition( INI* ini ) -{ - AsciiString tag; - WebBrowserURL *url; - - // read the name - const char* c = ini->getNextToken(); - tag.set( c ); - - if (TheWebBrowser != NULL) - { - url = TheWebBrowser->findURL(tag); - - if (url == NULL) - { - url = TheWebBrowser->makeNewURL(tag); - } - } - - // find existing item if present -// track = TheAudio->Music->getTrack( name ); -// if( track == NULL ) -// { - - // allocate a new track -// track = TheAudio->Music->newMusicTrack( name ); - -// } // end if - -// DEBUG_ASSERTCRASH( track, ("parseMusicTrackDefinition: Unable to allocate track '%s'\n", -// name.str()) ); - - // parse the ini definition - ini->initFromINI( url, url->getFieldParse() ); - - if (url->m_url.startsWith("file://")) - { - char cwd[_MAX_PATH] = "\\"; - getcwd(cwd, _MAX_PATH); - - url->m_url.format("file://%s\\Data\\%s\\%s", encodeURL(cwd).str(), GetRegistryLanguage().str(), url->m_url.str()+7); - DEBUG_LOG(("INI::parseWebpageURLDefinition() - converted URL to [%s]\n", url->m_url.str())); - } -} // end parseMusicTrackDefinition - - diff --git a/Generals/Code/GameEngine/Source/Common/System/MemoryInit.cpp b/Generals/Code/GameEngine/Source/Common/System/MemoryInit.cpp index 6798a26f362..9a7b1c6fbdd 100644 --- a/Generals/Code/GameEngine/Source/Common/System/MemoryInit.cpp +++ b/Generals/Code/GameEngine/Source/Common/System/MemoryInit.cpp @@ -114,7 +114,6 @@ static PoolSizeRec sizes[] = { "CommandButton", 300, 16 }, { "CommandSet", 256, 16 }, { "DisplayString", 32, 32 }, - { "WebBrowserURL", 16, 16 }, { "Drawable", 4096, 32 }, { "Image", 2048, 32 }, { "ParticlePool", 4096, 256 }, diff --git a/Generals/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLLadderScreen.cpp b/Generals/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLLadderScreen.cpp index 0739d5c9064..ae044416076 100644 --- a/Generals/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLLadderScreen.cpp +++ b/Generals/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLLadderScreen.cpp @@ -36,7 +36,6 @@ #include "GameClient/KeyDefs.h" #include "GameClient/GameWindowManager.h" #include "GameClient/MessageBox.h" -#include "GameNetwork/WOLBrowser/WebBrowser.h" // window ids ------------------------------------------------------------------------------------- static NameKeyType parentWindowID = NAMEKEY_INVALID; @@ -69,12 +68,6 @@ void WOLLadderScreenInit( WindowLayout *layout, void *userData ) //Load the listbox shiznit // PopulateReplayFileListbox(listboxReplayFiles); - //TheWebBrowser->createBrowserWindow("Westwood", windowLadder); - if (TheWebBrowser != NULL) - { - TheWebBrowser->createBrowserWindow("MessageBoard", windowLadder); - } - // show menu layout->hide( FALSE ); @@ -89,11 +82,6 @@ void WOLLadderScreenInit( WindowLayout *layout, void *userData ) void WOLLadderScreenShutdown( WindowLayout *layout, void *userData ) { - if (TheWebBrowser != NULL) - { - TheWebBrowser->closeBrowserWindow(windowLadder); - } - // hide menu layout->hide( TRUE ); diff --git a/Generals/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLLoginMenu.cpp b/Generals/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLLoginMenu.cpp index 128f90c8495..f60e693e50e 100644 --- a/Generals/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLLoginMenu.cpp +++ b/Generals/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLLoginMenu.cpp @@ -66,7 +66,6 @@ #include "GameNetwork/GameSpyOverlay.h" -#include "GameNetwork/WOLBrowser/WebBrowser.h" #ifdef _INTERNAL // for occasional debugging... @@ -78,8 +77,6 @@ Bool GameSpyUseProfiles = false; #endif // ALLOW_NON_PROFILED_LOGIN -static Bool webBrowserActive = FALSE; -static Bool useWebBrowserForTOS = FALSE; static Bool isShuttingDown = false; static Bool buttonPushed = false; @@ -719,14 +716,6 @@ void WOLLoginMenuShutdown( WindowLayout *layout, void *userData ) isShuttingDown = true; loggedInOK = false; TheWindowManager->clearTabList(); - if (webBrowserActive) - { - if (TheWebBrowser != NULL) - { - TheWebBrowser->closeBrowserWindow(listboxTOS); - } - webBrowserActive = FALSE; - } // if we are shutting down for an immediate pop, skip the animations Bool popImmediate = *(Bool *)userData; @@ -1418,13 +1407,8 @@ WindowMsgHandledType WOLLoginMenuSystem( GameWindow *window, UnsignedInt msg, else if ( controlID == buttonTOSID ) { parentTOS->winHide(FALSE); - useWebBrowserForTOS = FALSE;//loginPref->getBool("UseTOSBrowser", TRUE); - if (useWebBrowserForTOS && (TheWebBrowser != NULL)) - { - TheWebBrowser->createBrowserWindow("TermsOfService", listboxTOS); - webBrowserActive = TRUE; - } - else + + if (1) { // Okay, no web browser. This means we're looking at a UTF-8 text file. GadgetListBoxReset(listboxTOS); @@ -1483,18 +1467,10 @@ WindowMsgHandledType WOLLoginMenuSystem( GameWindow *window, UnsignedInt msg, EnableLoginControls( TRUE ); parentTOS->winHide(TRUE); - if (useWebBrowserForTOS && (TheWebBrowser != NULL)) - { - if (listboxTOS != NULL) - { - TheWebBrowser->closeBrowserWindow(listboxTOS); - } - } OptionPreferences optionPref; optionPref["SawTOS"] = "yes"; optionPref.write(); - webBrowserActive = FALSE; buttonBack->winEnable(TRUE); } break; diff --git a/Generals/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLWelcomeMenu.cpp b/Generals/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLWelcomeMenu.cpp index 929803ddd53..9721fee7a36 100644 --- a/Generals/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLWelcomeMenu.cpp +++ b/Generals/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLWelcomeMenu.cpp @@ -65,7 +65,6 @@ #include "GameNetwork/GameSpy/BuddyThread.h" #include "GameNetwork/GameSpy/ThreadUtils.h" #include "GameNetwork/GameSpy/MainMenuUtils.h" -#include "GameNetwork/WOLBrowser/WebBrowser.h" #ifdef _INTERNAL // for occasional debugging... diff --git a/Generals/Code/GameEngine/Source/GameNetwork/WOLBrowser/WebBrowser.cpp b/Generals/Code/GameEngine/Source/GameNetwork/WOLBrowser/WebBrowser.cpp deleted file mode 100644 index d55bcca94db..00000000000 --- a/Generals/Code/GameEngine/Source/GameNetwork/WOLBrowser/WebBrowser.cpp +++ /dev/null @@ -1,315 +0,0 @@ -/* -** Command & Conquer Generals(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -//////////////////////////////////////////////////////////////////////////////// -// // -// (c) 2001-2003 Electronic Arts Inc. // -// // -//////////////////////////////////////////////////////////////////////////////// - -/****************************************************************************** -* -* NAME -* $Archive: $ -* -* DESCRIPTION -* -* PROGRAMMER -* Bryan Cleveland -* $Author: $ -* -* VERSION INFO -* $Revision: $ -* $Modtime: $ -* -******************************************************************************/ - -#include "PreRTS.h" // This must go first in EVERY cpp file int the GameEngine - -//#include "WinMain.h" -#include "GameNetwork/WOLBrowser/WebBrowser.h" -#include "GameClient/GameWindow.h" -#include "GameClient/Display.h" - -#ifdef _INTERNAL -// for occasional debugging... -//#pragma optimize("", off) -//#pragma MESSAGE("************************************** WARNING, optimization disabled for debugging purposes") -#endif - -/** - * OLEInitializer class - Init and shutdown OLE & COM as a global - * object. Scary, nasty stuff, COM. /me shivers. - */ -class OLEInitializer -{ -public: - OLEInitializer() - { - // Initialize this instance - OleInitialize(NULL); - } - ~OLEInitializer() - { - OleUninitialize(); - } -}; -OLEInitializer g_OLEInitializer; -CComModule _Module; - -CComObject * TheWebBrowser = NULL; - - -/****************************************************************************** -* -* NAME -* WebBrowser::WebBrowser -* -* DESCRIPTION -* Default constructor -* -* INPUTS -* NONE -* -* RESULT -* NONE -* -******************************************************************************/ - -WebBrowser::WebBrowser() : - mRefCount(1) -{ - DEBUG_LOG(("Instantiating embedded WebBrowser\n")); - m_urlList = NULL; -} - - -/****************************************************************************** -* -* NAME -* WebBrowser::~WebBrowser -* -* DESCRIPTION -* Destructor -* -* INPUTS -* NONE -* -* RESULT -* NONE -* -******************************************************************************/ - -WebBrowser::~WebBrowser() -{ - DEBUG_LOG(("Destructing embedded WebBrowser\n")); - if (this == TheWebBrowser) { - DEBUG_LOG(("WebBrowser::~WebBrowser - setting TheWebBrowser to NULL\n")); - TheWebBrowser = NULL; - } - WebBrowserURL *url = m_urlList; - while (url != NULL) { - WebBrowserURL *temp = url; - url = url->m_next; - temp->deleteInstance(); - temp = NULL; - } -} - -//------------------------------------------------------------------------------------------------- -/** The INI data fields for Webpage URL's */ -//------------------------------------------------------------------------------------------------- -const FieldParse WebBrowserURL::m_URLFieldParseTable[] = -{ - - { "URL", INI::parseAsciiString, NULL, offsetof( WebBrowserURL, m_url ) }, - { NULL, NULL, NULL, 0 }, - -}; - -WebBrowserURL::WebBrowserURL() -{ - m_next = NULL; - m_tag.clear(); - m_url.clear(); -} - -WebBrowserURL::~WebBrowserURL() -{ -} -/****************************************************************************** -* -* NAME -* WebBrowser::init -* -* DESCRIPTION -* Perform post creation initialization. -* -* INPUTS -* NONE -* -* RESULT -* NONE -* -******************************************************************************/ - -void WebBrowser::init() -{ - m_urlList = NULL; - INI ini; - ini.load( AsciiString( "Data\\INI\\Webpages.ini" ), INI_LOAD_OVERWRITE, NULL ); -} - -/****************************************************************************** -* -* NAME -* WebBrowser::reset -* -* DESCRIPTION -* Perform post creation initialization. -* -* INPUTS -* NONE -* -* RESULT -* NONE -* -******************************************************************************/ - -void WebBrowser::reset() -{ -} - -void WebBrowser::update( void ) -{ -} - -WebBrowserURL * WebBrowser::findURL(AsciiString tag) -{ - WebBrowserURL *retval = m_urlList; - - while ((retval != NULL) && tag.compareNoCase(retval->m_tag.str())) - { - retval = retval->m_next; - } - - return retval; -} - -WebBrowserURL * WebBrowser::makeNewURL(AsciiString tag) -{ - WebBrowserURL *newURL = newInstance(WebBrowserURL); - - newURL->m_tag = tag; - - newURL->m_next = m_urlList; - m_urlList = newURL; - - return newURL; -} - -/****************************************************************************** -* -* NAME -* IUnknown::QueryInterface -* -* DESCRIPTION -* -* INPUTS -* IID - Interface ID -* -* RESULT -* -******************************************************************************/ - -STDMETHODIMP WebBrowser::QueryInterface(REFIID iid, void** ppv) -{ - *ppv = NULL; - - if ((iid == IID_IUnknown) || (iid == IID_IBrowserDispatch)) - { - *ppv = static_cast(this); - } - else - { - return E_NOINTERFACE; - } - - static_cast(*ppv)->AddRef(); - - return S_OK; -} - - -/****************************************************************************** -* -* NAME -* IUnknown::AddRef -* -* DESCRIPTION -* -* INPUTS -* NONE -* -* RESULT -* -******************************************************************************/ - -ULONG STDMETHODCALLTYPE WebBrowser::AddRef(void) -{ - return ++mRefCount; -} - - -/****************************************************************************** -* -* NAME -* IUnknown::Release -* -* DESCRIPTION -* -* INPUTS -* NONE -* -* RESULT -* -******************************************************************************/ - -ULONG STDMETHODCALLTYPE WebBrowser::Release(void) -{ - DEBUG_ASSERTCRASH(mRefCount > 0, ("Negative reference count")); - --mRefCount; - - if (mRefCount == 0) - { - DEBUG_LOG(("WebBrowser::Release - all references released, deleting the object.\n")); - if (this == TheWebBrowser) { - TheWebBrowser = NULL; - } - delete this; - return 0; - } - - return mRefCount; -} - -STDMETHODIMP WebBrowser::TestMethod(Int num1) -{ - DEBUG_LOG(("WebBrowser::TestMethod - num1 = %d\n", num1)); - return S_OK; -} diff --git a/Generals/Code/GameEngineDevice/GameEngineDevice.dsp b/Generals/Code/GameEngineDevice/GameEngineDevice.dsp index 1e6f39d9dca..83eeb836fce 100644 --- a/Generals/Code/GameEngineDevice/GameEngineDevice.dsp +++ b/Generals/Code/GameEngineDevice/GameEngineDevice.dsp @@ -906,10 +906,6 @@ SOURCE=.\Source\W3DDevice\GameClient\W3dWaypointBuffer.cpp # End Source File # Begin Source File -SOURCE=.\Source\W3DDevice\GameClient\W3DWebBrowser.cpp -# End Source File -# Begin Source File - SOURCE=.\Source\W3DDevice\GameClient\WorldHeightMap.cpp # End Source File # End Group @@ -1278,10 +1274,6 @@ SOURCE=.\Include\W3DDevice\GameClient\W3DWaypointBuffer.h # End Source File # Begin Source File -SOURCE=.\Include\W3DDevice\GameClient\W3DWebBrowser.h -# End Source File -# Begin Source File - SOURCE=.\Include\W3DDevice\GameClient\WorldHeightMap.h # End Source File # End Group diff --git a/Generals/Code/GameEngineDevice/Include/W3DDevice/GameClient/W3DWebBrowser.h b/Generals/Code/GameEngineDevice/Include/W3DDevice/GameClient/W3DWebBrowser.h deleted file mode 100644 index 37254ee1311..00000000000 --- a/Generals/Code/GameEngineDevice/Include/W3DDevice/GameClient/W3DWebBrowser.h +++ /dev/null @@ -1,49 +0,0 @@ -/* -** Command & Conquer Generals(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -//////////////////////////////////////////////////////////////////////////////// -// // -// (c) 2001-2003 Electronic Arts Inc. // -// // -//////////////////////////////////////////////////////////////////////////////// - -///// W3DWebBrowser.h //////////////////////// -// July 2002, Bryan Cleveland - -#pragma once - -#ifndef W3DWEBBROWSER_H -#define W3DWEBBROWSER_H - -#include "GameNetwork/WOLBrowser/WebBrowser.h" - -class TextureClass; -class Image; -class GameWindow; - -class W3DWebBrowser : public WebBrowser -{ - public: - W3DWebBrowser(); - - virtual Bool createBrowserWindow(char *url, GameWindow *win); - virtual void closeBrowserWindow(GameWindow *win); - -}; - -#endif // #ifndef W3DWEBBROWSER_H \ No newline at end of file diff --git a/Generals/Code/GameEngineDevice/Include/Win32Device/Common/Win32GameEngine.h b/Generals/Code/GameEngineDevice/Include/Win32Device/Common/Win32GameEngine.h index 98e85da26c4..b8d1d58de7c 100644 --- a/Generals/Code/GameEngineDevice/Include/Win32Device/Common/Win32GameEngine.h +++ b/Generals/Code/GameEngineDevice/Include/Win32Device/Common/Win32GameEngine.h @@ -44,7 +44,6 @@ #include "W3DDevice/Common/W3DModuleFactory.h" #include "W3DDevice/GameLogic/W3DGameLogic.h" #include "W3DDevice/GameClient/W3DGameClient.h" -#include "W3DDevice/GameClient/W3DWebBrowser.h" #include "W3DDevice/Common/W3DFunctionLexicon.h" #include "W3DDevice/Common/W3DRadar.h" #include "W3DDevice/Common/W3DFunctionLexicon.h" @@ -80,7 +79,6 @@ class Win32GameEngine : public GameEngine virtual ArchiveFileSystem *createArchiveFileSystem( void ); ///< factory for archive file system virtual NetworkInterface *createNetwork( void ); ///< Factory for the network virtual Radar *createRadar( void ); ///< Factory for radar - virtual WebBrowser *createWebBrowser( void ); ///< Factory for embedded browser virtual AudioManager *createAudioManager( void ); ///< Factory for audio device virtual ParticleSystemManager* createParticleSystemManager( void ); @@ -101,7 +99,6 @@ inline ParticleSystemManager* Win32GameEngine::createParticleSystemManager( void inline NetworkInterface *Win32GameEngine::createNetwork( void ) { return NetworkInterface::createNetwork(); } inline Radar *Win32GameEngine::createRadar( void ) { return NEW W3DRadar; } -inline WebBrowser *Win32GameEngine::createWebBrowser( void ) { return NEW CComObject; } inline AudioManager *Win32GameEngine::createAudioManager( void ) { return NEW MilesAudioManager; } #endif // end __WIN32GAMEENGINE_H_ diff --git a/Generals/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DDisplay.cpp b/Generals/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DDisplay.cpp index 12a18632f84..f6b9d28d384 100644 --- a/Generals/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DDisplay.cpp +++ b/Generals/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DDisplay.cpp @@ -91,7 +91,6 @@ static void drawFramerateBar(void); #include "WW3D2/Render2DSentence.h" #include "WW3D2/SortingRenderer.h" #include "WW3D2/Textureloader.h" -#include "WW3D2/DX8WebBrowser.h" #include "WW3D2/Mesh.h" #include "WW3D2/HLOD.h" #include "WW3D2/Meshmatdesc.h" @@ -413,7 +412,6 @@ W3DDisplay::~W3DDisplay() delete m_assetManager; WW3D::Shutdown(); WWMath::Shutdown(); - DX8WebBrowser::Shutdown(); delete TheW3DFileSystem; TheW3DFileSystem = NULL; @@ -758,7 +756,6 @@ void W3DDisplay::init( void ) m_nativeDebugDisplay->setFontWidth( 9 ); } - DX8WebBrowser::Initialize(); // we're now online m_initialized = true; diff --git a/Generals/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DWebBrowser.cpp b/Generals/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DWebBrowser.cpp deleted file mode 100644 index 156ab35b6fd..00000000000 --- a/Generals/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DWebBrowser.cpp +++ /dev/null @@ -1,74 +0,0 @@ -/* -** Command & Conquer Generals(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -//////////////////////////////////////////////////////////////////////////////// -// // -// (c) 2001-2003 Electronic Arts Inc. // -// // -//////////////////////////////////////////////////////////////////////////////// - -////// W3DWebBrowser.cpp /////////////// -// July 2002 Bryan Cleveland - -#include "W3DDevice/GameClient/W3DWebBrowser.h" -#include "WW3D2/Texture.h" -#include "WW3D2/TextureLoader.h" -#include "WW3D2/SurfaceClass.h" -#include "GameClient/Image.h" -#include "GameClient/GameWindow.h" -#include "vector2i.h" -#include -#include "WW3D2/dx8wrapper.h" -#include "WW3D2/dx8WebBrowser.h" - -W3DWebBrowser::W3DWebBrowser() : WebBrowser() { -} - -Bool W3DWebBrowser::createBrowserWindow(char *tag, GameWindow *win) -{ - - WinInstanceData *winData = win->winGetInstanceData(); - AsciiString windowName = winData->m_decoratedNameString; - - Int x, y, w, h; - - win->winGetSize(&w, &h); - win->winGetScreenPosition(&x, &y); - - WebBrowserURL *url = findURL( AsciiString(tag) ); - - if (url == NULL) { - DEBUG_LOG(("W3DWebBrowser::createBrowserWindow - couldn't find URL for page %s\n", tag)); - return FALSE; - } - - CComQIPtr idisp(m_dispatch); - if (m_dispatch == NULL) - { - return FALSE; - } - - DX8WebBrowser::CreateBrowser(windowName.str(), url->m_url.str(), x, y, w, h, 0, BROWSEROPTION_SCROLLBARS | BROWSEROPTION_3DBORDER, (LPDISPATCH)this); - - return TRUE; -} - -void W3DWebBrowser::closeBrowserWindow(GameWindow *win) -{ - DX8WebBrowser::DestroyBrowser(win->winGetInstanceData()->m_decoratedNameString.str()); -} diff --git a/Generals/Code/Libraries/Source/WWVegas/WW3D2/dx8webbrowser.cpp b/Generals/Code/Libraries/Source/WWVegas/WW3D2/dx8webbrowser.cpp deleted file mode 100644 index 287af9b8c67..00000000000 --- a/Generals/Code/Libraries/Source/WWVegas/WW3D2/dx8webbrowser.cpp +++ /dev/null @@ -1,242 +0,0 @@ -/* -** Command & Conquer Generals(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -//****************************************************************************************** -// -// Earth And Beyond -// Copyright (c) 2002 Electronic Arts , Inc. - Westwood Studios -// -// File Name : dx8webbrowser.cpp -// Description : Implementation of D3D Embedded Browser wrapper. -// Author : Darren Schueller -// Date of Creation : 6/4/2002 -// -//****************************************************************************************** -// $Header: $ -//****************************************************************************************** - -#include "dx8webbrowser.h" -#include "ww3d.h" -#include "dx8wrapper.h" - -#if ENABLE_EMBEDDED_BROWSER - -// Import the Browser Type Library -// BGC, the path for the dll file is pretty odd, no? -// I'll leave it like this till I can figure out a -// better way. -#import "..\..\..\..\..\run\BrowserEngine.DLL" no_namespace - -static IFEBrowserEngine2Ptr pBrowser = 0; - -HWND DX8WebBrowser::hWnd = 0; - -bool DX8WebBrowser::Initialize( const char* badpageurl, - const char* loadingpageurl, - const char* mousefilename, - const char* mousebusyfilename) -{ - if(pBrowser == 0) - { - // Initialize COM - CoInitialize(0); - - // Create an instance of the browser control - HRESULT hr = pBrowser.CreateInstance(__uuidof(FEBrowserEngine2)); - - if(hr == REGDB_E_CLASSNOTREG) - { - HMODULE lib = ::LoadLibrary("BrowserEngine.DLL"); - if(lib) - { - FARPROC proc = ::GetProcAddress(lib,"DllRegisterServer"); - if(proc) - { - proc(); - // Create an instance of the browser control - hr = pBrowser.CreateInstance(__uuidof(FEBrowserEngine2)); - } - FreeLibrary(lib); - } - } - - // Initialize the browser. - if(hr == S_OK) - { - hWnd = (HWND)WW3D::Get_Window(); - pBrowser->Initialize(reinterpret_cast(DX8Wrapper::_Get_D3D_Device8())); - - if(badpageurl) - pBrowser->put_BadPageURL(_bstr_t(badpageurl)); - - if(loadingpageurl) - pBrowser->put_LoadingPageURL(_bstr_t(loadingpageurl)); - - if(mousefilename) - pBrowser->put_MouseFileName(_bstr_t(mousefilename)); - - if(mousebusyfilename) - pBrowser->put_MouseBusyFileName(_bstr_t(mousebusyfilename)); - } - else - { - pBrowser = 0; - return false; - } - } - - return true; -} - -void DX8WebBrowser::Shutdown() -{ - if(pBrowser) - { - // Shutdown the browser - pBrowser->Shutdown(); - - // Release the smart pointer. - pBrowser = 0; - - hWnd = 0; - - // Shut down COM - CoUninitialize(); - } -} - - -// ****************************************************************************************** -// * Function Name: DX8WebBrowser::Update -// ****************************************************************************************** -// * Description: Updates the browser image surfaces by copying the bits from the browser -// * DCs to the D3D Image surfaces. -// * -// * Return Type: -// * -// * Argument: void -// * -// ****************************************************************************************** -void DX8WebBrowser::Update(void) -{ - if(pBrowser) pBrowser->D3DUpdate(); -}; - - -// ****************************************************************************************** -// * Function Name: DX8WebBrowser::Render -// ****************************************************************************************** -// * Description: Draws all browsers to the back buffer. -// * -// * Return Type: -// * -// * Argument: int backbufferindex -// * -// ****************************************************************************************** -void DX8WebBrowser::Render(int backbufferindex) -{ - if(pBrowser) pBrowser->D3DRender(backbufferindex); -}; - -// ****************************************************************************************** -// * Function Name: DX8WebBrowser::CreateBrowser -// ****************************************************************************************** -// * Description: Creates a browser window. -// * -// * Return Type: -// * -// * Argument: const char* browsername - This is a "name" used to identify the -// * browser instance. Multiple browsers can -// * be created, and are referenced using this name. -// * Argument: const char* url - The url to display. -// * Argument: int x - The position and size of the browser (in pixels) -// * Argument: int y -// * Argument: int w -// * Argument: int h -// * Argument: int updateticks - When non-zero, this forces the browser image to get updated -// * at the specified rate (number of milliseconds) regardless -// * of paint messages. When this is zero (the default) the browser -// * image is only updated whenever a paint message is received. -// * -// ****************************************************************************************** -void DX8WebBrowser::CreateBrowser(const char* browsername, const char* url, int x, int y, int w, int h, int updateticks, LONG options, LPDISPATCH gamedispatch) -{ - DEBUG_LOG(("DX8WebBrowser::CreateBrowser - Creating browser with the name %s, url = %s, (x, y, w, h) = (%d, %d, %d, %d), update ticks = %d\n", browsername, url, x, y, h, w, updateticks)); - if(pBrowser) - { - _bstr_t brsname(browsername); - pBrowser->CreateBrowser(brsname, _bstr_t(url), reinterpret_cast(hWnd), x, y, w, h, options, gamedispatch); - pBrowser->SetUpdateRate(brsname, updateticks); - } -} - - -// ****************************************************************************************** -// * Function Name: DX8WebBrowser::DestroyBrowser -// ****************************************************************************************** -// * Description: Destroys the specified browser. This closes the window and releases -// * the browser instance. -// * -// * Return Type: -// * -// * Argument: const char* browsername - The name of the browser to destroy. -// * -// ****************************************************************************************** -void DX8WebBrowser::DestroyBrowser(const char* browsername) -{ - DEBUG_LOG(("DX8WebBrowser::DestroyBrowser - destroying browser %s\n", browsername)); - if(pBrowser) - pBrowser->DestroyBrowser(_bstr_t(browsername)); -} - - -// ****************************************************************************************** -// * Function Name: DX8WebBrowser::Is_Browser_Open -// ****************************************************************************************** -// * Description: This function checks to see if a browser of the specified name exists and -// * is currently open. -// * -// * Return Type: -// * -// * Argument: const char* browsername - The name of the browser to test. -// * -// ****************************************************************************************** -bool DX8WebBrowser::Is_Browser_Open(const char* browsername) -{ - if(pBrowser == 0) return false; - return (pBrowser->IsOpen(_bstr_t(browsername)) != 0); -} - -// ****************************************************************************************** -// * Function Name: DX8WebBrowser::Navigate -// ****************************************************************************************** -// * Description: This function causes the browser to navigate to the specified page. -// * -// * Return Type: -// * -// * Argument: const char* browsername - The name of the browser to test. -// * const char* url - The url to navigate to. -// * -// ****************************************************************************************** -void DX8WebBrowser::Navigate(const char* browsername, const char* url) -{ - if(pBrowser == 0) return; - pBrowser->Navigate(_bstr_t(browsername),_bstr_t(url)); -} - -#endif \ No newline at end of file diff --git a/Generals/Code/Libraries/Source/WWVegas/WW3D2/dx8webbrowser.h b/Generals/Code/Libraries/Source/WWVegas/WW3D2/dx8webbrowser.h deleted file mode 100644 index 82d68c35d71..00000000000 --- a/Generals/Code/Libraries/Source/WWVegas/WW3D2/dx8webbrowser.h +++ /dev/null @@ -1,93 +0,0 @@ -/* -** Command & Conquer Generals(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -//****************************************************************************************** -// -// Earth And Beyond -// Copyright (c) 2002 Electronic Arts , Inc. - Westwood Studios -// -// File Name : dx8webbrowser.h -// Description : Implementation of D3D Embedded Browser Wrapper -// Author : Darren Schueller -// Date of Creation : 6/4/2002 -// -//****************************************************************************************** -// $Header: $ -//****************************************************************************************** - -#ifndef DX8_WEBBROWSER_H -#define DX8_WEBBROWSER_H - -#include -#include "d3d8.h" - -// *********************************** -// Set this to 0 to remove all embedded browser code. -// -#define ENABLE_EMBEDDED_BROWSER 1 -// -// *********************************** - -#if ENABLE_EMBEDDED_BROWSER - -// These options must match the browser option bits defined in the BrowserEngine code. -// Look in febrowserengine.h -#define BROWSEROPTION_SCROLLBARS 0x0001 -#define BROWSEROPTION_3DBORDER 0x0002 - -struct IDirect3DDevice8; - -/** -** DX8WebBrowser -** -** DX8 interface wrapper class. This encapsulates the BrowserEngine interface. -*/ -class DX8WebBrowser -{ -public: - - static bool Initialize( const char* badpageurl = 0, - const char* loadingpageurl = 0, - const char* mousefilename = 0, - const char* mousebusyfilename = 0); //Initialize the Embedded Browser - - static void Shutdown(void); // Shutdown the embedded browser. Will close any open browsers. - - static void Update(void); // Copies all browser contexts to D3D Image surfaces. - static void Render(int backbufferindex); //Draws all browsers to the backbuffer. - - // Creates a browser with the specified name - static void CreateBrowser(const char* browsername, const char* url, int x, int y, int w, int h, int updateticks = 0, LONG options = BROWSEROPTION_SCROLLBARS | BROWSEROPTION_3DBORDER, LPDISPATCH gamedispatch = 0); - - // Destroys the browser with the specified name - static void DestroyBrowser(const char* browsername); - - // Returns true if a browser with the specified name is open. - static bool Is_Browser_Open(const char* browsername); - - // Navigates the specified browser to the specified page. - static void Navigate(const char* browsername, const char* url); - -private: - // The window handle of the application. This is initialized by Initialize(). - static HWND hWnd; -}; - -#endif - -#endif \ No newline at end of file diff --git a/Generals/Code/Libraries/Source/WWVegas/WW3D2/dx8wrapper.cpp b/Generals/Code/Libraries/Source/WWVegas/WW3D2/dx8wrapper.cpp index b9835328e4b..93a1b87c843 100644 --- a/Generals/Code/Libraries/Source/WWVegas/WW3D2/dx8wrapper.cpp +++ b/Generals/Code/Libraries/Source/WWVegas/WW3D2/dx8wrapper.cpp @@ -72,7 +72,6 @@ #include "formconv.h" #include "dx8texman.h" #include "bound.h" -#include "dx8webbrowser.h" #define WW3D_DEVTYPE D3DDEVTYPE_HAL @@ -1425,7 +1424,6 @@ void DX8Wrapper::Begin_Scene(void) DX8_THREAD_ASSERT(); DX8CALL(BeginScene()); - DX8WebBrowser::Update(); } void DX8Wrapper::End_Scene(bool flip_frames) @@ -1433,7 +1431,6 @@ void DX8Wrapper::End_Scene(bool flip_frames) DX8_THREAD_ASSERT(); DX8CALL(EndScene()); - DX8WebBrowser::Render(0); if (flip_frames) { DX8_Assert(); diff --git a/Generals/Code/Libraries/Source/WWVegas/WW3D2/ww3d2.dsp b/Generals/Code/Libraries/Source/WWVegas/WW3D2/ww3d2.dsp index fd435587fb0..21852f87830 100644 --- a/Generals/Code/Libraries/Source/WWVegas/WW3D2/ww3d2.dsp +++ b/Generals/Code/Libraries/Source/WWVegas/WW3D2/ww3d2.dsp @@ -4,7 +4,7 @@ # TARGTYPE "Win32 (x86) Static Library" 0x0104 -CFG=ww3d2 - Win32 DebugW3D +CFG=ww3d2 - Win32 Release !MESSAGE This is not a valid makefile. To build this project using NMAKE, !MESSAGE use the Export Makefile command and run !MESSAGE @@ -13,7 +13,7 @@ CFG=ww3d2 - Win32 DebugW3D !MESSAGE You can specify a configuration when running NMAKE !MESSAGE by defining the macro CFG on the command line. For example: !MESSAGE -!MESSAGE NMAKE /f "ww3d2.mak" CFG="ww3d2 - Win32 DebugW3D" +!MESSAGE NMAKE /f "ww3d2.mak" CFG="ww3d2 - Win32 Release" !MESSAGE !MESSAGE Possible choices for configuration are: !MESSAGE @@ -289,10 +289,6 @@ SOURCE=.\dx8vertexbuffer.cpp # End Source File # Begin Source File -SOURCE=.\dx8webbrowser.cpp -# End Source File -# Begin Source File - SOURCE=.\dx8wrapper.cpp # End Source File # Begin Source File @@ -722,10 +718,6 @@ SOURCE=.\dx8vertexbuffer.h # End Source File # Begin Source File -SOURCE=.\dx8webbrowser.h -# End Source File -# Begin Source File - SOURCE=.\dx8wrapper.h # End Source File # Begin Source File diff --git a/Generals/Code/Libraries/Source/WWVegas/WWLib/LaunchWeb.cpp b/Generals/Code/Libraries/Source/WWVegas/WWLib/LaunchWeb.cpp deleted file mode 100644 index e244f5704e7..00000000000 --- a/Generals/Code/Libraries/Source/WWVegas/WWLib/LaunchWeb.cpp +++ /dev/null @@ -1,120 +0,0 @@ -/* -** Command & Conquer Generals(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -/****************************************************************************** -* -* FILE -* $Archive: /Commando/Code/wwlib/LaunchWeb.cpp $ -* -* PROGRAMMER -* Denzil E. Long, Jr. -* $Author: Denzil_l $ -* -* VERSION INFO -* $Revision: 2 $ -* $Modtime: 6/22/01 4:39p $ -* -******************************************************************************/ - -#include "LaunchWeb.h" -#include -#include -#include -#include - -/****************************************************************************** -* -* NAME -* LaunchWebBrowser -* -* DESCRIPTION -* Launch the default browser to view the specified URL -* -* INPUTS -* URL - Website address -* Wait - Wait for user to close browser (default = false) -* Callback - User callback to invoke during wait (default = NULL callback) -* -* RESULT -* Success - True if successful; otherwise false -* -******************************************************************************/ - -bool LaunchWebBrowser(const char* url) - { - // Just return if no URL specified - if (!url || (strlen(url) == 0)) - { - return false; - } - - // Create a temporary file with HTML content - char tempPath[MAX_PATH]; - GetWindowsDirectory(tempPath, MAX_PATH); - - char filename[MAX_PATH]; - GetTempFileName(tempPath, "WWS", 0, filename); - - char* extPtr = strrchr(filename, '.'); - strcpy(extPtr, ".html"); - - HANDLE file = CreateFile(filename, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, - FILE_ATTRIBUTE_NORMAL, NULL); - - assert(INVALID_HANDLE_VALUE != file && "Failed to create temporary HTML file."); - - if (INVALID_HANDLE_VALUE == file) - { - return false; - } - - // Write generic contents - const char* contents = "ViewHTML"; - DWORD written; - WriteFile(file, contents, strlen(contents), &written, NULL); - CloseHandle(file); - - // Find the executable that can launch this file - char exeName[MAX_PATH]; - HINSTANCE hInst = FindExecutable(filename, NULL, exeName); - assert(((int)hInst > 32) && "Unable to find executable that will display HTML files."); - - // Delete temporary file - DeleteFile(filename); - - if ((int)hInst <= 32) - { - return false; - } - - // Launch browser with specified URL - char commandLine[MAX_PATH]; - sprintf(commandLine, "[open] %s", url); - - STARTUPINFO startupInfo; - memset(&startupInfo, 0, sizeof(startupInfo)); - startupInfo.cb = sizeof(startupInfo); - - PROCESS_INFORMATION processInfo; - BOOL createSuccess = CreateProcess(exeName, commandLine, NULL, NULL, FALSE, - 0, NULL, NULL, &startupInfo, &processInfo); - - assert(createSuccess && "Failed to launch default WebBrowser."); - - return (TRUE == createSuccess); - } diff --git a/Generals/Code/Libraries/Source/WWVegas/WWLib/LaunchWeb.h b/Generals/Code/Libraries/Source/WWVegas/WWLib/LaunchWeb.h deleted file mode 100644 index a6d5f863ab1..00000000000 --- a/Generals/Code/Libraries/Source/WWVegas/WWLib/LaunchWeb.h +++ /dev/null @@ -1,48 +0,0 @@ -/* -** Command & Conquer Generals(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -/****************************************************************************** -* -* FILE -* $Archive: /Commando/Code/wwlib/LaunchWeb.h $ -* -* PROGRAMMER -* Denzil E. Long, Jr. -* $Author: Denzil_l $ -* -* VERSION INFO -* $Revision: 1 $ -* $Modtime: 4/20/01 3:22p $ -* -******************************************************************************/ - -#ifndef __LAUNCHWEB_H__ -#define __LAUNCHWEB_H__ - -#ifdef __cplusplus -extern "C" { -#endif - -bool LaunchWebBrowser(const char* url); - -#ifdef __cplusplus -} -#endif - - -#endif // __LAUNCHWEB_H__ diff --git a/Generals/Code/Libraries/Source/WWVegas/WWLib/wwlib.dsp b/Generals/Code/Libraries/Source/WWVegas/WWLib/wwlib.dsp index 536dda8987f..cbb4b5393b9 100644 --- a/Generals/Code/Libraries/Source/WWVegas/WWLib/wwlib.dsp +++ b/Generals/Code/Libraries/Source/WWVegas/WWLib/wwlib.dsp @@ -237,10 +237,6 @@ SOURCE=.\keyboard.cpp # End Source File # Begin Source File -SOURCE=.\LaunchWeb.cpp -# End Source File -# Begin Source File - SOURCE=.\lcw.cpp # End Source File # Begin Source File @@ -597,10 +593,6 @@ SOURCE=.\keyboard.h # End Source File # Begin Source File -SOURCE=.\LaunchWeb.h -# End Source File -# Begin Source File - SOURCE=.\LCW.H # End Source File # Begin Source File diff --git a/Generals/Code/RTS.dsp b/Generals/Code/RTS.dsp index 032115d90bf..a5c23b6d5b6 100644 --- a/Generals/Code/RTS.dsp +++ b/Generals/Code/RTS.dsp @@ -71,7 +71,7 @@ LINK32=link.exe # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c -# ADD CPP /nologo /G6 /MDd /W3 /WX /Gm /GX /ZI /Od /I "Libraries\Include" /I "GameEngine\Include" /I "gameenginedevice\Include" /I "Libraries\Source\WWVegas" /I "Libraries\Source\WWVegas\WWLib" /I "Libraries\Source\WWVegas\WWMath" /I "Libraries\Source\WWVegas\WWDebug" /I "Libraries\Source\WWVegas\WWSaveLoad" /I "Libraries\Source\WWVegas\WW3D2" /I "Libraries\Include\Granny" /I "Libraries\Source\Bink" /I "Libraries\Source\Miles" /D "_DEBUG" /D "BROWSER_DEBUG" /D WINVER=0x400 /D "WIN32" /D "_WINDOWS" /D "_MBCS" /Fr /YX /FD /GZ /c +# ADD CPP /nologo /G6 /MDd /W3 /WX /Gm /GX /ZI /Od /I "Libraries\Include" /I "GameEngine\Include" /I "gameenginedevice\Include" /I "Libraries\Source\WWVegas" /I "Libraries\Source\WWVegas\WWLib" /I "Libraries\Source\WWVegas\WWMath" /I "Libraries\Source\WWVegas\WWDebug" /I "Libraries\Source\WWVegas\WWSaveLoad" /I "Libraries\Source\WWVegas\WW3D2" /I "Libraries\Include\Granny" /I "Libraries\Source\Bink" /I "Libraries\Source\Miles" /D "_DEBUG" /D WINVER=0x400 /D "WIN32" /D "_WINDOWS" /D "_MBCS" /Fr /YX /FD /GZ /c # ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD BASE RSC /l 0x409 /d "_DEBUG" diff --git a/Generals/Run/BrowserEngine.dll b/Generals/Run/BrowserEngine.dll deleted file mode 100644 index a8a19e4b921..00000000000 Binary files a/Generals/Run/BrowserEngine.dll and /dev/null differ diff --git a/Generals/Run/place_steam_build_here.txt b/Generals/Run/place_steam_build_here.txt deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/GeneralsMD/Code/GameEngine/GameEngine.dsp b/GeneralsMD/Code/GameEngine/GameEngine.dsp index 281661825fd..678b7cb6485 100644 --- a/GeneralsMD/Code/GameEngine/GameEngine.dsp +++ b/GeneralsMD/Code/GameEngine/GameEngine.dsp @@ -441,10 +441,6 @@ SOURCE=.\Source\Common\INI\INIWater.cpp SOURCE=.\Source\Common\INI\INIWeapon.cpp # End Source File -# Begin Source File - -SOURCE=.\Source\Common\INI\INIWebpageURL.cpp -# End Source File # End Group # Begin Group "Audio" @@ -2430,14 +2426,6 @@ SOURCE=.\Source\GameClient\Water.cpp # Begin Group "GameNetwork" # PROP Default_Filter "" -# Begin Group "WOLBrowser" - -# PROP Default_Filter ".cpp" -# Begin Source File - -SOURCE=.\Source\GameNetwork\WOLBrowser\WebBrowser.cpp -# End Source File -# End Group # Begin Group "GameSpy" # PROP Default_Filter "" @@ -4671,20 +4659,6 @@ SOURCE=.\Include\GameClient\WinInstanceData.h # End Group # Begin Group "GameNetwork.H" -# PROP Default_Filter "" -# Begin Group "WOLBrowser H" - -# PROP Default_Filter ".h" -# Begin Source File - -SOURCE=.\Include\GameNetwork\WOLBrowser\FEBDispatch.h -# End Source File -# Begin Source File - -SOURCE=.\Include\GameNetwork\WOLBrowser\WebBrowser.h -# End Source File -# End Group -# Begin Group "GameSpyLibs.H" # PROP Default_Filter "" # Begin Group "md5" diff --git a/GeneralsMD/Code/GameEngine/Include/Common/GameEngine.h b/GeneralsMD/Code/GameEngine/Include/Common/GameEngine.h index 087e0e8aba7..6d19fa6d068 100644 --- a/GeneralsMD/Code/GameEngine/Include/Common/GameEngine.h +++ b/GeneralsMD/Code/GameEngine/Include/Common/GameEngine.h @@ -52,7 +52,6 @@ class ModuleFactory; class ThingFactory; class FunctionLexicon; class Radar; -class WebBrowser; class ParticleSystemManager; /** @@ -95,7 +94,6 @@ class GameEngine : public SubsystemInterface virtual ThingFactory *createThingFactory( void ) = 0; ///< Factory for the thing factory virtual FunctionLexicon *createFunctionLexicon( void ) = 0; ///< Factory for Function Lexicon virtual Radar *createRadar( void ) = 0; ///< Factory for radar - virtual WebBrowser *createWebBrowser( void ) = 0; ///< Factory for embedded browser virtual ParticleSystemManager* createParticleSystemManager( void ) = 0; virtual AudioManager *createAudioManager( void ) = 0; ///< Factory for Audio Manager diff --git a/GeneralsMD/Code/GameEngine/Include/Common/INI.h b/GeneralsMD/Code/GameEngine/Include/Common/INI.h index 1eef9ee1d95..1b1dc01dc9d 100644 --- a/GeneralsMD/Code/GameEngine/Include/Common/INI.h +++ b/GeneralsMD/Code/GameEngine/Include/Common/INI.h @@ -197,7 +197,6 @@ class INI static void parseAudioEventDefinition( INI *ini ); static void parseDialogDefinition( INI *ini ); static void parseMusicTrackDefinition( INI *ini ); - static void parseWebpageURLDefinition( INI *ini ); static void parseHeaderTemplateDefinition( INI *ini ); static void parseParticleSystemDefinition( INI *ini ); static void parseWaterSettingDefinition( INI *ini ); diff --git a/GeneralsMD/Code/GameEngine/Include/GameNetwork/WOLBrowser/FEBDispatch.h b/GeneralsMD/Code/GameEngine/Include/GameNetwork/WOLBrowser/FEBDispatch.h deleted file mode 100644 index c6a103c124c..00000000000 --- a/GeneralsMD/Code/GameEngine/Include/GameNetwork/WOLBrowser/FEBDispatch.h +++ /dev/null @@ -1,106 +0,0 @@ -/* -** Command & Conquer Generals Zero Hour(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -//////////////////////////////////////////////////////////////////////////////// -// // -// (c) 2001-2003 Electronic Arts Inc. // -// // -//////////////////////////////////////////////////////////////////////////////// - -// -// FEBDispatch class is a template class which, when inherited from, can implement the -// IDispatch for a COM object with a type library. -// - -#ifndef _FEBDISPATCH_H__ -#define _FEBDISPATCH_H__ - -#include -extern CComModule _Module; -#include -#include // For _bstr_t. - -#include "oleauto.h" - -template -class FEBDispatch : -public CComObjectRootEx, -public CComCoClass, -public C -{ -public: - - BEGIN_COM_MAP(T) - COM_INTERFACE_ENTRY(C) - COM_INTERFACE_ENTRY_AGGREGATE(IID_IDispatch, m_dispatch) - END_COM_MAP() - - FEBDispatch() - { - m_ptinfo = NULL; - m_dispatch = NULL; - - ITypeLib *ptlib; - HRESULT hr; - HRESULT TypeLibraryLoadResult; - char filename[256]; - - GetModuleFileName(NULL, filename, sizeof(filename)); - _bstr_t bstr(filename); - - TypeLibraryLoadResult = LoadTypeLib(bstr, &ptlib); - - DEBUG_ASSERTCRASH(TypeLibraryLoadResult == 0, ("Can't load type library for Embedded Browser")); - - if (TypeLibraryLoadResult == S_OK) - { - hr = ptlib->GetTypeInfoOfGuid(*I, &m_ptinfo); - ptlib->Release(); - - if (hr == S_OK) - { - hr = CreateStdDispatch(static_cast(this), static_cast(this), m_ptinfo, &m_dispatch); - - m_dispatch->AddRef(); - // Don't release the IUnknown from CreateStdDispatch without calling AddRef. - // It looks like CreateStdDispatch doesn't call AddRef on the IUnknown it returns. - } - } - - if ( (m_dispatch == NULL) ) - { - DEBUG_LOG(("Error creating Dispatch for Web interface\n")); - } - } - - virtual ~FEBDispatch() - { - if (m_ptinfo) - m_ptinfo->Release(); - - if (m_dispatch) - m_dispatch->Release(); - } - - IUnknown *m_dispatch; - -private: - ITypeInfo *m_ptinfo; -}; - -#endif diff --git a/GeneralsMD/Code/GameEngine/Include/GameNetwork/WOLBrowser/WebBrowser.h b/GeneralsMD/Code/GameEngine/Include/GameNetwork/WOLBrowser/WebBrowser.h deleted file mode 100644 index fa76db2b900..00000000000 --- a/GeneralsMD/Code/GameEngine/Include/GameNetwork/WOLBrowser/WebBrowser.h +++ /dev/null @@ -1,127 +0,0 @@ -/* -** Command & Conquer Generals Zero Hour(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -//////////////////////////////////////////////////////////////////////////////// -// // -// (c) 2001-2003 Electronic Arts Inc. // -// // -//////////////////////////////////////////////////////////////////////////////// - -/****************************************************************************** -* -* NAME -* $Archive: $ -* -* DESCRIPTION -* Web Browser -* -* PROGRAMMER -* Bryan Cleveland -* $Author: $ -* -* VERSION INFO -* $Revision: $ -* $Modtime: $ -* -******************************************************************************/ - -#pragma once - -#ifndef __WEBBROWSER_H__ -#define __WEBBROWSER_H__ - -#include "Common/SubsystemInterface.h" -#include -#include -#include -#include "EABrowserDispatch/BrowserDispatch.h" -#include "FEBDispatch.h" - -class GameWindow; - -class WebBrowserURL : public MemoryPoolObject -{ - MEMORY_POOL_GLUE_WITH_USERLOOKUP_CREATE( WebBrowserURL, "WebBrowserURL" ) - -public: - - WebBrowserURL(); - // virtual destructor prototype defined by memory pool object - - const FieldParse *getFieldParse( void ) const { return m_URLFieldParseTable; } - - AsciiString m_tag; - AsciiString m_url; - - WebBrowserURL *m_next; - - static const FieldParse m_URLFieldParseTable[]; ///< the parse table for INI definition - -}; - - - -class WebBrowser : - public FEBDispatch, - public SubsystemInterface - { - public: - void init( void ); - void reset( void ); - void update( void ); - - // Create an instance of the embedded browser for Dune Emperor. - virtual Bool createBrowserWindow(char *tag, GameWindow *win) = 0; - virtual void closeBrowserWindow(GameWindow *win) = 0; - - WebBrowserURL *makeNewURL(AsciiString tag); - WebBrowserURL *findURL(AsciiString tag); - - protected: - // Protected to prevent direct construction via new, use CreateInstance() instead. - WebBrowser(); - virtual ~WebBrowser(); - - // Protected to prevent copy and assignment - WebBrowser(const WebBrowser&); - const WebBrowser& operator=(const WebBrowser&); - -// Bool RetrievePageURL(const char* page, char* url, int size); -// Bool RetrieveHTMLPath(char* path, int size); - - protected: - ULONG mRefCount; - WebBrowserURL *m_urlList; - - //--------------------------------------------------------------------------- - // IUnknown methods - //--------------------------------------------------------------------------- - protected: - HRESULT STDMETHODCALLTYPE QueryInterface(REFIID riid, void** ppvObject); - ULONG STDMETHODCALLTYPE AddRef(void); - ULONG STDMETHODCALLTYPE Release(void); - - //--------------------------------------------------------------------------- - // IBrowserDispatch methods - //--------------------------------------------------------------------------- - public: - STDMETHOD(TestMethod)(Int num1); - }; - -extern CComObject *TheWebBrowser; -#endif // __WEBBROWSER_H__ diff --git a/GeneralsMD/Code/GameEngine/Source/Common/GameEngine.cpp b/GeneralsMD/Code/GameEngine/Source/Common/GameEngine.cpp index 18c691b1795..ba20321e594 100644 --- a/GeneralsMD/Code/GameEngine/Source/Common/GameEngine.cpp +++ b/GeneralsMD/Code/GameEngine/Source/Common/GameEngine.cpp @@ -102,7 +102,6 @@ #include "GameClient/GUICallbacks.h" #include "GameNetwork/NetworkInterface.h" -#include "GameNetwork/WOLBrowser/WebBrowser.h" #include "GameNetwork/LANAPI.h" #include "GameNetwork/GameSpy/GameResultsThread.h" @@ -169,7 +168,6 @@ void initSubsystem(SUBSYSTEM*& sysref, AsciiString name, SUBSYSTEM* sys, Xfer *p //------------------------------------------------------------------------------------------------- extern HINSTANCE ApplicationHInstance; ///< our application instance -extern CComModule _Module; //------------------------------------------------------------------------------------------------- static void updateTGAtoDDS(); @@ -189,8 +187,6 @@ GameEngine::GameEngine( void ) m_maxFPS = 0; m_quitting = FALSE; m_isActive = FALSE; - - _Module.Init(NULL, ApplicationHInstance); } //------------------------------------------------------------------------------------------------- @@ -228,8 +224,6 @@ GameEngine::~GameEngine() Drawable::killStaticImages(); - _Module.Term(); - #ifdef PERF_TIMERS PerfGather::termPerfDump(); #endif @@ -534,7 +528,6 @@ void GameEngine::init( int argc, char *argv[] ) initSubsystem(TheActionManager,"TheActionManager", MSGNEW("GameEngineSubsystem") ActionManager(), NULL); - //initSubsystem((CComObject *)TheWebBrowser,"(CComObject *)TheWebBrowser", (CComObject *)createWebBrowser(), NULL); initSubsystem(TheGameStateMap,"TheGameStateMap", MSGNEW("GameEngineSubsystem") GameStateMap, NULL, NULL, NULL ); initSubsystem(TheGameState,"TheGameState", MSGNEW("GameEngineSubsystem") GameState, NULL, NULL, NULL ); diff --git a/GeneralsMD/Code/GameEngine/Source/Common/INI/INI.cpp b/GeneralsMD/Code/GameEngine/Source/Common/INI/INI.cpp index 318d36af1e4..72aa8439eac 100644 --- a/GeneralsMD/Code/GameEngine/Source/Common/INI/INI.cpp +++ b/GeneralsMD/Code/GameEngine/Source/Common/INI/INI.cpp @@ -136,7 +136,6 @@ static const BlockParse theTypeTable[] = { "WaterTransparency", INI::parseWaterTransparencyDefinition}, { "Weather", INI::parseWeatherDefinition}, { "Weapon", INI::parseWeaponTemplateDefinition }, - { "WebpageURL", INI::parseWebpageURLDefinition }, { "HeaderTemplate", INI::parseHeaderTemplateDefinition }, { "StaticGameLOD", INI::parseStaticGameLODDefinition }, { "DynamicGameLOD", INI::parseDynamicGameLODDefinition }, diff --git a/GeneralsMD/Code/GameEngine/Source/Common/INI/INIWebpageURL.cpp b/GeneralsMD/Code/GameEngine/Source/Common/INI/INIWebpageURL.cpp deleted file mode 100644 index 09fd9d2e905..00000000000 --- a/GeneralsMD/Code/GameEngine/Source/Common/INI/INIWebpageURL.cpp +++ /dev/null @@ -1,128 +0,0 @@ -/* -** Command & Conquer Generals Zero Hour(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -//////////////////////////////////////////////////////////////////////////////// -// // -// (c) 2001-2003 Electronic Arts Inc. // -// // -//////////////////////////////////////////////////////////////////////////////// - -// FILE: INIWebpageURL.cpp ///////////////////////////////////////////////////////////////////////////// -// Author: Bryan Cleveland, November 2001 -// Desc: Parsing Webpage URL INI entries -/////////////////////////////////////////////////////////////////////////////////////////////////// - -// INCLUDES /////////////////////////////////////////////////////////////////////////////////////// -#include "PreRTS.h" // This must go first in EVERY cpp file int the GameEngine - -#include "Common/INI.h" -#include "Common/Registry.h" -#include "GameNetwork/WOLBrowser/WebBrowser.h" - -#ifdef _INTERNAL -// for occasional debugging... -//#pragma optimize("", off) -//#pragma MESSAGE("************************************** WARNING, optimization disabled for debugging purposes") -#endif - -/////////////////////////////////////////////////////////////////////////////////////////////////// -// PRIVATE DATA /////////////////////////////////////////////////////////////////////////////////// -/////////////////////////////////////////////////////////////////////////////////////////////////// - -/////////////////////////////////////////////////////////////////////////////////////////////////// -// PUBLIC FUNCTIONS /////////////////////////////////////////////////////////////////////////////// -/////////////////////////////////////////////////////////////////////////////////////////////////// - -AsciiString encodeURL(AsciiString source) -{ - if (source.isEmpty()) - { - return AsciiString::TheEmptyString; - } - - AsciiString target; - AsciiString allowedChars = "$-_.+!*'(),\\"; - const char *ptr = source.str(); - while (*ptr) - { - if (isalnum(*ptr) || allowedChars.find(*ptr)) - { - target.concat(*ptr); - } - else - { - AsciiString tmp; - target.concat('%'); - tmp.format("%2.2x", ((int)*ptr)); - target.concat(tmp); - } - ++ptr; - } - - return target; -} - -//------------------------------------------------------------------------------------------------- -/** Parse Music entry */ -//------------------------------------------------------------------------------------------------- -void INI::parseWebpageURLDefinition( INI* ini ) -{ - AsciiString tag; - WebBrowserURL *url; - - // read the name - const char* c = ini->getNextToken(); - tag.set( c ); - - if (TheWebBrowser != NULL) - { - url = TheWebBrowser->findURL(tag); - - if (url == NULL) - { - url = TheWebBrowser->makeNewURL(tag); - } - } - - // find existing item if present -// track = TheAudio->Music->getTrack( name ); -// if( track == NULL ) -// { - - // allocate a new track -// track = TheAudio->Music->newMusicTrack( name ); - -// } // end if - -// DEBUG_ASSERTCRASH( track, ("parseMusicTrackDefinition: Unable to allocate track '%s'\n", -// name.str()) ); - - // parse the ini definition - ini->initFromINI( url, url->getFieldParse() ); - - if (url->m_url.startsWith("file://")) - { - char cwd[_MAX_PATH] = "\\"; - getcwd(cwd, _MAX_PATH); - - url->m_url.format("file://%s\\Data\\%s\\%s", encodeURL(cwd).str(), GetRegistryLanguage().str(), url->m_url.str()+7); - DEBUG_LOG(("INI::parseWebpageURLDefinition() - converted URL to [%s]\n", url->m_url.str())); - } -} // end parseMusicTrackDefinition - - diff --git a/GeneralsMD/Code/GameEngine/Source/Common/System/MemoryInit.cpp b/GeneralsMD/Code/GameEngine/Source/Common/System/MemoryInit.cpp index 27f04f3478a..d04400597df 100644 --- a/GeneralsMD/Code/GameEngine/Source/Common/System/MemoryInit.cpp +++ b/GeneralsMD/Code/GameEngine/Source/Common/System/MemoryInit.cpp @@ -114,7 +114,6 @@ static PoolSizeRec sizes[] = { "CommandButton", 1024, 256 }, { "CommandSet", 820, 16 }, { "DisplayString", 32, 32 }, - { "WebBrowserURL", 16, 16 }, { "Drawable", 4096, 32 }, { "Image", 2048, 32 }, { "ParticlePool", 1400, 1024 }, diff --git a/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLLadderScreen.cpp b/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLLadderScreen.cpp index 76e671af293..95899d4850e 100644 --- a/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLLadderScreen.cpp +++ b/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLLadderScreen.cpp @@ -36,7 +36,6 @@ #include "GameClient/KeyDefs.h" #include "GameClient/GameWindowManager.h" #include "GameClient/MessageBox.h" -#include "GameNetwork/WOLBrowser/WebBrowser.h" // window ids ------------------------------------------------------------------------------------- static NameKeyType parentWindowID = NAMEKEY_INVALID; @@ -69,12 +68,6 @@ void WOLLadderScreenInit( WindowLayout *layout, void *userData ) //Load the listbox shiznit // PopulateReplayFileListbox(listboxReplayFiles); - //TheWebBrowser->createBrowserWindow("Westwood", windowLadder); - if (TheWebBrowser != NULL) - { - TheWebBrowser->createBrowserWindow("MessageBoard", windowLadder); - } - // show menu layout->hide( FALSE ); @@ -89,11 +82,6 @@ void WOLLadderScreenInit( WindowLayout *layout, void *userData ) void WOLLadderScreenShutdown( WindowLayout *layout, void *userData ) { - if (TheWebBrowser != NULL) - { - TheWebBrowser->closeBrowserWindow(windowLadder); - } - // hide menu layout->hide( TRUE ); diff --git a/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLLoginMenu.cpp b/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLLoginMenu.cpp index 42c14f6ac7a..3a4378ebb81 100644 --- a/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLLoginMenu.cpp +++ b/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLLoginMenu.cpp @@ -66,7 +66,6 @@ #include "GameNetwork/GameSpyOverlay.h" -#include "GameNetwork/WOLBrowser/WebBrowser.h" #ifdef _INTERNAL // for occasional debugging... @@ -78,8 +77,6 @@ Bool GameSpyUseProfiles = false; #endif // ALLOW_NON_PROFILED_LOGIN -static Bool webBrowserActive = FALSE; -static Bool useWebBrowserForTOS = FALSE; static Bool isShuttingDown = false; static Bool buttonPushed = false; @@ -719,14 +716,6 @@ void WOLLoginMenuShutdown( WindowLayout *layout, void *userData ) isShuttingDown = true; loggedInOK = false; TheWindowManager->clearTabList(); - if (webBrowserActive) - { - if (TheWebBrowser != NULL) - { - TheWebBrowser->closeBrowserWindow(listboxTOS); - } - webBrowserActive = FALSE; - } // if we are shutting down for an immediate pop, skip the animations Bool popImmediate = *(Bool *)userData; @@ -1418,13 +1407,8 @@ WindowMsgHandledType WOLLoginMenuSystem( GameWindow *window, UnsignedInt msg, else if ( controlID == buttonTOSID ) { parentTOS->winHide(FALSE); - useWebBrowserForTOS = FALSE;//loginPref->getBool("UseTOSBrowser", TRUE); - if (useWebBrowserForTOS && (TheWebBrowser != NULL)) - { - TheWebBrowser->createBrowserWindow("TermsOfService", listboxTOS); - webBrowserActive = TRUE; - } - else + + if (1) { // Okay, no web browser. This means we're looking at a UTF-8 text file. GadgetListBoxReset(listboxTOS); @@ -1483,18 +1467,10 @@ WindowMsgHandledType WOLLoginMenuSystem( GameWindow *window, UnsignedInt msg, EnableLoginControls( TRUE ); parentTOS->winHide(TRUE); - if (useWebBrowserForTOS && (TheWebBrowser != NULL)) - { - if (listboxTOS != NULL) - { - TheWebBrowser->closeBrowserWindow(listboxTOS); - } - } OptionPreferences optionPref; optionPref["SawTOS"] = "yes"; optionPref.write(); - webBrowserActive = FALSE; buttonBack->winEnable(TRUE); } break; diff --git a/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLWelcomeMenu.cpp b/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLWelcomeMenu.cpp index cdd0981ec74..6aaf468ffd5 100644 --- a/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLWelcomeMenu.cpp +++ b/GeneralsMD/Code/GameEngine/Source/GameClient/GUI/GUICallbacks/Menus/WOLWelcomeMenu.cpp @@ -67,7 +67,6 @@ #include "GameNetwork/GameSpy/BuddyThread.h" #include "GameNetwork/GameSpy/ThreadUtils.h" #include "GameNetwork/GameSpy/MainMenuUtils.h" -#include "GameNetwork/WOLBrowser/WebBrowser.h" #ifdef _INTERNAL // for occasional debugging... diff --git a/GeneralsMD/Code/GameEngine/Source/GameNetwork/WOLBrowser/WebBrowser.cpp b/GeneralsMD/Code/GameEngine/Source/GameNetwork/WOLBrowser/WebBrowser.cpp deleted file mode 100644 index 34466e79649..00000000000 --- a/GeneralsMD/Code/GameEngine/Source/GameNetwork/WOLBrowser/WebBrowser.cpp +++ /dev/null @@ -1,315 +0,0 @@ -/* -** Command & Conquer Generals Zero Hour(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -//////////////////////////////////////////////////////////////////////////////// -// // -// (c) 2001-2003 Electronic Arts Inc. // -// // -//////////////////////////////////////////////////////////////////////////////// - -/****************************************************************************** -* -* NAME -* $Archive: $ -* -* DESCRIPTION -* -* PROGRAMMER -* Bryan Cleveland -* $Author: $ -* -* VERSION INFO -* $Revision: $ -* $Modtime: $ -* -******************************************************************************/ - -#include "PreRTS.h" // This must go first in EVERY cpp file int the GameEngine - -//#include "WinMain.h" -#include "GameNetwork/WOLBrowser/WebBrowser.h" -#include "GameClient/GameWindow.h" -#include "GameClient/Display.h" - -#ifdef _INTERNAL -// for occasional debugging... -//#pragma optimize("", off) -//#pragma MESSAGE("************************************** WARNING, optimization disabled for debugging purposes") -#endif - -/** - * OLEInitializer class - Init and shutdown OLE & COM as a global - * object. Scary, nasty stuff, COM. /me shivers. - */ -class OLEInitializer -{ -public: - OLEInitializer() - { - // Initialize this instance - OleInitialize(NULL); - } - ~OLEInitializer() - { - OleUninitialize(); - } -}; -OLEInitializer g_OLEInitializer; -CComModule _Module; - -CComObject * TheWebBrowser = NULL; - - -/****************************************************************************** -* -* NAME -* WebBrowser::WebBrowser -* -* DESCRIPTION -* Default constructor -* -* INPUTS -* NONE -* -* RESULT -* NONE -* -******************************************************************************/ - -WebBrowser::WebBrowser() : - mRefCount(1) -{ - DEBUG_LOG(("Instantiating embedded WebBrowser\n")); - m_urlList = NULL; -} - - -/****************************************************************************** -* -* NAME -* WebBrowser::~WebBrowser -* -* DESCRIPTION -* Destructor -* -* INPUTS -* NONE -* -* RESULT -* NONE -* -******************************************************************************/ - -WebBrowser::~WebBrowser() -{ - DEBUG_LOG(("Destructing embedded WebBrowser\n")); - if (this == TheWebBrowser) { - DEBUG_LOG(("WebBrowser::~WebBrowser - setting TheWebBrowser to NULL\n")); - TheWebBrowser = NULL; - } - WebBrowserURL *url = m_urlList; - while (url != NULL) { - WebBrowserURL *temp = url; - url = url->m_next; - temp->deleteInstance(); - temp = NULL; - } -} - -//------------------------------------------------------------------------------------------------- -/** The INI data fields for Webpage URL's */ -//------------------------------------------------------------------------------------------------- -const FieldParse WebBrowserURL::m_URLFieldParseTable[] = -{ - - { "URL", INI::parseAsciiString, NULL, offsetof( WebBrowserURL, m_url ) }, - { NULL, NULL, NULL, 0 }, - -}; - -WebBrowserURL::WebBrowserURL() -{ - m_next = NULL; - m_tag.clear(); - m_url.clear(); -} - -WebBrowserURL::~WebBrowserURL() -{ -} -/****************************************************************************** -* -* NAME -* WebBrowser::init -* -* DESCRIPTION -* Perform post creation initialization. -* -* INPUTS -* NONE -* -* RESULT -* NONE -* -******************************************************************************/ - -void WebBrowser::init() -{ - m_urlList = NULL; - INI ini; - ini.load( AsciiString( "Data\\INI\\Webpages.ini" ), INI_LOAD_OVERWRITE, NULL ); -} - -/****************************************************************************** -* -* NAME -* WebBrowser::reset -* -* DESCRIPTION -* Perform post creation initialization. -* -* INPUTS -* NONE -* -* RESULT -* NONE -* -******************************************************************************/ - -void WebBrowser::reset() -{ -} - -void WebBrowser::update( void ) -{ -} - -WebBrowserURL * WebBrowser::findURL(AsciiString tag) -{ - WebBrowserURL *retval = m_urlList; - - while ((retval != NULL) && tag.compareNoCase(retval->m_tag.str())) - { - retval = retval->m_next; - } - - return retval; -} - -WebBrowserURL * WebBrowser::makeNewURL(AsciiString tag) -{ - WebBrowserURL *newURL = newInstance(WebBrowserURL); - - newURL->m_tag = tag; - - newURL->m_next = m_urlList; - m_urlList = newURL; - - return newURL; -} - -/****************************************************************************** -* -* NAME -* IUnknown::QueryInterface -* -* DESCRIPTION -* -* INPUTS -* IID - Interface ID -* -* RESULT -* -******************************************************************************/ - -STDMETHODIMP WebBrowser::QueryInterface(REFIID iid, void** ppv) -{ - *ppv = NULL; - - if ((iid == IID_IUnknown) || (iid == IID_IBrowserDispatch)) - { - *ppv = static_cast(this); - } - else - { - return E_NOINTERFACE; - } - - static_cast(*ppv)->AddRef(); - - return S_OK; -} - - -/****************************************************************************** -* -* NAME -* IUnknown::AddRef -* -* DESCRIPTION -* -* INPUTS -* NONE -* -* RESULT -* -******************************************************************************/ - -ULONG STDMETHODCALLTYPE WebBrowser::AddRef(void) -{ - return ++mRefCount; -} - - -/****************************************************************************** -* -* NAME -* IUnknown::Release -* -* DESCRIPTION -* -* INPUTS -* NONE -* -* RESULT -* -******************************************************************************/ - -ULONG STDMETHODCALLTYPE WebBrowser::Release(void) -{ - DEBUG_ASSERTCRASH(mRefCount > 0, ("Negative reference count")); - --mRefCount; - - if (mRefCount == 0) - { - DEBUG_LOG(("WebBrowser::Release - all references released, deleting the object.\n")); - if (this == TheWebBrowser) { - TheWebBrowser = NULL; - } - delete this; - return 0; - } - - return mRefCount; -} - -STDMETHODIMP WebBrowser::TestMethod(Int num1) -{ - DEBUG_LOG(("WebBrowser::TestMethod - num1 = %d\n", num1)); - return S_OK; -} diff --git a/GeneralsMD/Code/GameEngineDevice/GameEngineDevice.dsp b/GeneralsMD/Code/GameEngineDevice/GameEngineDevice.dsp index 0ea3ac08de8..bf2b2b55e82 100644 --- a/GeneralsMD/Code/GameEngineDevice/GameEngineDevice.dsp +++ b/GeneralsMD/Code/GameEngineDevice/GameEngineDevice.dsp @@ -1129,10 +1129,6 @@ SOURCE=.\Source\W3DDevice\GameClient\W3dWaypointBuffer.cpp # End Source File # Begin Source File -SOURCE=.\Source\W3DDevice\GameClient\W3DWebBrowser.cpp -# End Source File -# Begin Source File - SOURCE=.\Source\W3DDevice\GameClient\WorldHeightMap.cpp # End Source File # End Group @@ -1541,10 +1537,6 @@ SOURCE=.\Include\W3DDevice\GameClient\W3DWaypointBuffer.h # End Source File # Begin Source File -SOURCE=.\Include\W3DDevice\GameClient\W3DWebBrowser.h -# End Source File -# Begin Source File - SOURCE=.\Include\W3DDevice\GameClient\WorldHeightMap.h # End Source File # End Group diff --git a/GeneralsMD/Code/GameEngineDevice/Include/W3DDevice/GameClient/W3DWebBrowser.h b/GeneralsMD/Code/GameEngineDevice/Include/W3DDevice/GameClient/W3DWebBrowser.h deleted file mode 100644 index 39b59f3ca07..00000000000 --- a/GeneralsMD/Code/GameEngineDevice/Include/W3DDevice/GameClient/W3DWebBrowser.h +++ /dev/null @@ -1,49 +0,0 @@ -/* -** Command & Conquer Generals Zero Hour(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -//////////////////////////////////////////////////////////////////////////////// -// // -// (c) 2001-2003 Electronic Arts Inc. // -// // -//////////////////////////////////////////////////////////////////////////////// - -///// W3DWebBrowser.h //////////////////////// -// July 2002, Bryan Cleveland - -#pragma once - -#ifndef W3DWEBBROWSER_H -#define W3DWEBBROWSER_H - -#include "GameNetwork/WOLBrowser/WebBrowser.h" - -class TextureClass; -class Image; -class GameWindow; - -class W3DWebBrowser : public WebBrowser -{ - public: - W3DWebBrowser(); - - virtual Bool createBrowserWindow(char *url, GameWindow *win); - virtual void closeBrowserWindow(GameWindow *win); - -}; - -#endif // #ifndef W3DWEBBROWSER_H \ No newline at end of file diff --git a/GeneralsMD/Code/GameEngineDevice/Include/Win32Device/Common/Win32GameEngine.h b/GeneralsMD/Code/GameEngineDevice/Include/Win32Device/Common/Win32GameEngine.h index e5cbd2c3446..eb0ee00e701 100644 --- a/GeneralsMD/Code/GameEngineDevice/Include/Win32Device/Common/Win32GameEngine.h +++ b/GeneralsMD/Code/GameEngineDevice/Include/Win32Device/Common/Win32GameEngine.h @@ -44,7 +44,6 @@ #include "W3DDevice/Common/W3DModuleFactory.h" #include "W3DDevice/GameLogic/W3DGameLogic.h" #include "W3DDevice/GameClient/W3DGameClient.h" -#include "W3DDevice/GameClient/W3DWebBrowser.h" #include "W3DDevice/Common/W3DFunctionLexicon.h" #include "W3DDevice/Common/W3DRadar.h" #include "W3DDevice/Common/W3DFunctionLexicon.h" @@ -80,7 +79,6 @@ class Win32GameEngine : public GameEngine virtual ArchiveFileSystem *createArchiveFileSystem( void ); ///< factory for archive file system virtual NetworkInterface *createNetwork( void ); ///< Factory for the network virtual Radar *createRadar( void ); ///< Factory for radar - virtual WebBrowser *createWebBrowser( void ); ///< Factory for embedded browser virtual AudioManager *createAudioManager( void ); ///< Factory for audio device virtual ParticleSystemManager* createParticleSystemManager( void ); @@ -101,7 +99,6 @@ inline ParticleSystemManager* Win32GameEngine::createParticleSystemManager( void inline NetworkInterface *Win32GameEngine::createNetwork( void ) { return NetworkInterface::createNetwork(); } inline Radar *Win32GameEngine::createRadar( void ) { return NEW W3DRadar; } -inline WebBrowser *Win32GameEngine::createWebBrowser( void ) { return NEW CComObject; } inline AudioManager *Win32GameEngine::createAudioManager( void ) { return NEW MilesAudioManager; } #endif // end __WIN32GAMEENGINE_H_ diff --git a/GeneralsMD/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DDisplay.cpp b/GeneralsMD/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DDisplay.cpp index a94794d1a1e..8f52781e2df 100644 --- a/GeneralsMD/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DDisplay.cpp +++ b/GeneralsMD/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DDisplay.cpp @@ -92,7 +92,6 @@ static void drawFramerateBar(void); #include "WW3D2/Render2DSentence.h" #include "WW3D2/SortingRenderer.h" #include "WW3D2/Textureloader.h" -#include "WW3D2/DX8WebBrowser.h" #include "WW3D2/Mesh.h" #include "WW3D2/HLOD.h" #include "WW3D2/Meshmatdesc.h" @@ -462,7 +461,6 @@ W3DDisplay::~W3DDisplay() delete m_assetManager; WW3D::Shutdown(); WWMath::Shutdown(); - DX8WebBrowser::Shutdown(); delete TheW3DFileSystem; TheW3DFileSystem = NULL; @@ -824,7 +822,6 @@ void W3DDisplay::init( void ) m_nativeDebugDisplay->setFontWidth( 9 ); } - DX8WebBrowser::Initialize(); // we're now online m_initialized = true; diff --git a/GeneralsMD/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DWebBrowser.cpp b/GeneralsMD/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DWebBrowser.cpp deleted file mode 100644 index 0b12816e8b4..00000000000 --- a/GeneralsMD/Code/GameEngineDevice/Source/W3DDevice/GameClient/W3DWebBrowser.cpp +++ /dev/null @@ -1,74 +0,0 @@ -/* -** Command & Conquer Generals Zero Hour(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -//////////////////////////////////////////////////////////////////////////////// -// // -// (c) 2001-2003 Electronic Arts Inc. // -// // -//////////////////////////////////////////////////////////////////////////////// - -////// W3DWebBrowser.cpp /////////////// -// July 2002 Bryan Cleveland - -#include "W3DDevice/GameClient/W3DWebBrowser.h" -#include "WW3D2/Texture.h" -#include "WW3D2/TextureLoader.h" -#include "WW3D2/SurfaceClass.h" -#include "GameClient/Image.h" -#include "GameClient/GameWindow.h" -#include "vector2i.h" -#include -#include "WW3D2/dx8wrapper.h" -#include "WW3D2/dx8WebBrowser.h" - -W3DWebBrowser::W3DWebBrowser() : WebBrowser() { -} - -Bool W3DWebBrowser::createBrowserWindow(char *tag, GameWindow *win) -{ - - WinInstanceData *winData = win->winGetInstanceData(); - AsciiString windowName = winData->m_decoratedNameString; - - Int x, y, w, h; - - win->winGetSize(&w, &h); - win->winGetScreenPosition(&x, &y); - - WebBrowserURL *url = findURL( AsciiString(tag) ); - - if (url == NULL) { - DEBUG_LOG(("W3DWebBrowser::createBrowserWindow - couldn't find URL for page %s\n", tag)); - return FALSE; - } - - CComQIPtr idisp(m_dispatch); - if (m_dispatch == NULL) - { - return FALSE; - } - - DX8WebBrowser::CreateBrowser(windowName.str(), url->m_url.str(), x, y, w, h, 0, BROWSEROPTION_SCROLLBARS | BROWSEROPTION_3DBORDER, (LPDISPATCH)this); - - return TRUE; -} - -void W3DWebBrowser::closeBrowserWindow(GameWindow *win) -{ - DX8WebBrowser::DestroyBrowser(win->winGetInstanceData()->m_decoratedNameString.str()); -} diff --git a/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/dx8webbrowser.cpp b/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/dx8webbrowser.cpp deleted file mode 100644 index 9e6687b7fd2..00000000000 --- a/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/dx8webbrowser.cpp +++ /dev/null @@ -1,242 +0,0 @@ -/* -** Command & Conquer Generals Zero Hour(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -//****************************************************************************************** -// -// Earth And Beyond -// Copyright (c) 2002 Electronic Arts , Inc. - Westwood Studios -// -// File Name : dx8webbrowser.cpp -// Description : Implementation of D3D Embedded Browser wrapper. -// Author : Darren Schueller -// Date of Creation : 6/4/2002 -// -//****************************************************************************************** -// $Header: $ -//****************************************************************************************** - -#include "dx8webbrowser.h" -#include "ww3d.h" -#include "dx8wrapper.h" - -#if ENABLE_EMBEDDED_BROWSER - -// Import the Browser Type Library -// BGC, the path for the dll file is pretty odd, no? -// I'll leave it like this till I can figure out a -// better way. -#import "..\..\..\..\..\run\BrowserEngine.DLL" no_namespace - -static IFEBrowserEngine2Ptr pBrowser = 0; - -HWND DX8WebBrowser::hWnd = 0; - -bool DX8WebBrowser::Initialize( const char* badpageurl, - const char* loadingpageurl, - const char* mousefilename, - const char* mousebusyfilename) -{ - if(pBrowser == 0) - { - // Initialize COM - CoInitialize(0); - - // Create an instance of the browser control - HRESULT hr = pBrowser.CreateInstance(__uuidof(FEBrowserEngine2)); - - if(hr == REGDB_E_CLASSNOTREG) - { - HMODULE lib = ::LoadLibrary("BrowserEngine.DLL"); - if(lib) - { - FARPROC proc = ::GetProcAddress(lib,"DllRegisterServer"); - if(proc) - { - proc(); - // Create an instance of the browser control - hr = pBrowser.CreateInstance(__uuidof(FEBrowserEngine2)); - } - FreeLibrary(lib); - } - } - - // Initialize the browser. - if(hr == S_OK) - { - hWnd = (HWND)WW3D::Get_Window(); - pBrowser->Initialize(reinterpret_cast(DX8Wrapper::_Get_D3D_Device8())); - - if(badpageurl) - pBrowser->put_BadPageURL(_bstr_t(badpageurl)); - - if(loadingpageurl) - pBrowser->put_LoadingPageURL(_bstr_t(loadingpageurl)); - - if(mousefilename) - pBrowser->put_MouseFileName(_bstr_t(mousefilename)); - - if(mousebusyfilename) - pBrowser->put_MouseBusyFileName(_bstr_t(mousebusyfilename)); - } - else - { - pBrowser = 0; - return false; - } - } - - return true; -} - -void DX8WebBrowser::Shutdown() -{ - if(pBrowser) - { - // Shutdown the browser - pBrowser->Shutdown(); - - // Release the smart pointer. - pBrowser = 0; - - hWnd = 0; - - // Shut down COM - CoUninitialize(); - } -} - - -// ****************************************************************************************** -// * Function Name: DX8WebBrowser::Update -// ****************************************************************************************** -// * Description: Updates the browser image surfaces by copying the bits from the browser -// * DCs to the D3D Image surfaces. -// * -// * Return Type: -// * -// * Argument: void -// * -// ****************************************************************************************** -void DX8WebBrowser::Update(void) -{ - if(pBrowser) pBrowser->D3DUpdate(); -}; - - -// ****************************************************************************************** -// * Function Name: DX8WebBrowser::Render -// ****************************************************************************************** -// * Description: Draws all browsers to the back buffer. -// * -// * Return Type: -// * -// * Argument: int backbufferindex -// * -// ****************************************************************************************** -void DX8WebBrowser::Render(int backbufferindex) -{ - if(pBrowser) pBrowser->D3DRender(backbufferindex); -}; - -// ****************************************************************************************** -// * Function Name: DX8WebBrowser::CreateBrowser -// ****************************************************************************************** -// * Description: Creates a browser window. -// * -// * Return Type: -// * -// * Argument: const char* browsername - This is a "name" used to identify the -// * browser instance. Multiple browsers can -// * be created, and are referenced using this name. -// * Argument: const char* url - The url to display. -// * Argument: int x - The position and size of the browser (in pixels) -// * Argument: int y -// * Argument: int w -// * Argument: int h -// * Argument: int updateticks - When non-zero, this forces the browser image to get updated -// * at the specified rate (number of milliseconds) regardless -// * of paint messages. When this is zero (the default) the browser -// * image is only updated whenever a paint message is received. -// * -// ****************************************************************************************** -void DX8WebBrowser::CreateBrowser(const char* browsername, const char* url, int x, int y, int w, int h, int updateticks, LONG options, LPDISPATCH gamedispatch) -{ - WWDEBUG_SAY(("DX8WebBrowser::CreateBrowser - Creating browser with the name %s, url = %s, (x, y, w, h) = (%d, %d, %d, %d), update ticks = %d\n", browsername, url, x, y, h, w, updateticks)); - if(pBrowser) - { - _bstr_t brsname(browsername); - pBrowser->CreateBrowser(brsname, _bstr_t(url), reinterpret_cast(hWnd), x, y, w, h, options, gamedispatch); - pBrowser->SetUpdateRate(brsname, updateticks); - } -} - - -// ****************************************************************************************** -// * Function Name: DX8WebBrowser::DestroyBrowser -// ****************************************************************************************** -// * Description: Destroys the specified browser. This closes the window and releases -// * the browser instance. -// * -// * Return Type: -// * -// * Argument: const char* browsername - The name of the browser to destroy. -// * -// ****************************************************************************************** -void DX8WebBrowser::DestroyBrowser(const char* browsername) -{ - WWDEBUG_SAY(("DX8WebBrowser::DestroyBrowser - destroying browser %s\n", browsername)); - if(pBrowser) - pBrowser->DestroyBrowser(_bstr_t(browsername)); -} - - -// ****************************************************************************************** -// * Function Name: DX8WebBrowser::Is_Browser_Open -// ****************************************************************************************** -// * Description: This function checks to see if a browser of the specified name exists and -// * is currently open. -// * -// * Return Type: -// * -// * Argument: const char* browsername - The name of the browser to test. -// * -// ****************************************************************************************** -bool DX8WebBrowser::Is_Browser_Open(const char* browsername) -{ - if(pBrowser == 0) return false; - return (pBrowser->IsOpen(_bstr_t(browsername)) != 0); -} - -// ****************************************************************************************** -// * Function Name: DX8WebBrowser::Navigate -// ****************************************************************************************** -// * Description: This function causes the browser to navigate to the specified page. -// * -// * Return Type: -// * -// * Argument: const char* browsername - The name of the browser to test. -// * const char* url - The url to navigate to. -// * -// ****************************************************************************************** -void DX8WebBrowser::Navigate(const char* browsername, const char* url) -{ - if(pBrowser == 0) return; - pBrowser->Navigate(_bstr_t(browsername),_bstr_t(url)); -} - -#endif \ No newline at end of file diff --git a/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/dx8webbrowser.h b/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/dx8webbrowser.h deleted file mode 100644 index 6134daa6444..00000000000 --- a/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/dx8webbrowser.h +++ /dev/null @@ -1,93 +0,0 @@ -/* -** Command & Conquer Generals Zero Hour(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -//****************************************************************************************** -// -// Earth And Beyond -// Copyright (c) 2002 Electronic Arts , Inc. - Westwood Studios -// -// File Name : dx8webbrowser.h -// Description : Implementation of D3D Embedded Browser Wrapper -// Author : Darren Schueller -// Date of Creation : 6/4/2002 -// -//****************************************************************************************** -// $Header: $ -//****************************************************************************************** - -#ifndef DX8_WEBBROWSER_H -#define DX8_WEBBROWSER_H - -#include -#include "d3d8.h" - -// *********************************** -// Set this to 0 to remove all embedded browser code. -// -#define ENABLE_EMBEDDED_BROWSER 1 -// -// *********************************** - -#if ENABLE_EMBEDDED_BROWSER - -// These options must match the browser option bits defined in the BrowserEngine code. -// Look in febrowserengine.h -#define BROWSEROPTION_SCROLLBARS 0x0001 -#define BROWSEROPTION_3DBORDER 0x0002 - -struct IDirect3DDevice8; - -/** -** DX8WebBrowser -** -** DX8 interface wrapper class. This encapsulates the BrowserEngine interface. -*/ -class DX8WebBrowser -{ -public: - - static bool Initialize( const char* badpageurl = 0, - const char* loadingpageurl = 0, - const char* mousefilename = 0, - const char* mousebusyfilename = 0); //Initialize the Embedded Browser - - static void Shutdown(void); // Shutdown the embedded browser. Will close any open browsers. - - static void Update(void); // Copies all browser contexts to D3D Image surfaces. - static void Render(int backbufferindex); //Draws all browsers to the backbuffer. - - // Creates a browser with the specified name - static void CreateBrowser(const char* browsername, const char* url, int x, int y, int w, int h, int updateticks = 0, LONG options = BROWSEROPTION_SCROLLBARS | BROWSEROPTION_3DBORDER, LPDISPATCH gamedispatch = 0); - - // Destroys the browser with the specified name - static void DestroyBrowser(const char* browsername); - - // Returns true if a browser with the specified name is open. - static bool Is_Browser_Open(const char* browsername); - - // Navigates the specified browser to the specified page. - static void Navigate(const char* browsername, const char* url); - -private: - // The window handle of the application. This is initialized by Initialize(). - static HWND hWnd; -}; - -#endif - -#endif \ No newline at end of file diff --git a/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/dx8wrapper.cpp b/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/dx8wrapper.cpp index 3189b441d30..860751b7ae9 100644 --- a/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/dx8wrapper.cpp +++ b/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/dx8wrapper.cpp @@ -46,7 +46,6 @@ #define WW3D_DEVTYPE D3DDEVTYPE_HAL #include "dx8wrapper.h" -#include "dx8webbrowser.h" #include "dx8fvf.h" #include "dx8vertexbuffer.h" #include "dx8indexbuffer.h" @@ -79,7 +78,6 @@ #include "formconv.h" #include "dx8texman.h" #include "bound.h" -#include "dx8webbrowser.h" const int DEFAULT_RESOLUTION_WIDTH = 640; const int DEFAULT_RESOLUTION_HEIGHT = 480; @@ -1677,13 +1675,8 @@ void DX8Wrapper::Begin_Scene(void) { DX8_THREAD_ASSERT(); -#if ENABLE_EMBEDDED_BROWSER - DX8WebBrowser::Update(); -#endif - DX8CALL(BeginScene()); - DX8WebBrowser::Update(); } void DX8Wrapper::End_Scene(bool flip_frames) @@ -1691,7 +1684,6 @@ void DX8Wrapper::End_Scene(bool flip_frames) DX8_THREAD_ASSERT(); DX8CALL(EndScene()); - DX8WebBrowser::Render(0); if (flip_frames) { DX8_Assert(); diff --git a/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/ww3d2.dsp b/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/ww3d2.dsp index c128b7a2399..d3bc2b357d9 100644 --- a/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/ww3d2.dsp +++ b/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/ww3d2.dsp @@ -226,10 +226,6 @@ SOURCE=.\dx8vertexbuffer.cpp # End Source File # Begin Source File -SOURCE=.\dx8webbrowser.cpp -# End Source File -# Begin Source File - SOURCE=.\dx8wrapper.cpp # End Source File # Begin Source File @@ -683,10 +679,6 @@ SOURCE=.\dx8vertexbuffer.h # End Source File # Begin Source File -SOURCE=.\dx8webbrowser.h -# End Source File -# Begin Source File - SOURCE=.\dx8wrapper.h # End Source File # Begin Source File diff --git a/GeneralsMD/Code/Libraries/Source/WWVegas/WWLib/LaunchWeb.cpp b/GeneralsMD/Code/Libraries/Source/WWVegas/WWLib/LaunchWeb.cpp deleted file mode 100644 index 57d311e1563..00000000000 --- a/GeneralsMD/Code/Libraries/Source/WWVegas/WWLib/LaunchWeb.cpp +++ /dev/null @@ -1,120 +0,0 @@ -/* -** Command & Conquer Generals Zero Hour(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -/****************************************************************************** -* -* FILE -* $Archive: /Commando/Code/wwlib/LaunchWeb.cpp $ -* -* PROGRAMMER -* Denzil E. Long, Jr. -* $Author: Denzil_l $ -* -* VERSION INFO -* $Revision: 2 $ -* $Modtime: 6/22/01 4:39p $ -* -******************************************************************************/ - -#include "LaunchWeb.h" -#include -#include -#include -#include - -/****************************************************************************** -* -* NAME -* LaunchWebBrowser -* -* DESCRIPTION -* Launch the default browser to view the specified URL -* -* INPUTS -* URL - Website address -* Wait - Wait for user to close browser (default = false) -* Callback - User callback to invoke during wait (default = NULL callback) -* -* RESULT -* Success - True if successful; otherwise false -* -******************************************************************************/ - -bool LaunchWebBrowser(const char* url) - { - // Just return if no URL specified - if (!url || (strlen(url) == 0)) - { - return false; - } - - // Create a temporary file with HTML content - char tempPath[MAX_PATH]; - GetWindowsDirectory(tempPath, MAX_PATH); - - char filename[MAX_PATH]; - GetTempFileName(tempPath, "WWS", 0, filename); - - char* extPtr = strrchr(filename, '.'); - strcpy(extPtr, ".html"); - - HANDLE file = CreateFile(filename, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, - FILE_ATTRIBUTE_NORMAL, NULL); - - assert(INVALID_HANDLE_VALUE != file && "Failed to create temporary HTML file."); - - if (INVALID_HANDLE_VALUE == file) - { - return false; - } - - // Write generic contents - const char* contents = "ViewHTML"; - DWORD written; - WriteFile(file, contents, strlen(contents), &written, NULL); - CloseHandle(file); - - // Find the executable that can launch this file - char exeName[MAX_PATH]; - HINSTANCE hInst = FindExecutable(filename, NULL, exeName); - assert(((int)hInst > 32) && "Unable to find executable that will display HTML files."); - - // Delete temporary file - DeleteFile(filename); - - if ((int)hInst <= 32) - { - return false; - } - - // Launch browser with specified URL - char commandLine[MAX_PATH]; - sprintf(commandLine, "[open] %s", url); - - STARTUPINFO startupInfo; - memset(&startupInfo, 0, sizeof(startupInfo)); - startupInfo.cb = sizeof(startupInfo); - - PROCESS_INFORMATION processInfo; - BOOL createSuccess = CreateProcess(exeName, commandLine, NULL, NULL, FALSE, - 0, NULL, NULL, &startupInfo, &processInfo); - - assert(createSuccess && "Failed to launch default WebBrowser."); - - return (TRUE == createSuccess); - } diff --git a/GeneralsMD/Code/Libraries/Source/WWVegas/WWLib/LaunchWeb.h b/GeneralsMD/Code/Libraries/Source/WWVegas/WWLib/LaunchWeb.h deleted file mode 100644 index eaae54a5596..00000000000 --- a/GeneralsMD/Code/Libraries/Source/WWVegas/WWLib/LaunchWeb.h +++ /dev/null @@ -1,48 +0,0 @@ -/* -** Command & Conquer Generals Zero Hour(tm) -** Copyright 2025 Electronic Arts Inc. -** -** This program is free software: you can redistribute it and/or modify -** it under the terms of the GNU General Public License as published by -** the Free Software Foundation, either version 3 of the License, or -** (at your option) any later version. -** -** This program is distributed in the hope that it will be useful, -** but WITHOUT ANY WARRANTY; without even the implied warranty of -** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -** GNU General Public License for more details. -** -** You should have received a copy of the GNU General Public License -** along with this program. If not, see . -*/ - -/****************************************************************************** -* -* FILE -* $Archive: /Commando/Code/wwlib/LaunchWeb.h $ -* -* PROGRAMMER -* Denzil E. Long, Jr. -* $Author: Denzil_l $ -* -* VERSION INFO -* $Revision: 1 $ -* $Modtime: 4/20/01 3:22p $ -* -******************************************************************************/ - -#ifndef __LAUNCHWEB_H__ -#define __LAUNCHWEB_H__ - -#ifdef __cplusplus -extern "C" { -#endif - -bool LaunchWebBrowser(const char* url); - -#ifdef __cplusplus -} -#endif - - -#endif // __LAUNCHWEB_H__ diff --git a/GeneralsMD/Code/Libraries/Source/WWVegas/WWLib/wwlib.dsp b/GeneralsMD/Code/Libraries/Source/WWVegas/WWLib/wwlib.dsp index 3148f054d9c..5e700dba596 100644 --- a/GeneralsMD/Code/Libraries/Source/WWVegas/WWLib/wwlib.dsp +++ b/GeneralsMD/Code/Libraries/Source/WWVegas/WWLib/wwlib.dsp @@ -226,10 +226,6 @@ SOURCE=.\keyboard.cpp # End Source File # Begin Source File -SOURCE=.\LaunchWeb.cpp -# End Source File -# Begin Source File - SOURCE=.\lcw.cpp # End Source File # Begin Source File @@ -602,10 +598,6 @@ SOURCE=.\keyboard.h # End Source File # Begin Source File -SOURCE=.\LaunchWeb.h -# End Source File -# Begin Source File - SOURCE=.\LCW.H # End Source File # Begin Source File diff --git a/GeneralsMD/Code/RTS.dsp b/GeneralsMD/Code/RTS.dsp index ee82f0ad615..bc556eba28c 100644 --- a/GeneralsMD/Code/RTS.dsp +++ b/GeneralsMD/Code/RTS.dsp @@ -72,7 +72,7 @@ LINK32=link.exe # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c -# ADD CPP /nologo /G6 /MDd /W3 /WX /Gm /GX /ZI /Od /I "Libraries\Include" /I "GameEngine\Include" /I "gameenginedevice\Include" /I "Libraries\Source\WWVegas" /I "Libraries\Source\WWVegas\WWLib" /I "Libraries\Source\WWVegas\WWMath" /I "Libraries\Source\WWVegas\WWDebug" /I "Libraries\Source\WWVegas\WWSaveLoad" /I "Libraries\Source\WWVegas\WW3D2" /I "Libraries\Include\Granny" /I "Libraries\Source\Bink" /I "Libraries\Source\Miles" /D "_DEBUG" /D "BROWSER_DEBUG" /D WINVER=0x400 /D "WIN32" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c +# ADD CPP /nologo /G6 /MDd /W3 /WX /Gm /GX /ZI /Od /I "Libraries\Include" /I "GameEngine\Include" /I "gameenginedevice\Include" /I "Libraries\Source\WWVegas" /I "Libraries\Source\WWVegas\WWLib" /I "Libraries\Source\WWVegas\WWMath" /I "Libraries\Source\WWVegas\WWDebug" /I "Libraries\Source\WWVegas\WWSaveLoad" /I "Libraries\Source\WWVegas\WW3D2" /I "Libraries\Include\Granny" /I "Libraries\Source\Bink" /I "Libraries\Source\Miles" /D "_DEBUG" /D WINVER=0x400 /D "WIN32" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c # SUBTRACT CPP /Fr # ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 diff --git a/GeneralsMD/Run/BrowserEngine.dll b/GeneralsMD/Run/BrowserEngine.dll deleted file mode 100644 index a8a19e4b921..00000000000 Binary files a/GeneralsMD/Run/BrowserEngine.dll and /dev/null differ diff --git a/GeneralsMD/Run/place_steam_build_here.txt b/GeneralsMD/Run/place_steam_build_here.txt deleted file mode 100644 index e69de29bb2d..00000000000