2019-01-10 15:22:19 +01:00
|
|
|
// Copyright (c) 2019 The Chromium Embedded Framework Authors. All rights
|
2012-04-03 03:34:16 +02:00
|
|
|
// reserved. Use of this source code is governed by a BSD-style license that
|
|
|
|
// can be found in the LICENSE file.
|
|
|
|
//
|
|
|
|
// ---------------------------------------------------------------------------
|
|
|
|
//
|
|
|
|
// This file was generated by the CEF translator tool. If making changes by
|
|
|
|
// hand only do so within the body of existing method and function
|
|
|
|
// implementations. See the translator.README.txt file in the tools directory
|
|
|
|
// for more information.
|
|
|
|
//
|
2019-02-25 22:17:28 +01:00
|
|
|
// $hash=d9a6d69ef996bfb961d0b675fe37e5a2b23b12cc$
|
2017-05-17 11:29:28 +02:00
|
|
|
//
|
2012-04-03 03:34:16 +02:00
|
|
|
|
|
|
|
#ifndef CEF_LIBCEF_DLL_CTOCPP_BROWSER_HOST_CTOCPP_H_
|
|
|
|
#define CEF_LIBCEF_DLL_CTOCPP_BROWSER_HOST_CTOCPP_H_
|
|
|
|
#pragma once
|
|
|
|
|
2016-11-18 00:52:42 +01:00
|
|
|
#if !defined(WRAPPING_CEF_SHARED)
|
|
|
|
#error This file can be included wrapper-side only
|
|
|
|
#endif
|
2012-04-03 03:34:16 +02:00
|
|
|
|
2012-10-16 21:28:07 +02:00
|
|
|
#include <vector>
|
2012-04-03 03:34:16 +02:00
|
|
|
#include "include/capi/cef_browser_capi.h"
|
|
|
|
#include "include/capi/cef_client_capi.h"
|
2017-05-17 11:29:28 +02:00
|
|
|
#include "include/cef_browser.h"
|
|
|
|
#include "include/cef_client.h"
|
2017-02-09 23:07:43 +01:00
|
|
|
#include "libcef_dll/ctocpp/ctocpp_ref_counted.h"
|
2012-04-03 03:34:16 +02:00
|
|
|
|
|
|
|
// Wrap a C structure with a C++ class.
|
|
|
|
// This class may be instantiated and accessed wrapper-side only.
|
2017-05-17 11:29:28 +02:00
|
|
|
class CefBrowserHostCToCpp : public CefCToCppRefCounted<CefBrowserHostCToCpp,
|
|
|
|
CefBrowserHost,
|
|
|
|
cef_browser_host_t> {
|
2012-04-03 03:34:16 +02:00
|
|
|
public:
|
2015-04-26 20:40:01 +02:00
|
|
|
CefBrowserHostCToCpp();
|
2019-01-23 16:42:12 +01:00
|
|
|
virtual ~CefBrowserHostCToCpp();
|
2012-04-03 03:34:16 +02:00
|
|
|
|
2015-04-26 20:40:01 +02:00
|
|
|
// CefBrowserHost methods.
|
|
|
|
CefRefPtr<CefBrowser> GetBrowser() OVERRIDE;
|
|
|
|
void CloseBrowser(bool force_close) OVERRIDE;
|
2016-01-19 21:09:01 +01:00
|
|
|
bool TryCloseBrowser() OVERRIDE;
|
2015-04-26 20:40:01 +02:00
|
|
|
void SetFocus(bool focus) OVERRIDE;
|
|
|
|
CefWindowHandle GetWindowHandle() OVERRIDE;
|
|
|
|
CefWindowHandle GetOpenerWindowHandle() OVERRIDE;
|
2016-01-19 21:09:01 +01:00
|
|
|
bool HasView() OVERRIDE;
|
2015-04-26 20:40:01 +02:00
|
|
|
CefRefPtr<CefClient> GetClient() OVERRIDE;
|
|
|
|
CefRefPtr<CefRequestContext> GetRequestContext() OVERRIDE;
|
|
|
|
double GetZoomLevel() OVERRIDE;
|
|
|
|
void SetZoomLevel(double zoomLevel) OVERRIDE;
|
2017-05-17 11:29:28 +02:00
|
|
|
void RunFileDialog(FileDialogMode mode,
|
|
|
|
const CefString& title,
|
|
|
|
const CefString& default_file_path,
|
|
|
|
const std::vector<CefString>& accept_filters,
|
|
|
|
int selected_accept_filter,
|
|
|
|
CefRefPtr<CefRunFileDialogCallback> callback) OVERRIDE;
|
2015-04-26 20:40:01 +02:00
|
|
|
void StartDownload(const CefString& url) OVERRIDE;
|
2017-05-17 11:29:28 +02:00
|
|
|
void DownloadImage(const CefString& image_url,
|
|
|
|
bool is_favicon,
|
|
|
|
uint32 max_image_size,
|
|
|
|
bool bypass_cache,
|
|
|
|
CefRefPtr<CefDownloadImageCallback> callback) OVERRIDE;
|
2015-04-26 20:40:01 +02:00
|
|
|
void Print() OVERRIDE;
|
2017-05-17 11:29:28 +02:00
|
|
|
void PrintToPDF(const CefString& path,
|
|
|
|
const CefPdfPrintSettings& settings,
|
|
|
|
CefRefPtr<CefPdfPrintCallback> callback) OVERRIDE;
|
|
|
|
void Find(int identifier,
|
|
|
|
const CefString& searchText,
|
|
|
|
bool forward,
|
|
|
|
bool matchCase,
|
|
|
|
bool findNext) OVERRIDE;
|
2015-04-26 20:40:01 +02:00
|
|
|
void StopFinding(bool clearSelection) OVERRIDE;
|
|
|
|
void ShowDevTools(const CefWindowInfo& windowInfo,
|
2017-05-17 11:29:28 +02:00
|
|
|
CefRefPtr<CefClient> client,
|
|
|
|
const CefBrowserSettings& settings,
|
|
|
|
const CefPoint& inspect_element_at) OVERRIDE;
|
2015-04-26 20:40:01 +02:00
|
|
|
void CloseDevTools() OVERRIDE;
|
2016-06-10 20:33:07 +02:00
|
|
|
bool HasDevTools() OVERRIDE;
|
2015-04-26 20:40:01 +02:00
|
|
|
void GetNavigationEntries(CefRefPtr<CefNavigationEntryVisitor> visitor,
|
2017-05-17 11:29:28 +02:00
|
|
|
bool current_only) OVERRIDE;
|
2015-04-26 20:40:01 +02:00
|
|
|
void SetMouseCursorChangeDisabled(bool disabled) OVERRIDE;
|
|
|
|
bool IsMouseCursorChangeDisabled() OVERRIDE;
|
|
|
|
void ReplaceMisspelling(const CefString& word) OVERRIDE;
|
|
|
|
void AddWordToDictionary(const CefString& word) OVERRIDE;
|
|
|
|
bool IsWindowRenderingDisabled() OVERRIDE;
|
|
|
|
void WasResized() OVERRIDE;
|
|
|
|
void WasHidden(bool hidden) OVERRIDE;
|
|
|
|
void NotifyScreenInfoChanged() OVERRIDE;
|
|
|
|
void Invalidate(PaintElementType type) OVERRIDE;
|
2018-07-03 02:46:03 +02:00
|
|
|
void SendExternalBeginFrame() OVERRIDE;
|
2015-04-26 20:40:01 +02:00
|
|
|
void SendKeyEvent(const CefKeyEvent& event) OVERRIDE;
|
2017-05-17 11:29:28 +02:00
|
|
|
void SendMouseClickEvent(const CefMouseEvent& event,
|
|
|
|
MouseButtonType type,
|
|
|
|
bool mouseUp,
|
|
|
|
int clickCount) OVERRIDE;
|
2015-04-26 20:40:01 +02:00
|
|
|
void SendMouseMoveEvent(const CefMouseEvent& event, bool mouseLeave) OVERRIDE;
|
2017-05-17 11:29:28 +02:00
|
|
|
void SendMouseWheelEvent(const CefMouseEvent& event,
|
|
|
|
int deltaX,
|
|
|
|
int deltaY) OVERRIDE;
|
2019-02-25 22:17:28 +01:00
|
|
|
void SendTouchEvent(const CefTouchEvent& event) OVERRIDE;
|
2015-04-26 20:40:01 +02:00
|
|
|
void SendFocusEvent(bool setFocus) OVERRIDE;
|
|
|
|
void SendCaptureLostEvent() OVERRIDE;
|
|
|
|
void NotifyMoveOrResizeStarted() OVERRIDE;
|
2015-05-13 17:43:50 +02:00
|
|
|
int GetWindowlessFrameRate() OVERRIDE;
|
|
|
|
void SetWindowlessFrameRate(int frame_rate) OVERRIDE;
|
2016-10-28 18:11:24 +02:00
|
|
|
void ImeSetComposition(const CefString& text,
|
2017-05-17 11:29:28 +02:00
|
|
|
const std::vector<CefCompositionUnderline>& underlines,
|
|
|
|
const CefRange& replacement_range,
|
|
|
|
const CefRange& selection_range) OVERRIDE;
|
|
|
|
void ImeCommitText(const CefString& text,
|
|
|
|
const CefRange& replacement_range,
|
|
|
|
int relative_cursor_pos) OVERRIDE;
|
2016-10-28 18:11:24 +02:00
|
|
|
void ImeFinishComposingText(bool keep_selection) OVERRIDE;
|
|
|
|
void ImeCancelComposition() OVERRIDE;
|
2015-04-26 20:40:01 +02:00
|
|
|
void DragTargetDragEnter(CefRefPtr<CefDragData> drag_data,
|
2017-05-17 11:29:28 +02:00
|
|
|
const CefMouseEvent& event,
|
|
|
|
DragOperationsMask allowed_ops) OVERRIDE;
|
2015-04-26 20:40:01 +02:00
|
|
|
void DragTargetDragOver(const CefMouseEvent& event,
|
2017-05-17 11:29:28 +02:00
|
|
|
DragOperationsMask allowed_ops) OVERRIDE;
|
2015-04-26 20:40:01 +02:00
|
|
|
void DragTargetDragLeave() OVERRIDE;
|
|
|
|
void DragTargetDrop(const CefMouseEvent& event) OVERRIDE;
|
|
|
|
void DragSourceEndedAt(int x, int y, DragOperationsMask op) OVERRIDE;
|
|
|
|
void DragSourceSystemDragEnded() OVERRIDE;
|
2016-09-02 12:01:33 +02:00
|
|
|
CefRefPtr<CefNavigationEntry> GetVisibleNavigationEntry() OVERRIDE;
|
2017-05-12 20:28:25 +02:00
|
|
|
void SetAccessibilityState(cef_state_t accessibility_state) OVERRIDE;
|
2017-08-04 00:55:19 +02:00
|
|
|
void SetAutoResizeEnabled(bool enabled,
|
|
|
|
const CefSize& min_size,
|
|
|
|
const CefSize& max_size) OVERRIDE;
|
|
|
|
CefRefPtr<CefExtension> GetExtension() OVERRIDE;
|
|
|
|
bool IsBackgroundHost() OVERRIDE;
|
2019-02-26 17:44:17 +01:00
|
|
|
void SetAudioMuted(bool mute) OVERRIDE;
|
|
|
|
bool IsAudioMuted() OVERRIDE;
|
2012-04-03 03:34:16 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // CEF_LIBCEF_DLL_CTOCPP_BROWSER_HOST_CTOCPP_H_
|