diff options
author | sky@chromium.org <sky@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-05-26 20:22:26 +0000 |
---|---|---|
committer | sky@chromium.org <sky@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-05-26 20:22:26 +0000 |
commit | 04537be0a183839472a8a3b6422cba17d56ba9b1 (patch) | |
tree | e68330190f2a1d69ba92bde2c9e054ab7d8e7754 /chrome/browser/download/download_util.cc | |
parent | 6463cb2a117dcd866a12becb513cfdba935c16e5 (diff) | |
download | chromium_src-04537be0a183839472a8a3b6422cba17d56ba9b1.zip chromium_src-04537be0a183839472a8a3b6422cba17d56ba9b1.tar.gz chromium_src-04537be0a183839472a8a3b6422cba17d56ba9b1.tar.bz2 |
Gets a couple of download classes to compile on linux. Updates the
views build so that we only include the gtk classes we need.
BUG=none
TEST=none
Review URL: http://codereview.chromium.org/115788
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16899 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/download/download_util.cc')
-rw-r--r-- | chrome/browser/download/download_util.cc | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/chrome/browser/download/download_util.cc b/chrome/browser/download/download_util.cc index df3fb82..e22821a 100644 --- a/chrome/browser/download/download_util.cc +++ b/chrome/browser/download/download_util.cc @@ -22,8 +22,11 @@ #include "third_party/skia/include/core/SkPath.h" #include "third_party/skia/include/core/SkShader.h" -#if defined(OS_WIN) +#if defined(OS_WIN) || defined(TOOLKIT_VIEWS) #include "app/os_exchange_data.h" +#endif + +#if defined(OS_WIN) #include "base/base_drag_source.h" #include "views/drag_utils.h" #endif @@ -66,7 +69,7 @@ SkBitmap* g_foreground_32 = NULL; SkBitmap* g_background_32 = NULL; void PaintDownloadProgress(gfx::Canvas* canvas, -#if defined(OS_WIN) +#if defined(OS_WIN) || defined(TOOLKIT_VIEWS) views::View* containing_view, #endif int origin_x, @@ -96,7 +99,7 @@ void PaintDownloadProgress(gfx::Canvas* canvas, gfx::Rect foreground_bounds(origin_x, origin_y, foreground->width(), foreground->height()); -#if defined(OS_WIN) +#if defined(OS_WIN) || defined(TOOLKIT_VIEWS) // Mirror the positions if necessary. int mirrored_x = containing_view->MirroredLeftPointForRect(background_bounds); background_bounds.set_x(mirrored_x); @@ -165,7 +168,7 @@ void PaintDownloadProgress(gfx::Canvas* canvas, } void PaintDownloadComplete(gfx::Canvas* canvas, -#if defined(OS_WIN) +#if defined(OS_WIN) || defined(TOOLKIT_VIEWS) views::View* containing_view, #endif int origin_x, @@ -183,7 +186,7 @@ void PaintDownloadComplete(gfx::Canvas* canvas, gfx::Rect complete_bounds(origin_x, origin_y, complete->width(), complete->height()); -#if defined(OS_WIN) +#if defined(OS_WIN) || defined(TOOLKIT_VIEWS) // Mirror the positions if necessary. complete_bounds.set_x( containing_view->MirroredLeftPointForRect(complete_bounds)); @@ -230,9 +233,10 @@ int GetBigProgressIconOffset() { return (GetBigProgressIconSize() - kBigIconSize) / 2; } -#if defined(OS_WIN) +#if defined(OS_WIN) || defined(TOOLKIT_VIEWS) // Download dragging void DragDownload(const DownloadItem* download, SkBitmap* icon) { +#if defined(OS_WIN) DCHECK(download); // Set up our OLE machinery @@ -247,6 +251,9 @@ void DragDownload(const DownloadItem* download, SkBitmap* icon) { DWORD effects; DoDragDrop(data.get(), drag_source.get(), DROPEFFECT_COPY | DROPEFFECT_LINK, &effects); +#else + NOTIMPLEMENTED(); +#endif } #endif |