Ignore:
Timestamp:
May 5, 2011, 5:36:53 AM (14 years ago)
Author:
Dmitry A. Kuminov
Message:

trunk: Merged in qt 4.7.2 sources from branches/vendor/nokia/qt.

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk

  • trunk/src/gui/itemviews/qproxymodel.h

    r651 r846  
    11/****************************************************************************
    22**
    3 ** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
     3** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies).
    44** All rights reserved.
    55** Contact: Nokia Corporation (qt-info@nokia.com)
     
    6868    // implementing model interface
    6969
    70     QModelIndex index(int row, int column, const QModelIndex &parent) const;
     70    QModelIndex index(int row, int column, const QModelIndex &parent = QModelIndex()) const;
    7171    QModelIndex parent(const QModelIndex &child) const;
    7272
    73     int rowCount(const QModelIndex &parent) const;
    74     int columnCount(const QModelIndex &parent) const;
    75     bool hasChildren(const QModelIndex &parent) const;
     73    int rowCount(const QModelIndex &parent = QModelIndex()) const;
     74    int columnCount(const QModelIndex &parent = QModelIndex()) const;
     75    bool hasChildren(const QModelIndex &parent = QModelIndex()) const;
    7676
    77     QVariant data(const QModelIndex &index, int role) const;
    78     bool setData(const QModelIndex &index, const QVariant &value, int role);
     77    QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const;
     78    bool setData(const QModelIndex &index, const QVariant &value, int role = Qt::EditRole);
    7979
    80     QVariant headerData(int section, Qt::Orientation orientation, int role) const;
     80    QVariant headerData(int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const;
    8181    bool setHeaderData(int section, Qt::Orientation orientation, const QVariant &value,
    82                        int role);
     82                       int role = Qt::EditRole);
    8383
    8484    QStringList mimeTypes() const;
     
    8888    Qt::DropActions supportedDropActions() const;
    8989
    90     bool insertRows(int row, int count, const QModelIndex &parent);
    91     bool insertColumns(int column, int count, const QModelIndex &parent);
     90    bool insertRows(int row, int count, const QModelIndex &parent = QModelIndex());
     91    bool insertColumns(int column, int count, const QModelIndex &parent = QModelIndex());
    9292
    9393    void fetchMore(const QModelIndex &parent);
    9494    Qt::ItemFlags flags(const QModelIndex &index) const;
    9595
    96     void sort(int column, Qt::SortOrder order);
     96    void sort(int column, Qt::SortOrder order = Qt::AscendingOrder);
    9797
    9898    QModelIndexList match(const QModelIndex &start, int role, const QVariant &value,
    99                           int hits, Qt::MatchFlags flags) const;
     99                          int hits = 1, Qt::MatchFlags flags =
     100                          Qt::MatchFlags(Qt::MatchStartsWith|Qt::MatchWrap)) const;
    100101
    101102    QSize span(const QModelIndex &index) const;
Note: See TracChangeset for help on using the changeset viewer.