summaryrefslogtreecommitdiffstats
path: root/ppapi/shared_impl/ppb_flash_shared.cc
blob: c0504bf6a7fed933efb80a9344c6b472a79dd540 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "ppapi/shared_impl/ppb_flash_shared.h"

namespace ppapi {

PPB_Flash_Shared::PPB_Flash_Shared() {
}

PPB_Flash_Shared::~PPB_Flash_Shared() {
}

// static
bool PPB_Flash_Shared::IsValidClipboardType(
    PP_Flash_Clipboard_Type clipboard_type) {
  return clipboard_type == PP_FLASH_CLIPBOARD_TYPE_STANDARD ||
         clipboard_type == PP_FLASH_CLIPBOARD_TYPE_SELECTION;
}

// static
bool PPB_Flash_Shared::IsValidClipboardFormat(
    PP_Flash_Clipboard_Format format) {
  // Purposely excludes |PP_FLASH_CLIPBOARD_FORMAT_INVALID|.
  return format == PP_FLASH_CLIPBOARD_FORMAT_PLAINTEXT ||
         format == PP_FLASH_CLIPBOARD_FORMAT_HTML ||
         format == PP_FLASH_CLIPBOARD_FORMAT_RTF;
}

}  // namespace ppapi