Changeset 769 for trunk/tools/shared


Ignore:
Timestamp:
Aug 2, 2010, 9:27:30 PM (15 years ago)
Author:
Dmitry A. Kuminov
Message:

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

Location:
trunk
Files:
10 edited
6 copied

Legend:

Unmodified
Added
Removed
  • trunk

  • trunk/tools/shared/findwidget/abstractfindwidget.h

    r651 r769  
    7171    Q_DECLARE_FLAGS(FindFlags, FindFlag)
    7272
    73     AbstractFindWidget(FindFlags flags = FindFlags(), QWidget *parent = 0);
     73    AbstractFindWidget(FindFlags flags = FindFlags(), QWidget *parent = 0);
    7474    virtual ~AbstractFindWidget();
    7575
  • trunk/tools/shared/findwidget/itemviewfindwidget.h

    r651 r769  
    5656
    5757public:
    58     ItemViewFindWidget(FindFlags flags = FindFlags(), QWidget *parent = 0);
     58    ItemViewFindWidget(FindFlags flags = FindFlags(), QWidget *parent = 0);
    5959
    6060    QAbstractItemView *itemView() const
  • trunk/tools/shared/findwidget/texteditfindwidget.h

    r651 r769  
    5454
    5555public:
    56     TextEditFindWidget(FindFlags flags = FindFlags(), QWidget *parent = 0);
     56    TextEditFindWidget(FindFlags flags = FindFlags(), QWidget *parent = 0);
    5757
    5858    QTextEdit *textEdit() const
  • trunk/tools/shared/fontpanel/fontpanel.cpp

    r651 r769  
    218218
    219219    if (hasStyles) {
    220         foreach (QString style, styles) {
     220        foreach (style, styles) {
    221221            // try to maintain selection or select 'normal' preferably
    222222            const int newIndex = m_styleComboBox->count();
  • trunk/tools/shared/qtgradienteditor/qtgradientutils.cpp

    r651 r769  
    396396{
    397397    QStringList result;
    398     foreach (QGradientStop stop, gradient.stops()) {
     398    foreach (stop, gradient.stops()) {
    399399        const QColor color = stop.second;
    400400
  • trunk/tools/shared/qtpropertybrowser/qtpropertybrowserutils.cpp

    r651 r769  
    9494}
    9595
     96
     97
     98
     99
     100
     101
     102
     103
    96104void QtCursorDatabase::appendCursor(Qt::CursorShape shape, const QString &name, const QIcon &icon)
    97105{
    98106    if (m_cursorShapeToValue.contains(shape))
    99107        return;
    100     int value = m_cursorNames.count();
     108    int value = m_cursorNames.count();
    101109    m_cursorNames.append(name);
    102     m_cursorIcons[value] = icon;
    103     m_valueToCursorShape[value] = shape;
    104     m_cursorShapeToValue[shape] = value;
     110    m_cursorIcons;
     111    m_valueToCursorShape;
     112    m_cursorShapeToValue;
    105113}
    106114
  • trunk/tools/shared/qtpropertybrowser/qtpropertybrowserutils_p.h

    r651 r769  
    6969public:
    7070    QtCursorDatabase();
     71
    7172
    7273    QStringList cursorShapeNames() const;
  • trunk/tools/shared/qtpropertybrowser/qtpropertymanager.cpp

    r651 r769  
    13921392
    13931393// QtBoolPropertyManager
    1394 
    1395 class QtBoolPropertyManagerPrivate
    1396 {
    1397     QtBoolPropertyManager *q_ptr;
    1398     Q_DECLARE_PUBLIC(QtBoolPropertyManager)
    1399 public:
    1400 
    1401     QMap<const QtProperty *, bool> m_values;
    1402 };
    1403 
    1404 /*!
    1405     \class QtBoolPropertyManager
    1406     \internal
    1407     \inmodule QtDesigner
    1408     \since 4.4
    1409 
    1410     \brief The QtBoolPropertyManager class provides and manages boolean properties.
    1411 
    1412     The property's value can be retrieved using the value() function,
    1413     and set using the setValue() slot.
    1414 
    1415     In addition, QtBoolPropertyManager provides the valueChanged() signal
    1416     which is emitted whenever a property created by this manager
    1417     changes.
    1418 
    1419     \sa QtAbstractPropertyManager, QtCheckBoxFactory
    1420 */
    1421 
    1422 /*!
    1423     \fn void QtBoolPropertyManager::valueChanged(QtProperty *property, bool value)
    1424 
    1425     This signal is emitted whenever a property created by this manager
    1426     changes its value, passing a pointer to the \a property and the
    1427     new \a value as parameters.
    1428 */
    1429 
    1430 /*!
    1431     Creates a manager with the given \a parent.
    1432 */
    1433 QtBoolPropertyManager::QtBoolPropertyManager(QObject *parent)
    1434     : QtAbstractPropertyManager(parent), d_ptr(new QtBoolPropertyManagerPrivate)
    1435 {
    1436     d_ptr->q_ptr = this;
    1437 }
    1438 
    1439 /*!
    1440     Destroys this manager, and all the properties it has created.
    1441 */
    1442 QtBoolPropertyManager::~QtBoolPropertyManager()
    1443 {
    1444     clear();
    1445 }
    1446 
    1447 /*!
    1448     Returns the given \a property's value.
    1449 
    1450     If the given \a property is not managed by \e this manager, this
    1451     function returns false.
    1452 
    1453     \sa setValue()
    1454 */
    1455 bool QtBoolPropertyManager::value(const QtProperty *property) const
    1456 {
    1457     return d_ptr->m_values.value(property, false);
    1458 }
    1459 
    1460 /*!
    1461     \reimp
    1462 */
    1463 QString QtBoolPropertyManager::valueText(const QtProperty *property) const
    1464 {
    1465     const QMap<const QtProperty *, bool>::const_iterator it = d_ptr->m_values.constFind(property);
    1466     if (it == d_ptr->m_values.constEnd())
    1467         return QString();
    1468 
    1469     static const QString trueText = tr("True");
    1470     static const QString falseText = tr("False");
    1471     return it.value() ? trueText : falseText;
    1472 }
    1473 
    1474 // Return an icon containing a check box indicator
     1394//     Return an icon containing a check box indicator
    14751395static QIcon drawCheckBox(bool value)
    14761396{
     
    15021422}
    15031423
     1424
     1425
     1426
     1427
     1428
     1429
     1430
     1431
     1432
     1433
     1434
     1435
     1436
     1437
     1438
     1439
     1440
     1441
     1442
     1443
     1444
     1445
     1446
     1447
     1448
     1449
     1450
     1451
     1452
     1453
     1454
     1455
     1456
     1457
     1458
     1459
     1460
     1461
     1462
     1463
     1464
     1465
     1466
     1467
     1468
     1469
     1470
     1471
     1472
     1473
     1474
     1475
     1476
     1477
     1478
     1479
     1480
     1481
     1482
     1483
     1484
     1485
     1486
     1487
     1488
     1489
     1490
     1491
     1492
     1493
     1494
     1495
     1496
     1497
     1498
     1499
     1500
     1501
     1502
     1503
     1504
     1505
     1506
     1507
     1508
     1509
     1510
     1511
    15041512/*!
    15051513    \reimp
     
    15111519        return QIcon();
    15121520
    1513     static const QIcon checkedIcon = drawCheckBox(true);
    1514     static const QIcon uncheckedIcon = drawCheckBox(false);
    1515     return it.value() ? checkedIcon : uncheckedIcon;
     1521    return it.value() ? d_ptr->m_checkedIcon : d_ptr->m_uncheckedIcon;
    15161522}
    15171523
     
    62886294// QtCursorPropertyManager
    62896295
    6290 Q_GLOBAL_STATIC(QtCursorDatabase, cursorDatabase)
     6296// Make sure icons are removed as soon as QApplication is destroyed, otherwise,
     6297// handles are leaked on X11.
     6298static void clearCursorDatabase();
     6299Q_GLOBAL_STATIC_WITH_INITIALIZER(QtCursorDatabase, cursorDatabase, qAddPostRoutine(clearCursorDatabase))
     6300
     6301static void clearCursorDatabase()
     6302{
     6303    cursorDatabase()->clear();
     6304}
    62916305
    62926306class QtCursorPropertyManagerPrivate
  • trunk/tools/shared/qttoolbardialog/qttoolbardialog.h

    r651 r769  
    6969public:
    7070
    71     QtToolBarManager(QObject *parent = 0);
     71    QtToolBarManager(QObject *parent = 0);
    7272    ~QtToolBarManager();
    7373
     
    101101public:
    102102
    103     QtToolBarDialog(QWidget *parent = 0, Qt::WindowFlags flags = 0);
     103    QtToolBarDialog(QWidget *parent = 0, Qt::WindowFlags flags = 0);
    104104    ~QtToolBarDialog();
    105105
Note: See TracChangeset for help on using the changeset viewer.