~adamreichold/qpdfview/trunk

« back to all changes in this revision

Viewing changes to sources/main.cpp

  • Committer: Adam Reichold
  • Date: 2023-12-21 14:33:30 UTC
  • Revision ID: adam.reichold@t-online.de-20231221143330-dpmbfchec26vd0id
Avoid naming collision with Windows headers.

Show diffs side-by-side

added added

removed removed

Lines of Context:
400
400
 
401
401
    if(unique)
402
402
    {
403
 
        QScopedPointer< QDBusInterface > interface(MainWindowAdaptor::createInterface());
 
403
        QScopedPointer< QDBusInterface > uniqueInstance(MainWindowAdaptor::createInterface());
404
404
 
405
 
        if(interface->isValid())
 
405
        if(uniqueInstance->isValid())
406
406
        {
407
 
            interface->call("raiseAndActivate");
 
407
            uniqueInstance->call("raiseAndActivate");
408
408
 
409
409
            foreach(const File& file, files)
410
410
            {
411
 
                QDBusReply< bool > reply = interface->call("jumpToPageOrOpenInNewTab", QFileInfo(file.filePath).absoluteFilePath(), file.page, true, file.enclosingBox, quiet);
 
411
                QDBusReply< bool > reply = uniqueInstance->call("jumpToPageOrOpenInNewTab", QFileInfo(file.filePath).absoluteFilePath(), file.page, true, file.enclosingBox, quiet);
412
412
 
413
413
                if(!reply.isValid())
414
414
                {
420
420
 
421
421
            if(!files.isEmpty())
422
422
            {
423
 
                interface->call("saveDatabase");
 
423
                uniqueInstance->call("saveDatabase");
424
424
            }
425
425
 
426
426
            if(!searchText.isEmpty())
427
427
            {
428
 
                interface->call("startSearch", searchText);
 
428
                uniqueInstance->call("startSearch", searchText);
429
429
            }
430
430
 
431
431
            exit(ExitOk);