1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/editor/libeditor/base/EditTxn.cpp Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,50 @@ 1.4 +/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ 1.5 +/* This Source Code Form is subject to the terms of the Mozilla Public 1.6 + * License, v. 2.0. If a copy of the MPL was not distributed with this 1.7 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 1.8 + 1.9 +#include "EditTxn.h" 1.10 +#include "nsError.h" 1.11 +#include "nsISupportsBase.h" 1.12 + 1.13 +NS_IMPL_CYCLE_COLLECTION_CLASS(EditTxn) 1.14 + 1.15 +NS_IMPL_CYCLE_COLLECTION_UNLINK_0(EditTxn) 1.16 +NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN(EditTxn) 1.17 + // We don't have anything to traverse, but some of our subclasses do. 1.18 +NS_IMPL_CYCLE_COLLECTION_TRAVERSE_END 1.19 + 1.20 +NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(EditTxn) 1.21 + NS_INTERFACE_MAP_ENTRY(nsITransaction) 1.22 + NS_INTERFACE_MAP_ENTRY(nsPIEditorTransaction) 1.23 + NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, nsITransaction) 1.24 +NS_INTERFACE_MAP_END 1.25 + 1.26 +NS_IMPL_CYCLE_COLLECTING_ADDREF(EditTxn) 1.27 +NS_IMPL_CYCLE_COLLECTING_RELEASE_WITH_LAST_RELEASE(EditTxn, LastRelease()) 1.28 + 1.29 +EditTxn::~EditTxn() 1.30 +{ 1.31 +} 1.32 + 1.33 +NS_IMETHODIMP 1.34 +EditTxn::RedoTransaction(void) 1.35 +{ 1.36 + return DoTransaction(); 1.37 +} 1.38 + 1.39 +NS_IMETHODIMP 1.40 +EditTxn::GetIsTransient(bool *aIsTransient) 1.41 +{ 1.42 + *aIsTransient = false; 1.43 + 1.44 + return NS_OK; 1.45 +} 1.46 + 1.47 +NS_IMETHODIMP 1.48 +EditTxn::Merge(nsITransaction *aTransaction, bool *aDidMerge) 1.49 +{ 1.50 + *aDidMerge = false; 1.51 + 1.52 + return NS_OK; 1.53 +}