Changeset 986 for trunk/src/gui


Ignore:
Timestamp:
Aug 16, 2011, 12:57:10 AM (14 years ago)
Author:
Dmitry A. Kuminov
Message:

OS/2: Add missing documentation to methods.

Location:
trunk/src/gui/kernel
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/gui/kernel/qmime_pm.cpp

    r776 r986  
    290290}
    291291
     292
     293
     294
     295
    292296QPMMime::DefaultDragWorker::DefaultDragWorker(bool exclusive)
    293297    : d(new Data(this, exclusive))
     
    297301}
    298302
     303
     304
     305
    299306QPMMime::DefaultDragWorker::~DefaultDragWorker()
    300307{
     
    303310}
    304311
     312
     313
     314
    305315bool QPMMime::DefaultDragWorker::cleanup(bool isCancelled)
    306316{
     
    341351}
    342352
     353
     354
     355
    343356bool QPMMime::DefaultDragWorker::isExclusive() const
    344357{
     
    346359}
    347360
     361
     362
     363
    348364ULONG QPMMime::DefaultDragWorker::itemCount() const
    349365{
     
    351367}
    352368
     369
     370
     371
    353372ULONG QPMMime::DefaultDragWorker::hwnd() const
    354373{
     
    356375}
    357376
     377
     378
     379
    358380QByteArray QPMMime::DefaultDragWorker::composeFormatString()
    359381{
     
    392414}
    393415
     416
     417
     418
    394419bool QPMMime::DefaultDragWorker::prepare(const char *drm, const char *drf,
    395420                                          DRAGITEM *item, ULONG itemIndex)
     
    434459}
    435460
     461
     462
     463
    436464void QPMMime::DefaultDragWorker::defaultFileType(QString &type,
    437465                                                 QString &ext)
     
    676704}
    677705
     706
     707
     708
     709
     710
     711
     712
     713
     714
    678715bool QPMMime::DefaultDragWorker::addProvider(const QByteArray &drf, Provider *provider,
    679716                                             ULONG itemCnt /* = 1 */)
     
    701738}
    702739
     740
     741
     742
     743
    703744// static
    704745bool QPMMime::DefaultDragWorker::canRender(const char *drm)
     
    748789};
    749790
     791
     792
     793
    750794QPMMime::DefaultDropWorker::DefaultDropWorker() : d(new Data(this))
    751795{
     
    755799}
    756800
     801
     802
     803
    757804QPMMime::DefaultDropWorker::~DefaultDropWorker()
    758805{
     
    760807}
    761808
     809
     810
     811
    762812void QPMMime::DefaultDropWorker::cleanup(bool isAccepted)
    763813{
     
    776826}
    777827
     828
     829
     830
    778831bool QPMMime::DefaultDropWorker::isExclusive() const
    779832{
     
    781834}
    782835
     836
     837
     838
    783839bool QPMMime::DefaultDropWorker::hasFormat(const QString &mimeType) const
    784840{
     
    786842}
    787843
     844
     845
     846
    788847QStringList QPMMime::DefaultDropWorker::formats() const
    789848{
     
    824883}
    825884
     885
     886
     887
    826888QVariant QPMMime::DefaultDropWorker::retrieveData(const QString &mimeType,
    827889                                                  QVariant::Type preferredType) const
     
    11321194}
    11331195
     1196
     1197
     1198
     1199
     1200
     1201
     1202
     1203
    11341204bool QPMMime::DefaultDropWorker::addProvider(const QString &mimeType,
    11351205                                             Provider *provider)
     
    11451215}
    11461216
     1217
     1218
     1219
     1220
     1221
     1222
     1223
     1224
    11471225bool QPMMime::DefaultDropWorker::addExclusiveProvider(const QString &mimeType,
    11481226                                                      Provider *provider)
     
    11581236}
    11591237
     1238
     1239
     1240
     1241
    11601242// static
    11611243bool QPMMime::DefaultDropWorker::canRender(DRAGITEM *item, const char *drf)
     
    14881570    DRAGITEM structures in order to represent different mime data types). As
    14891571    opposed to super exclusive workers (identified by isExclusive() returning
    1490     TRUE and by itemCount() returning zero), exclusive and cooperative workers
     1572    ), exclusive and cooperative workers
    14911573    do not create DRAGINFO/DRAGITEM structures on their own, they implement a
    14921574    subset of methods that is used by the drag manager to fill drag structures
     
    15041586    mime type.
    15051587
    1506     \note Subclasses must NOT free the DRAGINFO structure they allocated and
    1507     returned by createDragInfo().
    1508 
    15091588    \note Every exclusive drag worker must implement createDragInfo() and must
    1510     not implement composeFormatSting()/canRender()/prepare()/defaultFileType().
    1511     And vice versa, every cooperative drag worker must implement the latter
    1512     three functions but not the former two.
    1513 
    1514     \note The return value of cleanup() is whether the Move operation is
    1515     disallowed by this worker or not (if the worker doesn't participate in the
    1516     DND session, it should return FALSE, to let other workers allow Move).
     1589    not implement composeFormatSting()/prepare()/defaultFileType(). And vice
     1590    versa, every cooperative drag worker must implement the latter three
     1591    functions but not the former two.
     1592*/
     1593
     1594/*!
     1595    \fn QPMMime::DragWorker::DragWorker()
     1596
     1597    Constructs a new instance.
     1598*/
     1599
     1600/*!
     1601    \fn QPMMime::DragWorker::~DragWorker()
     1602
     1603    Destroys the instance.
     1604*/
     1605
     1606/*!
     1607    \fn QPMMime::DragWorker::source() const
     1608
     1609    Returns the source of the current drag operation.
     1610*/
     1611
     1612/*!
     1613    \fn QPMMime::DragWorker::init()
     1614
     1615    Initializes the instance before the drag operation.
     1616*/
     1617
     1618/*!
     1619    \fn QPMMime::DragWorker::cleanup(bool isCancelled)
     1620
     1621    Performs cleanup after the drag operation. If the drag operation was
     1622    cancelled, \a isCancelled will be \c true.
     1623
     1624    Returns \c true if the Move operation is disallowed by this worker. Note
     1625    that if this worker doesn't participate in a given DnD session, it should
     1626    return \c false to let other workers allow Move.
     1627
     1628    Must be reimplemented in subclasses.
     1629*/
     1630
     1631/*!
     1632    \fn QPMMime::DragWorker::isExclusive() const
     1633
     1634    Returns \c true if this is an exclusive drag worker.
     1635
     1636    Must be reimplemented in subclasses.
     1637*/
     1638
     1639/*!
     1640    \fn QPMMime::DragWorker::itemCount() const
     1641
     1642    Returns the number of DRAGITEM elements this drag worker needs to represent
     1643    its data. If isExclusive() is \c true and this method returns 0, this drag
     1644    worker will manage creation of the DRAGINFO structure on its onwn.
     1645
     1646    Must be reimplemented in subclasses.
     1647*/
     1648
     1649/*!
     1650    \fn QPMMime::DragWorker::hwnd() const
     1651
     1652    Returns a window handle to be associated with DRAGITEM elemetns of this drag
     1653    worker.
     1654
     1655    Must be reimplemented in subclasses.
     1656*/
     1657
     1658/*!
     1659    \fn QPMMime::DragWorker::createDragInfo(const QString &targetName, USHORT
     1660                                            supportedOps)
     1661
     1662    Creates a new DRAGINFO structure for the drag operation with the suggested
     1663    \a targetName and supported operations represented by \a supportedOps.
     1664
     1665    \note The created structure is owned by QPMMime and should be not freed by
     1666    subclasses.
     1667
     1668    Must be reimplemented in subclasses if the isExclusive() implementation
     1669    returns \c true and itemCount() returns 0.
     1670*/
     1671
     1672/*!
     1673    \fn QPMMime::DragWorker::composeFormatString()
     1674
     1675    Returns a format string containing "<mechanism,format>" pairs supported by
     1676    this drag worker.
     1677
     1678    Must be reimplemented in subclasses if the isExclusive() implementation
     1679    returns \c false.
     1680*/
     1681
     1682/*!
     1683    \fn QPMMime::DragWorker::prepare(const char *drm, const char *drf,
     1684                                     DRAGITEM *item, ULONG itemIndex)
     1685
     1686    Prepares this worker for the drop operation of the \a item having
     1687    \a itemIndex using the mechanism and format specified in \a drm and \a drf,
     1688    respectively.
     1689
     1690    Must be reimplemented in subclasses if the isExclusive() implementation
     1691    returns \c false.
     1692*/
     1693
     1694/*!
     1695    \fn QPMMime::DragWorker::defaultFileType(QString &type, QString &ext)
     1696
     1697    Returns the default file \a type (and extension \a ext) for the data
     1698    represented by this worker.
     1699
     1700    Must be reimplemented in subclasses if the isExclusive() implementation
     1701    returns \c false.
    15171702*/
    15181703
     
    15281713
    15291714/*!
     1715
     1716
     1717
     1718
     1719
     1720
     1721
     1722
     1723
     1724
     1725
     1726
     1727
     1728
     1729
     1730
     1731
     1732
     1733
     1734
     1735
     1736
     1737
     1738
     1739
     1740
     1741
     1742
     1743
     1744
     1745
     1746
     1747
    15301748  \class QPMMime::DropWorker
    15311749
     
    15391757    processing the drop event, all other workers are silently ignored.
    15401758
    1541     \note Subclasses must NOT free the DRAGINFO structure pointed to by info().
    1542 
    1543     \note Subclasses must NOT send DM_ENDCONVERSATION to the source.
     1759    \note Subclasses must \b not send \c DM_ENDCONVERSATION to the source.
     1760*/
     1761
     1762/*!
     1763    \fn QPMMime::DropWorker::DropWorker()
     1764
     1765    Constructs a new instance.
     1766*/
     1767
     1768/*!
     1769    \fn QPMMime::DropWorker::~DropWorker()
     1770
     1771    Destroys the instance.
     1772*/
     1773
     1774/*!
     1775    \fn QPMMime::DropWorker::info() const
     1776
     1777    Returns a pointer to the DRAGINFO sctructure describing the current
     1778    drag operation.
     1779
     1780    \note Subclasses must \b not free this DRAGINFO structure.
     1781*/
     1782
     1783/*!
     1784    \fn QPMMime::DropWorker::init()
     1785
     1786    Initializes the instance before the drop operation.
     1787*/
     1788
     1789/*!
     1790    \fn QPMMime::DropWorker::cleanup(bool isAccepted)
     1791
     1792    Performs the cleanup after the drop operation. If the drag was accepted,
     1793    \a isAccepted will be \c true.
     1794*/
     1795
     1796/*!
     1797    \fn QPMMime::DropWorker::isExclusive() const
     1798
     1799    Returns \c true if this is an exclusive drop worker.
     1800
     1801    Must be reimplemented in subclasses.
     1802*/
     1803
     1804/*!
     1805    \fn QPMMime::DropWorker::hasFormat(const QString &mimeType) const
     1806
     1807    Returns \c true if this drop worker supports the given \a mimeType.
     1808
     1809    Must be reimplemented in subclasses.
     1810*/
     1811
     1812/*!
     1813    \fn QPMMime::DropWorker::formats() const
     1814
     1815    Returns a list of all MIME types supported by this drop worker.
     1816
     1817    Must be reimplemented in subclasses.
     1818*/
     1819
     1820/*!
     1821    \fn QPMMime::DropWorker::retrieveData(const QString &mimeType,
     1822                                          QVariant::Type preferredType) const
     1823
     1824    Returns data represented by this drag worker converted to the given
     1825    \a mimeType. The QVariant type preferred by the caller is indicated by
     1826    \a preferredType.
     1827
     1828    Must be reimplemented in subclasses.
    15441829*/
    15451830
     
    15521837    formats to particular mime types and apply postprocessing of data after
    15531838    rendering.
     1839
     1840
     1841
     1842
     1843
     1844
     1845
     1846
     1847
     1848
     1849
     1850
     1851
     1852
     1853
     1854
     1855
     1856
     1857
     1858
     1859
     1860
     1861
     1862
     1863
     1864
    15541865*/
    15551866
     
    17012012    mechanism and can be rendered by a target w/o involving the source (i.e.,
    17022013    \c DRM_OS2FILE is the first supported format and a valid file name with full
    1703     path is provided). If the function returns \c TRUE, \a fullName (if not
     2014    path is provided). If the function returns \c , \a fullName (if not
    17042015    \c NULL) will be assigned the item's full source file name (composed from
    17052016    \c hstrContainerName and \c hstrSourceName fields).
  • trunk/src/gui/kernel/qwidget_pm.cpp

    r938 r986  
    239239    with the given region using the \a op operation (CRGN_*); otherwise they are
    240240    directly validated on the window. The scope of relativeness is defined by
    241     the \fl argument which is one or more PWO_* flags OR-ed together.
     241    the \ argument which is one or more PWO_* flags OR-ed together.
    242242
    243243    Returns the complexity of the combined region (only when \a hrgn is not
Note: See TracChangeset for help on using the changeset viewer.