From 093d9523757abd6d8594fb0dc505641bfc736ce9 Mon Sep 17 00:00:00 2001 From: "kin%netscape.com" Date: Wed, 2 Dec 1998 17:40:56 +0000 Subject: [PATCH] Added GetTransaction() method. --- editor/txmgr/src/nsTransactionItem.cpp | 11 +++++++++++ editor/txmgr/src/nsTransactionItem.h | 1 + 2 files changed, 12 insertions(+) diff --git a/editor/txmgr/src/nsTransactionItem.cpp b/editor/txmgr/src/nsTransactionItem.cpp index ce66e1f84d40..3a972fbe2cdc 100644 --- a/editor/txmgr/src/nsTransactionItem.cpp +++ b/editor/txmgr/src/nsTransactionItem.cpp @@ -52,6 +52,17 @@ nsTransactionItem::AddChild(nsTransactionItem *aTransactionItem) return NS_OK; } +nsresult +nsTransactionItem::GetTransaction(nsITransaction **aTransaction) +{ + if (!aTransaction) + return NS_ERROR_NULL_POINTER; + + *aTransaction = mTransaction; + + return NS_OK; +} + nsresult nsTransactionItem::Do() { diff --git a/editor/txmgr/src/nsTransactionItem.h b/editor/txmgr/src/nsTransactionItem.h index 0d44ff30718b..bb3ef270847d 100644 --- a/editor/txmgr/src/nsTransactionItem.h +++ b/editor/txmgr/src/nsTransactionItem.h @@ -37,6 +37,7 @@ public: virtual ~nsTransactionItem(); virtual nsresult AddChild(nsTransactionItem *aTransactionItem); + virtual nsresult GetTransaction(nsITransaction **aTransaction); virtual nsresult Do(void); virtual nsresult Undo(void);