summaryrefslogtreecommitdiffstats
path: root/chrome/browser/renderer_host/render_widget_helper.h
Commit message (Collapse)AuthorAgeFilesLines
* Get rid of a bunch of includes to old locations of headers.jam@chromium.org2011-03-021-12/+0
| | | | | | | TBR=avi Review URL: http://codereview.chromium.org/6602061 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@76470 0039d316-1c4b-4281-b951-d872f2087c98
* Move core pieces of browser\renderer_host to src\content.jam@chromium.org2011-02-191-206/+2
| | | | | | | TBR=avi Review URL: http://codereview.chromium.org/6532073 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@75489 0039d316-1c4b-4281-b951-d872f2087c98
* gtk: Improve fullscreen RenderWidgetHostViewGtk.derat@chromium.org2011-02-111-7/+3
| | | | | | | | | | | | | | | | | | | | This was previously using the same code as for popup windows (i.e. <select> and autocomplete), which creates an override-redirect/popup window and grabs the pointer and keyboard. This is the wrong way to make a window fullscreen: since the window is override-redirect, the window manager will ignore the fullscreen request, and since the input is grabbed, other X clients' key grabs (such as Alt-Tab) won't work. This change makes us instead open a regular toplevel window. BUG=chromium-os:11545 TEST=checked that brightness and volume keys work while Pepper Flash is fullscreen and that <select> popups still work Review URL: http://codereview.chromium.org/6462017 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@74534 0039d316-1c4b-4281-b951-d872f2087c98
* Implement the onBeforeRetarget event of the webNavigation APIjochen@chromium.org2011-01-211-8/+5
| | | | | | | | | TEST=none BUG=50943 Review URL: http://codereview.chromium.org/6363002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@72163 0039d316-1c4b-4281-b951-d872f2087c98
* Remove obsolete base/lock.h and fix up callers to use the new header file andbrettw@chromium.org2011-01-211-3/+3
| | | | | | | | | | | the base namespace. Fix several files including lock.h unnecessarily. BUG=none TEST=none Original review=http://codereview.chromium.org/6142009/ Patch by leviw@chromium.org git-svn-id: svn://svn.chromium.org/chrome/trunk/src@72106 0039d316-1c4b-4281-b951-d872f2087c98
* Roll WebKit DEPS past WebKit move. Update gyp files and include paths to ↵abarth@chromium.org2011-01-171-1/+1
| | | | | | reflect the move. Consolidate how we DEPS in WebKit source files. Cross fingers. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@71585 0039d316-1c4b-4281-b951-d872f2087c98
* Move CancellationFlag and WaitableEvent to the synchronization subdirectory.brettw@chromium.org2011-01-021-1/+1
| | | | | | | | TEST=it compiles BUG=none Review URL: http://codereview.chromium.org/5977010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@70369 0039d316-1c4b-4281-b951-d872f2087c98
* Coverity: Pass parameters by reference.jhawkins@chromium.org2010-11-081-1/+1
| | | | | | | | | | | CID=2099,2573,2574,2575,2576,2633,2667, 2673,2674,5148,6514,7758,8059,8060,8071 BUG=none TEST=none Review URL: http://codereview.chromium.org/4527006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@65437 0039d316-1c4b-4281-b951-d872f2087c98
* Use RenderWidget(Host) for full screenboliu@chromium.org2010-08-191-0/+8
| | | | | | | | | | | | | | | | | | | Add RenderWidgetFullscreen(Host) subclasses, InitAsFullscreen method to RenderWidgetHostView, and add two new ipc messages for creating and showing full screen. Add createFullscreenWindow to RenderView that creates RenderWidgetFullscreen and sends message to browser which eventually creates RenderWidgetFullscreenHost. The show method on RenderWidgetFullscreen sends message to parent RenderViewHost in browser, which calls InitAsFullscreen on the view. BUG=16735 TEST=RenderViewHostTest.CreateFullscreenWidget Review URL: http://codereview.chromium.org/3055009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@56690 0039d316-1c4b-4281-b951-d872f2087c98
* `#pragma once` for app, base, chrome, gfx, ipc, net, skia, viewsthakis@chromium.org2010-07-261-0/+1
| | | | | | | | | BUG=50273 TEST=everything still builds, build is 10% faster on windows, same speed on mac/linux TBR: erg git-svn-id: svn://svn.chromium.org/chrome/trunk/src@53716 0039d316-1c4b-4281-b951-d872f2087c98
* Added plumbing to transport the frame name between RenderViewHost and the ↵atwilson@chromium.org2010-06-121-1/+3
| | | | | | | | | | | | | Webkit layer. Extended ViewMsg_New and ViewHostMsg_CreateWindow to have a new frame_name parameter. This allows the RVH to know the initial name of the frame associated with its RenderView, and also to set the name of the frame when creating a new RenderView. Review URL: http://codereview.chromium.org/2775003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@49622 0039d316-1c4b-4281-b951-d872f2087c98
* This is the second side of a multi-sided webkit patch that will allow ↵rafaelw@chromium.org2010-04-281-1/+4
| | | | | | | | | | | | | | | | | experimental window.open feature strings to be captured and passed to the client. It should wait for: https://bugs.webkit.org/show_bug.cgi?id=38013 to land. This is required because this patch needs to use the WebWindowFeature binding struct in WebKit. Once this is landed, a webkit patch to change the call signature for WebViewClient::createView to include the WebWindowFeatures will be submitted (and after that another chromium patch to remove the old call signature). This patch implements old and new WebViewClient::createView signatures, and additionally passes the vector all the way to RenderViewHostDelegateHelper who will eventually use it to observe the 'background' feature. BUG=41275 TEST=all tests should pass Review URL: http://codereview.chromium.org/1758004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@45877 0039d316-1c4b-4281-b951-d872f2087c98
* This adds in the ability for Chrome to generate windows with snapshotsgspencer@chromium.org2010-04-281-1/+1
| | | | | | | | | | | | of all currently open tabs in all browsers. This is needed for overview mode on ChromeOS. BUG=http://code.google.com/p/chromium-os/issues/detail?id=1170 TEST=Ran Chrome under ChromeOS with updated window manager. Review URL: http://codereview.chromium.org/661237 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@45824 0039d316-1c4b-4281-b951-d872f2087c98
* Fix Pepper2D on the Mac so that it runs in the sandbox. Note that trusteddspringer@google.com2010-04-081-2/+8
| | | | | | | | | | | | | plugins still have to run outside of the sandbox (this is not a regression). This CL allows untrusted Pepper 2D plugins to run in the sandbox on the Mac. BUG=40701 TEST=pepper_test_plugin (has to run w/ --no-sandbox on Mac), run any untrusted .nexe that uses Pepper 2D or 3D (examples are inthe NaCl SDK). Review URL: http://codereview.chromium.org/1558032 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@44016 0039d316-1c4b-4281-b951-d872f2087c98
* Adding the new WebPopupType to the RenderWidget creation.jcivelli@google.com2010-04-071-2/+7
| | | | | | | | | BUG=None TEST=Tests that all popups (select popup, autofill, browser actions, bookmark bubble...) work as expected and get the focus correctly. Review URL: http://codereview.chromium.org/1523013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@43845 0039d316-1c4b-4281-b951-d872f2087c98
* Remove dependency from webkit on chrome/common by moving files to src/app.pinkerton@chromium.org2010-03-191-1/+1
| | | | | | | | BUG=37985 TEST=no functional change. Review URL: http://codereview.chromium.org/1060001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42101 0039d316-1c4b-4281-b951-d872f2087c98
* Combine ViewHostMsg_{Paint,Scroll}Rect into one IPC.darin@chromium.org2009-12-211-24/+24
| | | | | | | | | | | | | | | | | | | | | | | | The combined IPC means that scrolling only requires one transport DIB instead of two. Previously, we'd use one in the ScrollRect IPC to pass up the pixels for the exposed region, and then we'd use a second one in the PaintRect IPC to pass up the pixels for the updated scroll bar rendering. Now all paints are done using a single transport DIB. Optimize RenderWidgetHostViewWin::OnPaint to only paint the damaged regions. This means calling GetUpdateRgn and GetRegionData to enumerate the list of damage rects. Then only those rects are copied from the backing store. The same optimization is not done for Linux or Mac yet. R=brettw BUG=29591 TEST=none Originally reviewed at http://codereview.chromium.org/506013 Review URL: http://codereview.chromium.org/509005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@35078 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 34951 - Combine ViewHostMsg_{Paint,Scroll}Rect into one IPC.rsesek@chromium.org2009-12-181-24/+24
| | | | | | | | | | | | | | | | | | | | | | | | | The combined IPC means that scrolling only requires one transport DIB instead of two. Previously, we'd use one in the ScrollRect IPC to pass up the pixels for the exposed region, and then we'd use a second one in the PaintRect IPC to pass up the pixels for the updated scroll bar rendering. Now all paints are done using a single transport DIB. Optimize RenderWidgetHostViewWin::OnPaint to only paint the damaged regions. This means calling GetUpdateRgn and GetRegionData to enumerate the list of damage rects. Then only those rects are copied from the backing store. The same optimization is not done for Linux or Mac yet. R=brettw BUG=29591 TEST=none Review URL: http://codereview.chromium.org/506013 TBR=darin@chromium.org Review URL: http://codereview.chromium.org/506075 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@34953 0039d316-1c4b-4281-b951-d872f2087c98
* Combine ViewHostMsg_{Paint,Scroll}Rect into one IPC.darin@chromium.org2009-12-181-24/+24
| | | | | | | | | | | | | | | | | | | | | | The combined IPC means that scrolling only requires one transport DIB instead of two. Previously, we'd use one in the ScrollRect IPC to pass up the pixels for the exposed region, and then we'd use a second one in the PaintRect IPC to pass up the pixels for the updated scroll bar rendering. Now all paints are done using a single transport DIB. Optimize RenderWidgetHostViewWin::OnPaint to only paint the damaged regions. This means calling GetUpdateRgn and GetRegionData to enumerate the list of damage rects. Then only those rects are copied from the backing store. The same optimization is not done for Linux or Mac yet. R=brettw BUG=29591 TEST=none Review URL: http://codereview.chromium.org/506013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@34951 0039d316-1c4b-4281-b951-d872f2087c98
* Fixes almost all of the rest of lint errors in the chrome/ directory (minus ↵erg@google.com2009-11-131-5/+5
| | | | | | | | the really hard ones which will need actual review instead of rubber-stamping.) Review URL: http://codereview.chromium.org/386026 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@31932 0039d316-1c4b-4281-b951-d872f2087c98
* Eighth patch in making destructors of refcounted objects private.jam@chromium.org2009-11-071-1/+3
| | | | | | | BUG=26749 Review URL: http://codereview.chromium.org/378004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@31339 0039d316-1c4b-4281-b951-d872f2087c98
* Third patch in getting rid of caching MessageLoop pointers and always using ↵jam@chromium.org2009-11-021-4/+0
| | | | | | | | | | ChromeThread instead. BUG=25354 Review URL: http://codereview.chromium.org/342068 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@30687 0039d316-1c4b-4281-b951-d872f2087c98
* Fix deadlock when plugin puts an alert and right afterwards the browser ↵jam@chromium.org2009-09-281-14/+2
| | | | | | | | | | process makes a win32 call that ends up waiting on the plugin. Since the plugin thread is blocked, the Windows message doesn't get dispatched and the browser ui thread deadlocks. The message from the renderer would make the plugin run a nested message loop but it doesn't get run on the browser ui thread since it's blocked. The fix is to set the event that runs nested message loop in the renderer process. BUG=23147 TEST=ui tests already cover nested message loops and plugins. This particular scenario is hard to write a test case for because it's a race condition involving the browser. Review URL: http://codereview.chromium.org/243018 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@27421 0039d316-1c4b-4281-b951-d872f2087c98
* Fix a race condition where rapid back/forward clicks could close a tabbrettw@chromium.org2009-07-241-4/+3
| | | | | | | | | | | | | | | | | | | | | | | This can be triggered when you're on the new tab page, going to *two* other sites, then rapidly hitting back and forward randomly. If a cross-site transition was canceled before the original page responds with an "OK to close me" message, it will mistakenly categorize the close as not just for the RenderView (correspondong to one side of the cross-site transition) but for the entire tab. This change adds an explicit parameter on the messages indicating whether it's for interstials or for the tab so we don't have to rely on the request still being active. This also adds the "requesting process + route" in addition to the "new process + request" so we can be more clear about sending the messages to the correct place. The previous patch conbimed these in a confusing way. BUG=16246 TEST=none Review URL: http://codereview.chromium.org/159255 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21531 0039d316-1c4b-4281-b951-d872f2087c98
* Windowed plugins like Flash would cause the hung plugin dialog to show up ↵ananta@chromium.org2009-07-091-0/+9
| | | | | | | | | | | | | | | when the print dialog was displayed. The proposed fix is to signal the modal dialog event which would ensure that the renderer and plugins both pump messages when the print dialog is displayed. This fixes http://code.google.com/p/chromium/issues/detail?id=13804 Bug=13804 Review URL: http://codereview.chromium.org/155133 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@20243 0039d316-1c4b-4281-b951-d872f2087c98
* Reduce header dependencies in base/phajdan.jr@chromium.org2009-06-031-0/+2
| | | | | | | | Also adds more explicit #includes for needed things. Review URL: http://codereview.chromium.org/118162 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17479 0039d316-1c4b-4281-b951-d872f2087c98
* Various popup UI fixes:pkasting@chromium.org2009-05-081-6/+0
| | | | | | | | | | | | | * Remove "show popup notification" option, pref, and all associated machinery. * Toggling whitelisting on for a site no longer hides the "manage" button. * Toggling whitelisting off for a site re-blocks (not closes) its popups, and does not hide the "manage" button. Also rips the whitelist hooks out of TabContents in preparation for getting the whitelist values directly from the BlockedPopupContainer, since there was no reason to plumb everything through TabContents. BUG=11440 Review URL: http://codereview.chromium.org/115112 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15670 0039d316-1c4b-4281-b951-d872f2087c98
* Replace all occurrances of WebContents with TabContents.brettw@chromium.org2009-05-041-1/+1
| | | | | | Review URL: http://codereview.chromium.org/99177 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15194 0039d316-1c4b-4281-b951-d872f2087c98
* Finish hooking up the worker process UI: use the domains of the workers as ↵jam@chromium.org2009-03-241-2/+4
| | | | | | | | | | the title in the task manager, and show an infobar when a page's workers die. I also cleaned up the code in RenderView which creates a window and widget, since when I originally wrote it I wasn't aware of RenderViewHost::FromID. Review URL: http://codereview.chromium.org/45025 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@12335 0039d316-1c4b-4281-b951-d872f2087c98
* Stop having renderers use both pids and a monotonically increasing ↵jam@chromium.org2009-03-121-2/+4
| | | | | | | | "host_id". This allows ResourceDispatcher to be used by child processes other than renderers. I've done minor related cleanup on the way to make the code simpler. Review URL: http://codereview.chromium.org/42054 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@11509 0039d316-1c4b-4281-b951-d872f2087c98
* Instead of queuing ResourceDispatcher IPC messages in RenderView, use ↵jam@chromium.org2009-03-101-7/+14
| | | | | | | | | | ResourceDispatcherHost's ability to block requests for a given route in the browser process. This is in prepration for switching to one ResourceDispatcher in the renderer process, instead of one per RenderView, to share more code between child processes. I realize that this means that resource requests for RenderViews created by other RenderViews will start a little bit later now (after a hop to the UI thread and back), but I don't think it should lead to much delay (since if our UI thread is that bogged down, we have bigger problems). I'll make sure this is the case by looking at the page cyclers. Review URL: http://codereview.chromium.org/42005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@11370 0039d316-1c4b-4281-b951-d872f2087c98
* POSIX: Rewrite IPC's interaction with FileDescriptoragl@chromium.org2009-03-051-2/+1
| | | | | | | | | | | | | | | | | | | The FileDescriptor API is clearly too hard to use. It's the only IPC data type which is non-POD and serialising an invalid file descriptor is fatal to Chrome on POSIX. The use of Maybe is possibly non-obvious to non-functional programmers. This patch merges Maybe and FileDescriptor so that serialising invalid file descriptors is permitted and results in -1 at the other end. (Serialising /closed/ a file descriptor is still fatal.) Also, it adds a pointer in base/file_descriptor.h to instructions for its use with IPC. Although it's generally bad practice to mention IPC in base, in this case I cannot find another suitable location. Review URL: http://codereview.chromium.org/39208 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@11041 0039d316-1c4b-4281-b951-d872f2087c98
* Bitmap transportagl@chromium.org2009-02-201-1/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch reworks bitmap transport on all platforms. Linux and Mac are switched from serialising bitmaps over the IPC channel to using shared memory. All platforms gain a shared memory mapping cache on the host side. The concept of a TransportDIB (device independent bitmap) is added to encapsulate most of the platform specifics. On Linux, we use SysV shared memory. This is because X shared pixmaps, which predate POSIX SHM, can only use SysV. By using SysV between renderer and browser, we open up the possibility to map the shared memory directly from the renderer to the X server. On Mac, we use POSIX shared memory. However, since this needs filesystem access and the Mac renderer is sandboxed from the filesystem, we add two new messages from renderer -> browser: The first, AllocTransportDIB, synchronously creates a transport DIB in the browser and passes a handle back to the renderer. The second, FreeTransportDIB, asynchronously, notifies the browser that it may close its handle to the shared memory region. On Mac, the shared memory regions are identified by their inode numbers on the wire. This means that the browser must keep handles open to all the allocated shared memory regions (since an inode number is insufficient to map the region). The alternative design is that the renderer passes the file descriptor with each paint operation. Since passing file descriptors is special case in the code, I felt that it would be best to minimise their use. Creating and freeing transport DIBs are relatively rare operations relative to paints and scrolls. On Windows, most of the code remains the same, except that Windows now uses the mapping cache added in this patch. This allows the browser to maintain a shared memory mapping for a transport DIB over several paints. Previously it mapped and unmapped for every operation, causing lots of TLB and VM churn. Review URL: http://codereview.chromium.org/21485 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10071 0039d316-1c4b-4281-b951-d872f2087c98
* POSIX: gfx::NativeViewId and CrossProcessEventagl@chromium.org2009-01-271-5/+3
| | | | | | | | | | | | | | | | | | | Create a couple new typedefs for porting work. Firstly, gfx::NativeViewId is a handle to a platform specific widget in the renderer process. For Windows, this is just a HWND as before. However, in other platforms the ids used in the renderer process will be something else. CrossProcessEvent is the type of a HANDLE to a Windows event object which is used across processes. Since we aren't going to support these sorts of events on non-Windows platforms, this will have to go away at some point. For now, however, this lets us build code without too many ifdefs all over the place. Review URL: http://codereview.chromium.org/18768 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@8756 0039d316-1c4b-4281-b951-d872f2087c98
* Make RenderWidgetHelper portable.brettw@chromium.org2009-01-261-3/+11
| | | | | | Review URL: http://codereview.chromium.org/18802 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@8660 0039d316-1c4b-4281-b951-d872f2087c98
* Move files out of browser and into either renderer_host or tab_contents.brettw@chromium.org2009-01-221-0/+159
This also fixes a crash in the web contents unit test in a commented-out test and re-enable it. Review URL: http://codereview.chromium.org/18504 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@8470 0039d316-1c4b-4281-b951-d872f2087c98