mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-03-22 14:55:36 +08:00
@@ -10,16 +10,19 @@
|
||||
#include "reader.h"
|
||||
#include <QFile>
|
||||
|
||||
void LineReader::run()
|
||||
namespace BlackSample
|
||||
{
|
||||
QFile file;
|
||||
file.open(stdin, QIODevice::ReadOnly | QIODevice::Text);
|
||||
forever
|
||||
void LineReader::run()
|
||||
{
|
||||
QString line = file.readLine().trimmed();
|
||||
if (! line.isEmpty())
|
||||
QFile file;
|
||||
file.open(stdin, QIODevice::ReadOnly | QIODevice::Text);
|
||||
forever
|
||||
{
|
||||
emit command(line);
|
||||
QString line = file.readLine().trimmed();
|
||||
if (! line.isEmpty())
|
||||
{
|
||||
emit command(line);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user