Ignore:
Timestamp:
Dec 2, 2009, 4:30:02 AM (16 years ago)
Author:
Dmitry A. Kuminov
Message:

tools: Patched qdesigner to make it compile without Drag&Drop.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tools/designer/src/components/widgetbox/widgetbox.cpp

    r2 r372  
    180180                                               bool acceptEventsFromWidgetBox)
    181181{
     182#ifndef QT_NO_DRAGANDDROP
    182183    const QDesignerMimeData *mimeData = qobject_cast<const QDesignerMimeData *>(event->mimeData());
    183184    if (!mimeData) {
     
    196197    mimeData->acceptEvent(event);
    197198    return mimeData;
     199#else
     200    return 0;
     201#endif
    198202}
    199203
    200204void WidgetBox::dragEnterEvent (QDragEnterEvent * event)
    201205{
     206#ifndef QT_NO_DRAGANDDROP
    202207    // We accept event originating from the widget box also here,
    203208    // because otherwise Windows will not show the DnD pixmap.
    204209    checkDragEvent(event, true);
     210#endif
    205211}
    206212
    207213void WidgetBox::dragMoveEvent(QDragMoveEvent * event)
    208214{
     215#ifndef QT_NO_DRAGANDDROP
    209216    checkDragEvent(event, true);
     217#endif
    210218}
    211219
    212220void WidgetBox::dropEvent(QDropEvent * event)
    213221{
     222#ifndef QT_NO_DRAGANDDROP
    214223    const QDesignerMimeData *mimeData = checkDragEvent(event, false);
    215224    if (!mimeData)
     
    218227    dropWidgets(mimeData->items(), event->pos());
    219228    QDesignerMimeData::removeMovedWidgetsFromSourceForm(mimeData->items());
     229#endif
    220230}
    221231
Note: See TracChangeset for help on using the changeset viewer.