- Auto-generate all C/C++ translation code (issue #33).

- Change index parameter types from int to size_t to make 0-based range implicit.
- Make CefPrintOptions and CefMenuInfo proper wrapper classes.
- Normalize the naming of menu-related types.
- Remove unused command_line variable from test_suite.cc.

git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@408 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
Marshall Greenblatt
2011-12-08 01:38:30 +00:00
parent b4653ce1da
commit 64e08c2918
238 changed files with 14703 additions and 4322 deletions

View File

@ -4,8 +4,8 @@
//
// ---------------------------------------------------------------------------
//
// A portion of this file was generated by the CEF translator tool. When
// making changes by hand only do so within the body of existing function
// 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.
//
@ -17,46 +17,89 @@
// MEMBER FUNCTIONS - Body may be edited by hand.
int CEF_CALLBACK menu_handler_on_before_menu(struct _cef_menu_handler_t* self,
cef_browser_t* browser, const cef_handler_menuinfo_t* menuInfo)
cef_browser_t* browser, const struct _cef_menu_info_t* menuInfo)
{
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
DCHECK(self);
if (!self)
return 0;
// Verify param: browser; type: refptr_diff
DCHECK(browser);
if (!browser)
return 0;
// Verify param: menuInfo; type: struct_byref_const
DCHECK(menuInfo);
if (!self || !browser || !menuInfo)
if (!menuInfo)
return 0;
return CefMenuHandlerCppToC::Get(self)->OnBeforeMenu(
CefBrowserCToCpp::Wrap(browser), *menuInfo);
// Translate param: menuInfo; type: struct_byref_const
CefMenuInfo menuInfoObj;
if (menuInfo)
menuInfoObj.Set(*menuInfo, false);
// Execute
bool _retval = CefMenuHandlerCppToC::Get(self)->OnBeforeMenu(
CefBrowserCToCpp::Wrap(browser),
menuInfoObj);
// Return type: bool
return _retval;
}
void CEF_CALLBACK menu_handler_get_menu_label(struct _cef_menu_handler_t* self,
cef_browser_t* browser, enum cef_handler_menuid_t menuId,
cef_string_t* label)
cef_browser_t* browser, enum cef_menu_id_t menuId, cef_string_t* label)
{
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
DCHECK(self);
if (!self)
return;
// Verify param: browser; type: refptr_diff
DCHECK(browser);
if (!browser)
return;
// Verify param: label; type: string_byref
DCHECK(label);
if (!self || !browser || !label)
if (!label)
return;
// Translate param: label; type: string_byref
CefString labelStr(label);
// Execute
CefMenuHandlerCppToC::Get(self)->GetMenuLabel(
CefBrowserCToCpp::Wrap(browser), menuId, labelStr);
CefBrowserCToCpp::Wrap(browser),
menuId,
labelStr);
}
int CEF_CALLBACK menu_handler_on_menu_action(struct _cef_menu_handler_t* self,
cef_browser_t* browser, enum cef_handler_menuid_t menuId)
cef_browser_t* browser, enum cef_menu_id_t menuId)
{
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
DCHECK(self);
if (!self)
return 0;
// Verify param: browser; type: refptr_diff
DCHECK(browser);
if (!self || !browser)
if (!browser)
return 0;
return CefMenuHandlerCppToC::Get(self)->OnMenuAction(
CefBrowserCToCpp::Wrap(browser), menuId);
// Execute
bool _retval = CefMenuHandlerCppToC::Get(self)->OnMenuAction(
CefBrowserCToCpp::Wrap(browser),
menuId);
// Return type: bool
return _retval;
}
// CONSTRUCTOR - Do not edit by hand.
CefMenuHandlerCppToC::CefMenuHandlerCppToC(CefMenuHandler* cls)