Apply clang-format to all C, C++ and ObjC files (issue #2171)

This commit is contained in:
Marshall Greenblatt
2017-05-17 11:29:28 +02:00
parent a566549e04
commit 31d9407ee2
1331 changed files with 33014 additions and 32258 deletions

View File

@@ -9,25 +9,27 @@
// implementations. See the translator.README.txt file in the tools directory
// for more information.
//
// $hash=db4176c64eb45165a67d1495aa9222169c6f4c89$
//
#include "libcef_dll/cpptoc/views/browser_view_delegate_cpptoc.h"
#include "libcef_dll/cpptoc/client_cpptoc.h"
#include "libcef_dll/cpptoc/views/browser_view_delegate_cpptoc.h"
#include "libcef_dll/cpptoc/views/view_delegate_cpptoc.h"
#include "libcef_dll/ctocpp/browser_ctocpp.h"
#include "libcef_dll/ctocpp/request_context_ctocpp.h"
#include "libcef_dll/ctocpp/views/browser_view_ctocpp.h"
#include "libcef_dll/ctocpp/views/button_ctocpp.h"
#include "libcef_dll/ctocpp/views/panel_ctocpp.h"
#include "libcef_dll/ctocpp/request_context_ctocpp.h"
#include "libcef_dll/ctocpp/views/scroll_view_ctocpp.h"
#include "libcef_dll/ctocpp/views/textfield_ctocpp.h"
#include "libcef_dll/ctocpp/views/view_ctocpp.h"
#include "libcef_dll/ctocpp/views/window_ctocpp.h"
// STATIC METHODS - Body may be edited by hand.
CefRefPtr<CefBrowserView> CefBrowserView::CreateBrowserView(
CefRefPtr<CefClient> client, const CefString& url,
CefRefPtr<CefClient> client,
const CefString& url,
const CefBrowserSettings& settings,
CefRefPtr<CefRequestContext> request_context,
CefRefPtr<CefBrowserViewDelegate> delegate) {
@@ -37,9 +39,7 @@ CefRefPtr<CefBrowserView> CefBrowserView::CreateBrowserView(
// Execute
cef_browser_view_t* _retval = cef_browser_view_create(
CefClientCppToC::Wrap(client),
url.GetStruct(),
&settings,
CefClientCppToC::Wrap(client), url.GetStruct(), &settings,
CefRequestContextCToCpp::Unwrap(request_context),
CefBrowserViewDelegateCppToC::Wrap(delegate));
@@ -57,14 +57,13 @@ CefRefPtr<CefBrowserView> CefBrowserView::GetForBrowser(
return NULL;
// Execute
cef_browser_view_t* _retval = cef_browser_view_get_for_browser(
CefBrowserCToCpp::Unwrap(browser));
cef_browser_view_t* _retval =
cef_browser_view_get_for_browser(CefBrowserCToCpp::Unwrap(browser));
// Return type: refptr_same
return CefBrowserViewCToCpp::Wrap(_retval);
}
// VIRTUAL METHODS - Body may be edited by hand.
CefRefPtr<CefBrowser> CefBrowserViewCToCpp::GetBrowser() {
@@ -89,8 +88,7 @@ void CefBrowserViewCToCpp::SetPreferAccelerators(bool prefer_accelerators) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
_struct->set_prefer_accelerators(_struct,
prefer_accelerators);
_struct->set_prefer_accelerators(_struct, prefer_accelerators);
}
CefRefPtr<CefBrowserView> CefBrowserViewCToCpp::AsBrowserView() {
@@ -187,8 +185,7 @@ CefString CefBrowserViewCToCpp::ToString(bool include_children) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
cef_string_userfree_t _retval = _struct->to_string(_struct,
include_children);
cef_string_userfree_t _retval = _struct->to_string(_struct, include_children);
// Return type: string
CefString _retvalStr;
@@ -207,7 +204,7 @@ bool CefBrowserViewCToCpp::IsValid() {
int _retval = _struct->is_valid(_struct);
// Return type: bool
return _retval?true:false;
return _retval ? true : false;
}
bool CefBrowserViewCToCpp::IsAttached() {
@@ -221,7 +218,7 @@ bool CefBrowserViewCToCpp::IsAttached() {
int _retval = _struct->is_attached(_struct);
// Return type: bool
return _retval?true:false;
return _retval ? true : false;
}
bool CefBrowserViewCToCpp::IsSame(CefRefPtr<CefView> that) {
@@ -237,11 +234,10 @@ bool CefBrowserViewCToCpp::IsSame(CefRefPtr<CefView> that) {
return false;
// Execute
int _retval = _struct->is_same(_struct,
CefViewCToCpp::Unwrap(that));
int _retval = _struct->is_same(_struct, CefViewCToCpp::Unwrap(that));
// Return type: bool
return _retval?true:false;
return _retval ? true : false;
}
CefRefPtr<CefViewDelegate> CefBrowserViewCToCpp::GetDelegate() {
@@ -294,8 +290,7 @@ void CefBrowserViewCToCpp::SetID(int id) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
_struct->set_id(_struct,
id);
_struct->set_id(_struct, id);
}
int CefBrowserViewCToCpp::GetGroupID() {
@@ -320,8 +315,7 @@ void CefBrowserViewCToCpp::SetGroupID(int group_id) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
_struct->set_group_id(_struct,
group_id);
_struct->set_group_id(_struct, group_id);
}
CefRefPtr<CefView> CefBrowserViewCToCpp::GetParentView() {
@@ -346,8 +340,7 @@ CefRefPtr<CefView> CefBrowserViewCToCpp::GetViewForID(int id) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
cef_view_t* _retval = _struct->get_view_for_id(_struct,
id);
cef_view_t* _retval = _struct->get_view_for_id(_struct, id);
// Return type: refptr_same
return CefViewCToCpp::Wrap(_retval);
@@ -361,8 +354,7 @@ void CefBrowserViewCToCpp::SetBounds(const CefRect& bounds) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
_struct->set_bounds(_struct,
&bounds);
_struct->set_bounds(_struct, &bounds);
}
CefRect CefBrowserViewCToCpp::GetBounds() {
@@ -401,8 +393,7 @@ void CefBrowserViewCToCpp::SetSize(const CefSize& size) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
_struct->set_size(_struct,
&size);
_struct->set_size(_struct, &size);
}
CefSize CefBrowserViewCToCpp::GetSize() {
@@ -427,8 +418,7 @@ void CefBrowserViewCToCpp::SetPosition(const CefPoint& position) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
_struct->set_position(_struct,
&position);
_struct->set_position(_struct, &position);
}
CefPoint CefBrowserViewCToCpp::GetPosition() {
@@ -506,8 +496,7 @@ int CefBrowserViewCToCpp::GetHeightForWidth(int width) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
int _retval = _struct->get_height_for_width(_struct,
width);
int _retval = _struct->get_height_for_width(_struct, width);
// Return type: simple
return _retval;
@@ -532,8 +521,7 @@ void CefBrowserViewCToCpp::SetVisible(bool visible) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
_struct->set_visible(_struct,
visible);
_struct->set_visible(_struct, visible);
}
bool CefBrowserViewCToCpp::IsVisible() {
@@ -547,7 +535,7 @@ bool CefBrowserViewCToCpp::IsVisible() {
int _retval = _struct->is_visible(_struct);
// Return type: bool
return _retval?true:false;
return _retval ? true : false;
}
bool CefBrowserViewCToCpp::IsDrawn() {
@@ -561,7 +549,7 @@ bool CefBrowserViewCToCpp::IsDrawn() {
int _retval = _struct->is_drawn(_struct);
// Return type: bool
return _retval?true:false;
return _retval ? true : false;
}
void CefBrowserViewCToCpp::SetEnabled(bool enabled) {
@@ -572,8 +560,7 @@ void CefBrowserViewCToCpp::SetEnabled(bool enabled) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
_struct->set_enabled(_struct,
enabled);
_struct->set_enabled(_struct, enabled);
}
bool CefBrowserViewCToCpp::IsEnabled() {
@@ -587,7 +574,7 @@ bool CefBrowserViewCToCpp::IsEnabled() {
int _retval = _struct->is_enabled(_struct);
// Return type: bool
return _retval?true:false;
return _retval ? true : false;
}
void CefBrowserViewCToCpp::SetFocusable(bool focusable) {
@@ -598,8 +585,7 @@ void CefBrowserViewCToCpp::SetFocusable(bool focusable) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
_struct->set_focusable(_struct,
focusable);
_struct->set_focusable(_struct, focusable);
}
bool CefBrowserViewCToCpp::IsFocusable() {
@@ -613,7 +599,7 @@ bool CefBrowserViewCToCpp::IsFocusable() {
int _retval = _struct->is_focusable(_struct);
// Return type: bool
return _retval?true:false;
return _retval ? true : false;
}
bool CefBrowserViewCToCpp::IsAccessibilityFocusable() {
@@ -627,7 +613,7 @@ bool CefBrowserViewCToCpp::IsAccessibilityFocusable() {
int _retval = _struct->is_accessibility_focusable(_struct);
// Return type: bool
return _retval?true:false;
return _retval ? true : false;
}
void CefBrowserViewCToCpp::RequestFocus() {
@@ -649,8 +635,7 @@ void CefBrowserViewCToCpp::SetBackgroundColor(cef_color_t color) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
_struct->set_background_color(_struct,
color);
_struct->set_background_color(_struct, color);
}
cef_color_t CefBrowserViewCToCpp::GetBackgroundColor() {
@@ -675,11 +660,10 @@ bool CefBrowserViewCToCpp::ConvertPointToScreen(CefPoint& point) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
int _retval = _struct->convert_point_to_screen(_struct,
&point);
int _retval = _struct->convert_point_to_screen(_struct, &point);
// Return type: bool
return _retval?true:false;
return _retval ? true : false;
}
bool CefBrowserViewCToCpp::ConvertPointFromScreen(CefPoint& point) {
@@ -690,11 +674,10 @@ bool CefBrowserViewCToCpp::ConvertPointFromScreen(CefPoint& point) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
int _retval = _struct->convert_point_from_screen(_struct,
&point);
int _retval = _struct->convert_point_from_screen(_struct, &point);
// Return type: bool
return _retval?true:false;
return _retval ? true : false;
}
bool CefBrowserViewCToCpp::ConvertPointToWindow(CefPoint& point) {
@@ -705,11 +688,10 @@ bool CefBrowserViewCToCpp::ConvertPointToWindow(CefPoint& point) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
int _retval = _struct->convert_point_to_window(_struct,
&point);
int _retval = _struct->convert_point_to_window(_struct, &point);
// Return type: bool
return _retval?true:false;
return _retval ? true : false;
}
bool CefBrowserViewCToCpp::ConvertPointFromWindow(CefPoint& point) {
@@ -720,15 +702,14 @@ bool CefBrowserViewCToCpp::ConvertPointFromWindow(CefPoint& point) {
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
// Execute
int _retval = _struct->convert_point_from_window(_struct,
&point);
int _retval = _struct->convert_point_from_window(_struct, &point);
// Return type: bool
return _retval?true:false;
return _retval ? true : false;
}
bool CefBrowserViewCToCpp::ConvertPointToView(CefRefPtr<CefView> view,
CefPoint& point) {
CefPoint& point) {
cef_view_t* _struct = reinterpret_cast<cef_view_t*>(GetStruct());
if (CEF_MEMBER_MISSING(_struct, convert_point_to_view))
return false;
@@ -741,16 +722,15 @@ bool CefBrowserViewCToCpp::ConvertPointToView(CefRefPtr<CefView> view,
return false;
// Execute
int _retval = _struct->convert_point_to_view(_struct,
CefViewCToCpp::Unwrap(view),
&point);
int _retval = _struct->convert_point_to_view(
_struct, CefViewCToCpp::Unwrap(view), &point);
// Return type: bool
return _retval?true:false;
return _retval ? true : false;
}
bool CefBrowserViewCToCpp::ConvertPointFromView(CefRefPtr<CefView> view,
CefPoint& point) {
CefPoint& point) {
cef_view_t* _struct = reinterpret_cast<cef_view_t*>(GetStruct());
if (CEF_MEMBER_MISSING(_struct, convert_point_from_view))
return false;
@@ -763,31 +743,34 @@ bool CefBrowserViewCToCpp::ConvertPointFromView(CefRefPtr<CefView> view,
return false;
// Execute
int _retval = _struct->convert_point_from_view(_struct,
CefViewCToCpp::Unwrap(view),
&point);
int _retval = _struct->convert_point_from_view(
_struct, CefViewCToCpp::Unwrap(view), &point);
// Return type: bool
return _retval?true:false;
return _retval ? true : false;
}
// CONSTRUCTOR - Do not edit by hand.
CefBrowserViewCToCpp::CefBrowserViewCToCpp() {
}
CefBrowserViewCToCpp::CefBrowserViewCToCpp() {}
template<> cef_browser_view_t* CefCToCppRefCounted<CefBrowserViewCToCpp,
CefBrowserView, cef_browser_view_t>::UnwrapDerived(CefWrapperType type,
CefBrowserView* c) {
template <>
cef_browser_view_t*
CefCToCppRefCounted<CefBrowserViewCToCpp, CefBrowserView, cef_browser_view_t>::
UnwrapDerived(CefWrapperType type, CefBrowserView* c) {
NOTREACHED() << "Unexpected class type: " << type;
return NULL;
}
#if DCHECK_IS_ON()
template<> base::AtomicRefCount CefCToCppRefCounted<CefBrowserViewCToCpp,
CefBrowserView, cef_browser_view_t>::DebugObjCt = 0;
template <>
base::AtomicRefCount CefCToCppRefCounted<CefBrowserViewCToCpp,
CefBrowserView,
cef_browser_view_t>::DebugObjCt = 0;
#endif
template<> CefWrapperType CefCToCppRefCounted<CefBrowserViewCToCpp,
CefBrowserView, cef_browser_view_t>::kWrapperType = WT_BROWSER_VIEW;
template <>
CefWrapperType CefCToCppRefCounted<CefBrowserViewCToCpp,
CefBrowserView,
cef_browser_view_t>::kWrapperType =
WT_BROWSER_VIEW;