예제 #1
0
NS_IMETHODIMP
nsEditorTxnLog::DidRedo(nsITransactionManager *aTxMgr, nsITransaction *aTransaction, nsresult aRedoResult)
{
  LOCK_LOG(this);

  PrintIndent(--mIndentLevel);

  if (aTransaction)
  {
    Write("DidRedo:  ");
    WriteTransaction(aTransaction);
    Write(" (");
    WriteInt(aRedoResult);
    Write(")\n");
  }
  else
  {
    Write("DidRedoBatch (");
    WriteInt(aRedoResult);
    Write(")\n");
  }

  Flush();

  UNLOCK_LOG(this);

  return NS_OK;
}
예제 #2
0
NS_IMETHODIMP
nsEditorTxnLog::WillMerge(nsITransactionManager *aTxMgr, nsITransaction *aTopTransaction, nsITransaction *aTransaction, bool *aInterrupt)
{
  LOCK_LOG(this);

  PrintIndent(mIndentLevel);
  Write("WillMerge:   ");
  WriteTransaction(aTopTransaction);
  Write(" <-- ");
  WriteTransaction(aTransaction);
  Write("\n");
  Flush();

  UNLOCK_LOG(this);

  return NS_OK;
}
예제 #3
0
NS_IMETHODIMP
nsEditorTxnLog::DidMerge(nsITransactionManager *aTxMgr, nsITransaction *aTopTransaction, nsITransaction *aTransaction, bool aDidMerge, nsresult aMergeResult)
{
  LOCK_LOG(this);

  PrintIndent(mIndentLevel);
  Write("DidMerge:    ");
  WriteTransaction(aTopTransaction);
  Write(" <-- ");
  WriteTransaction(aTransaction);
  Write(" (");
  Write(aDidMerge ? "TRUE" : "FALSE");
  Write(", ");
  WriteInt(aMergeResult);
  Write(")\n");
  Flush();

  UNLOCK_LOG(this);

  return NS_OK;
}
예제 #4
0
NS_IMETHODIMP
nsEditorTxnLog::DidDo(nsITransactionManager *aTxMgr, nsITransaction *aTransaction, nsresult aDoResult)
{
  LOCK_LOG(this);

  PrintIndent(--mIndentLevel);
  Write("DidDo:    ");
  WriteTransaction(aTransaction);
  Write("(");
  WriteInt(aDoResult);
  Write(")\n");
  Flush();

  UNLOCK_LOG(this);

  return NS_OK;
}
예제 #5
0
NS_IMETHODIMP
nsEditorTxnLog::WillUndo(nsITransactionManager *aTxMgr, nsITransaction *aTransaction, bool *aInterrupt)
{
  LOCK_LOG(this);

  PrintIndent(mIndentLevel++);

  if (aTransaction)
  {
    Write("WillUndo:   ");
    WriteTransaction(aTransaction);
    Write("\n");
  }
  else
    Write("WillUndoBatch\n");

  Flush();

  UNLOCK_LOG(this);

  return NS_OK;
}
예제 #6
0
Void metadata::ClassField::LogArrayRecord(StdUInt class_id, UInt32 count, UInt32 index) const
{
    if(!enable_logging)
        return;
    WriteTransaction(getOffset() + class_id * getStep() + index * getUnitSize(), count * getUnitSize());
}
예제 #7
0
Void metadata::ClassField::LogRecord(StdUInt class_id) const
{
    if(!enable_logging)
        return;
    WriteTransaction(getOffset() + class_id * getStep(), getUnitSize());
}