summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/declarative/graphicsitems/qdeclarativeitem.cpp1
-rw-r--r--tools/designer/src/components/buddyeditor/buddyeditor.cpp1
-rw-r--r--tools/designer/src/components/formeditor/qmdiarea_container.cpp1
-rw-r--r--tools/designer/src/lib/shared/qdesigner_menu.cpp8
-rw-r--r--tools/designer/src/lib/shared/qdesigner_toolbar.cpp1
5 files changed, 9 insertions, 3 deletions
diff --git a/src/declarative/graphicsitems/qdeclarativeitem.cpp b/src/declarative/graphicsitems/qdeclarativeitem.cpp
index 9a17d78..4abffc6 100644
--- a/src/declarative/graphicsitems/qdeclarativeitem.cpp
+++ b/src/declarative/graphicsitems/qdeclarativeitem.cpp
@@ -347,6 +347,7 @@ void QDeclarativeContents::complete()
void QDeclarativeContents::itemGeometryChanged(QDeclarativeItem *changed, const QRectF &newGeometry, const QRectF &oldGeometry)
{
+ Q_UNUSED(changed)
//### we can only pass changed if the left edge has moved left, or the right edge has moved right
if (newGeometry.width() != oldGeometry.width() || newGeometry.x() != oldGeometry.x())
calcWidth(/*changed*/);
diff --git a/tools/designer/src/components/buddyeditor/buddyeditor.cpp b/tools/designer/src/components/buddyeditor/buddyeditor.cpp
index 9da257e..e367f9a 100644
--- a/tools/designer/src/components/buddyeditor/buddyeditor.cpp
+++ b/tools/designer/src/components/buddyeditor/buddyeditor.cpp
@@ -405,6 +405,7 @@ QWidget *BuddyEditor::findBuddy(QLabel *l, const QWidgetList &existingBuddies) c
const int y = geom.center().y();
QWidget *neighbour = 0;
switch (l->layoutDirection()) {
+ case Qt::LayoutDirectionAuto:
case Qt::LeftToRight: { // Walk right to find next managed neighbour
const int xEnd = parent->size().width();
for (int x = geom.right() + 1; x < xEnd; x += DeltaX)
diff --git a/tools/designer/src/components/formeditor/qmdiarea_container.cpp b/tools/designer/src/components/formeditor/qmdiarea_container.cpp
index 5971094..5e266f4 100644
--- a/tools/designer/src/components/formeditor/qmdiarea_container.cpp
+++ b/tools/designer/src/components/formeditor/qmdiarea_container.cpp
@@ -105,6 +105,7 @@ void QMdiAreaContainer::positionNewMdiChild(const QWidget *area, QWidget *mdiChi
const QPoint pos = mdiChild->pos();
const QSize areaSize = area->size();
switch (QApplication::layoutDirection()) {
+ case Qt::LayoutDirectionAuto:
case Qt::LeftToRight: {
const QSize fullSize = QSize(areaSize.width() - pos.x(), areaSize.height() - pos.y());
if (fullSize.width() > MinSize && fullSize.height() > MinSize)
diff --git a/tools/designer/src/lib/shared/qdesigner_menu.cpp b/tools/designer/src/lib/shared/qdesigner_menu.cpp
index ba512e4..31a226a 100644
--- a/tools/designer/src/lib/shared/qdesigner_menu.cpp
+++ b/tools/designer/src/lib/shared/qdesigner_menu.cpp
@@ -77,6 +77,7 @@ using namespace qdesigner_internal;
static inline void extendClickableArea(QRect *subMenuRect, Qt::LayoutDirection dir)
{
switch (dir) {
+ case Qt::LayoutDirectionAuto: // Should never happen
case Qt::LeftToRight:
subMenuRect->setLeft(subMenuRect->left() - 20);
break;
@@ -931,8 +932,8 @@ void QDesignerMenu::moveUp(bool ctrl)
if (ctrl)
(void) swap(m_currentIndex, m_currentIndex - 1);
-
- m_currentIndex = qMax(0, --m_currentIndex);
+ --m_currentIndex;
+ m_currentIndex = qMax(0, m_currentIndex);
// Always re-select, swapping destroys order
update();
selectCurrentAction();
@@ -947,7 +948,8 @@ void QDesignerMenu::moveDown(bool ctrl)
if (ctrl)
(void) swap(m_currentIndex + 1, m_currentIndex);
- m_currentIndex = qMin(actions().count() - 1, ++m_currentIndex);
+ ++m_currentIndex;
+ m_currentIndex = qMin(actions().count() - 1, m_currentIndex);
update();
if (!ctrl)
selectCurrentAction();
diff --git a/tools/designer/src/lib/shared/qdesigner_toolbar.cpp b/tools/designer/src/lib/shared/qdesigner_toolbar.cpp
index 02a2f6d..e3bc64c 100644
--- a/tools/designer/src/lib/shared/qdesigner_toolbar.cpp
+++ b/tools/designer/src/lib/shared/qdesigner_toolbar.cpp
@@ -467,6 +467,7 @@ QRect ToolBarEventFilter::freeArea(const QToolBar *tb)
switch (tb->orientation()) {
case Qt::Horizontal:
switch (tb->layoutDirection()) {
+ case Qt::LayoutDirectionAuto: // Should never happen
case Qt::LeftToRight:
rc.setX(exclusionRectangle.right() + 1);
break;