r15730 by fschmid - Fixed Bug #9426: "Adding guides doesn't change document status"
scribus-commit
scribus-commit at lists.scribus.net
Tue Nov 2 22:30:59 CET 2010
Author: fschmid
Date: Tue Nov 2 21:30:59 2010
New Revision: 15730
URL: http://scribus.info/websvn/listing.php?repname=Scribus&sc=1&rev=15730
Log:
Fixed Bug #9426: "Adding guides doesn't change document status"
Modified:
trunk/Scribus/scribus/canvasgesture_rulermove.cpp
trunk/Scribus/scribus/ui/guidemanager.cpp
Modified: trunk/Scribus/scribus/canvasgesture_rulermove.cpp
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=15730&path=/trunk/Scribus/scribus/canvasgesture_rulermove.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasgesture_rulermove.cpp (original)
+++ trunk/Scribus/scribus/canvasgesture_rulermove.cpp Tue Nov 2 21:30:59 2010
@@ -181,6 +181,7 @@
m_guide = mousePointDoc.y() - m_doc->Pages->at(page)->yOffset();
m_page = page;
m_haveGuide = true;
+ m_doc->changed();
}
}
else if (mouseRelease)
@@ -193,11 +194,12 @@
m_doc->Pages->at(page)->guides.addHorizontal(mousePointDoc.y() - m_doc->Pages->at(page)->yOffset(), GuideManagerCore::Standard);
m_page = page;
}
+ m_doc->changed();
}
else
{
- QCursor* cursor = qApp->overrideCursor();
- if (cursor && (cursor->shape() != Qt::SplitVCursor))
+ QCursor* cursor = qApp->overrideCursor();
+ if (cursor && (cursor->shape() != Qt::SplitVCursor))
qApp->changeOverrideCursor(QCursor(Qt::SplitVCursor));
}
m_currentGuide = mousePointDoc.y() - m_doc->Pages->at(page)->yOffset();
@@ -211,6 +213,7 @@
{
m_doc->Pages->at(m_page)->guides.deleteHorizontal( m_guide, GuideManagerCore::Standard);
m_haveGuide = false;
+ m_doc->changed();
}
}
}
@@ -232,6 +235,7 @@
m_guide = mousePointDoc.x() - m_doc->Pages->at(page)->xOffset();
m_page = page;
m_haveGuide = true;
+ m_doc->changed();
}
}
else if (mouseRelease)
@@ -244,11 +248,12 @@
m_doc->Pages->at(page)->guides.addVertical(mousePointDoc.x() - m_doc->Pages->at(page)->xOffset(), GuideManagerCore::Standard);
m_page = page;
}
+ m_doc->changed();
}
else
{
- QCursor* cursor = qApp->overrideCursor();
- if (cursor && (cursor->shape() != Qt::SplitHCursor))
+ QCursor* cursor = qApp->overrideCursor();
+ if (cursor && (cursor->shape() != Qt::SplitHCursor))
qApp->changeOverrideCursor(QCursor(Qt::SplitHCursor));
}
m_currentGuide = mousePointDoc.x() - m_doc->Pages->at(page)->xOffset();
@@ -262,6 +267,7 @@
{
m_doc->Pages->at(m_page)->guides.deleteVertical( m_guide, GuideManagerCore::Standard);
m_haveGuide = false;
+ m_doc->changed();
}
}
}
Modified: trunk/Scribus/scribus/ui/guidemanager.cpp
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=15730&path=/trunk/Scribus/scribus/ui/guidemanager.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/guidemanager.cpp (original)
+++ trunk/Scribus/scribus/ui/guidemanager.cpp Tue Nov 2 21:30:59 2010
@@ -312,6 +312,7 @@
currentPage->guides.clearHorizontals(GuideManagerCore::Standard);
currentPage->guides.addHorizontals(horizontalModel->values(), GuideManagerCore::Standard);
drawGuides();
+ m_Doc->changed();
}
void GuideManager::delVerButton_clicked()
@@ -330,6 +331,7 @@
currentPage->guides.clearVerticals(GuideManagerCore::Standard);
currentPage->guides.addVerticals(verticalModel->values(), GuideManagerCore::Standard);
drawGuides();
+ m_Doc->changed();
}
void GuideManager::addHorButton_clicked()
@@ -373,6 +375,7 @@
}
}
drawGuides();
+ m_Doc->changed();
}
void GuideManager::applyToAllStdButton_clicked()
@@ -395,12 +398,14 @@
horizontalAutoGapSpin->setEnabled(false);
currentPage->guides.setHorizontalAutoCount(val);
drawGuides();
+ m_Doc->changed();
}
void GuideManager::horizontalAutoGapSpin_valueChanged(double)
{
currentPage->guides.setHorizontalAutoGap(value2pts(horizontalAutoGapSpin->value(), docUnitIndex));
drawGuides();
+ m_Doc->changed();
}
void GuideManager::horizontalAutoGapCheck_stateChanged( int )
@@ -411,6 +416,7 @@
else
currentPage->guides.setHorizontalAutoGap(0.0);
drawGuides();
+ m_Doc->changed();
}
void GuideManager::verticalAutoCountSpin_valueChanged(int val)
@@ -423,12 +429,14 @@
verticalAutoGapSpin->setEnabled(false);
currentPage->guides.setVerticalAutoCount(val);
drawGuides();
+ m_Doc->changed();
}
void GuideManager::verticalAutoGapSpin_valueChanged(double)
{
currentPage->guides.setVerticalAutoGap(value2pts(verticalAutoGapSpin->value(), docUnitIndex));
drawGuides();
+ m_Doc->changed();
}
void GuideManager::verticalAutoGapCheck_stateChanged( int )
@@ -439,6 +447,7 @@
else
currentPage->guides.setVerticalAutoGap(0.0);
drawGuides();
+ m_Doc->changed();
}
void GuideManager::tabWidget_currentChanged(QWidget *)
@@ -528,6 +537,7 @@
trans.commit();
drawGuides();
+ m_Doc->changed();
}
void GuideManager::deleteAllGuides_clicked()
@@ -543,6 +553,7 @@
m_drawGuides = true;
trans.commit();
drawGuides();
+ m_Doc->changed();
}
void GuideManager::windowActivationChange(bool oldActive)
@@ -628,6 +639,7 @@
currentPage->guides.clearVerticals(GuideManagerCore::Standard);
currentPage->guides.addVerticals(verticalModel->values(), GuideManagerCore::Standard);
drawGuides();
+ m_Doc->changed();
}
void GuideManager::horizontalModel_valueChanged()
@@ -635,6 +647,7 @@
currentPage->guides.clearHorizontals(GuideManagerCore::Standard);
currentPage->guides.addHorizontals(horizontalModel->values(), GuideManagerCore::Standard);
drawGuides();
+ m_Doc->changed();
}
void GuideManager::setHorizontalRefer(int button)
@@ -721,6 +734,7 @@
return;
currentPage->guides.setVerticalAutoRefer(0);
drawGuides();
+ m_Doc->changed();
}
void GuideManager::verticalMarginsAutoButton_toggled(bool state)
@@ -729,6 +743,7 @@
return;
currentPage->guides.setVerticalAutoRefer(1);
drawGuides();
+ m_Doc->changed();
}
void GuideManager::verticalSelectionAutoButton_toggled(bool state)
@@ -739,4 +754,5 @@
if (verticalSelectionAutoButton->isEnabled())
resetSelectionForPage();
drawGuides();
-}
+ m_Doc->changed();
+}
More information about the scribus-commit
mailing list