Properly update default config

--HG--
branch : feature-material-editor
hg/feature/material-editor
kaetemi 9 years ago
parent 596a4ba7a3
commit 2053e075fc

@ -1,12 +1 @@
RootConfigFilename = "mesh_editor_default.cfg";
GraphicsEnabled = 1;
SoundEnabled = 1;
GraphicsDriver = "OpenGL";
SoundDriver = "OpenAL";
SoundDevice = "";
LanguageCode = "en";
FontName = "andbasr.ttf";
FontShadow = 1;
BackgroundColor = {
151, 156, 182
};

@ -39,7 +39,7 @@ FontName = "andbasr.ttf";
FontShadow = 1;
// Background color
BackgroundColor = { 151, 156, 182 };
BackgroundColor = { 41, 57, 85 };
// Screenshot formats
ScreenshotJPG = 1;

@ -136,7 +136,7 @@ void CGraphicsViewport::release()
void CGraphicsViewport::updateInput()
{
m_Driver->EventServer.pump();
// m_Driver->EventServer.pump(); // Can't do this, conflicts with Qt processing
}
void CGraphicsViewport::renderDriver()

@ -110,7 +110,11 @@ sint main(int argc, char **argv)
CFile::createDirectoryTree(appData);
CFile::createDirectoryTree(appData + "screenshots/");
CFile::setRWAccess(localAppData + "andbasr.ttf");
QFile::remove(QString::fromStdString(localAppData + "andbasr.ttf"));
QFile(":/data/andbasr.ttf").copy(QString::fromStdString(localAppData + "andbasr.ttf"));
CFile::setRWAccess(appData + "mesh_editor_default.cfg");
QFile::remove(QString::fromStdString(appData + "mesh_editor_default.cfg"));
QFile(":/data/mesh_editor_default.cfg").copy(QString::fromStdString(appData + "mesh_editor_default.cfg"));
if (!QFileInfo(QString::fromStdString(appData + "mesh_editor.cfg")).exists())
{

@ -424,9 +424,10 @@ void CMainWindow::about()
void CMainWindow::updateRender()
{
updateInitialization(isVisible());
bool visible = isVisible();
updateInitialization(visible);
if (isVisible())
if (visible)
{
// call all update functions

Loading…
Cancel
Save