diff options
author | pinkerton@chromium.org <pinkerton@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-03-27 18:43:57 +0000 |
---|---|---|
committer | pinkerton@chromium.org <pinkerton@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-03-27 18:43:57 +0000 |
commit | 702c7d210cbccf936e19811b4a8f389b8dd812ae (patch) | |
tree | be9e4632151da30004f28c2c74fe47293141076e /chrome/common/temp_scaffolding_stubs.cc | |
parent | 6b323787634825c525d1a17f402ad8252d42c924 (diff) | |
download | chromium_src-702c7d210cbccf936e19811b4a8f389b8dd812ae.zip chromium_src-702c7d210cbccf936e19811b4a8f389b8dd812ae.tar.gz chromium_src-702c7d210cbccf936e19811b4a8f389b8dd812ae.tar.bz2 |
Correctly position windows that are detached during a drag, instead of relying on the default window position in the nib. Stub a little more of WindowSizer, but only enough to get drag working. Default new windows to 1024x768.
Review URL: http://codereview.chromium.org/55023
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@12677 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common/temp_scaffolding_stubs.cc')
-rw-r--r-- | chrome/common/temp_scaffolding_stubs.cc | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/chrome/common/temp_scaffolding_stubs.cc b/chrome/common/temp_scaffolding_stubs.cc index 181d4b1..abd26d8 100644 --- a/chrome/common/temp_scaffolding_stubs.cc +++ b/chrome/common/temp_scaffolding_stubs.cc @@ -369,3 +369,16 @@ void DragDownload(const DownloadItem* download, SkBitmap* icon) { } } // namespace download_util + +void WindowSizer::GetBrowserWindowBounds(const std::wstring& app_name, + const gfx::Rect& specified_bounds, + gfx::Rect* window_bounds, + bool* maximized) { + // If we're given a bounds, use it (for things like tearing off tabs during + // drags). If not, make up something reasonable until the rest of the + // WindowSizer infrastructure is in place. + *window_bounds = specified_bounds; + if (specified_bounds.IsEmpty()) { + *window_bounds = gfx::Rect(0, 0, 1024, 768); + } +} |