comparison view/PaneStack.cpp @ 806:4c8ca536b54f warnfix_no_size_t

Some more unsigned/long removal
author Chris Cannam
date Tue, 17 Jun 2014 15:36:56 +0100
parents b6dc57688c72
children 57efeb75880d
comparison
equal deleted inserted replaced
805:1d526ba11a24 806:4c8ca536b54f
96 layout->setRowStretch(1, 20); 96 layout->setRowStretch(1, 20);
97 currentIndicator->setMinimumWidth(8); 97 currentIndicator->setMinimumWidth(8);
98 currentIndicator->setScaledContents(true); 98 currentIndicator->setScaledContents(true);
99 currentIndicator->setVisible(m_showAccessories); 99 currentIndicator->setVisible(m_showAccessories);
100 100
101 long initialCentreFrame = -1; 101 int initialCentreFrame = -1;
102 for (int i = 0; i < m_panes.size(); ++i) { 102 for (int i = 0; i < (int)m_panes.size(); ++i) {
103 long f = m_panes[i].pane->getCentreFrame(); 103 int f = m_panes[i].pane->getCentreFrame();
104 initialCentreFrame = f; 104 initialCentreFrame = f;
105 break; 105 break;
106 } 106 }
107 107
108 Pane *pane = new Pane(frame); 108 Pane *pane = new Pane(frame);
156 this, SLOT(rightButtonMenuRequested(QPoint))); 156 this, SLOT(rightButtonMenuRequested(QPoint)));
157 connect(pane, SIGNAL(dropAccepted(QStringList)), 157 connect(pane, SIGNAL(dropAccepted(QStringList)),
158 this, SLOT(paneDropAccepted(QStringList))); 158 this, SLOT(paneDropAccepted(QStringList)));
159 connect(pane, SIGNAL(dropAccepted(QString)), 159 connect(pane, SIGNAL(dropAccepted(QString)),
160 this, SLOT(paneDropAccepted(QString))); 160 this, SLOT(paneDropAccepted(QString)));
161 connect(pane, SIGNAL(doubleClickSelectInvoked(size_t)), 161 connect(pane, SIGNAL(doubleClickSelectInvoked(int)),
162 this, SIGNAL(doubleClickSelectInvoked(size_t))); 162 this, SIGNAL(doubleClickSelectInvoked(int)));
163 163
164 emit paneAdded(pane); 164 emit paneAdded(pane);
165 emit paneAdded(); 165 emit paneAdded();
166 166
167 if (!m_currentPane) { 167 if (!m_currentPane) {
218 } 218 }
219 219
220 Pane * 220 Pane *
221 PaneStack::getPane(int n) 221 PaneStack::getPane(int n)
222 { 222 {
223 if (n < m_panes.size()) { 223 if (n < (int)m_panes.size()) {
224 return m_panes[n].pane; 224 return m_panes[n].pane;
225 } else { 225 } else {
226 return 0; 226 return 0;
227 } 227 }
228 } 228 }
530 { 530 {
531 int maxMinWidth = 0; 531 int maxMinWidth = 0;
532 532
533 if (m_propertyStackMinWidth > 0) maxMinWidth = m_propertyStackMinWidth; 533 if (m_propertyStackMinWidth > 0) maxMinWidth = m_propertyStackMinWidth;
534 534
535 for (size_t i = 0; i < m_panes.size(); ++i) { 535 for (int i = 0; i < (int)m_panes.size(); ++i) {
536 if (!m_panes[i].propertyStack) continue; 536 if (!m_panes[i].propertyStack) continue;
537 #ifdef DEBUG_PANE_STACK 537 #ifdef DEBUG_PANE_STACK
538 SVDEBUG << "PaneStack::sizePropertyStacks: " << i << ": min " 538 SVDEBUG << "PaneStack::sizePropertyStacks: " << i << ": min "
539 << m_panes[i].propertyStack->minimumSizeHint().width() << ", hint " 539 << m_panes[i].propertyStack->minimumSizeHint().width() << ", hint "
540 << m_panes[i].propertyStack->sizeHint().width() << ", current " 540 << m_panes[i].propertyStack->sizeHint().width() << ", current "
552 552
553 int setWidth = maxMinWidth; 553 int setWidth = maxMinWidth;
554 554
555 m_propertyStackStack->setMaximumWidth(setWidth + 10); 555 m_propertyStackStack->setMaximumWidth(setWidth + 10);
556 556
557 for (size_t i = 0; i < m_panes.size(); ++i) { 557 for (int i = 0; i < (int)m_panes.size(); ++i) {
558 if (!m_panes[i].propertyStack) continue; 558 if (!m_panes[i].propertyStack) continue;
559 m_panes[i].propertyStack->setMinimumWidth(setWidth); 559 m_panes[i].propertyStack->setMinimumWidth(setWidth);
560 } 560 }
561 561
562 emit propertyStacksResized(setWidth); 562 emit propertyStacksResized(setWidth);
579 579
580 void 580 void
581 PaneStack::paneDeleteButtonClicked() 581 PaneStack::paneDeleteButtonClicked()
582 { 582 {
583 QObject *s = sender(); 583 QObject *s = sender();
584 for (size_t i = 0; i < m_panes.size(); ++i) { 584 for (int i = 0; i < (int)m_panes.size(); ++i) {
585 if (m_panes[i].xButton == s) { 585 if (m_panes[i].xButton == s) {
586 emit paneDeleteButtonClicked(m_panes[i].pane); 586 emit paneDeleteButtonClicked(m_panes[i].pane);
587 } 587 }
588 } 588 }
589 } 589 }
591 void 591 void
592 PaneStack::indicatorClicked() 592 PaneStack::indicatorClicked()
593 { 593 {
594 QObject *s = sender(); 594 QObject *s = sender();
595 595
596 for (size_t i = 0; i < m_panes.size(); ++i) { 596 for (int i = 0; i < (int)m_panes.size(); ++i) {
597 if (m_panes[i].currentIndicator == s) { 597 if (m_panes[i].currentIndicator == s) {
598 setCurrentPane(m_panes[i].pane); 598 setCurrentPane(m_panes[i].pane);
599 return; 599 return;
600 } 600 }
601 } 601 }