From e8f841473bcefc618ddf6712567e624156e88399 Mon Sep 17 00:00:00 2001 From: Patrick Gansterer Date: Mon, 19 Nov 2012 15:48:33 +0100 Subject: Introduce the abstract class cmGlobalGeneratorFactory This new abstract class allows us move some logic from the cmGlobalGenerator into its own layer in a next step. --- Source/cmGlobalVisualStudio71Generator.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'Source/cmGlobalVisualStudio71Generator.h') diff --git a/Source/cmGlobalVisualStudio71Generator.h b/Source/cmGlobalVisualStudio71Generator.h index a8daad6a2b..fa0ad92ef9 100644 --- a/Source/cmGlobalVisualStudio71Generator.h +++ b/Source/cmGlobalVisualStudio71Generator.h @@ -24,8 +24,9 @@ class cmGlobalVisualStudio71Generator : public cmGlobalVisualStudio7Generator { public: cmGlobalVisualStudio71Generator(); - static cmGlobalGenerator* New() - { return new cmGlobalVisualStudio71Generator; } + static cmGlobalGeneratorFactory* NewFactory() { + return new cmGlobalGeneratorSimpleFactory + (); } ///! Get the name for the generator. virtual const char* GetName() const { -- cgit v1.2.1 From 5170a8800ff4613dd41f6995e8efd43df36a40bd Mon Sep 17 00:00:00 2001 From: Patrick Gansterer Date: Mon, 19 Nov 2012 16:42:24 +0100 Subject: Make cmGlobalGenerator::GetDocumentation() a static function Making the function static allows us to call it directly, without creating and removing an instance of the generator. --- Source/cmGlobalVisualStudio71Generator.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Source/cmGlobalVisualStudio71Generator.h') diff --git a/Source/cmGlobalVisualStudio71Generator.h b/Source/cmGlobalVisualStudio71Generator.h index fa0ad92ef9..dfbbe437b7 100644 --- a/Source/cmGlobalVisualStudio71Generator.h +++ b/Source/cmGlobalVisualStudio71Generator.h @@ -34,7 +34,7 @@ public: static const char* GetActualName() {return "Visual Studio 7 .NET 2003";} /** Get the documentation entry for this generator. */ - virtual void GetDocumentation(cmDocumentationEntry& entry) const; + static void GetDocumentation(cmDocumentationEntry& entry); ///! Create a local generator appropriate to this Global Generator virtual cmLocalGenerator *CreateLocalGenerator(); -- cgit v1.2.1