author Tom Prince <>
Thu, 25 Jan 2018 11:33:14 -0700
changeset 30964 2b56d89a8792fc1af6ae66be5f38cd9d26ecb7e1
parent 30620 12a18e736fca9a9ac8e0866caf470fa9342af842
child 32138 4b27cf3e7225d5efbc5ffd1921bf44241972aafa
permissions -rw-r--r--
Bug 1433211: Don't redefine `imapMessageFlagsType` in idl; r=jorgk MozReview-Commit-ID: 7Lc7H2OVysZ Differential Revision:

/* -*- Mode: IDL; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at */

#include "nsISupports.idl"
#include "MailNewsTypes2.idl"
#include "nsIImapUrl.idl" // for imapMessageFlagsType

typedef long nsOfflineImapOperationType;

[scriptable, uuid(b5229a55-22bb-444b-be92-13d719353828)]

interface nsIMsgOfflineImapOperation : nsISupports
// type of stored imap operations
  const long kFlagsChanged      = 0x1;
  const long kMsgMoved          = 0x2;
  const long kMsgCopy           = 0x4;
  const long kMoveResult        = 0x8;
  const long kAppendDraft       = 0x10;
  const long kAddedHeader       = 0x20;
  const long kDeletedMsg        = 0x40;
  const long kMsgMarkedDeleted	= 0x80;
  const long kAppendTemplate    = 0x100;
  const long kDeleteAllMsgs     = 0x200;
  const long kAddKeywords       = 0x400;
  const long kRemoveKeywords    = 0x800;

  attribute nsOfflineImapOperationType operation;
  void clearOperation(in nsOfflineImapOperationType operation);
  attribute nsMsgKey messageKey;

  // for move/copy operations, the msg key of the source msg.
  attribute nsMsgKey srcMessageKey;

  attribute imapMessageFlagsType flagOperation;
  attribute imapMessageFlagsType newFlags; // for kFlagsChanged
  attribute string destinationFolderURI; // for move or copy
  attribute string sourceFolderURI;
  void addKeywordToAdd(in string aKeyword);
  void addKeywordToRemove(in string aKeyword);
  readonly attribute string keywordsToAdd;
  readonly attribute string keywordsToRemove;
  readonly attribute long numberOfCopies;
  void addMessageCopyOperation(in string destinationBox);
  string getCopyDestination(in long copyIndex);
  attribute unsigned long msgSize;
  attribute boolean playingBack;