Ignore:
Timestamp:
Jan 29, 2010, 10:35:04 AM (15 years ago)
Author:
Dmitry A. Kuminov
Message:

tests/widget: Added QDesktopServices test.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tests/widget/widget.cpp

    r481 r488  
    418418#endif
    419419
    420 #if 1
     420#if 0
    421421    // QCursor shape test
    422422    void mousePressEvent(QMouseEvent *aE)
     
    687687#endif
    688688
     689#if 1
     690    //--------------------------------------------------------------------------
     691    // QDesktopServices test
     692    {
     693        for (int i = 0; i <= 10; ++i) {
     694            qWarning() << "StandardLocation" << i
     695                       << QDesktopServices::
     696                storageLocation((QDesktopServices::StandardLocation)i);
     697        }
     698
     699        PRINT_EXPR(QDesktopServices::openUrl(QUrl::fromLocalFile(QDir::currentPath())));
     700        PRINT_EXPR(QDesktopServices::openUrl(QUrl("file:///C:/OS2/BITMAP/OCEAN.BMP")));
     701        PRINT_EXPR(QDesktopServices::openUrl(QUrl("mailto:user@example.com")));
     702        PRINT_EXPR(QDesktopServices::openUrl(QUrl("http://www.ru")));
     703    }
     704#endif
     705
    689706#if 0
    690707    //--------------------------------------------------------------------------
Note: See TracChangeset for help on using the changeset viewer.