Пример #1
0
bool Application::BaseUpdate()
{
	auto isEscapeKeyPressed = (glfwGetKey(window, GLFW_KEY_ESCAPE) != GLFW_PRESS);

	auto canWindowClose = glfwWindowShouldClose(window);

	if (isEscapeKeyPressed && canWindowClose)
	{
		return false;
	}
	else
	{
		glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
		glEnable(GL_DEPTH_TEST); // enables the depth buffer

		Gizmos::clear();
		auto result = Update();
		BaseDraw();

		glfwSwapBuffers(window);
		glfwPollEvents();

		return result;
	}
}
/**
 * All password setting pages containing edwins will have the same draw code
 *
 */
EXPORT_C void CAknPasswordSettingPage::Draw(const TRect& aRect) const
	{
	BaseDraw( aRect );
	// Suppress this legacy frame drawing if skins is performing it
	if ( !IsSkinsHandlingEditorFrameDrawing() )
		{
		CWindowGc& gc=SystemGc(); 
		iSecretEditorLayoutRect.DrawRect( gc );
		iHorizontalShadow.DrawRect( gc );
		iVerticalShadow.DrawRect( gc );
		iOutlineFrame.DrawOutLineRect( gc );
		}
	}
EXPORT_C void CAknSliderSettingPage::Draw(const TRect &aRect) const
{
  BaseDraw(aRect);
}
// -----------------------------------------------------------------------------
// CTestSettingPage::TestBaseDraw
// -----------------------------------------------------------------------------
//
void CTestSettingPage::TestBaseDraw(const TRect& aRect) const
    {
    BaseDraw( aRect );
    }
void CAknFileSettingPage::Draw(const TRect &aRect) const
{
    BaseDraw(aRect);
    CWindowGc& gc=SystemGc();
    iOutlineFrame.DrawOutLineRect(gc);
}