Changeset 769 for trunk/tools/shared
- Timestamp:
- Aug 2, 2010, 9:27:30 PM (15 years ago)
- Location:
- trunk
- Files:
-
- 10 edited
- 6 copied
Legend:
- Unmodified
- Added
- Removed
-
trunk
- Property svn:mergeinfo changed
/branches/vendor/nokia/qt/4.6.3 (added) merged: 768 /branches/vendor/nokia/qt/current merged: 767 /branches/vendor/nokia/qt/4.6.2 removed
- Property svn:mergeinfo changed
-
trunk/tools/shared/findwidget/abstractfindwidget.h
r651 r769 71 71 Q_DECLARE_FLAGS(FindFlags, FindFlag) 72 72 73 AbstractFindWidget(FindFlags flags = FindFlags(), QWidget *parent = 0);73 AbstractFindWidget(FindFlags flags = FindFlags(), QWidget *parent = 0); 74 74 virtual ~AbstractFindWidget(); 75 75 -
trunk/tools/shared/findwidget/itemviewfindwidget.h
r651 r769 56 56 57 57 public: 58 ItemViewFindWidget(FindFlags flags = FindFlags(), QWidget *parent = 0);58 ItemViewFindWidget(FindFlags flags = FindFlags(), QWidget *parent = 0); 59 59 60 60 QAbstractItemView *itemView() const -
trunk/tools/shared/findwidget/texteditfindwidget.h
r651 r769 54 54 55 55 public: 56 TextEditFindWidget(FindFlags flags = FindFlags(), QWidget *parent = 0);56 TextEditFindWidget(FindFlags flags = FindFlags(), QWidget *parent = 0); 57 57 58 58 QTextEdit *textEdit() const -
trunk/tools/shared/fontpanel/fontpanel.cpp
r651 r769 218 218 219 219 if (hasStyles) { 220 foreach ( QStringstyle, styles) {220 foreach (style, styles) { 221 221 // try to maintain selection or select 'normal' preferably 222 222 const int newIndex = m_styleComboBox->count(); -
trunk/tools/shared/qtgradienteditor/qtgradientutils.cpp
r651 r769 396 396 { 397 397 QStringList result; 398 foreach ( QGradientStopstop, gradient.stops()) {398 foreach (stop, gradient.stops()) { 399 399 const QColor color = stop.second; 400 400 -
trunk/tools/shared/qtpropertybrowser/qtpropertybrowserutils.cpp
r651 r769 94 94 } 95 95 96 97 98 99 100 101 102 103 96 104 void QtCursorDatabase::appendCursor(Qt::CursorShape shape, const QString &name, const QIcon &icon) 97 105 { 98 106 if (m_cursorShapeToValue.contains(shape)) 99 107 return; 100 int value = m_cursorNames.count();108 int value = m_cursorNames.count(); 101 109 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; 105 113 } 106 114 -
trunk/tools/shared/qtpropertybrowser/qtpropertybrowserutils_p.h
r651 r769 69 69 public: 70 70 QtCursorDatabase(); 71 71 72 72 73 QStringList cursorShapeNames() const; -
trunk/tools/shared/qtpropertybrowser/qtpropertymanager.cpp
r651 r769 1392 1392 1393 1393 // 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 1475 1395 static QIcon drawCheckBox(bool value) 1476 1396 { … … 1502 1422 } 1503 1423 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 1504 1512 /*! 1505 1513 \reimp … … 1511 1519 return QIcon(); 1512 1520 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; 1516 1522 } 1517 1523 … … 6288 6294 // QtCursorPropertyManager 6289 6295 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. 6298 static void clearCursorDatabase(); 6299 Q_GLOBAL_STATIC_WITH_INITIALIZER(QtCursorDatabase, cursorDatabase, qAddPostRoutine(clearCursorDatabase)) 6300 6301 static void clearCursorDatabase() 6302 { 6303 cursorDatabase()->clear(); 6304 } 6291 6305 6292 6306 class QtCursorPropertyManagerPrivate -
trunk/tools/shared/qttoolbardialog/qttoolbardialog.h
r651 r769 69 69 public: 70 70 71 QtToolBarManager(QObject *parent = 0);71 QtToolBarManager(QObject *parent = 0); 72 72 ~QtToolBarManager(); 73 73 … … 101 101 public: 102 102 103 QtToolBarDialog(QWidget *parent = 0, Qt::WindowFlags flags = 0);103 QtToolBarDialog(QWidget *parent = 0, Qt::WindowFlags flags = 0); 104 104 ~QtToolBarDialog(); 105 105
Note:
See TracChangeset
for help on using the changeset viewer.