소스 검색

Fixed Application class namespace declaration.

Wei Tjong Yao 12 년 전
부모
커밋
ed01bd0959
3개의 변경된 파일6개의 추가작업 그리고 3개의 파일을 삭제
  1. 0 2
      Source/Engine/Core/Main.h
  2. 5 0
      Source/Engine/Engine/Application.cpp
  3. 1 1
      Source/Engine/Engine/Application.h

+ 0 - 2
Source/Engine/Core/Main.h

@@ -32,8 +32,6 @@
 #endif
 #endif
 #endif
 #endif
 
 
-using namespace Urho3D;
-
 // Define a platform-specific main function, which in turn executes the user-defined function
 // Define a platform-specific main function, which in turn executes the user-defined function
 
 
 // MSVC debug mode: use memory leak reporting
 // MSVC debug mode: use memory leak reporting

+ 5 - 0
Source/Engine/Engine/Application.cpp

@@ -30,6 +30,9 @@
 
 
 #include "DebugNew.h"
 #include "DebugNew.h"
 
 
+namespace Urho3D
+{
+
 Application::Application(Context* context) :
 Application::Application(Context* context) :
     Object(context),
     Object(context),
     exitCode_(EXIT_SUCCESS)
     exitCode_(EXIT_SUCCESS)
@@ -88,3 +91,5 @@ void Application::ErrorExit(const String& message)
     else
     else
         ErrorDialog(GetTypeName(), message);
         ErrorDialog(GetTypeName(), message);
 }
 }
+
+}

+ 1 - 1
Source/Engine/Engine/Application.h

@@ -65,7 +65,7 @@ protected:
 #define DEFINE_APPLICATION_MAIN(className) \
 #define DEFINE_APPLICATION_MAIN(className) \
 int RunApplication() \
 int RunApplication() \
 { \
 { \
-    Urho3D::SharedPtr<Urho3D::Context> context(new Context()); \
+    Urho3D::SharedPtr<Urho3D::Context> context(new Urho3D::Context()); \
     Urho3D::SharedPtr<className> application(new className(context)); \
     Urho3D::SharedPtr<className> application(new className(context)); \
     return application->Run(); \
     return application->Run(); \
 } \
 } \