QTfrontend/main.cpp
changeset 7724 36c539c9cfb1
parent 7278 000e4543f204
child 7768 13e2037ebc79
child 7794 ab7b94c03bc9
--- a/QTfrontend/main.cpp	Sat Oct 06 01:09:41 2012 +0400
+++ b/QTfrontend/main.cpp	Sat Oct 06 23:36:43 2012 +0400
@@ -272,18 +272,10 @@
 
     QFile resFile(":/res/css/" + fname);
 
-    QFile & file = (extFile.exists()?extFile:resFile);
+    QFile & file = (extFile.exists() ? extFile : resFile);
 
     if (file.open(QIODevice::ReadOnly | QIODevice::Text))
-    {
-        QTextStream in(&file);
-        while (!in.atEnd())
-        {
-            QString line = in.readLine();
-            if(!line.isEmpty())
-                style.append(line);
-        }
-    }
+        style.append(file.readAll());
 
     app.form = new HWForm(NULL, style);
     app.form->show();