Commit Graph

311 Commits

Author SHA1 Message Date
Marshall Greenblatt 06e73fff15 Implement Views framework on Windows and Linux (issue #1749).
- Add Views header files in a new include/views directory.
- Add initial top-level window (CefWindow), control (CefBrowserView,
  CefLabelButton, CefMenuButton, CefPanel, CefScrollView,
  CefTextfield) and layout (CefBoxLayout, CefFlowLayout) support.
  See libcef/browser/views/view_impl.h comments for implementation
  details.
- Add Views example usage in cefclient and cefsimple and Views unit
  tests in cef_unittests. Pass the `--use-views` command-line flag to
  cefclient, cefsimple and cef_unittests to run using the Views
  framework instead of platform APIs. For cefclient and cefsimple
  this will create the browser window and all related functionality
  using the Views framework. For cef_unittests this will run all
  tests (except OSR tests) in a Views-based browser window. Views-
  specific unit tests (`--gtest_filter=Views*`) will be run even if
  the the `--use-views` flag is not specified.
- Pass the `--hide-frame` command-line flag to cefclient to demo a
  frameless Views-based browser window.
- Pass the `--hide-controls` command-line flag to cefclient to demo a
  browser window without top controls. This also works in non-Views
  mode.
- Pass the `--enable-high-dpi-support` command-line flag to
  cef_unittests on Windows to test high-DPI support on a display
  that supports it.
- Add CefImage for reading/writing image file formats.
- Add CefBrowser::DownloadImage() for downloading image URLs as a
  CefImage representation. This is primarily for loading favicons.
- Add CefMenuModel::CreateMenuModel() and CefMenuModelDelegate for
  creating custom menus. This is primarily for use with
  CefMenuButton.
- Add CefBrowser::TryCloseBrowser() helper for closing a browser.
  Also improve related documentation in cef_life_span_handler.h.
- Rename cef_page_range_t to cef_range_t. It is now also used by
  CefTextfield.
- Remove CefLifeSpanHandler::RunModal() which is never called.
- Add draggable regions example to cefclient.
2016-04-26 11:58:13 -04:00
Marshall Greenblatt 243a9c26d7 Update to Chromium revision 0bfd25d4 (#381305)
- Delete include/cef_runnable.h (issue #1336).
- Build the cef_unittests target using all Chromium headers. Add a
  USING_CHROMIUM_INCLUDES define and libcef_dll_wrapper_unittests
  target to support this. This change avoids compile errors due to
  the divergence of CEF and Chromium base/ header implementations.
  The libcef_dll_wrapper sources must now compile successfully with
  both CEF and Chromium base/ headers (issue #1632).
- The onbeforeunload message specified via JavaScript is no longer
  passed to the client (see http://crbug.com/587940).
2016-03-17 13:01:21 -04:00
Marshall Greenblatt a1d9c22b58 Add DNS resolution methods to CefRequestContext (issue #1841) 2016-02-23 18:37:35 -05:00
Marshall Greenblatt fabd3db33e Allow clients to clear certificate exceptions and close connections (issue #1793) 2016-02-23 14:32:07 -05:00
Marshall Greenblatt f7aa98fe69 Update to Chromium revision 088f14a0 (#373530)
- Building on Windows now requires the Windows 10.0.10586 SDK.
- Remove CefParseCSSColor which was implemented using Blink code in the
  browser process. This is longer advisable now that the Oilpan GC is enabled.
- Avoid potential renderer process crashes by disabling script actions
  on the CefV8Context passed to CefRenderProcessHandler::OnContextReleased.
2016-02-08 13:16:11 -05:00
Marshall Greenblatt ff8c5a6caa Update generated file copyright year 2016-01-08 14:00:27 -05:00
Marshall Greenblatt 12f19e3a33 Expose additional SSL certificate information.
- Provide access to the full certificate issuer chain (issue #1530)
- Add several missing certificate error codes to cef_errorcode_t (issue #1784)
- Provide the full certificate status bitmask (issue #1790)
2015-12-18 14:05:42 -05:00
Marshall Greenblatt 07e845ed31 CefRequestHandler::GetAuthCredentials |scheme| argument is optional for FTP sources (issue #1794) 2015-12-17 13:24:22 -05:00
Marshall Greenblatt f207a555a3 Add support for response filtering (issue #515).
- Add a new CefRequestHandler::GetResourceResponseFilter method and
  CefResponseFilter class.
2015-12-08 13:47:52 -05:00
Marshall Greenblatt 626fc561ca Add new CefRequestHandler::OnResourceLoadComplete callback (issue #1781) 2015-12-04 13:59:14 -05:00
Marshall Greenblatt 9bc8da1e02 - Add CefPostData::HasExcludedElements which returns true if the underlying
POST data includes elements that are not represented (issue #1761).
- Add CefRequest::SetReferrer and CefRequest::GetReferrer[URL|Policy]. The
  Referer value will no longer be stored in the header map.
- Move request-related conversion logic to CefRequestImpl and standardize the
  implementation.
2015-12-02 17:23:16 -05:00
Marshall Greenblatt 694b45717c Windows: Fix VS2008SP1 compiler errors (issue #1758)
- override was being defined but this compiler doesn't support it.
- Warning C4355 wasn't being properly suppressed in cef_resource_manager.cc
2015-11-13 11:19:27 -05:00
Marshall Greenblatt c6111d5947 Update to Chromium revision 304f01a1 (#358063)
- Improve ordering of CefLoadHandler callbacks. OnLoadingStateChange will
  be called before and after all calls to OnLoadStart and OnLoadEnd.
  OnLoadStart/OnLoadEnd calls will occur as matching pairs
  (see http://crbug.com/539952#c2).
- Remove the |requesting_url| argument to CefGeolocationHandler::
  OnCancelGeolocationPermission. Clients can use the |request_id| argument
  to track this information themselves.
- Fix a crash when loading the PDF extension in multiple browsers with a
  custom CefRequestContext (issue #1757).
2015-11-11 18:24:00 -05:00
Marshall Greenblatt 70ed95bcca base: Change DCHECK_IS_ON to a macro DCHECK_IS_ON() to match Chromium
changes (see http://crrev.com/e649f573) and fix unit test runtime
errors when building with GYP_DEFINES=dcheck_always_on=1.
2015-10-14 09:40:59 -07:00
Marshall Greenblatt 3f4687a4cd Fix parsing of CefResourceManager::Request::url() when both query
and fragment components are present (issue #1733)
2015-10-13 16:51:52 -04:00
Marshall Greenblatt 1f21fe5412 Add CefPrintHandler::OnPrintStart callback (issue #1736) 2015-10-13 14:04:02 -04:00
Marshall Greenblatt 8aac23386e Update to Chromium revision cb947c01 (#352221)
- Implement CefRequestHandler::OnBeforeBrowse using NavigationThrottle
  instead of ResourceThrottle (see http://crbug.com/537634). The CefRequest
  object passed to OnBeforeBrowse will no longer have an associated request
  identifier.
- Mac: Remove additional helper apps which are no longer required (see
  http://crbug.com/520680)
- Remove the UR_FLAG_REPORT_RAW_HEADERS flag which is no longer supported (see
  http://crbug.com/517114)
- Remove the CefBrowserSettings.java parameter. Java is an NPAPI plugin and
  NPAPI plugins are no longer supported (see http://crbug.com/470301#c11)
- Add CefFormatUrlForSecurityDisplay function in cef_parser.h
- Fix crash when passing `--disable-extensions` command-line flag (issue #1721)
- Linux: Fix NSS handler loading (issue #1727)
2015-10-09 17:31:27 -04:00
Marshall Greenblatt 5780ea8baa Support configuration of preferences during runtime (issue #1709)
- Preferences are now associated with a CefRequestContext instead of
  being stored globally.
- Add methods to CefRequestContext for getting/setting preferences.
2015-10-06 18:14:11 -04:00
Marshall Greenblatt 4149192d81 Call OnBeforePluginLoad when building the plugin list (issue #1708) 2015-09-30 18:09:28 -04:00
Marshall Greenblatt dc3aae19e8 Add plugin placeholder and policy support (issue #1708)
- Default plugin loading policy can be specified using the new
  `--plugin-policy=[allow|block|detect]` command-line flag.
- Move CefRequestHandler::OnBeforePluginLoad to
  CefRequestContextHandler and add a new policy argument that
  supports different actions (allow, block, detect, disable) on a
  per-plugin-instance basis.
- Add CefContextMenuHandler::RunContextMenu for providing a custom
  context menu implementation.
- Add CefResourceBundleHandler::GetDataResourceForScale for
  returning scaled resources (issue #1272).
- Add CefResourceBundle for retrieving resources from the resource
  bundle (*.pak) files loaded by CEF during startup or via the
  CefResourceBundleHandler.
- Linux: Fix Debug build IO access warning with CefGetMimeType.
- cef_unittests: Move the refcounting implementation from TestHandler
  to subclasses in order to support interface inheritance from
  subclasses.
2015-09-22 12:28:46 +03:00
Marshall Greenblatt fda35eae80 Windows: Fix VS2015 build errors in the binary distribution (issue #1692) 2015-08-20 10:22:12 -04:00
Marshall Greenblatt 9e0d84d94a Windows: Add CefEnableHighDPISupport function and fix high-dpi scaling issues (issue #1674) 2015-08-07 16:04:03 -04:00
Marshall Greenblatt 378a64b39a Update to Chromium revision 14bd12d6 (#333041)
- Remove CefNavigationEntry::GetFrameName() (see http://crbug.com/477150#c5).
- Devirtualize base::BindState (see http://crbug.com/486594).
- Move Tuple to the base namespace.
2015-06-08 17:31:50 -04:00
Marshall Greenblatt d820080479 Add fullscreen API support (issue #562) 2015-06-04 18:33:24 -04:00
Alexei Bykov 85f83680d7 Add PDF printing support (issue #1478). 2015-06-04 13:15:26 -04:00
Marshall Greenblatt b6e5310bce Add CefResourceManager class for mapping requests to data providers (issue #1640). 2015-06-03 15:21:40 -04:00
Yu-Teh Shen d02f03a71a Add JSON parsing support (issue #1188). 2015-06-03 15:03:41 -04:00
Felix Bruns c5b8b8b9c8 Add support for draggable regions (issue #1645).
Regions are defined using the '-webkit-app-region: drag/no-drag'
CSS property and passed to the CefDragHandler::
OnDraggableRegionsChanged callback.
2015-06-03 14:48:28 -04:00
Marshall Greenblatt 483a841348 Add a new CefBrowserHost::SetWindowlessFrameRate method to support
dynamic configuration of the windowless frame rate (issue #1629).
2015-05-13 20:42:40 +03:00
Marshall Greenblatt b849e7fb70 Return CefTime instead of time_t from CefZipReader::GetFileLastModified (issue #1625) 2015-05-05 19:12:10 -04:00
Marshall Greenblatt 616fdbf3ff Improve inheritance support in the CEF API (issue #1623).
- Support single parent inheritance in CEF API classes.
- Support non-virtual inheritance in CEF API classes.
- Support translation of CEF API sub-directories.
- Add test sub-directories for testing-only functionality that will be
  available to unit tests but not exposed via the binary distribution.
- Add unit tests for the translator tool.
- Fix parsing of template parameter types that include commas.
2015-05-05 17:16:44 -04:00
Marshall Greenblatt 0369063810 - Add CefValue for wrapping various value types in a single object (issue #1607).
- Add IsSame() and IsEqual() methods for comparing CefValue* types.
- Improve CefValue* documentation.
2015-04-16 15:04:56 +02:00
Marshall Greenblatt ae91d8f4e5 - cefclient: Add `background-color` command-line argument (issue #1161).
- Rename cef_url.h to cef_parser.h.
- Add new CefParseCSSColor function.
2015-04-10 11:35:31 +02:00
Marshall Greenblatt 4a905f1e2b - Allow asynchronous continuation of OnBeforeResourceLoad (issue #1593).
- Use CefRequestCallback for most asynchronous CefRequestHandler methods.
2015-04-08 10:33:49 +02:00
Marshall Greenblatt 7acecd6b6b Change CEF version number format to remove SVN dependency (issue #1580). 2015-03-16 19:34:35 -04:00
Marshall Greenblatt 558a8a3658 Implement improvements for request handling (issue #1327).
- Add a new CefRequestHandler::OnResourceResponse() method for inspecting the request/response headers and potentially restarting or redirecting the request.
- Add a new CefRequest::GetIdentifier() method for tracking a request across multiple CefRequestHandler callbacks.
- Pass a CefRequest object instead of just the old URL to CefRequestHandler::OnResourceRedirect().

git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@2073 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
2015-03-11 18:44:11 +00:00
Marshall Greenblatt 9dc7d2a398 Add a new CefRequestHandler::OnRenderViewReady method which is called when a browser is ready to receive/handle IPC messages in the render process (issue #1564).
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@2055 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
2015-03-09 21:05:22 +00:00
Marshall Greenblatt c49473729d Add a new CefRequestHandler::OnOpenURLFromTab method for handling certain limited cases where navigating a new or different browser might be desirable (issue #1526).
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@2054 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
2015-03-09 20:22:31 +00:00
Marshall Greenblatt 5de989e306 Add target disposition and user gesture parameters to CefLifeSpanHandler::OnBeforePopup (issue #1525).
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@2053 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
2015-03-06 21:38:38 +00:00
Marshall Greenblatt 36fd5e3ed0 Pass the scroll offset to CefRenderHandler::OnScrollOffsetChanged (issue #1561).
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@2052 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
2015-03-06 17:50:14 +00:00
Marshall Greenblatt 5f3df0b702 Add missing initializer to CefStreamResourceHandler constructor (issue #1187).
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@2046 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
2015-03-04 19:01:53 +00:00
Marshall Greenblatt ca0e381681 Add support for complete isolation of storage and permissions (cache, cookies, localStorage, access grants, etc) on a per-request-context basis (issue #1044).
- CefRequestContext instances can be configured using a new CefRequestContextSettings structure passed to CefRequestContext::CreateContext.
- Scheme registration is now per-request-context using new CefRequestContext::RegisterSchemeHandlerFactory and ClearSchemeHandlerFactories methods.
- Cookie managers are now per-request-context by default and can be retrieved using a new CefRequestContext::GetDefaultCookieManager method.
- CefURLRequest::Create now accepts an optional CefRequestContext argument for associating a URL request with a context (browser process only).
- The CefRequestContextHandler associated with a CefRequestContext will not be released until all objects related to that context have been destroyed.
- When the cache path is empty an in-memory cache ("incognito mode") will be used for storage and no data will be persisted to disk.
- Add CefSettings.user_data_path which specifies the location where user data such as spell checking dictionary files will be stored on disk.
- Add asynchronous callbacks for all CefCookieManager methods.
- Add PK_LOCAL_APP_DATA and PK_USER_DATA path keys for retrieving user directories via CefGetPath.
- cefclient: Add "New Window" test that creates a new window unrelated to existing windows. When used in combination with `--request-context-per-browser` the new window will be given a new and isolated request context.

git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@2040 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
2015-03-02 20:25:14 +00:00
Marshall Greenblatt 7c5cb76692 - Pass SSL certificate information to CefRequestHandler::OnCertificateError via a new CefSSLInfo interface (issue #1530).
- cefclient: Improve error message text and use a data: URI instead of LoadString for loading error messages (issue #579).
- Add functions in cef_url.h for base64 and URI encoding/decoding (issue #579).

git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@2028 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
2015-02-11 18:15:04 +00:00
Marshall Greenblatt 3dc9072f58 Update to Chromium revision beafd8cb (#314338).
- Remove unused CefContextMenuHandler::GetMisspellingHash() method.

git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@2020 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
2015-02-04 18:10:14 +00:00
Marshall Greenblatt 4bf08b70d6 Rename .cpp file extensions to .cc for consistency (issue #1500).
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@1981 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
2015-01-22 01:55:39 +00:00
Marshall Greenblatt c71cae325f Add CefDownloadItem::GetOriginalUrl method (issue #1201).
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@1976 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
2015-01-20 22:48:32 +00:00
Marshall Greenblatt e50ea8c29f - Add open folder dialog support (FILE_DIALOG_OPEN_FOLDER mode) for CefBrowserHost::RunFileDialog (issue #1030).
- Standardize file dialog behavior across all platforms (issue #1492).
-- Show a file type filter list on OS X.
-- Show the file extensions as part of the filter list description on all platforms (e.g. "Image Types (*.png;*.gif;*.jpg)").
-- Rename the CefBrowserHost::RunFileDialog |accept_types| argument to |accept_filters| and expand support for filters that will be displayed as-is in addition to the currently supported mime-type and extension-based filters. For example, a filter value of "Supported Image Types|.png;.gif;.jpg" will display "Supported Image Types (*.png;*.gif;*.jpg)" in the filter drop-down list and accept *.png, *.gif and *.jpg files.
-- Persist the selected filter item index by passing a new |selected_accept_filter| argument to CefBrowserHost::RunFileDialog and returning the newly selected index via the CefRunFileDialogCallback and CefFileDialogCallback callbacks.
-- Rename the CefBrowserHost::RunFileDialog |default_file_name| argument to |default_file_path| and use the directory component, if any, to set the default directory location. If |default_file_path| ends in a trailing path separator it will be treated as a directory without a file name component.
-- Add FILE_DIALOG_OVERWRITEPROMPT_FLAG and FILE_DIALOG_HIDEREADONLY_FLAG values to cef_file_dialog_mode_t for controlling those behaviors where possible.

git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@1973 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
2015-01-20 18:24:54 +00:00
Marshall Greenblatt 758d5c23c5 Add CefFindHandler for reporting find results (issue #1482).
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@1969 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
2015-01-12 21:04:08 +00:00
Marshall Greenblatt a2d690a9bd Use int64 instead of uint64 for CefURLRequestClient progress notifications (issue #1202).
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@1968 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
2015-01-12 20:46:31 +00:00
Marshall Greenblatt 833f762273 Add the ability to Pause/Resume downloads via new CefDownloadItemCallback methods (issue #1425).
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@1966 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
2015-01-12 19:47:40 +00:00