2016-07-03 03:26:43 +00:00
|
|
|
// Copyright (c) 2016 GitHub, Inc.
|
|
|
|
// Use of this source code is governed by the MIT license that can be
|
|
|
|
// found in the LICENSE file.
|
|
|
|
|
2021-11-22 07:34:31 +00:00
|
|
|
#ifndef ELECTRON_SHELL_BROWSER_UI_DRAG_UTIL_H_
|
|
|
|
#define ELECTRON_SHELL_BROWSER_UI_DRAG_UTIL_H_
|
2016-07-03 03:26:43 +00:00
|
|
|
|
2020-10-27 21:28:43 +00:00
|
|
|
#include <memory>
|
2016-07-03 04:58:31 +00:00
|
|
|
#include <vector>
|
|
|
|
|
2020-10-27 21:28:43 +00:00
|
|
|
#include "shell/common/api/api.mojom.h"
|
|
|
|
#include "third_party/skia/include/core/SkRegion.h"
|
2016-07-03 03:26:43 +00:00
|
|
|
#include "ui/gfx/image/image.h"
|
|
|
|
|
|
|
|
namespace base {
|
|
|
|
class FilePath;
|
|
|
|
}
|
|
|
|
|
|
|
|
namespace electron {
|
|
|
|
|
2016-07-03 04:58:31 +00:00
|
|
|
void DragFileItems(const std::vector<base::FilePath>& files,
|
|
|
|
const gfx::Image& icon,
|
|
|
|
gfx::NativeView view);
|
2016-07-03 03:26:43 +00:00
|
|
|
|
2020-10-27 21:28:43 +00:00
|
|
|
// Convert draggable regions in raw format to SkRegion format.
|
|
|
|
std::unique_ptr<SkRegion> DraggableRegionsToSkRegion(
|
|
|
|
const std::vector<mojom::DraggableRegionPtr>& regions);
|
|
|
|
|
2016-07-03 03:26:43 +00:00
|
|
|
} // namespace electron
|
|
|
|
|
2021-11-22 07:34:31 +00:00
|
|
|
#endif // ELECTRON_SHELL_BROWSER_UI_DRAG_UTIL_H_
|