Removed default_theme namespace
This commit is contained in:
parent
0ff43f8994
commit
db20794b7f
@ -30,6 +30,7 @@ namespace hgl
|
||||
void Resize(uint w,uint h);
|
||||
|
||||
bool BeginRender();
|
||||
virtual bool Render()=0;
|
||||
bool EndRender();
|
||||
};//class ThemeForm
|
||||
}//namespace gui
|
||||
|
@ -7,8 +7,8 @@ SET(THEME_SOURCE ${GUI_INCLUDE_PATH}/ThemeForm.h
|
||||
|
||||
SET(DEFAULT_THEME_SOURCE DefaultThemeEngine.h
|
||||
DefaultThemeEngine.cpp
|
||||
DTForm.h
|
||||
DTForm.cpp)
|
||||
DefaultThemeForm.h
|
||||
DefaultThemeForm.cpp)
|
||||
|
||||
set(WIDGET_SOURCE ${GUI_INCLUDE_PATH}/Widget.h
|
||||
${GUI_INCLUDE_PATH}/Layout.h
|
||||
|
@ -1,13 +0,0 @@
|
||||
#include"DTForm.h"
|
||||
#include<hgl/gui/Form.h>
|
||||
#include<hgl/graph/VKRenderTarget.h>
|
||||
|
||||
namespace hgl
|
||||
{
|
||||
namespace gui
|
||||
{
|
||||
namespace default_theme
|
||||
{
|
||||
}//namespace default_theme
|
||||
}//namespace gui
|
||||
}//namespace hgl
|
@ -6,11 +6,9 @@ namespace hgl
|
||||
{
|
||||
ThemeEngine *CreateDefaultThemeEngine(GPUDevice *dev)
|
||||
{
|
||||
return(new default_theme::DefaultThemeEngine(dev));
|
||||
return(new DefaultThemeEngine(dev));
|
||||
}
|
||||
|
||||
namespace default_theme
|
||||
{
|
||||
bool DefaultThemeEngine::Init()
|
||||
{
|
||||
return(true);
|
||||
@ -22,8 +20,7 @@ namespace hgl
|
||||
|
||||
ThemeForm *DefaultThemeEngine::CreateForm(Form *f,RenderTarget *rt,RenderCommand *rc)
|
||||
{
|
||||
return(new DTForm(f,rt,rc));
|
||||
return(new DefaultThemeForm(f,rt,rc));
|
||||
}
|
||||
}//namespace default_theme
|
||||
}//namespace gui
|
||||
}//namespace hgl
|
@ -13,8 +13,6 @@ namespace hgl
|
||||
|
||||
class Form; ///<窗体
|
||||
|
||||
namespace default_theme
|
||||
{
|
||||
/**
|
||||
* 缺省GUI主题引擎
|
||||
*/
|
||||
@ -30,6 +28,5 @@ namespace hgl
|
||||
|
||||
ThemeForm *CreateForm(Form *,RenderTarget *,RenderCommand *) override;
|
||||
};//class DefaultThemeEngine:public ThemeEngine
|
||||
}//namespace default_theme
|
||||
}//namespace gui
|
||||
}//namespace hgl
|
20
src/GUI/DefaultThemeForm.cpp
Normal file
20
src/GUI/DefaultThemeForm.cpp
Normal file
@ -0,0 +1,20 @@
|
||||
#include"DefaultThemeForm.h"
|
||||
#include<hgl/gui/Form.h>
|
||||
#include<hgl/graph/VKCommandBuffer.h>
|
||||
|
||||
namespace hgl
|
||||
{
|
||||
namespace gui
|
||||
{
|
||||
bool DefaultThemeForm::Render()
|
||||
{
|
||||
if(!cmd_buf->BeginRenderPass())
|
||||
return(false);
|
||||
|
||||
|
||||
|
||||
cmd_buf->EndRenderPass();
|
||||
return(true);
|
||||
}
|
||||
}//namespace gui
|
||||
}//namespace hgl
|
@ -12,17 +12,16 @@ namespace hgl
|
||||
|
||||
class Form;
|
||||
|
||||
namespace default_theme
|
||||
{
|
||||
class DTForm:public ThemeForm
|
||||
class DefaultThemeForm:public ThemeForm
|
||||
{
|
||||
|
||||
public:
|
||||
|
||||
using ThemeForm::ThemeForm;
|
||||
~DTForm()=default;
|
||||
};//class DTForm
|
||||
}//namespace default_theme
|
||||
~DefaultThemeForm()=default;
|
||||
|
||||
bool Render() override;
|
||||
};//class DefaultThemeForm
|
||||
}//namespace gui
|
||||
}//namespace hgl
|
||||
#endif//HGL_GUI_DEFAULT_THEME_FORM_INCLUDE
|
@ -121,6 +121,7 @@ namespace hgl
|
||||
|
||||
tf->BeginRender();
|
||||
|
||||
tf->Render();
|
||||
|
||||
tf->EndRender();
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user