Subversion Repositories tpanel

Rev

Rev 424 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 424 Rev 425
Line 5383... Line 5383...
5383
 
5383
 
5384
        if (button->isMultiLine())
5384
        if (button->isMultiLine())
5385
            text = ReplaceString(text, "|", "\n");
5385
            text = ReplaceString(text, "|", "\n");
5386
 
5386
 
5387
        nobj.object.plaintext = new TQEditLine(text, par->object.widget, button->isMultiLine());
5387
        nobj.object.plaintext = new TQEditLine(text, par->object.widget, button->isMultiLine());
5388
//        nobj.object.plaintext = new TQTextEdit(QString::fromStdString(text), par->object.widget);
-
 
5389
        nobj.object.plaintext->setObjectName(string("EditLine_") + handleToString(handle));
5388
        nobj.object.plaintext->setObjectName(string("EditLine_") + handleToString(handle));
5390
        nobj.object.plaintext->setHandle(handle);
5389
        nobj.object.plaintext->setHandle(handle);
5391
        nobj.object.plaintext->move(nobj.left, nobj.top);
5390
        nobj.object.plaintext->move(nobj.left, nobj.top);
5392
        nobj.object.plaintext->setFixedSize(nobj.width, nobj.height);
5391
        nobj.object.plaintext->setFixedSize(nobj.width, nobj.height);
5393
        nobj.object.plaintext->setPadding(frame, frame, frame, frame);
5392
        nobj.object.plaintext->setPadding(frame, frame, frame, frame);
Line 6389... Line 6388...
6389
 
6388
 
6390
void MainWindow::onFocusChanged(ulong handle, bool in)
6389
void MainWindow::onFocusChanged(ulong handle, bool in)
6391
{
6390
{
6392
    DECL_TRACER("MainWindow::onFocusChanged(ulong handle, bool in)");
6391
    DECL_TRACER("MainWindow::onFocusChanged(ulong handle, bool in)");
6393
 
6392
 
-
 
6393
    try
-
 
6394
    {
-
 
6395
        std::thread thr = std::thread([=] {
6394
    if (gPageManager)
6396
            if (gPageManager)
6395
        gPageManager->inputFocusChanged(handle, in);
6397
                gPageManager->inputFocusChanged(handle, in);
-
 
6398
        });
-
 
6399
 
-
 
6400
        thr.detach();
-
 
6401
    }
-
 
6402
    catch (std::exception& e)
-
 
6403
    {
-
 
6404
        MSG_ERROR("Error starting a thread to handle input line finish: " << e.what());
-
 
6405
    }
6396
}
6406
}
6397
 
6407
 
6398
void MainWindow::onCursorChanged(ulong handle, int oldPos, int newPos)
6408
void MainWindow::onCursorChanged(ulong handle, int oldPos, int newPos)
6399
{
6409
{
6400
    DECL_TRACER("MainWindow::onCursorChanged(ulong handle, int oldPos, int newPos)");
6410
    DECL_TRACER("MainWindow::onCursorChanged(ulong handle, int oldPos, int newPos)");
6401
 
6411
 
-
 
6412
    try
-
 
6413
    {
-
 
6414
        std::thread thr = std::thread([=] {
6402
    if (gPageManager)
6415
            if (gPageManager)
6403
        gPageManager->inputCursorPositionChanged(handle, oldPos, newPos);
6416
                gPageManager->inputCursorPositionChanged(handle, oldPos, newPos);
-
 
6417
        });
-
 
6418
 
-
 
6419
        thr.detach();
-
 
6420
    }
-
 
6421
    catch (std::exception& e)
-
 
6422
    {
-
 
6423
        MSG_ERROR("Error starting a thread to handle input line finish: " << e.what());
-
 
6424
    }
6404
}
6425
}
6405
 
6426
 
6406
void MainWindow::onGestureEvent(QObject *obj, QGestureEvent *event)
6427
void MainWindow::onGestureEvent(QObject *obj, QGestureEvent *event)
6407
{
6428
{
6408
    DECL_TRACER("MainWindow::onGestureEvent(QObject *obj, QGestureEvent *event)");
6429
    DECL_TRACER("MainWindow::onGestureEvent(QObject *obj, QGestureEvent *event)");