logo       

koffice/kformula: msg#12745

kde-commits

Subject: koffice/kformula

SVN commit 1004957 by rempt:

Replace K3 with Q

This replaces the undo history for kformula which was almost
completely commented out anyway.

M +0 -4 CMakeLists.txt
M +3 -4 KFormulaPartDocument.cpp
M +5 -5 KFormulaPartDocument.h


--- trunk/koffice/kformula/CMakeLists.txt #1004956:1004957
@@ -8,8 +8,6 @@

include_directories(${KFORMULA_INCLUDES})

-add_definitions(-DQT3_SUPPORT -DQT3_SUPPORT_WARNINGS)
-
add_subdirectory( pics )
add_subdirectory( flake )

@@ -31,8 +29,6 @@
komain
${KDE4_KDEUI_LIBS}
${KDE4_KPARTS_LIBS}
- ${KDE4_KDE3SUPPORT_LIBS}
- ${QT_QT3SUPPORT_LIBRARY}
)

set_target_properties(kformulaprivate PROPERTIES VERSION
${GENERIC_KOFFICE_LIB_VERSION} SOVERSION ${GENERIC_KOFFICE_LIB_SOVERSION} )
--- trunk/koffice/kformula/KFormulaPartDocument.cpp #1004956:1004957
@@ -19,8 +19,6 @@
the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
Boston, MA 02110-1301, USA.
*/
-
-
#include "KFormulaPartDocument.h"
#include "KFormulaPartView.h"
#include "KFormulaPartFactory.h"
@@ -28,6 +26,8 @@

#include <QPainter>
#include <QString>
+#include <QUndoCommand>
+#include <QUndoStack>

#include <KoGlobal.h>
#include <KoXmlWriter.h>
@@ -45,7 +45,7 @@
{
setComponentData( KFormulaPartFactory::global(), false );

- m_commandHistory = new K3CommandHistory( actionCollection() );
+ m_commandHistory = new QUndoStack(this);
m_formulaElement = new FormulaElement;
/* connect( m_commandHistory, SIGNAL( commandExecuted() ),
this, SLOT( slotExecuted() ) );
@@ -56,7 +56,6 @@

KFormulaPartDocument::~KFormulaPartDocument()
{
- delete m_commandHistory;
}


--- trunk/koffice/kformula/KFormulaPartDocument.h #1004956:1004957
@@ -28,12 +28,12 @@
#include <KoShapeControllerBase.h>
#include "KFormulaPartView.h"
#include <QPainter>
-#include <k3command.h>
#include "kformula_export.h"

class QIODevice;
+class QUndoStack;
+class KoDataCenter;
class KoXmlWriter;
-class KoDataCenter;

class FormulaElement;

@@ -82,8 +82,8 @@
/// reimplemented from KoDocument
bool showEmbedInitDialog(QWidget* parent);

- /// Return our Formula container
- FormulaElement* formulaElement() const { return m_formulaElement; }
+ /// Return our Formula container
+ FormulaElement* formulaElement() const { return m_formulaElement; }

protected slots:
void commandExecuted();
@@ -96,7 +96,7 @@
private:
FormulaElement* m_formulaElement;
/// The undo stack
- K3CommandHistory* m_commandHistory;
+ QUndoStack* m_commandHistory;

};


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | Mail Home | sitemap | FAQ | advertise